"Fossies" - the Fresh Open Source Software Archive 
Member "xterm-379/unicode/make-precompose.sh" (5 Feb 2007, 682 Bytes) of package /linux/misc/xterm-379.tgz:
As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) Bash source code syntax highlighting (style:
standard) with prefixed line numbers and
code folding option.
Alternatively you can here
view or
download the uninterpreted source code file.
1 #!/bin/sh
2 # $XTermId: make-precompose.sh,v 1.6 2007/02/05 01:06:36 Thomas.Wolff Exp $
3 # $XFree86: xc/programs/xterm/unicode/make-precompose.sh,v 1.4 2005/03/29 04:00:32 tsi Exp $
4
5 cat precompose.c.head | sed -e's/@/$/g'
6
7 # extract canonical decomposition data from UnicodeData.txt,
8 # pad hex values to 5 digits,
9 # sort numerically on base character, then combining character,
10 # then reduce to 4 digits again where possible
11 cut UnicodeData.txt -d ";" -f 1,6 |
12 grep ";[0-9,A-F]" | grep " " |
13 sed -e "s/ /, 0x/;s/^/{ 0x/;s/;/, 0x/;s/$/},/" |
14 sed -e "s,0x\(....\)\([^0-9A-Fa-f]\),0x0\1\2,g" |
15 (sort -k 3 || sort +2) |
16 sed -e "s,0x0\(...[0-9A-Fa-f]\),0x\1,g"
17
18 cat precompose.c.tail