Thanks for the extra set of eyes! The extra comma was the problem.

Thanks,

David Ruggles
CCNA MCSE (NT) CNA A+
Network Engineer        Safe Data, Inc.
(910) 285-7200  [email protected]



-----Original Message-----
From: Mark Miesfeld [mailto:[email protected]] 
Sent: Thursday, January 28, 2010 12:00 PM
To: Open Object Rexx Developer Mailing List
Subject: Re: [Oorexx-devel] Odd OODialog Font Issue


On Thu, Jan 28, 2010 at 8:21 AM, David Ruggles <[email protected]>
wrote:

> I upgraded from oorexx 3.2 to oorexx 4.0 on a windows 2000 machine. I am
> creating a dialog using a subclass of userdialog with this statement:
>    rc = self~create(0, 0, width, height, title, , , , 'MS Sans Serif', 8)

Prior to 4.0 ooDialog's handling of fonts was completely broken.  I
opened a bug and attached a program that demonstrates it was broken.
Forget the number right now, but it should be easy to find.

> On 3.2 the font displays as expected, however on 4.0 it doesn't.
>
> Is there a quick fix for this?

This would depend on what you mean by "expected," probably.  Since you
are explicitly specifying the font in the create() method, for that
case, I would have expected 3.2.0 and 4.0.0 to behave exactly the
same.

If you could send me a program that demonstrates this, I'll take a
look at why it isn't working as I would expect.  Send it to miesfeld
at gmail.

One thing most people don't realize is that when you specify a font,
the Windows font manager creates a logical font that it thinks most
closely matches what is requested.  It always gives you a font.  But,
if there is no close match, what you actually get could be far
different then what you wanted.

Since I don't have easy access to a W2K box, if it is easy for you to
try, could you see if this same behavior exists on a XP machine?

Well, I wrote the above and then looked more closely at your create()
call.  The above is all still valid, but

rc = self~create(0, 0, width, height, title, , , , 'MS Sans Serif', 8)

that looks to have too many commas

rc = self~create(0, 0, width, height, title, options, dlgClass,
fontNameBelongsHereThenNextSouldBeSize, 'MS Sans Serif', 8)

So, your call is incorrect, and who knows what font you are actually
getting.  But probably, you are getting System 10.  A quick fix could
be to add this to the top of your dialog code:

.PlainBaseDialog~setDefaultFont("System", 10)  -- or maybe 8

If, I'm correct in the font you are actually getting, this should also
give your dialog the same appearance:

rc = self~create(0, 0, width, height, title,  ,  , "System", 10)  -- or
maybe 8

Let me know if that works.  If not, I'll need to the example program.

--
Mark Miesfeld

----------------------------------------------------------------------------
--
The Planet: dedicated and managed hosting, cloud storage, colocation
Stay online with enterprise data centers and the best network in the
business
Choose flexible plans and management services without long-term contracts
Personal 24x7 support from experience hosting pros just a phone call away.
http://p.sf.net/sfu/theplanet-com
_______________________________________________
Oorexx-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/oorexx-devel


------------------------------------------------------------------------------
The Planet: dedicated and managed hosting, cloud storage, colocation
Stay online with enterprise data centers and the best network in the business
Choose flexible plans and management services without long-term contracts
Personal 24x7 support from experience hosting pros just a phone call away.
http://p.sf.net/sfu/theplanet-com
_______________________________________________
Oorexx-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/oorexx-devel

Reply via email to