Adapt src/roff (src/roff/groff)
[s-roff.git] / src / roff / troff / TODO
blobbc4c829302485cc1a1d266479c0f44cbb1363e0b
1 A line prefix request to make e.g. French quotation possible:
3   He said: >> blablablabla
4   >> blablabla blabla  bla
5   >> blabla blabla bla bla
6   >> bla bla bla blablabla
7   >> blabla. <<
9 Give a more helpful error message when the indent is set to a value
10 greater than the line-length.
12 Tracing. This is a pain to implement because requests are responsible
13 for reading their own arguments.
15 Possibly implement -s option (stop every N pages). This functionality
16 would be more appropriate in a postprocessor.
18 Line breaking should be smarter.  In particular, it should be possible
19 to shrink spaces.  Also avoid having a line that's been shrunk a lot
20 next to a line that's been stretched a lot.  The difficulty is to
21 design a mechanism that allows the user complete control over the
22 decision of where to break the line.
24 Provide a mechanism to control the shape of the rag in non-justified
25 text.
27 Add a discretionary break escape sequence. \='...'...'...' like TeX.
29 Think about kerning between characters and spaces. (Need to implement
30 get_breakpoints and split methods for kern_pair_node class.)
32 In troff, if .L > 1 when a diversion is reread in no-fill mode, then
33 extra line-spacing is added on. Groff at the moment treats line-spacing
34 like vertical spacing and doesn't do this. 
36 Suppose \(ch comes from a special font S, and that the current font is
37 R. Suppose that R contains a hyphen character and that S does not.
38 Suppose that the current font is R. Suppose that \(ch is in a word
39 and has a non-zero hyphen-type. Then we ought to be able to hyphenate,
40 but we won't be able to because we will look for the hyphen only in
41 font S and not in font R.
43 Perhaps the current input level should be accessible in a number register.
45 Should \w deal with a newline like \X?
47 Have another look at uses of token::delimiter.  Perhaps we need to
48 distinguish the case where we want to see if a token could start a
49 number, from the case where we want to see if it could occur somewhere
50 in a number expression.
52 Provide a facility like copy thru in pic.
54 Fancier implementation of font families which doesn't group fonts into
55 families purely on the basis of their names.
57 In the DESC file make the number of fonts optional if they are all on
58 one line.
60 Number register to give the diversion level.
62 Time various alternative implementations of scale (both in font.c and
63 number.c). On a sparc it's faster to always do it in floating point.
65 Devise a more compact representation for the hyphenation patterns trie.
67 Have a per-environment parameter to increase letter-spacing.
69 Request to set character height.
71 Request to set character slant.
73 Provide some way to upcase or downcase strings.
75 Support non-uniformly scalable fonts. Perhaps associate a suffix with
76 a particular range of sizes.  eg
77   sizesuffix .display 14-512
78 Then is you ask for R at pointsize 16, groff will first look for
79 R.display and then R.  Probably necessary to be able to specify a
80 separate unitwidth for each sizesuffix (eg. for X).
82 Make it possible to suppress hyphenation on a word-by-word basis.
83 (Perhaps store hyphenation flags in tfont.)
85 Possibly allow multiple simultaneous input line traps.
87 Unpaddable, breakable space escape sequence.
89 Support hanging punctuation.
91 In justified text, if the last line of a paragraph is only a little
92 bit short it might be desirable to justify the line.  Allow the user
93 control over this.
95 The pm request could print where the macro was defined.  Also could
96 optionally print the contents of a macro.
98 Provide some way to round numbers to multiples of the current
99 horizontal or vertical resolution.
101 Better string-processing support (search).
103 Generalized ligatures.
105 Request to remove an environment. (Maintain a count of the references
106 to the environment from the environment table, environment dictionary
107 or environment stack.)
109 Perhaps in the nr request a leading `-' should only be recognized as a
110 decrement when it's at the same input level as the request.
112 Don't ever change a charinfo.  Create new variants instead and chain
113 them together.
115 Unix troff appears to read the first character of a request name in
116 copy mode.  Should we do the same?
118 Number register giving name of end macro.
120 More thorough range checking.
122 Provide syntax for octal and hexadecimal numeric constants.  Perhaps
123 o#100 and x#7f as per Scheme.  Or perhaps PostScript 16#7f.  Ambiguity
124 between whether `c' is treated as digit or scaling indicator.
126 Local variables.