This commit is contained in:
James McDonald
2018-01-09 20:39:32 +01:00
parent d86f2129f0
commit 96eedb5095
64 changed files with 682 additions and 0 deletions
@@ -0,0 +1,39 @@
---
title: Hardcoded GNOMEish composition
author: james
type: post
date: 2012-06-11T16:42:20+00:00
url: /2012/06/hardcoded-gnomeish-composition/
aktt_notify_twitter:
- yes
al2fb_facebook_link_id:
- 658281334_10151014685521335
al2fb_facebook_link_time:
- 2012-06-11T16:42:24+00:00
al2fb_facebook_link_picture:
- post=https://jamesmcdonald.com/?al2fb_image=1
aktt_tweeted:
- 1
dsq_thread_id:
- 3804739886
categories:
- Tech
---
From Ubuntu docs about the Compose key at https://help.ubuntu.com/community/ComposeKey:
> The compose key sequences used by Gnome are derived from the X compose tables of XFree86 version 4.0 with further modifications to provide a Gnome standard for all locales. They are hard coded into the program in source file gtk+-2.10.7/gtk/gtkimcontextsimple.c
Digging into the current Debian gtk+ source verifies this:
`<br />
/* This file contains the table of the compose sequences,<br />
* static const guint16 gtk_compose_seqs_compact[] = {}<br />
* IT is generated from the compose-parse.py script.<br />
*/<br />
#include "gtkimcontextsimpleseqs.h"<br />
`
So they start with the X Input Method layer which has nice unixy text config files (check out /usr/share/X11/locale) and they want to extend it with some extra sequences. What&#8217;s the best way to do that? Clearly snarf what&#8217;s already there, bolt on your own bits and hardcode the lot into your binary.
Well done, chaps.