COIN-OR::LEMON - Graph Library

Opened 17 years ago

Closed 17 years ago

#79 closed defect (fixed)

Missing images in the documentation of graph_to_eps.h

Reported by: Alpar Juttner Owned by: Akos Ladanyi
Priority: major Milestone: LEMON 1.0 release
Component: documentation Version: hg main
Keywords: Cc:
Revision id:

Description

The images doc/images/nodeshape* hasn't been ported yet. In the svn repo, all of the files under doc/images are added both in .eps and .png format.

However, it would be much better to add the .eps files only and then the make html command would generate the .png version.

In some cases (e.g. plane_tree.eps) even the .eps file should also be generated. (Though it isn't necessary yet, as the related doc still hasn't been ported).

Attachments (12)

add-nodeshapes.patch (12.7 KB) - added by Akos Ladanyi 17 years ago.
convert.patch (1.9 KB) - added by Akos Ladanyi 17 years ago.
doxyfile.patch (17.0 KB) - added by Akos Ladanyi 17 years ago.
hgignore.patch (378 bytes) - added by Akos Ladanyi 17 years ago.
doxyfile.2.patch (52.2 KB) - added by Alpar Juttner 17 years ago.
New version (using -u -s)
doxy-stl.patch (380 bytes) - added by Alpar Juttner 17 years ago.
Turn on built in Doxygen STL support
hgignore.2.patch (461 bytes) - added by Alpar Juttner 17 years ago.
New Updated .hgignore
external-build.patch (1.6 KB) - added by Alpar Juttner 17 years ago.
Fix external doc build
transparent.patch (680 bytes) - added by Akos Ladanyi 17 years ago.
move-esp-files.patch (25.6 KB) - added by Akos Ladanyi 17 years ago.
Patch which moves the eps files to doc/ form doc/images/.
makefile-move-esp.patch (1007 bytes) - added by Akos Ladanyi 17 years ago.
gen-images.patch (1.3 KB) - added by Akos Ladanyi 17 years ago.

Download all attachments as: .zip

Change History (24)

comment:1 Changed 17 years ago by Akos Ladanyi

Please see the attached patches.

comment:2 in reply to:  1 Changed 17 years ago by Alpar Juttner

Replying to ladanyi:

Please see the attached patches.

Some comments:

  • in attachment:add-nodeshapes.patch, the .eps file became bitmap files. This is probably due to a a wrong rescaling. There are two options:
    • The .esp files are more or less easy to rescale by hand. I can do it for you, if we decide to choose this approach.
    • They can also be rescaled during the conversion. The problem here is that different images needs different scaling factors, thus probably we need different make-rules for .png images requiring different scaling. The advantage of this approach is that the .eps images can remain untouched.
  • The Makefile (attachment:convert.patch) doesn't work correctly for external target.
  • A .png generation is only necessary if the .png is missing or older than the .eps.

comment:3 Changed 17 years ago by Alpar Juttner

Version: hg main

Changed 17 years ago by Akos Ladanyi

Attachment: add-nodeshapes.patch added

Changed 17 years ago by Akos Ladanyi

Attachment: convert.patch added

Changed 17 years ago by Akos Ladanyi

Attachment: doxyfile.patch added

Changed 17 years ago by Akos Ladanyi

Attachment: hgignore.patch added

comment:4 Changed 17 years ago by Akos Ladanyi

Attached the updated patches.

Changed 17 years ago by Alpar Juttner

Attachment: doxyfile.2.patch added

New version (using -u -s)

Changed 17 years ago by Alpar Juttner

Attachment: doxy-stl.patch added

Turn on built in Doxygen STL support

Changed 17 years ago by Alpar Juttner

Attachment: hgignore.2.patch added

New Updated .hgignore

Changed 17 years ago by Alpar Juttner

Attachment: external-build.patch added

Fix external doc build

comment:5 in reply to:  4 Changed 17 years ago by Alpar Juttner

Replying to ladanyi:

Attached the updated patches.

I uploaded some updated patches: attachment:doxyfile.2.patch (removing comments from Doxyfile.in), attachment:doxy-stl.patch (turn on doxygen stl support) and attachment:hgignore.patch (ignore *.bak files)

comment:6 in reply to:  4 Changed 17 years ago by Alpar Juttner

Replying to ladanyi:

Attached the updated patches.

The external build still does not work, because

  • Doxygen is not looking for imaged in the build dir
  • If is Doxyfile.in is changed so that it will do, then the .png images gets into the tar.gz file twice (both under doc/images and doc/html)

See the attachment:external-build.patch for a possible fix. Could you review/test if it is really work?

I was also thinking of moving all the source images to doc/ and use doc/images only for the generated images. What do you think of this idea? (The fixed Makefile could do it easily.)

Changed 17 years ago by Akos Ladanyi

Attachment: transparent.patch added

comment:7 Changed 17 years ago by Akos Ladanyi

Replying to alpar:

See the attachment:external-build.patch for a possible fix. Could you review/test if it is really work?

I've tested your patchset both in case of in-source and out-of-source builds. The resulting tarballs seem to contain everything needed and install fine.

I was also thinking of moving all the source images to doc/ and use doc/images only for the generated images. What do you think of this idea? (The fixed Makefile could do it easily.)

I don't see the benefit of this (except that it would be created and deleted similarly like the html subdirectory). Could you explain, please?

One idea: if we use the pngalpha device of Ghostscript instead of png16m, then unpainted areas will be left transparent, i.e. the background will be transparent and not white. This looks better in the documentation. Both Firefox and IE7 handle transparent PNGs and the size of the files increases only slightly:

png16m pngalpha
nodeshape_0.png 974 1024
nodeshape_1.png 249 285
nodeshape_2.png 514 592
nodeshape_3.png 1596 1723
nodeshape_4.png 1337 1414

Attached the patch.

comment:8 in reply to:  7 Changed 17 years ago by Alpar Juttner

Replying to ladanyi:

I don't see the benefit of this (except that it would be created and deleted similarly like the html subdirectory). Could you explain, please?

I would prefer to put the generated images in a separate directory, because it makes it easier the clean-up and also to ignore the generated files. For example, currently doc/images/*.png is in .hgignore, making it difficult to add .png images to the doc.

Changed 17 years ago by Akos Ladanyi

Attachment: move-esp-files.patch added

Patch which moves the eps files to doc/ form doc/images/.

Changed 17 years ago by Akos Ladanyi

Attachment: makefile-move-esp.patch added

comment:9 Changed 17 years ago by Akos Ladanyi

move-esp-files.patch and makefile-move-esp.patch move the eps files to doc/ from doc/images/.

All patches are available here too.

I've removed the '-p' option from mkdir becaues it is said to be not portable.

comment:10 in reply to:  9 ; Changed 17 years ago by Alpar Juttner

Replying to ladanyi:

move-esp-files.patch and makefile-move-esp.patch move the eps files to doc/ from doc/images/.

I'm very sorry for hesitating so much, but what about leaving the source images under doc/images (for the sake of clarity) and generate the target images into an other directory, say doc/gen-images? We can also do it in a later date, when we will really have source .png images.

I've removed the '-p' option from mkdir becaues it is said to be not portable.

Doesn't it causes problem if doc/images already exists? What about using 'mkdir -f'?

comment:11 in reply to:  10 Changed 17 years ago by Akos Ladanyi

Replying to alpar:

Replying to ladanyi:

move-esp-files.patch and makefile-move-esp.patch move the eps files to doc/ from doc/images/.

I'm very sorry for hesitating so much, but what about leaving the source images under doc/images (for the sake of clarity) and generate the target images into an other directory, say doc/gen-images? We can also do it in a later date, when we will really have source .png images.

gen-images.patch does this. It replaces move-esp-files.patch and makefile-move-esp.patch. Again all patches are available here too.

I've removed the '-p' option from mkdir becaues it is said to be not portable.

Doesn't it causes problem if doc/images already exists? What about using 'mkdir -f'?

mkdir -f doesn't work for me. Anyway 'mkdir -p foo' and '-mkdir foo' in a Makefile are functionally the same. In the former case mkdir ignores the existing directory, while in the latter case make ignores the non-zero exit code of mkdir.

Changed 17 years ago by Akos Ladanyi

Attachment: gen-images.patch added

comment:12 Changed 17 years ago by Alpar Juttner

Resolution: fixed
Status: newclosed

Thank you for the patches.

The changes are now in the main branch, see [f3af90ef0143], [4d79daa40e9b], [b37cc0bb12db], [976a014b3797] and [f4e4dbc1d467].

Note: See TracTickets for help on using tickets.