~ubuntu-branches/ubuntu/hardy/ghostscript/hardy

« back to all changes in this revision

Viewing changes to examples/cjk/article9.ps

  • Committer: Bazaar Package Importer
  • Author(s): Till Kamppeter
  • Date: 2007-11-22 12:17:43 UTC
  • mfrom: (1.1.7 upstream)
  • Revision ID: james.westby@ubuntu.com-20071122121743-cd70s3ypq0r243mp
Tags: 8.61.dfsg.1-0ubtuntu1
* New upstream release
  o Final 8.61 release
* debian/patches/09_ijs_krgb_support.dpatch: Adapted to upstream changes.
* debian/rules: Updated CUPS-related variables for "make install" calls.
* debian/rules: Remove /usr/include/ghostscript from the ghostscript
  package, they go into lings-dev.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
%!PS-Adobe-2.0
2
 
%
3
 
% Article 9 of the Constitution of Japan 
4
 
% written in vertical direction using ...
5
 
%       Fonts:
6
 
%               Ryumin-Light-V, GothicBBB-Medium-V
7
 
%       Operators for characters:
8
 
%               show, widthshow, ashow, stringwidth, charpath, cshow
9
 
 
10
 
% (lib/cjkv/cjk_ttf.ps) runlibfile
11
 
% (lib/cjkv/cjkfnmap.ps) runlibfile
12
 
% /Ryumin-Light      (Resource/FreeTT/sazanami-mincho.ttf) .openttcidfont /CIDFont defineresource pop
13
 
% /GothicBBB-Medium  (Resource/FreeTT/sazanami-gothic.ttf) .openttcidfont /CIDFont defineresource pop
14
 
 
15
 
 
16
 
% constants
17
 
 
18
 
/RIGHT  550 def
19
 
/WIDTH  500 def
20
 
/TOP    750 def
21
 
/HEIGHT 700 def
22
 
/SIZE    20 def
23
 
/MARGIN  40 def
24
 
 
25
 
% utility operators
26
 
 
27
 
/GOTHIC { /GothicBBB-Medium-V findfont exch dup
28
 
          /FONTSIZE exch def scalefont setfont } def
29
 
/RYUMIN { /Ryumin-Light-V findfont exch dup
30
 
          /FONTSIZE exch def scalefont setfont } def
31
 
/NEXTLINE { currentpoint pop FONTSIZE 1.8 mul sub TOP MARGIN sub moveto } def
32
 
 
33
 
/MARU { dup gsave false charpath flattenpath pathbbox grestore
34
 
        /ury exch def /urx exch def /lly exch def /llx exch def
35
 
        gsave llx urx add 2 div lly ury add 2 div translate 
36
 
        urx llx sub ury lly sub 2 copy gt { pop }{ exch pop }ifelse 
37
 
        1.2 mul dup scale 0 setlinewidth
38
 
        0.5 0 moveto 0 0 0.5 0 360 arc stroke grestore show } def
39
 
/STRLEN { 0 exch { pop pop pop 1 add } exch cshow } def
40
 
/JUSTIFY { dup STRLEN 1 sub 1 index stringwidth exch pop 
41
 
           currentpoint exch pop add TOP HEIGHT MARGIN sub sub sub
42
 
           exch div neg 0 exch 3 -1 roll ashow } def
43
 
 
44
 
% initialize
45
 
 
46
 
RIGHT TOP moveto 0 HEIGHT neg rlineto WIDTH neg 0 rlineto 0 HEIGHT rlineto
47
 
closepath stroke
48
 
 
49
 
RIGHT MARGIN sub TOP MARGIN sub moveto
50
 
 
51
 
% title
52
 
 
53
 
SIZE 2 mul GOTHIC
54
 
<2121467C4B5C3971377B4B21> show
55
 
NEXTLINE
56
 
 
57
 
% chapter
58
 
 
59
 
SIZE 1.5 mul GOTHIC
60
 
<21212121426846733E4F2121> show
61
 
 
62
 
SIZE 1.5 mul RYUMIN
63
 
<406F4168244E4A7C347E> show
64
 
NEXTLINE
65
 
 
66
 
% abstract
67
 
 
68
 
SIZE GOTHIC
69
 
0 SIZE 2 div 16#2122 <2121214C406F4168244E4A7C347E2122406F4E4F244E49544A5D3B7D
70
 
21223872406F3822244E485D4727214D> widthshow
71
 
NEXTLINE
72
 
 
73
 
% sentence
74
 
 
75
 
SIZE GOTHIC
76
 
<426836653E72> show
77
 
SIZE RYUMIN
78
 
<2331> MARU
79
 
<2121467C4B5C39714C31244F212240353541244843613D7824723470443424482439246B39713A
80
 
5D> JUSTIFY
81
 
NEXTLINE
82
 
 
83
 
<4A3F4F422472403F3C42244B347535612437212239713822244E482F4630243F246B406F416824
84
 
48212249704E4F244B2468246B> JUSTIFY
85
 
NEXTLINE
86
 
 
87
 
<305233454B74244F49704E4F244E39543B48244F212239713A5D4A364168247232723768243924
88
 
6B3C6A434A244824372446> JUSTIFY
89
 
NEXTLINE
90
 
 
91
 
<244F2122314A3557244B2433246C24724A7C347E2439246B2123> show
92
 
NEXTLINE
93
 
 
94
 
<2332> MARU
95
 
<212141303960244E4C5C452A247243232439246B243F246121224E26332436753733243D244E42
96
 
3E244E406F4E4F> JUSTIFY
97
 
NEXTLINE
98
 
 
99
 
<244F21222433246C24724A5D3B7D2437244A242421233971244E3872406F3822244F2122243324
100
 
6C247247272461244A24242123> show
101
 
NEXTLINE
102
 
 
103
 
showpage