Index
2015-03-03 10:37Paul Newton : Autosize and labels
2015-03-03 10:42Dave Crozier : RE: Autosize and labels
2015-03-03 10:42Fred Taylor : Re: Autosize and labels
2015-03-03 12:09Rafael Copquin : Re: Autosize and labels
2015-03-03 13:39Tracy Pearson : RE: Autosize and labels
2015-03-03 16:49Rafael Copquin : Re: Autosize and labels
Back to top
Autosize and labels

Author: Paul Newton

Posted: 2015-03-03 10:37:54   Link

Hi all

I have a label which is has Autosize set to .T. but when I change the caption at runtime it does not resize properly - any ideas how I can force it to do so?

Many thanks

Paul Newton

_______________________________________________

Post Messages to: ProFox@leafe.com

Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/profox

OT-free version of this list: http://mail.leafe.com/mailman/listinfo/profoxtech

Searchable Archive: http://leafe.com/archives/search/profox

This message: http://leafe.com/archives/byMID/profox/9A8106AFB0EF9B44B69045C4448935A270BEC20B@NLBAWEXMBX1.infor.com

** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious.

©2015 Paul Newton
Back to top
RE: Autosize and labels

Author: Dave Crozier

Posted: 2015-03-03 10:42:09   Link

Paul,

Set autosize = .f. then populate the label with appropriate text and then set autosize .T..

I subclassed the label and did this automatically on the assign method as it is a known problem with certain fonts/sizes and sometimes the field will autosize and just miss off the start/end of the label caption depending upon what fonts are used. If you use the assign to size the label then you can size the label exactly by using the sysmetric() settings for the font you are using.

-----Original Message-----

From: ProFox [mailto:profox-bounces@leafe.com] On Behalf Of Paul Newton

Sent: 03 March 2015 16:38

To: profox@leafe.com

Subject: Autosize and labels

Hi all

I have a label which is has Autosize set to .T. but when I change the caption at runtime it does not resize properly - any ideas how I can force it to do so?

Many thanks

Paul Newton

[excessive quoting removed by server]

_______________________________________________

Post Messages to: ProFox@leafe.com

Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/profox

OT-free version of this list: http://mail.leafe.com/mailman/listinfo/profoxtech

Searchable Archive: http://leafe.com/archives/search/profox

This message: http://leafe.com/archives/byMID/profox/18725B8CD2D5D247873A2BAF401D4AB2468C68C1@EX2010-A-FPL.FPL.LOCAL

** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious.

©2015 Dave Crozier
Back to top
Re: Autosize and labels

Author: Fred Taylor

Posted: 2015-03-03 10:42:10   Link

What's your .WordWrap property value? Change it to the opposite of

whatever it is and try that.

Fred

On Tue, Mar 3, 2015 at 9:37 AM, Paul Newton <Paul.Newton@pegasus.co.uk>

wrote:

> Hi all

>

> I have a label which is has Autosize set to .T. but when I change the

> caption at runtime it does not resize properly - any ideas how I can force

> it to do so?

>

> Many thanks

>

> Paul Newton

>

[excessive quoting removed by server]

_______________________________________________

Post Messages to: ProFox@leafe.com

Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/profox

OT-free version of this list: http://mail.leafe.com/mailman/listinfo/profoxtech

Searchable Archive: http://leafe.com/archives/search/profox

This message: http://leafe.com/archives/byMID/profox/CAJCBksqChm4yWsSA91B=M4u7oiN6UGk=3srZMXNPG-_9HRgXEg@mail.gmail.com

** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious.

©2015 Fred Taylor
Back to top
Re: Autosize and labels

Author: Rafael Copquin

Posted: 2015-03-03 12:09:07   Link

That's interesting. Can you post an example (code snippet I mean) ?

I am not very familiarized with the assign method. Could never use it

properly. Perhaps an example will clarify this issue for me.

TIA

Rafael Copquin

El 03/03/2015 a las 13:42, Dave Crozier escibió:

> Paul,

> Set autosize = .f. then populate the label with appropriate text and then set autosize .T..

>

> I subclassed the label and did this automatically on the assign method as it is a known problem with certain fonts/sizes and sometimes the field will autosize and just miss off the start/end of the label caption depending upon what fonts are used. If you use the assign to size the label then you can size the label exactly by using the sysmetric() settings for the font you are using.

>

> -----Original Message-----

> From: ProFox [mailto:profox-bounces@leafe.com] On Behalf Of Paul Newton

> Sent: 03 March 2015 16:38

> To: profox@leafe.com

> Subject: Autosize and labels

>

> Hi all

>

> I have a label which is has Autosize set to .T. but when I change the caption at runtime it does not resize properly - any ideas how I can force it to do so?

>

> Many thanks

>

> Paul Newton

>

[excessive quoting removed by server]

_______________________________________________

Post Messages to: ProFox@leafe.com

Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/profox

OT-free version of this list: http://mail.leafe.com/mailman/listinfo/profoxtech

Searchable Archive: http://leafe.com/archives/search/profox

This message: http://leafe.com/archives/byMID/profox/54F5F8C3.4020104@fibertel.com.ar

** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious.

©2015 Rafael Copquin
Back to top
RE: Autosize and labels

Author: Tracy Pearson

Posted: 2015-03-03 13:39:30   Link

Rafael Copquin wrote on 2015-03-03:

> That's interesting. Can you post an example (code snippet I mean) ?

> I am not very familiarized with the assign method. Could never use it

> properly. Perhaps an example will clarify this issue for me.

>

> TIA

>

> Rafael Copquin

>

> El 03/03/2015 a las 13:42, Dave Crozier escibió:

> Paul,

> Set autosize = .f. then populate the label with appropriate text and

then set autosize .T..

>

> I subclassed the label and did this automatically on the assign method as

it is a known problem with certain fonts/sizes and sometimes the field will

autosize and just miss off the start/end of the label caption depending upon

what fonts are used. If you use the assign to size the label then you can

size the label exactly by using the sysmetric() settings for the font you

are using.

>

Rafael,

Not tested

Define Class baseLabel as Label

Procedure Caption_Assign

LParameters cValue

If This.AutoSize = .T.

This.AutoSize = .F.

This.Caption = cValue

This.AutoSize = .T.

Else

This.Caption = cValue

EndIf

EndProc

EndDefine

I would gather that would be the structure of the method he created.

HTH,

Tracy

Tracy Pearson

PowerChurch Software

_______________________________________________

Post Messages to: ProFox@leafe.com

Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/profox

OT-free version of this list: http://mail.leafe.com/mailman/listinfo/profoxtech

Searchable Archive: http://leafe.com/archives/search/profox

This message: http://leafe.com/archives/byMID/profox/000f01d055e9$c4fc14a0$4ef43de0$@powerchurch.com

** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious.

©2015 Tracy Pearson
Back to top
Re: Autosize and labels

Author: Rafael Copquin

Posted: 2015-03-03 16:49:26   Link

Thank you

regards

Rafael

El 03/03/2015 a las 16:39, Tracy Pearson escibió:

> Rafael Copquin wrote on 2015-03-03:

>> That's interesting. Can you post an example (code snippet I mean) ?

>> I am not very familiarized with the assign method. Could never use it

>> properly. Perhaps an example will clarify this issue for me.

>>

>> TIA

>>

>> Rafael Copquin

>>

>> El 03/03/2015 a las 13:42, Dave Crozier escibió:

>> Paul,

>> Set autosize = .f. then populate the label with appropriate text and

> then set autosize .T..

>>

>> I subclassed the label and did this automatically on the assign method as

> it is a known problem with certain fonts/sizes and sometimes the field will

> autosize and just miss off the start/end of the label caption depending upon

> what fonts are used. If you use the assign to size the label then you can

> size the label exactly by using the sysmetric() settings for the font you

> are using.

>>

> Rafael,

>

> Not tested

> Define Class baseLabel as Label

> Procedure Caption_Assign

> LParameters cValue

> If This.AutoSize = .T.

> This.AutoSize = .F.

> This.Caption = cValue

> This.AutoSize = .T.

> Else

> This.Caption = cValue

> EndIf

> EndProc

> EndDefine

>

> I would gather that would be the structure of the method he created.

>

> HTH,

> Tracy

>

> Tracy Pearson

> PowerChurch Software

>

>

[excessive quoting removed by server]

_______________________________________________

Post Messages to: ProFox@leafe.com

Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/profox

OT-free version of this list: http://mail.leafe.com/mailman/listinfo/profoxtech

Searchable Archive: http://leafe.com/archives/search/profox

This message: http://leafe.com/archives/byMID/profox/54F63A76.1090509@fibertel.com.ar

** All postings, unless explicitly stated otherwise, are the opinions of the author, and do not constitute legal or medical advice. This statement is added to the messages for those lawyers who are too stupid to see the obvious.

©2015 Rafael Copquin