Sybase NNTP forums - End Of Life (EOL)

The NNTP forums from Sybase - forums.sybase.com - are now closed.

All new questions should be directed to the appropriate forum at the SAP Community Network (SCN).

Individual products have links to the respective forums on SCN, or you can go to SCN and search for your product in the search box (upper right corner) to find your specific developer center.

Bottom Justify Footer Text

3 posts in DataWindow Last posting was on 2009-07-23 17:37:10.0Z
Brad L Posted on 2009-07-22 15:20:38.0Z
Sender: 7f55.4a672aae.1804289383@sybase.com
From: Brad L
Newsgroups: sybase.public.powerbuilder.datawindow
Subject: Bottom Justify Footer Text
X-Mailer: WebNews to Mail Gateway v1.1t
Message-ID: <4a672e46.32f.1681692777@sybase.com>
NNTP-Posting-Host: forums-3-dub.sybase.com
X-Original-NNTP-Posting-Host: forums-3-dub.sybase.com
Date: 22 Jul 2009 08:20:38 -0700
X-Trace: forums-3-dub.sybase.com 1248276038 10.22.241.188 (22 Jul 2009 08:20:38 -0700)
X-Original-Trace: 22 Jul 2009 08:20:38 -0700, forums-3-dub.sybase.com
Lines: 11
Path: forums-1-dub!forums-master!forums-3-dub.sybase.com!not-for-mail
Xref: forums-1-dub sybase.public.powerbuilder.datawindow:89673
Article PK: 418862

We have a report builder where the user can add text or an
image to the footer of a composite report. They can also
specify the height of the footer. I would like to be able
to bottom justify whatever was specified. I'm able to get
the size of the image and subtract it from the height of the
footer to get the Y position and that works fine. I'm
struggling with the text though because we also let the user
specify a font and size of the text they want to show in the
footer. Is there any way to get the actual height of the
text at a given font and size at runtime in order to
determine the Y position? Thanks!


"Jerry Siegel [TeamSybase]" <jNOsSPAMsiegel Posted on 2009-07-22 17:19:21.0Z
From: "Jerry Siegel [TeamSybase]" <jNOsSPAMsiegel@yahoo!.com>
Newsgroups: sybase.public.powerbuilder.datawindow
References: <4a672e46.32f.1681692777@sybase.com>
Subject: Re: Bottom Justify Footer Text
Lines: 26
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.5512
X-RFC2646: Format=Flowed; Original
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.5579
NNTP-Posting-Host: vip152.sybase.com
X-Original-NNTP-Posting-Host: vip152.sybase.com
Message-ID: <4a674a19$5@forums-3-dub.sybase.com>
Date: 22 Jul 2009 10:19:21 -0700
X-Trace: forums-3-dub.sybase.com 1248283161 10.22.241.152 (22 Jul 2009 10:19:21 -0700)
X-Original-Trace: 22 Jul 2009 10:19:21 -0700, vip152.sybase.com
X-Authenticated-User: TeamSybase
Path: forums-1-dub!forums-master!forums-3-dub.sybase.com!not-for-mail
Xref: forums-1-dub sybase.public.powerbuilder.datawindow:89674
Article PK: 418861

How about the GetTextMetrics API?
http://msdn.microsoft.com/en-us/library/dd144941%28VS.85%29.aspx
or GetTextExtentPoint32 Function
http://msdn.microsoft.com/en-us/library/dd144938%28VS.85%29.aspx
I've done that in a previous life but can't seem to find sample code.

--
Report Bugs: http://case-express.sybase.com/cx/welcome.do
Product Enhancement Requests:
http://my.isug.com/cgi-bin/1/c/submit_enhancement

<Brad L> wrote in message news:4a672e46.32f.1681692777@sybase.com...
> We have a report builder where the user can add text or an
> image to the footer of a composite report. They can also
> specify the height of the footer. I would like to be able
> to bottom justify whatever was specified. I'm able to get
> the size of the image and subtract it from the height of the
> footer to get the Y position and that works fine. I'm
> struggling with the text though because we also let the user
> specify a font and size of the text they want to show in the
> footer. Is there any way to get the actual height of the
> text at a given font and size at runtime in order to
> determine the Y position? Thanks!


Brad L Posted on 2009-07-23 17:37:10.0Z
Sender: 61e6.4a6858c9.1804289383@sybase.com
From: Brad L
Newsgroups: sybase.public.powerbuilder.datawindow
Subject: Re: Bottom Justify Footer Text
X-Mailer: WebNews to Mail Gateway v1.1t
Message-ID: <4a689fc5.18b8.1681692777@sybase.com>
References: <4a674a19$5@forums-3-dub.sybase.com>
NNTP-Posting-Host: forums-3-dub.sybase.com
X-Original-NNTP-Posting-Host: forums-3-dub.sybase.com
Date: 23 Jul 2009 10:37:10 -0700
X-Trace: forums-3-dub.sybase.com 1248370630 10.22.241.188 (23 Jul 2009 10:37:10 -0700)
X-Original-Trace: 23 Jul 2009 10:37:10 -0700, forums-3-dub.sybase.com
Lines: 35
Path: forums-1-dub!forums-master!forums-3-dub.sybase.com!not-for-mail
Xref: forums-1-dub sybase.public.powerbuilder.datawindow:89678
Article PK: 418866

Thanks for the direction. I was able to use the
GetTextExtentPoint32 to get what I needed. Good Stuff!!!
Thanks Again!

> How about the GetTextMetrics API?
>
http://msdn.microsoft.com/en-us/library/dd144941(VS.85).aspx
> or GetTextExtentPoint32 Function
>
http://msdn.microsoft.com/en-us/library/dd144938(VS.85).aspx
> I've done that in a previous life but can't seem to find
> sample code.
>
> --
> Report Bugs: http://case-express.sybase.com/cx/welcome.do
> Product Enhancement Requests:
> http://my.isug.com/cgi-bin/1/c/submit_enhancement
>
>
> <Brad L> wrote in message
> > news:4a672e46.32f.1681692777@sybase.com... We have a
> > report builder where the user can add text or an image
> > to the footer of a composite report. They can also
> > specify the height of the footer. I would like to be
> able to bottom justify whatever was specified. I'm able
> > to get the size of the image and subtract it from the
> > height of the footer to get the Y position and that
> > works fine. I'm struggling with the text though because
> > we also let the user specify a font and size of the text
> > they want to show in the footer. Is there any way to
> > get the actual height of the text at a given font and
> > size at runtime in order to determine the Y position?
> Thanks!
>
>