]> git.lyx.org Git - lyx.git/blob - src/graphics/ChangeLog
Asymptotic approach to a well-designed graphics loader.
[lyx.git] / src / graphics / ChangeLog
1 2002-06-28  Angus Leeming  <leeming@lyx.org>
2
3         * GraphicsCacheItem.[Ch]: refactor some of the more convoluted logic
4         by moving those SignalPtrs into the grfx::Image and grfx::Converter
5         classes where they really belong.
6         Use the Pimpl idiom to hide the class internals from public view.
7
8         * GraphicsTypes: remove the typedefs, leaving only the enums.
9
10         * GraphicsImage.h: now has a finishedLoading signal, as opposed to being
11         passed a reference to one in the load() method.
12
13         * GraphicsConverter.[Ch]: totally refactored. An instance of
14         grfx::Converter now represents a single conversion process.
15         Thus grfx::CachItem now has a grfx::Converter * that is set when the
16         conversion is initiated and destroyed on completion.
17         
18         * GraphicsCache.[Ch]:
19         * GraphicsCacheItem.[Ch]:
20         * GraphicsConverter.[Ch]:
21         * GraphicsLoader.[Ch]: use the Pimpl idiom to hide the class internals
22         from public view.
23         Note that I have done this only after making the above changes,
24         so not only should we have a clean, minimal and well documented
25         interface to these classes in the header files, but the class internals
26         should be much clearer too.
27         
28         * Renamed classes
29         grfx::GCache -> grfx::Cache,
30         grfx::GCacheItem -> grfx::CacheItem,
31         grfx::GConverter -> grfx::Converter,
32         grfx::GImage -> grfx::Image,
33         grfx::GImageXPM -> grfx::ImageXPM,
34         grfx::GParams -> grfx::Params.
35
36 2002-06-26  Angus Leeming  <leeming@lyx.org>
37
38         * GraphicsLoader.[Ch]: use boost::scoped_ptr in preference to
39         std::auto_ptr. Define an empty Loader d-tor out-of-line to ensure it
40         compiles.
41
42 2002-06-26  Angus Leeming  <leeming@lyx.org>
43
44         * GraphicsTypes.h: add "Ready" to the ImageStatus enum.
45         move the DisplayType enum out of grfx::GParams to here.
46
47         * GraphicsCacheItem.h: re-write preliminary description to reflect
48         current reality.
49
50         * GraphicsParams.[Ch]:
51         * GraphicsImageXPM.C (load, setPixmap): changes aassociated with moving
52         grfx::DisplayType out of grfx::GParams.
53
54         * GraphicsLoader.[Ch]: new files. Factor out the image loading stuff
55         that was in frontends/screen.C and insets/insetgraphics.C into a
56         single, easy-to-use class.
57
58         * Makefile.am: add these files.
59
60 2002-06-25  Angus Leeming  <leeming@lyx.org>
61
62         * GraphicsCache.[Ch]:
63         * GraphicsCacheItem.[Ch]:
64         * GraphicsTypes.h: rewrite the graphics cache to just load a graphics
65         file into memory. The cache no longer controls the generation of the
66         pixmap. Instead, it just emits a signal when the loading status of an
67         image changes.
68         The cache no longer stores InsetGraphics pointers and nor does it
69         assume responsibility for modifying an image (scaling, rotating etc).
70         Instead, that must now be performed elsewhere.
71
72 2002-06-19  Angus Leeming  <leeming@lyx.org>
73
74         * GraphicsConverter.C: add using std::endl directive.
75
76 2002-06-17  Herbert Voss  <voss@lyx.org>
77
78         * GraphicsCachItem.C: (findTargetFormat)return xpm-format as a 
79         default when nothing different was found
80         (convertToDisplayFormat): handle zipped files in the right way and 
81         choose always convert as a default converter when no other 
82         userdefined was found
83         
84         * GraphicsConverter.C: add more lyxerr comments and choose
85         convert when no other userdefined converter was found
86                 
87 2002-06-10  Herbert Voss  <voss@lyx.org>
88
89         * GraphicsImageXPM.C (convertTo7chars): get another special color
90         format from convert work in the right way
91
92 2002-06-12  John Levon  <moz@compsoc.man.ac.uk>
93
94         * GraphicsCache.C: use right colormap incantation
95  
96 2002-06-12  John Levon  <moz@compsoc.man.ac.uk>
97
98         * GraphicsCache.C: use lyx_gui namespace
99
100         * GraphicsImageXPM.C: back down to using xforms
101           directly again
102  
103 2002-06-07  Angus Leeming  <leeming@lyx.org>
104
105         Fixes needed to compile with Compaq cxx 6.5.
106         * GraphicsConverter.h: forward declare class ConvProcess.
107
108         * GraphicsImageXPM.C: 
109         all c-library variables have been moved into namespace std.
110         Wrap using std::xyz declarations inside a #ifndef CXX_GLOBAL_CSTD block.
111
112 2002-06-06  Angus Leeming  <a.leeming@ic.ac.uk>
113
114         * GraphicsImageXPM.C (rotate): rotate in the same sense as xdvi!
115
116 2002-05-30  Lars Gullik Bjønnes  <larsbj@birdstep.com>
117
118         * GraphicsImageXPM.C: SigC to boot::signals changes.
119         (newImage): fix () bug when using new.
120
121 2002-05-29  Lars Gullik Bjønnes  <larsbj@birdstep.com>
122
123         * switch from SigC signals to boost::signals.
124
125 2002-05-29  André Pönitz <poenitz@gmx.net>
126
127         * GraphicsParam.C: remove unneeded #include, move vomment
128
129 2002-05-28  André Pönitz <poenitz@gmx.net>
130
131         * GraphicsParam.[Ch]: move inset related stuff to inset/insetgraphics
132
133 2002-05-24  John Levon  <moz@compsoc.man.ac.uk>
134
135         * GraphicsImageXPM.C: ColorHandler moved
136
137 2002-05-24  Juergen Vigna  <jug@sad.it>
138
139         * GraphicsCache.h:
140         * GraphicsImage.h: include LString.h first.
141
142 2002-05-22  Lars Gullik Bjønnes  <larsbj@birdstep.com>
143
144         * GraphicsCacheItem.h: use more specific smart_ptr header.
145         * GraphicsTypes.h: ditto
146         * GraphicsImage.h: ditto
147         * GraphicsConverter.h: ditto
148
149 2002-04-28  John Levon  <moz@compsoc.man.ac.uk>
150
151         * GraphicsImageXPM.C: understand convert's use of "opaque"
152           as a colour name
153
154 2002-04-19  Marco Morandini <morandini@aero.polimi.it>
155
156         * GraphicsCache.[Ch] (loadableFormats): new method. A wrapper for
157         GImage::loadableFormats() that ensures that the signal is connected
158         to the derived class' method.
159
160 2002-04-18  Lars Gullik Bjønnes  <larsbj@birdstep.com>
161
162         * GraphicsImageXPM.C (convertTo7chars): drop all conversions and
163         only work on the string.
164
165 2002-04-17  Angus Leeming  <a.leeming@ic.ac.uk>
166
167         * GraphicsImageXPM.C (Data::reset): Fix the loading of xpm files by
168         the simple image loader when it encounters colour strings like
169         #rrrrggggbbbb.
170
171 2002-04-16  Angus Leeming  <a.leeming@ic.ac.uk>
172
173         * GraphicsCacheItem.C (convertToDisplayFormat):
174         * GraphicsConverter.C (build_script): remove the Alerts when things go
175         wrong as the inset displays the message anyway. Moreover, Alert seems
176         pretty temperamemtal at the moment.
177
178 2002-04-16  Rob Lahaye  <lahaye@users.sourceforge.net>
179         * GraphicsImageXPM.C: fix clipping for boundingbox y-coordinates
180
181 2002-04-08  Angus Leeming  <a.leeming@ic.ac.uk>
182
183         * GraphicsCacheItem.C (findTargetFormat): fix bug waiting to bite:
184         a reference to a temp object that's going out of scope...
185
186 2002-04-09  Herbert Voss  <voss@lyx.org>
187
188         * GraphicsParams.C (BoundingBox c-tor): fix rounding errors by using
189         LyXLength::inBP instead of inPixels.
190
191 2002-04-10  Herbert Voss  <voss@perce.de>
192
193         * GraphicsCache.[Ch]:
194         * GraphicsCacheItem.[Ch]: add width/height functions from Angus
195         to read the "Bounding Box" from non (e)ps files.
196
197 2002-04-08  Angus Leeming  <a.leeming@ic.ac.uk>
198
199         * GraphicsParams.C (c-tor): if clipping, then check the Bounding Box of
200         the EPS file too, to ensure that the clipped Bounding Box is relative
201         to the original. (From Herbert.)
202
203 2002-04-04  Angus Leeming  <a.leeming@ic.ac.uk>
204
205         * GraphicsParams.C (BoundingBox c-tor): ensure that the member
206         variables are initialised. Clean-up parsing of the string (with thanks
207         to Herbert.)
208
209 2002-03-26  Angus Leeming  <a.leeming@ic.ac.uk>
210
211         * GraphicsCacheItem.C (convertToDisplayFormat): don't launch that Alert
212         if the file can't be found.
213
214         * GraphicsParams.h (c-tor): remove string() as default argument.
215
216         * GraphicsCacheItem.C: a couple of changes as a result.
217
218 2002-03-22  Angus Leeming  <a.leeming@ic.ac.uk>
219
220         * GraphicsCache.[Ch] (update): now passed filepath to determine absolute
221         path to graphics file.
222
223         * GraphicsParams.[Ch] (c-tor): now passed filepath.
224
225 2002-03-21  Lars Gullik Bjønnes  <larsbj@birdstep.com>
226
227         * most files: ws cleanup
228
229         * Makefile.am: remove ld -r stuff
230
231 2002-03-20  Lars Gullik Bjønnes  <larsbj@birdstep.com>
232
233         * Makefile.am: special rules if partial linking
234
235 2002-03-14  Angus Leeming  <a.leeming@ic.ac.uk>
236
237         * GraphicsCache.C: use Lars' preferred idiom for a for-loop.
238
239 2002-03-11  Lars Gullik Bjønnes  <larsbj@birdstep.com>
240
241         * GraphicsConverter.[Ch] (converted): make first arg const ref.
242
243         * GraphicsCacheItem.h: doxy change
244
245         * GraphicsCacheItem.C: ws change
246
247 2002-03-05  Angus Leeming  <a.leeming@ic.ac.uk>
248
249         * Makefile.am: if there is no image loading class leveraging the power
250         of the appropriate gui library, then compile the basic alternative
251         found in GraphicsImageXPM.[Ch].
252
253 2002-03-04  Angus Leeming  <a.leeming@ic.ac.uk>
254
255         * GraphicsCache.C: change associated with move of initialiseGraphics
256         to GUIRuntime.
257
258 2002-02-28  Angus Leeming  <a.leeming@ic.ac.uk>
259
260         * GraphicsParams.[Ch]:
261         * GraphicsImage.C:
262         * GraphicsImageXPM.C: properly resolve more warnings about comparison
263         between signed and unsigned integer expressions.
264
265         * Makefile.am: add GraphicsTypes.h which I'd carelessly left out.
266
267         * GraphicsCache.C: move connections to the GImage-derived classes to
268         the frontends.
269
270         * GraphicsImageXPM.C (copy c-tor): don't copy pixmap.
271
272         * GraphicsCacheItem.C (findTargetFormat): if we can load direct without
273         conversion, then do that.
274
275 2002-02-27  Angus Leeming  <a.leeming@ic.ac.uk>
276
277         * GraphicsCache.C: improve commentary to graphicsInit and where it
278         should really go.
279
280         * GraphicsImageXPM.C (~Data, free_color_table): resolve the crash
281         that became a memory leak properly. (Let the shared_c_ptr free the
282         color table.)
283         (reset, mapcolor): tidy up and introduce a work around for XPM files
284         with crappy color entries. Print out a nice friendly message on what's
285         gone wrong and how to resolve it properly.
286
287 2002-02-27  Angus Leeming  <a.leeming@ic.ac.uk>
288
289         * GraphicsImageXPM.[Ch]: more rigorous use of types (signed/unsigned).
290         (Data d-tor): introduce memory leak temporarily, to "fix" a crash
291         in free_color_table.
292         (unique_color_string): use the correct string c-tor.
293
294 2002-02-15  Angus Leeming  <a.leeming@ic.ac.uk>
295
296         * ImageLoader.[Ch]:
297         * ImageLoaderXPM.[Ch]: removed.
298
299         * GraphicsConverter.[Ch]:
300         * GraphicsImage.[Ch]:
301         * GraphicsImageXPM.[Ch]:
302         * GraphicsParams.[Ch]:
303         * GraphicsTypes.h: new files.
304
305         * All files. A total re-write of the graphics cache. The cache now
306         supports asynchronous file conversion and file loading. Images
307         can be cropped, rotated and scaled for display on the LyX screen.
308         The old LyXImage and ImageLoader have been combined in a new class
309         GImage. Ditto, ImageLoaderXPM's functionality has been moved into
310         GImageXPM.
311
312 2002-02-07  Herbert Voss  <voss@lyx.org>
313
314         * GraphicsCacheItem.C: use unzipFile() from support/filetools
315
316 2002-01-31  Herbert Voss  <voss@lyx.org>
317
318         * GraphicsCacheItem.h: handle filetype without the file extension;
319         getting type from contents; handle zipped files
320
321 2002-01-27  Herbert Voss  <voss@lyx.org>
322
323         * GraphicsCacheItem.h: added Converting to the ImageStatus enum.
324
325 2002-01-17  John Levon  <moz@compsoc.man.ac.uk>
326
327         * ImageLoaderXPM.C: don't set XpmColorKey flag if we don't use it
328
329 2001-12-19  Jean-Marc Lasgouttes  <lasgouttes@freesurf.fr>
330
331         * GraphicsCacheItem.h: do not include <config.h> in header files
332
333 2001-09-21  Angus Leeming  <a.leeming@ic.ac.uk>
334
335         * ImageLoaderXPM.C (runImageLoader): If the pixmap contains a
336         transparent colour, then set it to the colour of the background.
337         Also take account of the monochrome, grayscale of color
338         preferences option.
339
340 2001-09-20  Angus Leeming  <a.leeming@ic.ac.uk>
341
342         * GraphicsCacheItem.C (convertImage): only convert if "from" and "to"
343         are different. Thus, don't delete the "to" if it's the original!
344
345 2001-09-01  John Levon  <moz@compsoc.man.ac.uk>
346
347         * ImageLoadXPM.C: remove setting of alloc colour mask,
348           led to crash as we don't define a callback
349
350 2001-07-29  Baruch Even  <baruch@lyx.org>
351
352         * ImageLoaderXPM.C (runImageLoader): When loading agree to use non-exact
353         colors with closeness of 10000.
354
355         * GraphicsCacheItem.C: Fixed a compilation bug introduced earlier.
356
357 2001-07-29  Baruch Even  <baruch@lyx.org>
358
359         * GraphicsCacheItem.C (findTargetFormat): Removed error dialog box,
360         too annoying.
361
362 2001-07-23  Baruch Even  <baruch@lyx.org>
363
364         * GraphicsCacheItem.C (convertImage): Fixed a bug with regard to loading
365         the image after conversion.
366
367 2001-07-17  Baruch Even  <baruch@lyx.org>
368
369         * GraphicsCacheItem.h:
370         * GraphicsCacheItem.C: Shuffled things a bit to make it easier to switch
371         from synchronous to asynchronous and to ease the coming changes.
372
373 2001-07-03  Jean-Marc Lasgouttes  <Jean-Marc.Lasgouttes@inria.fr>
374
375         * ImageLoaderXPM.C (runImageLoader): get display information from
376         GUIRunTime.
377
378 2001-06-14  Angus Leeming  <a.leeming@ic.ac.uk>
379
380         * GraphicsCache.C:
381         * GraphicsCacheItem.C:
382         * ImageLoader.C:
383         * ImageLoaderXPM.C: removed // -*- C++ -*- as first line.
384
385 2001-04-17  Lars Gullik Bjønnes  <larsbj@birdstep.com>
386
387         * GraphicsCache.h: inherit privately from noncopyable
388         * ImageLoader.h: ditto
389         * GraphicsCacheItem.h: ditto
390
391 2001-04-16  Allan Rae  <rae@lyx.org>
392
393         * ImageLoaderXPM.C (runImageLoader): #warning triggers an error on Sun
394         CC 6.0 as an unrecognised preprocessor directive.  So ensure they're
395         wrapped.
396
397 2001-04-02  Baruch Even  <baruch@lyx.org>
398
399         * GraphicsCacheItem.[Ch]: Changed to used the Converter class instead
400         of hard coding ImageMagick.
401
402 2001-03-10  Baruch Even  <baruch@lyx.org>
403
404         * GraphicsCache.C: Style change from (*it).field to it->field
405
406 2001-03-15  Lars Gullik Bjønnes  <larsbj@trylle.birdstep.com>
407
408         * GraphicsCache.h: noncopyable is in namespace boost
409         * ImageLoader.h: ditto
410         * GraphicsCacheItem.h: ditto
411
412 2001-03-07  Baruch Even  <baruch@lyx.org>
413
414         * GraphicsCache.C (d-tor): Removed the assert, the assumption it carried
415         was false and it's not needed anyhow since the shared_ptr's in the cache
416         will destroy everything on exit.
417
418 2001-02-28  Baruch Even  <baruch@ev-en.org>
419
420         * GraphicsCache.h:
421         * GraphicsCache.C: Changed the singleton pattern implementation, the
422         former version "leaked" in the sense that it was not deallocated at
423         program end.
424
425 2001-02-20  Baruch Even  <baruch@ev-en.org>
426
427         * GraphicsCache.C: Changed to use shared_ptr<GraphicsCacheItem>
428         instead of a pure pointer.
429
430         * GraphicsCacheItem.[Ch]:
431         * GraphicsCacheItem_pimpl.[Ch]: Collapsed them into GraphicsCacheItem,
432         removed the reference counting that was inside. Also fixed a bug where
433         a temporary file wouldn't get erased.
434
435         * ImageLoader.[Ch]: Changed the semantics of the image_ pointers usage.
436         Ownership is now dropped when the caller requests the image_ pointer.
437
438 2001-02-20  Baruch Even  <baruch@ev-en.org>
439
440         * GraphicsCache.C: Cleared up the confusion on when and how it is
441         emptied.
442
443         * GraphicsCacheItem.C: Indentation change.
444
445         * GraphicsCacheItem_pimpl.C: Fixed the loading logic so that it will
446         figure correctly when the image has been loaded successfully.
447
448 2001-02-08  Jean-Marc Lasgouttes  <Jean-Marc.Lasgouttes@inria.fr>
449
450         * ImageLoader.C: add a "using" directive.
451
452         * ImageLoader.h: remove extra comma at the end of enum; add an
453         std:: qualifier for vector.
454
455 2001-01-21  Baruch Even  <baruch@ev-en.org>
456
457         * GraphicsCacheItem.[Ch]: Changes due to the storage of width and
458         height in the image itself and minor cleanups.
459
460         * GraphicsCacheItem_impl.[Ch]: Changes due to the switch to use a
461         new ImageLoader class instead of the older Renderer class. This
462         means change of responsibilities.