PDA

View Full Version : Checking fonts before (re-) installing



NewsArchive
05-01-2009, 04:27 AM
There is a disparity in font-name here which is confusing me:

** In "Register Font" the SB help is quite specific about what should be
used in the entry fields... *very* specific:

Font File Name

[in] String that specifies the full path to the font file. The file
must be a valid Windows .TTF file. When the font is installed, it should be
installed to the standard Windows Fonts directory (%FONTSDIR%). Wildcard
characters, such as "*", are not permitted.


Font Name

[in] String that specifies the name you want to use for the TrueType
font (as it will appear in the Registry). The font name must be followed by
(TrueType). An example for the Arial font would be: Arial (TrueType).



** However, when it comes to "Check Font", it is to me quite unclear what I
should be using for fontname:

Font Name

[in] String that specifies the typeface name of the font you want to
check. You can use variables to build the font name.


And in fact the example muddies the waters even more, by using a 'simple'
font name:
Set Variable %FONT_EXISTS% to FUNCTION:Check Font "Verdana"



So, to clarify for me:
1. I want to ensure that *all 4 variants* of "Arial Narrow" are installed
2. I have set up "Install File" and "Register Font" for each of those 4
variants
3. If I now want to wrap that up checking if it/they are *already* installed
and not to do so again if that is the case: what do I put in "Check Font"?

Is it
a) "Arial Narrow" (one time).. which seems to be what is implied by the
SB help (but which seems to me cannot check all variants), or
b) 4 x "Check Font" lines, using the font names from the Registry, as
required in "Register Font", or
c) something else


Once we've sorted this out, a mod. to the help/doco clarifying this would
be a good idea.

tia
Steve

NewsArchive
05-01-2009, 04:28 AM
You have to check for all 4 font names. The following checks whether "Arial
Narrow Bold Italic" does exist:

Set Variable %EXISTS% to FUNCTION:Check Font "Arial Narrow Bold Italic"

Do the same for "Arial Narrow", "Arial Narrow Bold" and "Arial Narrow
Italic" and you are done.

HTH,
Friedrich

--
Friedrich Linder
Lindersoft
www.lindersoft.com
+1.954.252.3910

SetupBuilder "point. click. ship"
Create Windows Vista ready installations in minutes

-- Official Comodo Code Signing and SSL Certificate Partner

NewsArchive
05-01-2009, 04:28 AM
Ok, I see.... option "b -minus"... <g>

I trust you see what I mean about the difference in naming styles.

Tx

Steve Bywaters

NewsArchive
05-04-2009, 01:32 AM
Since - as you pointed out - the std. Install File handles font installation
and reg..... is there any reason why *not* to use the "Never": replacement
option in that dialog rather than explicitly using the "Check font.."
command?

Seems to me just another way to the same result, no?

Steve Bywaters

NewsArchive
05-04-2009, 01:32 AM
> Since - as you pointed out - the std. Install File handles font
> installation and reg..... is there any reason why *not* to use the
> "Never": replacement option in that dialog rather than explicitly
> using the "Check font.." command?
>
> Seems to me just another way to the same result, no?

The Install File(s) replacement option just checks if a font file
"physically" exists. The Check Font function determines whether a
particular font is "registered".

It's possible to have a font file in the Windows Fonts folder and Windows
does not know anything at all about it (because it's not registered).

And it's also possible that the same font has completely different
filenames (e.g. if a non-standard font comes from a font website).

--
Friedrich Linder
Lindersoft
www.lindersoft.com
+1.954.252.3910

SetupBuilder "point. click. ship"
Create Windows Vista ready installations in minutes

-- Official Comodo Code Signing and SSL Certificate Partner