1. win32 text spacing

I've had a problem trying to determine text spacing on a screen for a long 
time. My software looks fine on some screens and not on others. I've been
trying to figure this out and this link seems to have the parms I need.

http://msdn2.microsoft.com/en-us/library/ms534015.aspx

Does anyone know if we have a win32 function which returns these values
depicted in the drawing? We have a getTextExtent but it does not have the
spacing between lines. I can't seem to find such a function in win32lib.

new topic     » topic index » view message » categorize

2. Re: win32 text spacing

George Walters wrote:
> 
> I've had a problem trying to determine text spacing on a screen for a long 
> time. My software looks fine on some screens and not on others. I've been
> trying to figure this out and this link seems to have the parms I need.
> 
> <a
> href="http://msdn2.microsoft.com/en-us/library/ms534015.aspx">http://msdn2.microsoft.com/en-us/library/ms534015.aspx</a>
> 
> Does anyone know if we have a win32 function which returns these values
> depicted in the drawing? We have a getTextExtent but it does not have the
> spacing between lines. I can't seem to find such a function in win32lib.

getFontMetric(id,field) has been here to help for a long time. It will return
any of the tmxxx or ntmxxx fields.

If you need the outline (otmxxx) parameters, then you'll need to wrap an extra
Windows API and refer to the documentation for GetOutlineTextMetrics() on MSDN,
and define the OUTLINETEXTMETRICS structure to access the data (or peek at the
right places).

I could consider extending getFontMetric() to return these at well, but there
will be hardly any development of any kind for the next 8-10 days, so I'm not
promising it for 70.3. The extension will be in 70.4, for which I'm not giving
any timetable - should be during 2008 -, anyway.

CChris.

new topic     » goto parent     » topic index » view message » categorize

3. Re: win32 text spacing

Thanks, getFontMetric(id,field) should be sufficient for me.

Thanks

CChris wrote:
> 
> George Walters wrote:
> > 
> > I've had a problem trying to determine text spacing on a screen for a long 
> > time. My software looks fine on some screens and not on others. I've been
> > trying to figure this out and this link seems to have the parms I need.
> > 
> > <a
> > href="http://msdn2.microsoft.com/en-us/library/ms534015.aspx">http://msdn2.microsoft.com/en-us/library/ms534015.aspx</a>
> > 
> > Does anyone know if we have a win32 function which returns these values
> > depicted in the drawing? We have a getTextExtent but it does not have the
> > spacing between lines. I can't seem to find such a function in win32lib.
> 
> getFontMetric(id,field) has been here to help for a long time. It will return
> any of the tmxxx or ntmxxx fields.
> 
> If you need the outline (otmxxx) parameters, then you'll need to wrap an extra
> Windows API and refer to the documentation for GetOutlineTextMetrics() on
> MSDN,
> and define the OUTLINETEXTMETRICS structure to access the data (or peek at the
> right places).
> 
> I could consider extending getFontMetric() to return these at well, but there
> will be hardly any development of any kind for the next 8-10 days, so I'm not
> promising it for 70.3. The extension will be in 70.4, for which I'm not giving
> any timetable - should be during 2008 -, anyway.
> 
> CChris.

new topic     » goto parent     » topic index » view message » categorize

Search



Quick Links

User menu

Not signed in.

Misc Menu