1 2002-07-09 Angus Leeming <leeming@lyx.org>
3 * PreviewLoader.C (setAscentFractions): fix bug due to use of integer
4 arithmetic when it should be floating.
6 2002-07-09 Angus Leeming <leeming@lyx.org>
8 * PreviewLoader.C (startLoading): prepend LaTeX file with "\batchmode".
9 Output equation labels as "(#)" if lyxrc preference is set.
10 (setFontScalingFactor): use lyxrc variable preview_scale_factor
11 rather than hard-coding this.
13 2002-07-09 Angus Leeming <leeming@lyx.org>
15 * PreviewLoader.C: Further refactoring of the code. Should now be
18 * PreviewMetrics.[Ch]: removed. Had a v. short shelf life and is now
19 past its sell-by date. The code to read the metrics file is now found
20 as a helper function in PreviewLoader.C.
22 * GraphicsImageXPM.C (scale): use boost::tie.
24 2002-07-08 Herbert Voss <voss@lyx.org>
26 * PreviewLoader.C: use of preview_size_factor to get the right
27 font-size! 0.9 is the default.
29 2002-07-08 Angus Leeming <leeming@lyx.org>
31 * PreviewLoader.C: Add "delayed" and "showlabels" options to the
32 invocation of preview.sty.
33 Perform something of an internal clean-up.
35 2002-07-06 Angus Leeming <leeming@lyx.org>
37 * PreviewLoader.C: ensure that the metrics data is used by the
41 * PreviewImage.C: (Impl d-tor): remove all generated files that still
42 exist (perhaps because the process was curtailed before the images
45 * PreviewLoader.C (unique_filename): store the files in Buffer::tmppath.
47 2002-07-05 Angus Leeming <leeming@lyx.org>
56 * Previews.C: new files. The previewed LaTeX snippet stuff.
58 * Makefile.am: add these files.
60 2002-07-05 Angus Leeming <leeming@lyx.org>
62 * GraphicsLoader.h: whitespace.
64 2002-07-04 Lars Gullik Bjønnes <larsbj@birdstep.com>
66 * GraphicsImage.[Ch]: newImage and loadableFormats changed to
67 boost::function from boost::signal.
69 2002-07-01 Jean-Marc Lasgouttes <lasgouttes@freesurf.fr>
71 * GraphicsConverter.C (convert): do not use ChangeExtension
72 because to_file_base may contain a dot.
74 2002-06-28 Angus Leeming <leeming@lyx.org>
76 * GraphicsCacheItem.[Ch]: refactor some of the more convoluted logic
77 by moving those SignalPtrs into the grfx::Image and grfx::Converter
78 classes where they really belong.
79 Use the Pimpl idiom to hide the class internals from public view.
81 * GraphicsTypes: remove the typedefs, leaving only the enums.
83 * GraphicsImage.h: now has a finishedLoading signal, as opposed to being
84 passed a reference to one in the load() method.
86 * GraphicsConverter.[Ch]: totally refactored. An instance of
87 grfx::Converter now represents a single conversion process.
88 Thus grfx::CachItem now has a grfx::Converter * that is set when the
89 conversion is initiated and destroyed on completion.
92 * GraphicsCacheItem.[Ch]:
93 * GraphicsConverter.[Ch]:
94 * GraphicsLoader.[Ch]: use the Pimpl idiom to hide the class internals
96 Note that I have done this only after making the above changes,
97 so not only should we have a clean, minimal and well documented
98 interface to these classes in the header files, but the class internals
99 should be much clearer too.
102 grfx::GCache -> grfx::Cache,
103 grfx::GCacheItem -> grfx::CacheItem,
104 grfx::GConverter -> grfx::Converter,
105 grfx::GImage -> grfx::Image,
106 grfx::GImageXPM -> grfx::ImageXPM,
107 grfx::GParams -> grfx::Params.
109 2002-06-26 Angus Leeming <leeming@lyx.org>
111 * GraphicsLoader.[Ch]: use boost::scoped_ptr in preference to
112 std::auto_ptr. Define an empty Loader d-tor out-of-line to ensure it
115 2002-06-26 Angus Leeming <leeming@lyx.org>
117 * GraphicsTypes.h: add "Ready" to the ImageStatus enum.
118 move the DisplayType enum out of grfx::GParams to here.
120 * GraphicsCacheItem.h: re-write preliminary description to reflect
123 * GraphicsParams.[Ch]:
124 * GraphicsImageXPM.C (load, setPixmap): changes aassociated with moving
125 grfx::DisplayType out of grfx::GParams.
127 * GraphicsLoader.[Ch]: new files. Factor out the image loading stuff
128 that was in frontends/screen.C and insets/insetgraphics.C into a
129 single, easy-to-use class.
131 * Makefile.am: add these files.
133 2002-06-25 Angus Leeming <leeming@lyx.org>
135 * GraphicsCache.[Ch]:
136 * GraphicsCacheItem.[Ch]:
137 * GraphicsTypes.h: rewrite the graphics cache to just load a graphics
138 file into memory. The cache no longer controls the generation of the
139 pixmap. Instead, it just emits a signal when the loading status of an
141 The cache no longer stores InsetGraphics pointers and nor does it
142 assume responsibility for modifying an image (scaling, rotating etc).
143 Instead, that must now be performed elsewhere.
145 2002-06-19 Angus Leeming <leeming@lyx.org>
147 * GraphicsConverter.C: add using std::endl directive.
149 2002-06-17 Herbert Voss <voss@lyx.org>
151 * GraphicsCachItem.C: (findTargetFormat)return xpm-format as a
152 default when nothing different was found
153 (convertToDisplayFormat): handle zipped files in the right way and
154 choose always convert as a default converter when no other
155 userdefined was found
157 * GraphicsConverter.C: add more lyxerr comments and choose
158 convert when no other userdefined converter was found
160 2002-06-10 Herbert Voss <voss@lyx.org>
162 * GraphicsImageXPM.C (convertTo7chars): get another special color
163 format from convert work in the right way
165 2002-06-12 John Levon <moz@compsoc.man.ac.uk>
167 * GraphicsCache.C: use right colormap incantation
169 2002-06-12 John Levon <moz@compsoc.man.ac.uk>
171 * GraphicsCache.C: use lyx_gui namespace
173 * GraphicsImageXPM.C: back down to using xforms
176 2002-06-07 Angus Leeming <leeming@lyx.org>
178 Fixes needed to compile with Compaq cxx 6.5.
179 * GraphicsConverter.h: forward declare class ConvProcess.
181 * GraphicsImageXPM.C:
182 all c-library variables have been moved into namespace std.
183 Wrap using std::xyz declarations inside a #ifndef CXX_GLOBAL_CSTD block.
185 2002-06-06 Angus Leeming <a.leeming@ic.ac.uk>
187 * GraphicsImageXPM.C (rotate): rotate in the same sense as xdvi!
189 2002-05-30 Lars Gullik Bjønnes <larsbj@birdstep.com>
191 * GraphicsImageXPM.C: SigC to boot::signals changes.
192 (newImage): fix () bug when using new.
194 2002-05-29 Lars Gullik Bjønnes <larsbj@birdstep.com>
196 * switch from SigC signals to boost::signals.
198 2002-05-29 André Pönitz <poenitz@gmx.net>
200 * GraphicsParam.C: remove unneeded #include, move vomment
202 2002-05-28 André Pönitz <poenitz@gmx.net>
204 * GraphicsParam.[Ch]: move inset related stuff to inset/insetgraphics
206 2002-05-24 John Levon <moz@compsoc.man.ac.uk>
208 * GraphicsImageXPM.C: ColorHandler moved
210 2002-05-24 Juergen Vigna <jug@sad.it>
213 * GraphicsImage.h: include LString.h first.
215 2002-05-22 Lars Gullik Bjønnes <larsbj@birdstep.com>
217 * GraphicsCacheItem.h: use more specific smart_ptr header.
218 * GraphicsTypes.h: ditto
219 * GraphicsImage.h: ditto
220 * GraphicsConverter.h: ditto
222 2002-04-28 John Levon <moz@compsoc.man.ac.uk>
224 * GraphicsImageXPM.C: understand convert's use of "opaque"
227 2002-04-19 Marco Morandini <morandini@aero.polimi.it>
229 * GraphicsCache.[Ch] (loadableFormats): new method. A wrapper for
230 GImage::loadableFormats() that ensures that the signal is connected
231 to the derived class' method.
233 2002-04-18 Lars Gullik Bjønnes <larsbj@birdstep.com>
235 * GraphicsImageXPM.C (convertTo7chars): drop all conversions and
236 only work on the string.
238 2002-04-17 Angus Leeming <a.leeming@ic.ac.uk>
240 * GraphicsImageXPM.C (Data::reset): Fix the loading of xpm files by
241 the simple image loader when it encounters colour strings like
244 2002-04-16 Angus Leeming <a.leeming@ic.ac.uk>
246 * GraphicsCacheItem.C (convertToDisplayFormat):
247 * GraphicsConverter.C (build_script): remove the Alerts when things go
248 wrong as the inset displays the message anyway. Moreover, Alert seems
249 pretty temperamemtal at the moment.
251 2002-04-16 Rob Lahaye <lahaye@users.sourceforge.net>
252 * GraphicsImageXPM.C: fix clipping for boundingbox y-coordinates
254 2002-04-08 Angus Leeming <a.leeming@ic.ac.uk>
256 * GraphicsCacheItem.C (findTargetFormat): fix bug waiting to bite:
257 a reference to a temp object that's going out of scope...
259 2002-04-09 Herbert Voss <voss@lyx.org>
261 * GraphicsParams.C (BoundingBox c-tor): fix rounding errors by using
262 LyXLength::inBP instead of inPixels.
264 2002-04-10 Herbert Voss <voss@perce.de>
266 * GraphicsCache.[Ch]:
267 * GraphicsCacheItem.[Ch]: add width/height functions from Angus
268 to read the "Bounding Box" from non (e)ps files.
270 2002-04-08 Angus Leeming <a.leeming@ic.ac.uk>
272 * GraphicsParams.C (c-tor): if clipping, then check the Bounding Box of
273 the EPS file too, to ensure that the clipped Bounding Box is relative
274 to the original. (From Herbert.)
276 2002-04-04 Angus Leeming <a.leeming@ic.ac.uk>
278 * GraphicsParams.C (BoundingBox c-tor): ensure that the member
279 variables are initialised. Clean-up parsing of the string (with thanks
282 2002-03-26 Angus Leeming <a.leeming@ic.ac.uk>
284 * GraphicsCacheItem.C (convertToDisplayFormat): don't launch that Alert
285 if the file can't be found.
287 * GraphicsParams.h (c-tor): remove string() as default argument.
289 * GraphicsCacheItem.C: a couple of changes as a result.
291 2002-03-22 Angus Leeming <a.leeming@ic.ac.uk>
293 * GraphicsCache.[Ch] (update): now passed filepath to determine absolute
294 path to graphics file.
296 * GraphicsParams.[Ch] (c-tor): now passed filepath.
298 2002-03-21 Lars Gullik Bjønnes <larsbj@birdstep.com>
300 * most files: ws cleanup
302 * Makefile.am: remove ld -r stuff
304 2002-03-20 Lars Gullik Bjønnes <larsbj@birdstep.com>
306 * Makefile.am: special rules if partial linking
308 2002-03-14 Angus Leeming <a.leeming@ic.ac.uk>
310 * GraphicsCache.C: use Lars' preferred idiom for a for-loop.
312 2002-03-11 Lars Gullik Bjønnes <larsbj@birdstep.com>
314 * GraphicsConverter.[Ch] (converted): make first arg const ref.
316 * GraphicsCacheItem.h: doxy change
318 * GraphicsCacheItem.C: ws change
320 2002-03-05 Angus Leeming <a.leeming@ic.ac.uk>
322 * Makefile.am: if there is no image loading class leveraging the power
323 of the appropriate gui library, then compile the basic alternative
324 found in GraphicsImageXPM.[Ch].
326 2002-03-04 Angus Leeming <a.leeming@ic.ac.uk>
328 * GraphicsCache.C: change associated with move of initialiseGraphics
331 2002-02-28 Angus Leeming <a.leeming@ic.ac.uk>
333 * GraphicsParams.[Ch]:
335 * GraphicsImageXPM.C: properly resolve more warnings about comparison
336 between signed and unsigned integer expressions.
338 * Makefile.am: add GraphicsTypes.h which I'd carelessly left out.
340 * GraphicsCache.C: move connections to the GImage-derived classes to
343 * GraphicsImageXPM.C (copy c-tor): don't copy pixmap.
345 * GraphicsCacheItem.C (findTargetFormat): if we can load direct without
346 conversion, then do that.
348 2002-02-27 Angus Leeming <a.leeming@ic.ac.uk>
350 * GraphicsCache.C: improve commentary to graphicsInit and where it
353 * GraphicsImageXPM.C (~Data, free_color_table): resolve the crash
354 that became a memory leak properly. (Let the shared_c_ptr free the
356 (reset, mapcolor): tidy up and introduce a work around for XPM files
357 with crappy color entries. Print out a nice friendly message on what's
358 gone wrong and how to resolve it properly.
360 2002-02-27 Angus Leeming <a.leeming@ic.ac.uk>
362 * GraphicsImageXPM.[Ch]: more rigorous use of types (signed/unsigned).
363 (Data d-tor): introduce memory leak temporarily, to "fix" a crash
365 (unique_color_string): use the correct string c-tor.
367 2002-02-15 Angus Leeming <a.leeming@ic.ac.uk>
370 * ImageLoaderXPM.[Ch]: removed.
372 * GraphicsConverter.[Ch]:
373 * GraphicsImage.[Ch]:
374 * GraphicsImageXPM.[Ch]:
375 * GraphicsParams.[Ch]:
376 * GraphicsTypes.h: new files.
378 * All files. A total re-write of the graphics cache. The cache now
379 supports asynchronous file conversion and file loading. Images
380 can be cropped, rotated and scaled for display on the LyX screen.
381 The old LyXImage and ImageLoader have been combined in a new class
382 GImage. Ditto, ImageLoaderXPM's functionality has been moved into
385 2002-02-07 Herbert Voss <voss@lyx.org>
387 * GraphicsCacheItem.C: use unzipFile() from support/filetools
389 2002-01-31 Herbert Voss <voss@lyx.org>
391 * GraphicsCacheItem.h: handle filetype without the file extension;
392 getting type from contents; handle zipped files
394 2002-01-27 Herbert Voss <voss@lyx.org>
396 * GraphicsCacheItem.h: added Converting to the ImageStatus enum.
398 2002-01-17 John Levon <moz@compsoc.man.ac.uk>
400 * ImageLoaderXPM.C: don't set XpmColorKey flag if we don't use it
402 2001-12-19 Jean-Marc Lasgouttes <lasgouttes@freesurf.fr>
404 * GraphicsCacheItem.h: do not include <config.h> in header files
406 2001-09-21 Angus Leeming <a.leeming@ic.ac.uk>
408 * ImageLoaderXPM.C (runImageLoader): If the pixmap contains a
409 transparent colour, then set it to the colour of the background.
410 Also take account of the monochrome, grayscale of color
413 2001-09-20 Angus Leeming <a.leeming@ic.ac.uk>
415 * GraphicsCacheItem.C (convertImage): only convert if "from" and "to"
416 are different. Thus, don't delete the "to" if it's the original!
418 2001-09-01 John Levon <moz@compsoc.man.ac.uk>
420 * ImageLoadXPM.C: remove setting of alloc colour mask,
421 led to crash as we don't define a callback
423 2001-07-29 Baruch Even <baruch@lyx.org>
425 * ImageLoaderXPM.C (runImageLoader): When loading agree to use non-exact
426 colors with closeness of 10000.
428 * GraphicsCacheItem.C: Fixed a compilation bug introduced earlier.
430 2001-07-29 Baruch Even <baruch@lyx.org>
432 * GraphicsCacheItem.C (findTargetFormat): Removed error dialog box,
435 2001-07-23 Baruch Even <baruch@lyx.org>
437 * GraphicsCacheItem.C (convertImage): Fixed a bug with regard to loading
438 the image after conversion.
440 2001-07-17 Baruch Even <baruch@lyx.org>
442 * GraphicsCacheItem.h:
443 * GraphicsCacheItem.C: Shuffled things a bit to make it easier to switch
444 from synchronous to asynchronous and to ease the coming changes.
446 2001-07-03 Jean-Marc Lasgouttes <Jean-Marc.Lasgouttes@inria.fr>
448 * ImageLoaderXPM.C (runImageLoader): get display information from
451 2001-06-14 Angus Leeming <a.leeming@ic.ac.uk>
454 * GraphicsCacheItem.C:
456 * ImageLoaderXPM.C: removed // -*- C++ -*- as first line.
458 2001-04-17 Lars Gullik Bjønnes <larsbj@birdstep.com>
460 * GraphicsCache.h: inherit privately from noncopyable
461 * ImageLoader.h: ditto
462 * GraphicsCacheItem.h: ditto
464 2001-04-16 Allan Rae <rae@lyx.org>
466 * ImageLoaderXPM.C (runImageLoader): #warning triggers an error on Sun
467 CC 6.0 as an unrecognised preprocessor directive. So ensure they're
470 2001-04-02 Baruch Even <baruch@lyx.org>
472 * GraphicsCacheItem.[Ch]: Changed to used the Converter class instead
473 of hard coding ImageMagick.
475 2001-03-10 Baruch Even <baruch@lyx.org>
477 * GraphicsCache.C: Style change from (*it).field to it->field
479 2001-03-15 Lars Gullik Bjønnes <larsbj@trylle.birdstep.com>
481 * GraphicsCache.h: noncopyable is in namespace boost
482 * ImageLoader.h: ditto
483 * GraphicsCacheItem.h: ditto
485 2001-03-07 Baruch Even <baruch@lyx.org>
487 * GraphicsCache.C (d-tor): Removed the assert, the assumption it carried
488 was false and it's not needed anyhow since the shared_ptr's in the cache
489 will destroy everything on exit.
491 2001-02-28 Baruch Even <baruch@ev-en.org>
494 * GraphicsCache.C: Changed the singleton pattern implementation, the
495 former version "leaked" in the sense that it was not deallocated at
498 2001-02-20 Baruch Even <baruch@ev-en.org>
500 * GraphicsCache.C: Changed to use shared_ptr<GraphicsCacheItem>
501 instead of a pure pointer.
503 * GraphicsCacheItem.[Ch]:
504 * GraphicsCacheItem_pimpl.[Ch]: Collapsed them into GraphicsCacheItem,
505 removed the reference counting that was inside. Also fixed a bug where
506 a temporary file wouldn't get erased.
508 * ImageLoader.[Ch]: Changed the semantics of the image_ pointers usage.
509 Ownership is now dropped when the caller requests the image_ pointer.
511 2001-02-20 Baruch Even <baruch@ev-en.org>
513 * GraphicsCache.C: Cleared up the confusion on when and how it is
516 * GraphicsCacheItem.C: Indentation change.
518 * GraphicsCacheItem_pimpl.C: Fixed the loading logic so that it will
519 figure correctly when the image has been loaded successfully.
521 2001-02-08 Jean-Marc Lasgouttes <Jean-Marc.Lasgouttes@inria.fr>
523 * ImageLoader.C: add a "using" directive.
525 * ImageLoader.h: remove extra comma at the end of enum; add an
526 std:: qualifier for vector.
528 2001-01-21 Baruch Even <baruch@ev-en.org>
530 * GraphicsCacheItem.[Ch]: Changes due to the storage of width and
531 height in the image itself and minor cleanups.
533 * GraphicsCacheItem_impl.[Ch]: Changes due to the switch to use a
534 new ImageLoader class instead of the older Renderer class. This
535 means change of responsibilities.