1
0
mirror of git://git.suckless.org/svkbd synced 2024-12-18 04:04:44 +00:00
Commit Graph

159 Commits

Author SHA1 Message Date
Hiltjo Posthuma
faed34dbcf bump version to 0.4.2 2024-11-26 18:30:20 +01:00
hazardchem
0e53d9d1a0 Reducing xspacing and yspacing to 1 so touchscreen users have less mistyping.
Signed-off-by: hazardchem <hazardchem@disroot.org>
2024-10-27 12:14:39 +01:00
norayr chilingarian
92795b2a0a fix uppercase in armenian (and perhaps some other) layouts
"This patch fixes uppercase in armenian (and perhaps some other) layouts. svkbd
was previously registering a key in one modification (xorg accepts up to 4
modifications). with this patch svkbd registers 2 modifications - upper and
lower case. function tmp_remap changed in a way that if the key is not found in
a current layout, it is temporary added to it. for cyrillic layout uppercase
(when shift is pressed) letters were showing anyway, because those are somehow
found (modified) by xorg. but for armenian layout that did not work. now works."

Patch by նորայր <norayr@arnet.am>
2023-12-13 19:10:08 +01:00
Hiltjo Posthuma
ff704d5d1e update LICENSE 2023-02-05 11:26:58 +01:00
Norayr Chilingarian
7fc78a0b44 dvorak layout 2023-02-05 11:25:58 +01:00
Hiltjo Posthuma
3dfb00ccf8 fix comment style 2023-02-05 11:25:46 +01:00
Norayr Chilingarian
c247720ae4 armenian layout 2023-01-29 17:33:13 +01:00
Hiltjo Posthuma
38faf1cc8a bump version to 0.4.1 2022-01-07 12:38:18 +01:00
Justin Torres
5dd14703ed Fix color scheme editing on smiley with Xresources
Fixes a small oversight that was preventing the colors of the smiley on q from changing with Xresources.

Signed-off-by: Maarten van Gompel <proycon@anaproy.nl>
2021-10-09 10:29:10 +02:00
Max Schillinger
4061bacc1d create layout-dependent object files
When you build svkbd with different layouts, you get one binary per
layout but all binaries are identical:

    $ make LAYOUT=mobile-plain
    $ make LAYOUT=mobile-simple
    $ diff -s svkbd-mobile-plain svkbd-mobile-simple
    Files svkbd-mobile-plain and svkbd-mobile-simple are identical

The problem is that svkbd.o from the first build is being reused in the
second build.

This commit changes the Makefile to create layout-dependent object files
like svkbd-mobile-plain.o and svkbd-mobile-simple.o (instead of a shared
svkbd.o).
2021-10-01 12:32:38 +02:00
Страхиња Радић
0f07238b53 Add a Serbian layout: layout.sr.h 2021-08-02 18:20:38 +02:00
Hiltjo Posthuma
6ffe71a5f6 bump version to 0.4 2021-07-30 16:50:14 +02:00
Hiltjo Posthuma
d9dcf0d113 config.mk: fix version printing for -v 2021-07-30 16:49:57 +02:00
Maarten van Gompel
4a511a6cfb minor update for emoji overlay on Q: simpler glyph
I picked a simpler glyph because the other might be more likely to not be
present in a font.
2021-07-20 11:01:01 +02:00
Hiltjo Posthuma
6a14319331 change comment-style in .c file 2021-07-12 12:51:52 +02:00
Maarten van Gompel
378a1c8b30 made the Q key double as a trigger for the emoji overlay in the default mobile-intl layout
This makes the emoji overlay accessible without sacrificing an extra key.
There are (afaik) no languages with diacritics on the Q anyway and it's
the first letter key.

A small emoji will show as 2nd label on the keycap as a hint, the caveat
being that the hint applies to a long press rather than a shift-press as
with most 2nd labels, but better than no hint at all.
2021-07-12 12:34:10 +02:00
Maarten van Gompel
3cff4547c5 code cleanup in overlay definitions (removed empty lines comments) 2021-07-12 12:34:03 +02:00
Maarten van Gompel
b053404199 moved backspace key down in dialer layer (mobile-intl and simple layout), for more consistency with other layers 2021-07-12 12:33:55 +02:00
Maarten van Gompel
b5775349f6 minor documentation update 2021-07-12 12:33:50 +02:00
Maarten van Gompel
2164466746 protection against segfault if overlay has more keys than the keyboard itself 2021-07-12 12:33:44 +02:00
Maarten van Gompel
b70948b74c exclude certain modifier keys and basic keys from being overlayed
This ensures that modifiers like shift/ctrl can be correctly used with the overlay.
2021-07-12 12:33:39 +02:00
Maarten van Gompel
e2828d4f7a added missing e caron to overlay in international and simple layouts (e.g. for czech) 2021-07-12 12:33:32 +02:00
Hiltjo Posthuma
4c9182636c no need to initialize these variables here 2021-07-03 11:45:15 +02:00
Hiltjo Posthuma
2a2acdacaa small code-style changes 2021-07-03 11:45:05 +02:00
Hiltjo Posthuma
81c96cec89 check key for NULL dereference, just in case
This matches the check pattern in other parts of the code.
2021-07-03 11:44:18 +02:00
Hiltjo Posthuma
fd01322564 adjust other layouts for the second label change
From the commit:

	commit d06db9eb4f
	Author: Maarten van Gompel <proycon@anaproy.nl>
	Date:   Sat Mar 6 16:30:44 2021 +0100

	    Added a second key label for the shift-activated symbols
2021-07-03 11:30:53 +02:00
Sebastian LaVine
e2dff73599 Fix broken key definitions in layout.en.h
There were two problems with this file.

First, there were commas missing from the definitions for XK_7, XK_0,
XK_minus, and XK_plus. This prevented svkbd from even compiling.

Secondly, XK_Return was misdefined. This resulted in an immediate
segmentation fault upon loading the program.
2021-07-03 11:02:50 +02:00
Hiltjo Posthuma
34e5659db8 remove unused variable 2021-06-13 23:19:45 +02:00
Maarten van Gompel
5491251610 added an additional minimal mobile layer 2021-06-13 23:15:46 +02:00
Maarten van Gompel
a5cb7d53ce increase spacing, set scheme for window, make window render faster by removing unnecessary map requests to X 2021-06-13 23:15:39 +02:00
Maarten van Gompel
2a84ae50f9 adding dead spacing between keys to prevent misclicks and adapting keyboard layout to a less rigid grid (all aimed to reduce typos) 2021-06-13 23:15:32 +02:00
Hiltjo Posthuma
2306b8eb40 remove unneeded initialization to zero
This removes a warning when compiling with -Wall (tested with clang 11.1.0).
2021-06-13 22:35:16 +02:00
silver
34530800bb Fix error in >1 wide key width calc, also 2021
Signed-off-by: Maarten van Gompel <proycon@anaproy.nl>
2021-06-13 22:33:11 +02:00
Max Schillinger
42380f62eb allow neutralizing a key modifier by applying the same modifier again
svkbd allows you to create keys for symbols of the second (=shift) layer by defining them with a modifier included, like:

    { "|", "|", XK_backslash, 1, XK_Shift_L },

This key creates a pipe symbol by sending shift + backslash. But unfortunately, this way you can't emit get the original symbol (backslash) anymore. So you still need a separate key for typing a backslash, wasting precious space on the screen.

The appended patch fixes this by allowing to neutralize the shift by tapping this key with shift. It works both by tapping first shift, then the pipe key on the on-screen keyboard, or by clicking the pipe key with the middle mouse button (assuming XK_Shift_L is set as the button 2 mod).

This way you can create a "flipped" backslash/pipe key:

    { "|", "\\", XK_backslash, 1, XK_Shift_L },

This patch works equally for AltGr symbols in a `de`-based layout. For example:

    { "~", "+", XK_plus, 1, XK_ISO_Level3_Shift },

(In the German QWERTZ layout, you enter "~" with AltGr-"+".)

Best regards,
Max

Signed-off-by: Maarten van Gompel <proycon@anaproy.nl>
2021-06-13 22:33:03 +02:00
Hiltjo Posthuma
b25e55e462 bump version to 0.3
... and change 0.3.0 to be consistent to the 0.2 and 0.1 release.
2021-03-28 22:54:23 +02:00
Stacy Harper
1d5e9346e8 Add missing keys on lazy layers
As I used it, it really feels like ctrl and alt should be accessible
Esc now replace shift on symbol page (as shift is useless here anyway)
As we now got keys on the two first layers, I removed the smart
old layer.

Signed-off-by: Stacy Harper <contact@stacyharper.net>
Signed-off-by: Maarten van Gompel <proycon@anaproy.nl>
2021-03-28 19:08:49 +02:00
Hiltjo Posthuma
4c4a085580 code-style 2021-03-28 15:24:42 +02:00
Hiltjo Posthuma
d509e189d4 usage already exits, remove exit(2)
This now exits with the same status 1.
Document exit status in the man page.
2021-03-28 15:19:38 +02:00
Hiltjo Posthuma
d81fe4c879 bump LICENSE year 2021-03-28 15:13:04 +02:00
Hiltjo Posthuma
c91cf4a12a rm unused variables 2021-03-28 15:12:30 +02:00
Hiltjo Posthuma
1cc5f87511 usage: add -g information entry and fix newline after -H option 2021-03-28 15:10:40 +02:00
Hiltjo Posthuma
d6026943d3 improve command-line parsing, fix crash with -fn without argument
Print the usage information instead of silently continuing.
On an invalid argument print the invalid argument and usage.
2021-03-28 15:05:56 +02:00
Hiltjo Posthuma
55de8b5184 comment style 2021-03-28 15:03:09 +02:00
Hiltjo Posthuma
7c06a0caf5 code-style changes 2021-03-28 15:02:25 +02:00
Hiltjo Posthuma
8f6a7b5e42 use sizeof(buffer) instead of hardcoded 32 2021-03-28 14:58:19 +02:00
Hiltjo Posthuma
4b5a61b275 add check for debug flag in printdbg() function itself 2021-03-28 14:56:05 +02:00
Hiltjo Posthuma
7980cb5f51 estrdup errors out, so remove the condition 2021-03-28 14:52:03 +02:00
Hiltjo Posthuma
9c492b6913 some code-style changes 2021-03-28 14:51:00 +02:00
Hiltjo Posthuma
ea4b058833 fix unnecesary c99-ism, fixes compilation on OpenBSD using gcc 2021-03-28 14:42:38 +02:00
Hiltjo Posthuma
d19a80dfe5 put estrdup in util and use die() instead of BSD err() 2021-03-28 14:41:32 +02:00