VB Uses Bitmap Fonts when TrueType FontSize is Less than 8

ID Number: Q84483

1.00

WINDOWS

buglist1.00

Summary:

The Microsoft Windows 3.1 operating environment provides you with

TrueType scalable fonts that can be used in Visual Basic applications.

Microsoft Visual Basic programming system version 1.0 for Windows

supports TrueType fonts only for font sizes of 8 or greater. Smaller

fonts are mapped to available bitmap fonts. There is no way to force

Visual Basic to use TrueType fonts for font sizes less than 8.

Microsoft has confirmed this to be a problem in Microsoft Visual Basic

programming system version 1.0 for Windows. We are researching this

problem and will post new information here as it becomes available.

More Information:

The program below demonstrates the problem. The program attempts to

print a message using the Arial font in sizes from 1 to 9. Visual Basic

incorrectly uses the font Small Fonts for font sizes less than 6, and

incorrectly uses MS Serif for font sizes between 6 and 8, inclusive.

Steps to Reproduce Problem

--------------------------

1. Run Visual Basic, or from the File menu, choose New Project (ALT,

F, N) if Visual Basic is already running. Form1 is created by

default.

2. Enter the following code into the Form_Click procedure:

Sub Form_Click ()

For i = 1 To 9 Step .25

FontName = "Arial"

FontSize = i

Print Str$(i); Chr$(9); Str$(FontSize); Chr$(9); FontName

Next i

End Sub

3. Press F5 to run the program, and click anywhere on the form. Notice

that the Arial TrueType font is used only for font sizes of 8.25 or

larger.

Additional reference words: 1.00 3.10