> I’m needing to know the coordinate (Y is the tricky one) for a line of text...
the selectedLoc
if you need the rectangle use additionally measureText or measureUnicodeText
___
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this
on the loc of the field, and otherwise has no
relationship to the field itself, that is, the Y coordinate within that field.
Craig
-Original Message-
From: Mark Wieder via use-livecode
To: dunbarx--- via use-livecode
Cc: Mark Wieder
Sent: Wed, Nov 13, 2019 11:20 am
Subject: Re: Y coordinate
On 11/13/19 10:11 AM, dunbarx--- via use-livecode wrote:
The selectedLoc will give the loc in window coordinates, not the "local" Y
coordinate within the field of interest, which is what I thought you wanted. I cannot
imagine what value that would have, since it depends on where the stack
Mark,
Yep, that will do the translation. But I am no longer sure what the OP
originally wanted.
OP?
Craig
-Original Message-
From: Mark Wieder via use-livecode
To: dunbarx--- via use-livecode
Cc: Mark Wieder
Sent: Wed, Nov 13, 2019 11:20 am
Subject: Re: Y coordinate for a line
On 11/13/19 8:11 AM, dunbarx--- via use-livecode wrote:
The selectedLoc will give the loc in window coordinates, not the "local" Y
coordinate within the field of interest, which is what I thought you wanted. I cannot
imagine what value that would have, since it depends on where the stack
al Message-
From: scott--- via use-livecode
To: How to use LiveCode
Cc: sc...@elementarysoftware.com
Sent: Tue, Nov 12, 2019 10:12 pm
Subject: Re: Y coordinate for a line of text
Thank you Craig and Paul. Your answers were what I was hoping for. Devin, it
turned out that selectedLoc() was t
Thank you Craig and Paul. Your answers were what I was hoping for. Devin, it
turned out that selectedLoc() was the easiest to implement. How did I not know
about that function!
Thanks!
Scott Morrow
Elementary Software
(Now with 20% less chalk dust!)
web https://elementarysoftware.com/
The selectedLoc function may also be helpful.
> On Nov 12, 2019, at 7:27 AM, Paul Dupuis via use-livecode
> wrote:
>
> You may want to look at the Dictionary entry for "measureText"
>
>
> On 11/12/2019 1:43 AM, scott--- via use-livecode wrote:
>> I’m needing to know the coordinate (Y is the
You may want to look at the Dictionary entry for "measureText"
On 11/12/2019 1:43 AM, scott--- via use-livecode wrote:
I’m needing to know the coordinate (Y is the tricky one) for a line of text.
I’m not do a very good job at calculating it. I think I remember a newish LC
command or function
Sent: Tue, Nov 12, 2019 9:05 am
Subject: Re: Y coordinate for a line of text
Hi.
Assuming you have a field 1 with several lines of text in it, and have set the
textHeight of that field, then in a button script somewhere;
on mouseUpanswer the textHeight of fld 1 * lineOffset(yourText,fld 1) + the top
use-livecode
To: How to use LiveCode
Cc: sc...@elementarysoftware.com
Sent: Tue, Nov 12, 2019 1:45 am
Subject: Y coordinate for a line of text
I’m needing to know the coordinate (Y is the tricky one) for a line of text.
I’m not do a very good job at calculating it. I think I remember a newish
I’m needing to know the coordinate (Y is the tricky one) for a line of text.
I’m not do a very good job at calculating it. I think I remember a newish LC
command or function that achieved this but I can’t locate it in the dictionary.
Am I imagining?
--
Scott Morrow
Elementary Software
(Now
12 matches
Mail list logo