"Typesetting" functions

Sivakatirswami katir at hindu.org
Fri Dec 16 19:28:55 EST 2005


I tried getting the formattedWidth of a chunk expression for char 1  
to char -1 of someFooLine.. but this gets you a pixel integer,  how  
do you translate that into "len(someSpacesStringToInsert)" /2

example all in one field.

Center This Title

paragraph aligned left; paragraph aligned left; paragraph aligned  
left; paragraph aligned left;
paragraph aligned left; paragraph aligned left; paragraph aligned  
left; paragraph aligned left;
paragraph aligned left; paragraph aligned left; paragraph aligned  
left; paragraph aligned left;

Maybe the formula is there, but I couldn't get my head around it, if  
it is..??

Sivakatirswami

On Dec 16, 2005, at 7:10 AM, Bill Marriott wrote:

> Sivakatirswami,
>
> Have you looked into whether formattedWidth, formattedHeight and other
> formatted* commands will help you achieve this? I don't think  
> you'll be able
> to get kerning control or Quark-like results when printing, but these
> functions may be of use when trying to get screen elements to look  
> right.
>
> Bill
>
> "Sivakatirswami" <katir at hindu.org> wrote in
> message news:FA40421A-B673-4B13-A1CE-8BAE1ADF0257 at hindu.org...
>
>> I was wondering if any one had "rolled their own" typesetting   
>> functions.
>> I would rather not have to create multiple flds and then  group  
>> these with
>> some being centered and others align left... so I  was thinking  
>> that one
>> could, for example, center type but getting  some measurement of the
>> len(the selection) and then inserting  something like
>>
>> (an algorithm that needs real code:)
>>
>> the total length of the line -(the length of type to be centered)/2 =
>> (some  number of spaces to insert in front of the text)
>>
>
>
>
> _______________________________________________
> use-revolution mailing list
> use-revolution at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your  
> subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-revolution
>




More information about the use-livecode mailing list