Skip to content

Instantly share code, notes, and snippets.

@dharmx
dharmx / eww.scss
Last active May 19, 2022 13:15
Sample eww volume slider demo [Pulse].
* {
all: unset;
font-family: "Cooper Hewitt";
}
box {
padding: 0.5em;
}
scale highlight {
@dharmx
dharmx / eww.yuck
Created May 21, 2022 09:51
EWW current window name example.
(deflisten node_events "./loop.zsh")
(defwindow test :geometry
(geometry :anchor "center" :width "500px" :height "50px")
(window-test))
(defwidget window-test [] (box :orientation "v" (label :text node_events)))
;; vim:ft=yuck
@dharmx
dharmx / eww.scss
Last active May 22, 2022 17:07
EWW box image example.
box box {
background-image: url("https://runt-of-the-web.com/wordpress/wp-content/uploads/2013/05/shibe-meme-blazed.jpg");
border-radius: 20%;
color: red;
font-size: 30;
font-weight: bolder;
background-repeat: no-repeat;
}
// vim:ft=scss
@dharmx
dharmx / node.c
Created September 21, 2022 12:11
A node of a BST
#include <stdio.h>
typedef struct node_t node_t;
struct node_t {
int data;
node_t* left;
node_t* right;
};
int
@dharmx
dharmx / xkb.c
Last active September 27, 2022 19:18
xkb indicator logger
/* compile command: cc -O3 --std=c11 -pedantic -Wall xkb.c -o xkb -lX11 -lXi */
/* Headers and Defines {{{*/
#include <X11/XKBlib.h>
#include <getopt.h>
#include <stdio.h>
#include <stdlib.h>
#define HELP_MESSAGE \
@dharmx
dharmx / THEMES.md
Last active December 26, 2022 14:49
An exhaustive list of colorschemes.

LIST OF COLORSCHEMES

This is a generated themes list so, errors or, typos may exist. They are highly unlikely that they will be fixed. It is recommended to visit the source if you want ful clarity.

Themes are fetched from nvim-colo.

The 3024 Dark theme

@dharmx
dharmx / eww.scss
Created September 16, 2022 21:42
EWW GTK3 Calendar.
* { all: unset; }
tooltip {
font-size: 2em;
background-color: #7BB0DF;
color: #24292E;
}
calendar {
background: #0C0F12;
@dharmx
dharmx / eww.yuck
Last active July 25, 2023 08:11
Handle keys only when EWW window is open.
(defwindow window :windowtype "normal" :wm-ignore true
:geometry (geometry :anchor "center" :y 100 :width "10%" :height "10%")
(key))
(deflisten log "./key.sh")
(defwidget key[] "This prints nohing. '${log}'")
;; vim:filetype=yuck
* { all: unset; }
label {
font-family: Phosphor, Dosis;
font-size: 4em;
}
@dharmx
dharmx / .zshrc
Created June 23, 2022 18:23
Monolithic .zshrc file that uses zplug.
ZDOTDIR="$HOME"
[ -f "$HOME/.cargo/env" ] && source "$HOME/.cargo/env"
# Colors
# black
foreground='#d4d4d5'
background='#101317'
color0='#171c21'