Re: NewEra 3.0 Question
Posted in 1997
Topics: Clustering, Grid & MACH11
In article <5sj5oh$a13@cssun.mathcs.emory.edu>, candym@olcinc.com ("Candy McCall") wrote: > > I have a NewEra 3.0 question: > > I'm creating a grid-form supertable in which the columns are determined > at run-time (they are based on a query). When I create the superfields for > the supertable, I want to set the width of the superfield depending on the > length of the title or the max # chars allowed in the field (which ever is > greater). How can I determine the width of a font character in twips > depending on the > point size of the font? The font will be a font in which the width of all > characters are > the same (such as Courier New). I guess the width should be from the > left-most > part of a character to the leftmost part of the next character. > > Thanks in advance! > > Candy > > -- > Candy McCall > On-Line Computing, Inc. > (candym@olcinc.com) I have come with a solution using trial and error with the painter. Since I'm always using courier new 10, I use the following function: FUNCTION getGridFieldWidth( length SMALLINT ) RETURNING SMALLINT RETURN ( (length*120) + 105 ) END FUNCTION -- getGridFieldWidth Francois Brulotte -------------------==== Posted via Deja News ====----------------------- http://www.dejanews.com/ Search, Read, Post to Usenet