|
0b7c8d61
|
2013-02-08T14:32:47
|
|
action: take xkb_mod_set instead of the entire keymap
A couple of modiifer actions need this information, but not the entire
keymap.
Signed-off-by: Ran Benita <ran234@gmail.com>
|
|
18a0ead5
|
2012-09-14T15:17:20
|
|
Rename ACTION_TYPE_LAST to _ACTION_TYPE_NUM_ENTRIES
It's not really "last" per-se, and we use this other format in some
other enums.
Signed-off-by: Ran Benita <ran234@gmail.com>
|
|
0b2506db
|
2012-09-10T19:23:16
|
|
kbproto unentanglement: action types
Signed-off-by: Daniel Stone <daniel@fooishbar.org>
|
|
af2a8b3a
|
2012-09-02T21:45:42
|
|
Unify some string tables from xkbcomp, text and keymap-dump
We move the LookupEntry struct from expr.h to text.h, along with most of
the lookup tables. This makes them available everywhere.
Looking up a value in the LookupEntry format is slower than direct index
mapping, but it allows multiple names per value (with the canonical one
being first) and "all"- and "none"-type masks. These functions are not
used anywhere efficiency matters.
Signed-off-by: Ran Benita <ran234@gmail.com>
|
|
87bfd973
|
2012-09-02T11:29:31
|
|
action: keep array of default actions, instead of list of changes
The implementation of changing the default properties of actions, e.g. a
statements such as (from test/data/compat/basic):
setMods.clearLocks= True;
latchMods.clearLocks= True;
latchMods.latchToLock= True;
works by keeping a list of ActionInfo's, each containing the neccesary
info from each statement, and then when some action comes up (e.g. in an
interpret statment) it goes through the list, and applies the relevent
ActionInfo's to the newly-constructed xkb_action.
Instead of doing this, we add a struct ActionsInfo, which contains an
array of xkb_actions, one for each type. When a default changing
statement appears, we change the action in the array; when a new action
comes up, we just copy from the array. This is simpler to figure out,
and pretty straightforward.
Signed-off-by: Ran Benita <ran234@gmail.com>
|
|
e9aa84f3
|
2012-08-14T15:06:11
|
|
compat: small changes
Signed-off-by: Ran Benita <ran234@gmail.com>
|
|
79a2cc09
|
2012-08-11T11:54:05
|
|
action: convert action field type to enum
We can also hide the ActionInfo definition inside action.c.
Signed-off-by: Ran Benita <ran234@gmail.com>
|
|
cdc228ea
|
2012-08-13T11:00:43
|
|
Organize xkbcomp/ header files
Various non-functional changes:
- Re-add keycodes.h and move some stuff there.
- Add parser-priv.h for internal bison/flex stuff.
- Don't include headers from other headers, such that file dependencies
are immediate in each file.
- Rename xkbcomp.h -> ast.h, parseutils.{c,h} -> ast-build.{c,h}
- Rename path.{c,h} -> include.{c,h}
- Rename keytypes.c -> types.c
- Make the naming of XkbFile-related functions more consistent.
- Move xkb_map_{new,ref,unref} to map.c.
- Remove most extern keyword from function declarations, it's just
noise (XKB_EXPORT is what's important here).
- Append XKBCOMP_ to include guards.
- Shuffle some code around to make all of this work.
Splitting this would be a headache..
Signed-off-by: Ran Benita <ran234@gmail.com>
|
|
4c34bda1
|
2012-08-10T22:38:07
|
|
action: get rid of xkb_any_action
And use union xkb_action instead. We add xkb_private_action, which is
the same as xkb_any_action, but only used where the intention is clear.
This should take care of whatever sizing changes the action struct might
have.
Signed-off-by: Ran Benita <ran234@gmail.com>
|
|
87dff888
|
2012-08-10T18:14:35
|
|
Store actions inside struct xkb_key
Cuts out a lot of useless redirection and space.
Signed-off-by: Ran Benita <ran234@gmail.com>
|
|
74be1762
|
2012-07-23T21:30:28
|
|
Remove alloc.{c,h}
These functions are more appropriate elsewhere now.
Signed-off-by: Ran Benita <ran234@gmail.com>
|
|
112cccb1
|
2012-07-23T16:03:34
|
|
Some atom related optimizations
We often get a strdup'd string, just to pass it over the atom_intern and
then immediately free it. But atom_intern then strdup's it again (if
it's not interned already); so instead we can have the interning "steal"
the memory instead of allocing a new one and freeing the old one. This
is done by a new xkb_atom_steal function.
It also turns out, that every time we strdup an atom, we don't actually
modify it afterwards. Since we are guaranteed that the atom table will
live as long as the context, we can just use xkb_atom_text instead. This
removes a some more dynamic allocations.
For this change we had to remove the ability to append two strings, e.g.
"foo" + "bar" -> "foobar"
which is only possible with string literals. This is unused and quite
useless for our purposes.
xkb_atom_strdup is left unused, as it may still be useful.
Running rulescomp in valgrind, Before:
==7907== total heap usage: 173,698 allocs, 173,698 frees, 9,775,973 bytes allocated
After:
==6348== total heap usage: 168,403 allocs, 168,403 frees, 9,732,648 bytes allocated
Signed-off-by: Ran Benita <ran234@gmail.com>
|
|
9308a460
|
2012-07-17T10:20:15
|
|
Run source tree through uncrustify
.uncrustify.cfg committed for future reference also, but had to manually
fix up a few things: it really likes justifying struct initialisers.
Signed-off-by: Daniel Stone <daniel@fooishbar.org>
|
|
38cb6390
|
2012-05-09T15:15:30
|
|
Change all 'xkb' xkb_keymap names to 'keymap'
To make it a bit more clear what it actually is.
Signed-off-by: Daniel Stone <daniel@fooishbar.org>
|
|
33273304
|
2012-05-08T13:57:07
|
|
Rename xkbcomp/misc.h to xkbcomp-priv.h and use it
The include dependencies were quite convoluted, where you change the
order and get a ton of errors. Instead, change one file to act as the
internal interface for the xkbcomp files, and make every file use it.
Also drop the pointless "xkb" prefix to file names.
Signed-off-by: Ran Benita <ran234@gmail.com>
|
|
12b3495d
|
2012-04-11T01:55:50
|
|
Remove unused 'which' and 'merge' arguments
Signed-off-by: Ran Benita <ran234@gmail.com>
[daniels: Updated for xkb_desc -> xkb_keymap changes.]
|
|
a39ed85f
|
2012-04-05T11:24:39
|
|
Fix formatting in xkbcomp headers
Signed-off-by: Ran Benita <ran234@gmail.com>
[daniels: Fixed for xkb_desc -> xkb_keymap change.]
|
|
ef88c7ef
|
2012-04-03T15:14:16
|
|
Rename xkb_desc to xkb_keymap
struct xkb_desc was just a hangover from the old XkbDescRec, which isn't
a very descriptive name.
Signed-off-by: Daniel Stone <daniel@fooishbar.org>
|
|
eb738b13
|
2012-03-02T17:40:19
|
|
Constify global tables
Signed-off-by: Ran Benita <ran234@gmail.com>
|
|
73ca959d
|
2010-09-27T16:05:52
|
|
Dead code removal and static markup
Signed-off-by: Adam Jackson <ajax@redhat.com>
|
|
9f602686
|
2010-07-01T14:35:24
|
|
Pull in enough structs and defines from XKBstr.h to only need XKB.h
We want to move away from sharing implementation structs and let libX11
and libxkbcommon use each their own set of structs.
|
|
9258cc3d
|
2010-06-30T13:31:21
|
|
Rename Xkbc*Action to struct xkb_*_action
|
|
15b0db54
|
2010-06-17T05:56:08
|
|
Copy in XkbCompatMapRec and XkbSymInterpretRec
These contain actions, so transition them ahead to XkbcAction and move
them into XKBcommon.h.
Signed-off-by: Daniel Stone <daniel@fooishbar.org>
|
|
5c910623
|
2009-04-04T09:19:51
|
|
Remove trailing spaces in source files
|
|
37769b5a
|
2009-03-27T20:01:32
|
|
libxkbcomp: s/XkbDescPtr/XkbcDescPtr/
We need to use the keyboard description structure from XKBcommon.h since
it doesn't have the Display field.
|
|
0c1bbb05
|
2009-03-27T06:55:32
|
|
Import xkbcomp sources for CompileKeymap
A copy of the xkbcomp sources (except the frontend) have been copied in
to provide a means to compile a XkbDescPtr. This definitely doesn't
build or do the right thing yet.
|