Font Dialog

LiveCode is the premier environment for creating multi-platform solutions for all major operating systems - Windows, Mac OS X, Linux, the Web, Server environments and Mobile platforms. Brand new to LiveCode? Welcome!

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
TonyL
Posts: 24
Joined: Mon Aug 07, 2006 1:15 am

Font Dialog

Post by TonyL » Fri Oct 03, 2008 7:29 pm

I am creating a font dialog for a Windows application I am developing.

The problem is, the available font sizes for a specific font is different on Revolution than in Windows.

Example: The available font sizes for MS Serif in a Windows font dialog is:
6,7,8,10,12,14,18,24

Using the fontSizes function in Rev, MS Serif returns:
8,9,10,13,16,17,22,29

Is there anything I can do to correct this?

Thanks,
Tony

Mark
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 5150
Joined: Thu Feb 23, 2006 9:24 pm
Contact:

Post by Mark » Fri Oct 03, 2008 7:57 pm

Hi Tony,

Where do you see that Windows font font dialog?

Although it is theoretically possible that Rev returns incorrect font sizes, I'd say Windows is at fault here, rather than Revolution.

Best,

Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode

TonyL
Posts: 24
Joined: Mon Aug 07, 2006 1:15 am

Post by TonyL » Fri Oct 03, 2008 8:15 pm

Hi Mark,

The Windows dialog is the Windows Common Font Dialog available in a lot of apps developed in VB, C etc.

Mark
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 5150
Joined: Thu Feb 23, 2006 9:24 pm
Contact:

Post by Mark » Fri Oct 03, 2008 9:04 pm

Hi Tony,

I understand which dialog you mean. You'd have to open the font in a font editor, see which sizes are available, and then compare that with the results given by Windows' font dialog and Rev's fontSizes function. I really couldn't tell whether Windows or Revolution is showing a bug here, or whether perhaps the font is corrupt.

Best,

Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode

TonyL
Posts: 24
Joined: Mon Aug 07, 2006 1:15 am

Post by TonyL » Fri Oct 03, 2008 10:06 pm

Thanks for the reply Mark. After looking closely at the Windows dialog, I noticed in the sample window that some of the edges of some of the fonts were jagged.

Leads me to think that it could be the Windows dialog. Good idea to check in a font editor to make sure.

Thanks again,
Tony

Post Reply