24a019f1b0211bb9d18562c690f9de25d44eb82e
[pspp-builds.git] / src / output / ChangeLog
1 2007-08-23  Ben Pfaff  <blp@gnu.org>
2
3         Implement journaling.  Bug #17240.
4         
5         * automake.mk (output_sources): Add journal.c, journal.h.
6         
7         * journal.c: New file.
8         
9         * journal.h: New file.
10
11 2007-08-16  Ben Pfaff  <blp@gnu.org>
12
13         * output.c output.h: export function outp_configure_driver_line.
14         * ascii.c: Added an "append" property.
15         
16 2007-08-12  Ben Pfaff  <blp@gnu.org>
17
18         Add support for charts to ASCII driver.  Bug #16364.
19         Thanks to John Darrington for review.
20         
21         * ascii.c (struct ascii_driver_ext): Add chart_type,
22         chart_file_name, chart_cnt members.
23         (ascii_open_driver): Initialize new members.
24         (static array option_tab): Add new options, reorganize slightly.
25         (handle_option): Handle new options.
26         (ascii_submit): New function.
27         (ascii_chart_initialise): Implement.
28         (ascii_chart_finalise): Implement.
29
30         * chart.c (chart_init_separate): New function.
31         (chart_finalise_separate): New function.
32         
33         * dummy-chart.c (chart_init_separate): New function.
34         (chart_finalise_separate): New function.
35
36         * html.c (html_open_driver): Don't free chart_file_name.
37         (html_close_driver): Do free chart_file_name.
38         (handle_option): Only give an error for chart-files options that
39         don't contain "#".
40         (html_initialise_chart): Use new chart_init_separate.
41         (html_finalise_chart): Use new chart_finalise_separate.
42
43 2007-07-25  Ben Pfaff  <blp@gnu.org>
44
45         Allow the user to specify an initialization string to write at the
46         beginning of an ASCII output file.
47         * ascii.c (struct ascii_driver_ext): New member `init'.
48         (ascii_open_driver): Initialize `init'.
49         (ascii_close_driver): Parse `init'.
50         (ascii_open_page): Write `init' to output file.
51
52         * output.c (get_option_token): Fix parsing of octal constants.
53
54 2007-07-25  Ben Pfaff  <blp@gnu.org>
55
56         Make interactive output go to the terminal (bug #17213), by
57         causing the UI to flush output to the user when it prompts for a
58         command.
59
60         * ascii.c (ascii_open_driver): Move the file open into
61         ascii_open_page, so that we can re-open after a flush.
62         (ascii_close_driver): Close file using ascii_flush.
63         (ascii_open_page): Open the output file if it's not already open.
64         Use fn_open so that we can support pipes.
65         (ascii_close_page): Do nothing if output file not open.
66         (ascii_flush): New function.
67         (static var ascii_class): Add ascii_flush.
68
69         * manager.c (som_flush): New function.
70
71         * output.c (outp_flush): New function.
72
73 Tue Feb 20 07:03:48 2007  Ben Pfaff  <blp@gnu.org>
74
75         * html.c: Don't need to include "getlogin_r.h" anymore, because
76         gnulib merged it into <unistd.h>.
77
78 Sun Feb 18 11:20:35 2007  Ben Pfaff  <blp@gnu.org>
79
80         * postscript.c: Add missing _() around message.
81
82 Sun Feb 11 17:59:30 2007  Ben Pfaff  <blp@gnu.org>
83
84         * html.c (html_initialise_chart): Mark `this' parameter UNUSED to
85         account for NO_CHARTS case.
86
87 Sat Feb  3 21:56:46 2007  Ben Pfaff  <blp@gnu.org>
88
89         * table.c (tab_hline): Allow t->nr as y argument, so that we can
90         draw a line below the bottom row of the table.
91
92 Wed Feb  7 21:38:12 2007  Ben Pfaff  <blp@gnu.org>
93
94         * afm.c: Add #include <limits.h>.  Thanks to John McCabe-Dansted
95         <gmatht@gmail.com> for pointing out the need.
96
97 Sun Oct  8 07:09:34 WST 2006 John Darrington <john@darrington.wattle.id.au>
98
99         * table.c (tab_destroy): Freed title, since this is not allocated
100         from the pool.
101
102         * html.c (html_open_driver): Freed chart_file_name.
103
104 Wed Jul 12 21:03:37 2006  Ben Pfaff  <blp@gnu.org>
105
106         * table.c (tab_natural_width): Get rid of warning on empty column,
107         which tended to just trigger false positives because we handle
108         joined cells so badly.  We need a real fix, and the warning is not
109         helpful.
110
111         * table.c (tab_offset): [DEBUGGING] Let row, col arguments be as
112         big as row or column count.
113         
114 Wed Jul 12 20:58:19 2006  Ben Pfaff  <blp@gnu.org>
115
116         * output.c (outp_drivers): [DEBUGGING] Delete unused declaration.
117
118 Sat Jul  1 17:20:03 2006  Ben Pfaff  <blp@gnu.org>
119
120         Make the destination for charts configurable in the HTML driver.
121         Fixes bug #15723, "HTML driver creates .png files insecurely".
122
123         * htmlP.h: (struct html_driver_ext) Add chart_file_name, chart_cnt
124         members.
125         
126         * html.c: (html_open_driver) Initialize new members.
127         (option_tab var) Add "chart-files" option.
128         (handle_option) Parse "chart-files" option.
129         (html_initialise_chart) Name file based on "chart-files" option.
130         
131 Sat Jul  1 22:41:26 2006  Ben Pfaff  <blp@gnu.org>
132
133         Fix bug #16644: Output Driver crashes in DISPLAY VARIABLES.
134         
135         * table.c (tab_create): Don't allocate t->hrh, t->wrv yet, because
136         the table size might change before we're ready to use them.
137         (tabi_table) Allocate them here instead.
138
139 Fri Jun  9 14:42:35 2006  Ben Pfaff  <blp@gnu.org>
140
141         Reform string library.
142         
143         * output.c (init_default_drivers): Update call to
144         configure_driver() to new interface.
145         (get_option_token) Use a modifiable substring in interface instead
146         of a separate position parameter.  Use ss_get_*() functions.
147         (configure_driver) Take and work with substrings.
148         (configure_driver_line) Update call to configure_driver() to new
149         interface.
150         (outp_get_paper_size) Use substrings.
151
152         * output.h (struct outp_class): Change open_driver interface to
153         use substring.  Update all implementations.
154
155         * table.c (text_format): Change to return substring.
156         (tab_title) Use xvasprintf().
157
158         * table.h (struct tab_table): Change title member to char *.
159
160 Thu May 25 18:02:53 WST 2006 John Darrington <john@darrington.wattle.id.au>
161
162         * table.c: Removed redundant extern declaration.
163
164 Sun May 14 14:03:56 2006  Ben Pfaff  <blp@gnu.org>
165
166         * output.c (outp_eject_page): Always make sure that a page is open
167         upon return.
168
169 Sun May 14 13:54:58 2006  Ben Pfaff  <blp@gnu.org>
170
171         * postscript.c: (ps_chart_finalise) Fix format of %%EndDocument
172         comment, which screwed up gv's idea of where one page ended and
173         the next one began.  Thanks to John Darrington for pointing out
174         the bug.
175
176 Sun Apr 16 11:48:25 2006  Ben Pfaff  <blp@gnu.org>
177
178         Start reforming error message support.  In this phase, we get rid
179         of "installation errors" and change all uses of msg() in the
180         output drivers to uses of error() or error_at_line().
181
182         * Removed all inclusion of <libpspp/message.h> in this directory.
183
184         * output.c: Changed all uses of msg() to error() or
185         error_at_line().
186         (outp_read_devices) Maintain line number in int variable instead
187         of "struct file_locator".
188         (tokener) Renamed get_option_token(), rewritten, changed interface.
189         (outp_parse_options) Change `options' argument to type const
190         struct string *.  Rewritten.
191         (configure_driver) Passes a struct string * to ->open_driver()
192         instead of char *.
193         (outp_get_paper_size) Maintain line number in int variable instead
194         of "struct file_locator".  Removed stupid cache.
195
196         * output.h: (struct outp_class) Change `open_driver' function to
197         take const struct string * instead of const char *.  Updated all
198         implementations.
199
200 Mon Apr  3 11:14:38 2006  Ben Pfaff  <blp@gnu.org>
201
202         Rewrite a lot of the output drivers and infrastructure.
203         Started transitioning from msg() to error().
204         Vertical rules in tables now default to putting a small gap
205         between columns, instead of no gap or rule at all.
206         See NEWS for user-visible changes.
207
208         * automake.mk: (output_sources) Add afm.c, afm.h.  Remove font.h,
209         groff-font.c.
210         
211         * afm.c, afm.h: New files.
212
213         * font.h: Removed.
214
215         * groff-font.c: Removed.
216         
217         * ascii.c: Rewrote and simplified.
218
219         * html.c: Ditto.
220
221         * postscript.c: Ditto.
222
223         * output.c: (struct outp_driver_class_list) Move here from
224         output.h.  Remove ref_count member and all references to it.
225         (outp_init) Remove epsf_class references.
226         (init_default_drivers) Use new configure_driver_line() interface.
227         (parse_options) Renamed outp_parse_options(), changed interface.
228         (configure_driver) Changed args from `const char *'s to `const
229         struct string *'s.  Rewrote.  Don't call ->open_global().  Now
230         just calls ->open_driver() instead of ->preopen_driver(),
231         ->option(), ->postopen_driver().
232         (configure_driver_line) Adapt to new configure_driver() interface.
233         (destroy_driver) Don't call ->close_global().
234         (option_cmp) Removed.
235         (outp_match_keyword) Rewrite for simplicity.
236         (outp_open_page) New function.  Changed all equivalent
237         functionality to use this function instead.
238         (outp_close_page) Ditto.
239         (outp_eject_page) Use above functions.
240         (outp_string_width) Add font argument and change all callers to
241         pass one.
242
243         * output.h: (struct rect) Removed.
244         (OUTP_L_*) Name this enumeration "enum outp_line_style".
245         (OUTP_L_SPECIAL) Removed.
246         (struct color) Removed.
247         (OUTP_F_*) Removed.
248         (struct outp_styles) Removed.
249         (OUTP_T_*) Removed.
250         (enum outp_justification) New, containing OUTP_RIGHT, OUTP_LEFT,
251         OUTP_CENTER.
252         (enum outp_font) New, containing OUTP_FIXED, OUTP_PROPORTIONAL,
253         and OUTP_EMPHASIS.
254         (struct outp_text) Replaced `options' member by `font' and
255         `justification'.  Renamed `s' to `string'.  Removed `w', `l'.
256         Updated all usages.
257         (struct outp_class) Removed `magic', `open_global',
258         `close_global', `font_sizes', `preopen_driver', `option',
259         `postopen_driver', `line_horz', `line_vert', `line_intersection',
260         `box', `polyline_begin', `polyline_point', `polyline_end',
261         `text_set_font_by_name', `text_set_font_by_position',
262         `text_set_font_family', `text_get_font_name',
263         `text_get_font_family', `text_set_Size', and `text_get_size'
264         members.  Added `open_driver', `close_driver', `line' members.
265         Changed interface of `open_page', `close_page', `text_metrics',
266         `text_draw' members.  Updated all usages.
267         (struct outp_driver) Rearranged members.  Removed `driver_open',
268         `res', `horiz', `vert', `horiz_line_spacing', `vert_line_spacing'
269         members.
270         (struct outp_option_info) Removed.
271         (struct outp_driver_class_list) Removed.
272         (outp_match_keyword) Changed interface.
273
274         * table.c: (tab_create) Now ignores reallocable argument: tables
275         can always be reallocated.  Use pool_create_container().
276         Initialize vertical rules to UCHAR_MAX.
277         (options_to_font) New function.
278         (tab_destroy) Remove futile assignment.
279         (tab_realloc) Initialize vertical rules to UCHAR_MAX.
280         (text_format) Use xvasprintf() instead of local_alloc().
281         (tab_title) Always format the argument, and drop the option
282         argument.  Change all callers to agree.
283         (tab_natural_width) Adapt to new ->text_metrics() interface.
284         (tab_natural_height) Ditto.
285         (tab_joint_text) Clear rules within the joined cell.  Now
286         necessary because of the default to put spacing between cells.
287         (tab_output_text) Use xvasprintf() instead of local_alloc().
288         Remove special cases for fixed-width font.
289         (rule_to_spacing_type) New function.
290         (tabi_driver) Calculate rule widths manually now that we don't
291         have ->trh or ->trv.  Implement new default for vertical rules.
292         (render_rows) New function.
293         (tabi_render) Rewrite in terms of render_rows() for clarity.
294         (translate_justification) New function.
295         (rule_to_draw_type) New function.
296         (get_hrule) New function.
297         (get_vrule) New function.
298         (render_horz_rule) New function.
299         (render_vert_rule) New function.
300         (render_rule_intersection) New function.
301         (strip_width) New function.
302         (strip_height) New function.
303         (render_cell) New function.
304         (render_strip) Rewrite in terms of new functions.
305
306         * table.h: (TAB_EMPH) New flag.
307         (TAB_FIX) New flag.
308         (TAL_3) Removed.
309         (TAL_GAP) Added.
310         (TAL_SPACING) Removed.
311         (struct tab_table) Members `trh', `hrv', `hr_tot', `vr_tot'
312         removed.
313         [DEBUGGING] (reallocable) Removed.
314         (TAT_FIX) Removed.  All references replaced by TAB_FIX.
315         (TAT_TITLE) Now implies TAB_EMPH.
316                 
317 Thu Mar 30 16:26:56 2006  Ben Pfaff  <blp@gnu.org>
318
319         * output.c: (colon_tokenize) Removed.
320         (configure_driver_line) Rewrote to use ds_separate().  Fixed leak.
321
322 Tue Mar 28 13:50:53 WST 2006 John Darrington <john@darrington.wattle.id.au>
323
324         * html.c, postscript.c, output.c:  Changed to fit the new signature 
325         of fn_interp_vars
326         
327 Sun Mar  5 13:19:32 2006  Ben Pfaff  <blp@gnu.org>
328
329         * postscript.c: (postopen) Fix segfault when the active file has
330         no title.
331
332 Sat Mar  4 13:48:16 2006  Ben Pfaff  <blp@gnu.org>
333
334         We didn't provide a way to define these macros, so obviously
335         there's little demand for them.
336
337         * html.c: Don't test for NO_HTML.
338
339         * postscript.c: Don't test for NO_POSTSCRIPT.
340
341         * output.c: Don't test for either of those.
342
343 Thu Mar  2 08:40:33 WST 2006 John Darrington <john@darrington.wattle.id.au>
344         
345         * Moved files from src directory