General Discussion on Graphics

This forum is for all Flare issues not related to any of the other categories.
Post Reply
RiverMonster
Sr. Propeller Head
Posts: 149
Joined: Fri May 09, 2008 8:51 am
Location: Alicante, Spain
Contact:

General Discussion on Graphics

Post by RiverMonster »

Sept 07 2009: Updated Capture info to version 4. Look for yellow arrow.
[Feb 26 2009: Added some text (in red) to clarify what happens during FrameMaker>Flare conversion in the case of inserted PDFs and objects.]

Hi,

I have spent a few days experimenting with graphics in our Flare projects and jotting down my findings. I came across a lot of info that does not seem to be in the help file (at least I could not find it) or is not well explained and thought it could be useful to others. If there are any mistakes/omissions etc please tell me.

(I originally posted results of testing with Flare 4.1, Frame 7.2, and Capture 2.0. I have since replaced the info on Capture with updated results for Capture 4.0. I tested WebHelp and PDF outputs. I tested with PNGs although I doubt things will be different for JPGs etc)

Thanks,

Adrian

________________________________________

I split the info into the following sections:
  • Importing Graphics without Callouts from FrameMaker
    Importing Graphics with Callouts from FrameMaker
    Graphic Output from Flare for WebHelp
    Resizing Graphics
    Resizing Graphics in a Single Source Project
    Miscellaneous Info
IMPORTING GRAPHIC FILES WITHOUT CALLOUTS FROM FRAMEMAKER

On import, graphic files are recreated in the Flare project such that they are identical to the source graphics in the Frame project (i.e. they are effectively just copied and pasted).

FrameMaker DPI Bug: Suppose you have resized a graphic in Frame. Regardless of the import settings the graphic file that gets recreated in the Flare folder should be identical to the source graphic file in the Frame project – the graphic itself should not be resized. However, there is a bug that occurs when a graphic has been resized in Frame by changing the DPI setting (rather than by dragging to resize it or changing the % setting). In such cases, a smaller, low-quality version of the graphic file gets recreated in the Flare project. (This happens regardless of the Preserve Image Size setting.)
Workaround: Rather than “fix” this up front in the FrameMaker file a much easier workaround is to copy all source graphics from the Frame project into the Flare project after the import. When you do this you may end up with graphics in your Flare project that are not used. You can identify them by creating a report (Project>Add Report File> All Unused Items) and delete them.

Preserve Image Size Setting: The Preserve Image Size setting controls how to display the graphic that gets copied/recreated in the Flare project during import. If you select Preserve Image Size then height and width properties get stamped into the <img> tags for graphics.

> If you intend to create print output from the Flare project it makes sense to preserve image sizes on import – a subsequent PDF output will show the graphic at the reduced size it was on screen in the Frame file. As long as the graphic is not reduced in size so much that the DPI exceeds that of the “printer” DPI setting then it will be reproduced well in the output.

> For online output from the Flare project it does not necessarily make sense to preserve image size on import. As soon as you reduce the size of an image the screen has the task of displaying more pixels per inch than there were in the original image and the quality of such graphics is therefore poorer. The more reduced in size the poorer quality a graphic will be. The situation is greatly improved if Generate Resized Copies of Scaled Images is selected for the target (see below). If the quality is still not deemed good enough then the option of not preserving image size should be considered. This basically means screenshots get shown at exactly the size they were on screen when taken. Full screen shots will be large and not aesthetically pleasing but they will be crystal clear.

> In any case, if you preserve image size you can easily revert to the original (large) size in Flare whereas the inverse is not true – if you do not preserve image size the sizing info you had in Frame is lost.


IMPORTING GRAPHIC FILES WITH CALLOUTS FROM FRAMEMAKER
(Or multiple graphics in the same anchored frame, or graphics that are inserted PDF pages or objects in the Frame document (Word, Excel, Visio...))

You need to set Generate Images for Anchored Frames during import to do this. My tests show the following:

• If Generate Images for Anchored Frames is not selected the graphics are not imported at all (this contrasts with the Flare help file, which says images will be created but any callouts will be dropped).

• If Preserve Image Size is also selected, any images with callouts appear tiny in Flare topics and with the wrong width/height ratio on screen. It seems that the width and height properties being set for the img tag are completely wrong.

• Regardless of the source format, graphics that have callouts are recreated as JPGs in the conversion to Flare

• The Flare “Transition from FrameMaker” Guide says that Distiller is used to recreate graphics with callouts and implies that it uses the last job options file that was used in Distiller. However, if you look at the log file for Distiller after you perform a conversion it seems that in fact it uses the “High Quality Print” job options file.

• The Flare “Transition from FrameMaker” Guide suggests that disabling image downsampling and compression will result in better image conversion but in my tests it didn’t make any difference – the result is always poor quality graphics.


GRAPHIC OUTPUT FROM FLARE FOR WEBHELP

Generate Resized Copies of Scaled Images: Suppose you resize images in Flare and then create Webhelp. If you select Generate Resized Copies of Scaled Images for the target, then instead of the output html page linking to a full size graphic and relying on the browser to resize it Flare creates a resized graphic of the exact dimensions needed. This is a great feature. The quality of such graphics is noticeably better than the quality of the same graphic resized by the browser (I tested with IE and Firefox). Therefore, there doesn’t really seem any reason not to select this option.


RESIZING GRAPHICS

There are several ways to resize graphics in Flare:
• By dragging the edge of a graphic
• By setting the properties of a graphic
• Using styles
• By resetting a resized graphic back to its original size. (This will remove any width and height properties stamped into the <img> tag.)
The help file for Flare contains clear info on this subject so I won’t repeat it here. (Just search for “resizing pictures”). Some things to note though…

Notes

i. By using styles or setting the properties of a graphic you can specify height, width, minimum height, minimum width, maximum height and maximum width. In Flare there is no way to scale a graphic by specifying a DPI setting or a % setting.

ii. If you resize a picture by dragging its edge then height and width properties get added to its img tag and these override any height/width settings that may have been set up for the img style. (They also override any DPI settings that may have been made for the picture in Capture if you used that.) Basically, you have to be careful not to manually resize a graphic by accident if you are using other means to resize it. If you manually resize by even a tiny amount it will not be at all obvious in the topic page viewed in Flare but will totally mess up the graphic in your online/PDF output.

iii. At the bottom of the Resizing Pictures topic in Flare 4.1 is a note that says the following:
Note: If you are using Flare's features to resize images, you need to make sure that the DOCTYPE declaration is set in order for the pictures to be resized in online outputs (DotNet Help, HTML Help, WebHelp, WebHelp Plus, WebHelp AIR). However, please note that this is not supported in Internet Explorer 6 and earlier versions; users must have Internet Explorer 7 or later in order to see the image in its resized state. However, I spoke to MadCap about this and they say that this note is now obsolete and will be removed from the next Flare release. (There is no restriction on graphic handling in IE 6.)


RESIZING GRAPHICS IN A SINGLE SOURCE PROJECT

Suppose you want a graphic at one size for print output but another for screen output. There are several ways to achieve this:
  • Method A- Set the “Size” and “Print Size” properties of each graphic
    Method B – Use styles with different settings for each media
    Method C – Set graphic properties in Capture instead of Flare
    Method D – Use conditions

Method A – Set the “Size” and “Print Size” properties of each graphic
Set the properties of each graphic (right-click the graphic in the topic and select Object). Set different height and width values for print and online, as required. You need to calculate values yourself to correspond with specific scaling values e.g. all graphics at 80% (120 dpi).

Notes:

> The settings you make override any <img> tag settings in your style sheet.

> There is no print DPI setting or % setting that you can set in order to have the graphics scaled by the same factor. However, you can calculate the pixel size to set for each individual graphic to achieve the same effect, as follows:
i. In Explorer, look at the Properties of the graphic to determine the number of horizontal pixels
ii. To resize to a certain percentage, multiply the number of horizontal pixels by that percentage.
To resize to a certain dpi, multiply the number of horizontal pixels by 96 and divide by the DPI that you want e.g. If the image has a width of 200 pixels and you want to set it to 120dpi then the value is 96/120 x 200 = 160 pixels.
iii. In the Size tab enter the horizontal length that you calculated (160 pixels in this example) and set the vertical size to “Automatic”. This will scale the height proportionally.


Method B – Use Styles with different settings for each media
Use styles to control <img> tags. Create a class for each style definition you want. Set up different definitions for print medium and online medium, as required. You can specify height, width, minimum height, minimum width, maximum height and maximum width.

Notes:
> Using styles works okay if you want a bunch of graphics to have the same height or width but you cannot use styles to have the graphics scaled by the same factor. This is a major shortcoming of using styles to control image dimensions.


Method C – Set graphic properties in Capture instead of Flare
In Capture, right-click the graphic and select File Properties. You can then set properties for the graphic file so that it displays differently in online and print outputs.

New! : :arrow: ************************UPDATED TO CAPTURE 4.0 **************************
Format tab:
Set Size For: You can choose between "Screen", "Print" or "Both". Choosing an option other than "screen" is intended for situations where you are not going to be using the image in a Flare project but in a print-based output such as a Microsoft Word document.
Scale and Screen Size: Changing an image size using Scale is effectively the same as changing the Screen Size dimensions – when you edit one setting the other changes accordingly. Online, the quality of images resized in Capture in this way is the same as online images resized using Flare e.g via the right-click Object > Size tab. However, in PDF, the quality of the Capture-resized image is noticeably worse than when just resizing for online in Flare. It is as if the image is being resampled for the print output.
In other words…
…using Flare to resize means you only have to set size settings once (with any of the methods previously described for resizing online images). As long as you are happy with the image in Webhelp you can rest assured it will look great in PDF.
…using Capture > Format to resize means you have to set size settings in both the Format tab and either the Flare Print Format tab in Capture or the Object > Print Size tab in Flare; if you just set the size in the Capture Format tab the graphic quality in a PDF will be poor.

CONCLUSION: If you want your print size different than your online size then it doesn't matter whether you change the online size using Flare or Capture. However, if you want the image to be the same size in both outputs you should use Flare for resizing not Capture.

Here is a link to the test I did
CaptureTest.zip
Note that after you have scaled a graphic in Capture there is no way to “unscale” it in Flare; you have to do this in Capture.

Print Format tab:
Print DPI: Besides the handful of default DPI entries in the dropdown list, you can also directly type in whatever setting you want (e.g. 120 (80% scaling) and 150 (64% scaling) are noticeably absent).The last setting you use gets remembered by Capture for the next image you edit (unfortunately there is no way to have Capture store DPIs that you enter permanently though). The value gets stamped to the properties file and used by Flare to resize the image in a PDF/Frame output. It works well -- as long as the DPI setting is less than that of the “printer” then the image will be reproduced perfectly in the PDF. (It works in the same way as setting DPI for a graphic in FrameMaker.) Basically, you are not controlling the innate quality of the screenshot in any way, just its size in the print output. (This is why it would make more sense for values such as 120 and 150 to appear in the drop-down list rather than 300 and 400.) One advantage of using this DPI setting is that it is easy to set the same print resolution for multiple graphics.
Image quality in the PDF is good when resizing with Print DPI.

Note: If resizing an image using the Print DPI command the Lock DPI setting is irrelevant.

Print Size:
With Lock DPI selected.
When you change the Print Size settings with Lock DPI selected you are resampling the image.
E.g. Suppose an image is 192 pixels wide. The default print width will be 2 inches. Now suppose you half the print size while retaining that DPI. This means that your 1 inch picture will be left with 96 pixels ie. 96 pixels will be removed.
The result is a low quality graphic.

With Lock DPI cleared.
What I suspect is supposed to happen…
Changing an image size using Print Size is effectively the same as changing the Print DPI – when you edit one setting the other changes accordingly. The quality of images in PDF should be the same using each – excellent.
What actually happens
When you resize by changing Print Size i. the Print DPI does not change correspondingly but remains the same ii. The image is resampled resulting in a low quality image i.e. it is as if Lock DPI is selected.

CONCLUSION: This seems to be a bug. I don't have Capture v5 to check if it is fixed there. So, in Capture up to version 4 and in version 5 if it isn't fixed you should only use Print DPI to set print resolution in Capture, never Print Size. (Alternatively, use the Object > Print Size tab in Flare which provides good results too.)

**************************************************

Method D – Use conditions
In your topic files in Flare, copy/paste each graphic to have two versions, one immediately after another. Resize each independently as required. Apply “print” condition to one and “screen” condition to the other.
(As the same graphic appears twice some people may consider that this is not really single sourcing. However, both “views” are coming from the same source file and no post-editing of either output is needed so in my opinion it is.)

Notes:
> Having graphics doubled makes topics more difficult to read and work with in Flare.
> You can easily see how graphics will look in both outputs without changing the media or generating outputs.
> Using conditions only makes sense if you do not resize your graphics in any other way than dragging or directly setting values in the “Size” tab for the graphic. If you use styles to resize image or you enter any settings on the “Print Size” tab for the graphic it makes using conditions pointless.


MISCELLANEOUS INFO

Setting a Percentage value for Height or Width
There is an option to set the height and width to a percentage e.g. 50%. However, this scales the image according to its containing block. E.g. 50% means that it will occupy 50% of the containing block, not that it will become 50% of its original size. In Webhelp output the containing block is essentially the browser window, so setting a width of 50% means the graphic’s width will always be 50% of the browser window width. How big and legible an image is will depend on the browser window width and will change if the user resizes the browser. So basically do this is not a good option for WebHelp.

Editing Callouts with Capture
Whenever you create or open a graphic file in Capture it creates a properties (.props) file in the same folder. If you add callouts to an image they get added directly to it. However, the props file effectively contains the original graphic plus all the changes that have been made. So, when you open a graphics file in Capture any callout that you added is an editable layer rather than a merged and uneditable part of the graphic.
This is a clever design. It means that to edit callouts in a graphic that is part of your Flare project you just need to right-click the graphic in the Flare topic, select Edit with MadCap Capture, edit the callouts and save the file. In contrast, if you want to edit the callouts in another program, such as SnagIt, you have to maintain a separate .snag version of the file for editing purposes and save an additional PNG version into your Flare project.
You do not have the required permissions to view the files attached to this post.
Last edited by RiverMonster on Tue Sep 08, 2009 7:09 am, edited 19 times in total.
iand
Sr. Propeller Head
Posts: 131
Joined: Thu Dec 18, 2008 5:46 am
Location: London, England

Re: General Discussion on Graphics

Post by iand »

Great summary. Thanks for posting this information.

Ian
RiverMonster
Sr. Propeller Head
Posts: 149
Joined: Fri May 09, 2008 8:51 am
Location: Alicante, Spain
Contact:

Re: General Discussion on Graphics

Post by RiverMonster »

Thanks Ian.

BTW I just noticed something confusing in the last line. It says "...and save an additional PNG version into your Flare project". That's just because I work with PNGs. It should really say something like "...and save an additional graphic version (whatever you need for your project e.g. PNG) into your Flare project".
forfear
Propellus Maximus
Posts: 766
Joined: Sat Feb 16, 2008 3:37 am
Location: Jungle Jingles

Re: General Discussion on Graphics

Post by forfear »

Another thing, if you're hoping to output vector graphics like line charts, graphs or business diagrams to print, they don't get produced as vector line art. instead they are rasterized for print output, i.e. Word or PDF. So if pixelation in line drawings or charts are not a biggie for print output, then that's not something you will be bothered by.

It would be nice if the callouts used in Capture and included in Flare projects, retain their crisp vector sharpness quality...i am told it'll be rectified soon. If FrameMaker is to be matched to some extent on this are with regards to professional print output, nonetheless Flare/Blaze is still a great single-sourcing tool.

Graphics resized for online output, as produced by Flare and Capture are top notch. Try the Min Height, or Min Width declarations, which should help to simplify things.
If you submit your bug feedback request here, the more likely it'll get fixed or included in a future release
Open Utilities PageLayout Resizer for Flare/Blaze | Batch builder
RiverMonster
Sr. Propeller Head
Posts: 149
Joined: Fri May 09, 2008 8:51 am
Location: Alicante, Spain
Contact:

Re: General Discussion on Graphics

Post by RiverMonster »

I just updated the original post to include info on Capture 3.0.

Regarding this comment...
forfear wrote:Graphics resized for online output, as produced by Flare and Capture are top notch. Try the Min Height, or Min Width declarations, which should help to simplify things.
...my tests didn't show exactly this; what I observed was the following:

> Graphics resized for online output in Flare are of great quality as long as Generate Resized Copies of Scaled Images is selected. There are a number of ways to achieve good results; you do not necessarily need to use min ht or min width.

> Graphics resized in Capture do not give good results in Flare online output, only in print ...and when resizing using Print DPI, not Print Size.

At least this is what I am seeing in my tests with PNGs.

Adrian
forfear
Propellus Maximus
Posts: 766
Joined: Sat Feb 16, 2008 3:37 am
Location: Jungle Jingles

Re: General Discussion on Graphics

Post by forfear »

RiverMonster,
Ya did a commendable job with a comprehensive discussion on graphics!
and i think it made an impact on getting some decent vector image support built into Flare, the way its meant to be in a Flare 4.2 patch.

Because by supporting a vector image file type the right way, takes away a lot of the image compression issues people have when working with images in print or online.
So its....
EMF

for line drawings and diagrams, or anything with callouts and text in them.

In most other cases, its
JPG and PNG



My tests after the Flare 4.2 patch release, indicates that the other picture formats are not worth considering.

Reasons below.

XPS (its actually a native vector file type, almost like EMF, but Flare RASTERIZES, it in the XML editor....a real no no) i think this is a bug. or perhaps there's no decent viewer for this Microsoft specced format other than the one embedded in Internet Explorer perhaps. it IS vector though
WDP and HDP (you're lucky if you can even view this file type or find a decent viewer for this, its too 'draft spec' ish for now) they are displayed as broken files in the XML editor.
TIF (rasterized)
WMF (the older version of EMF, the jaggies are less visible but still apparent. )

XAML,
EXPS (not to be confused with EPS)
(i couldn't find any illustration programs that saved to these formats)
If you submit your bug feedback request here, the more likely it'll get fixed or included in a future release
Open Utilities PageLayout Resizer for Flare/Blaze | Batch builder
KevinDAmery
Propellus Maximus
Posts: 1985
Joined: Tue Jan 23, 2007 8:18 am
Location: Darn, I knew I was around here somewhere...

Re: General Discussion on Graphics

Post by KevinDAmery »

XAML isn't an image format, so you would have a hard time finding systems that use it as such :) XAML stands for Extensible Application Markup Language and it's what Microsoft is using for their new WPF programming platform.

http://msdn.microsoft.com/en-us/library/ms752059.aspx
Until next time....
Image
Kevin Amery
Certified MAD for Flare
Andrew
Propellus Maximus
Posts: 1237
Joined: Fri Feb 10, 2006 5:37 am

Re: General Discussion on Graphics

Post by Andrew »

I believe XAML can be used to create graphics (though it isn't an image format, strictly speaking). However, it's not something most help authors need to worry about -- it's really more for user interfaces.
Flare v6.1 | Capture 4.0.0
RiverMonster
Sr. Propeller Head
Posts: 149
Joined: Fri May 09, 2008 8:51 am
Location: Alicante, Spain
Contact:

Re: General Discussion on Graphics

Post by RiverMonster »

Hi,

I updated the section on graphic resolution in Capture to Capture v4. When I get my hands on v5 I will update it again although I imagine most/all of what I say applies to that too.

Adrian
Post Reply