Skip to content

Instantly share code, notes, and snippets.

@d3fz
Last active June 7, 2023 14:36
Show Gist options
  • Save d3fz/ce7913baf14e959fbfb4fce87516921d to your computer and use it in GitHub Desktop.
Save d3fz/ce7913baf14e959fbfb4fce87516921d to your computer and use it in GitHub Desktop.
Surfingkeys Settings
// an example to create a new mapping `ctrl-y`
api.mapkey('ctrl-y', 'Show me the money', function() {
Front.showPopup('a well-known phrase uttered by characters in the 1996 film Jerry Maguire (Escape to close).');
});
api.mapkey('p', '#0enter ephemeral PassThrough mode to temporarily suppress SurfingKeys', function() {
Normal.passThrough(1500);
});
api.Hints.setCharacters('yuiop'); // for right hand
scrollStepSize = 100;
settings.hintAlign = "left";
settings.omnibarMaxResults = "30";
settings.focusFirstCandidate = true;
settings.modeAfterYank = "Normal";
api.iunmap(":");
api.iunmap("t");
api.iunmap(",");
api.iunmap(".");
api.iunmap("b");
api.iunmap("B");
api.iunmap("n");
api.map('q', 'x');
api.map('t', 'T');
api.map(',', 'E');
api.map('.', 'R');
api.map('b', 'B');
api.map('B', 'F');
api.imap('jj', '<Esc>');
// font-family: Input Sans Condensed, Charcoal, sans-serif;
// set theme
settings.theme = `
.sk_theme {
font-family: Hack Regular;
font-size: 12pt;
background: #24272e;
color: #abb2bf;
}
.sk_theme tbody {
color: #fff;
}
.sk_theme input {
color: #d0d0d0;
}
.sk_theme .url {
color: #61afef;
}
.sk_theme .annotation {
color: #56b6c2;
}
.sk_theme .omnibar_highlight {
color: #528bff;
}
.sk_theme .omnibar_timestamp {
color: #e5c07b;
}
.sk_theme .omnibar_visitcount {
color: #98c379;
}
.sk_theme #sk_omnibarSearchResult ul li:nth-child(odd) {
background: #303030;
}
.sk_theme #sk_omnibarSearchResult ul li.focused {
background: #3e4452;
}
#sk_status, #sk_find {
font-size: 20pt;
}`;
const hintsCss =
//"font-size: 12pt; font-family: Sarasa Mono SC, Consolas, Menlo, monospace; border: 0px; color: #f7f7a2; background: initial; background-color: #808080;";
"font-size:11pt;font-family:Consolas,monospace;border:0px";
api.Hints.style(hintsCss);
api.Hints.style(hintsCss, "text");
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment