slothg / flex-object-handles

Automatically exported from code.google.com/p/flex-object-handles
0 stars 0 forks source link

[ObjectHandlesV1]:How to increase & decrease font size according to objecthandles resizing #49

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Hi,

i am using ObjectHandlesV1 and i want to do font size increase & decrease 
according to objecthandle resizing. 

how to increase & decrease font size according to objecthandles resizing.

how to possible.

please help me  

Original issue reported on code.google.com by abidr...@gmail.com on 13 Jan 2011 at 1:00

GoogleCodeExporter commented 9 years ago
One way to do this is to set up a custom MXML shape/group definition with an 
attached OH model and an included text element. Then, bind the fontSize  
property for the text element to the model/object height (e.g. 
fontSize="{Math.abs(height)}"). You'll have to play with this a bit. One 
problem you'll encounter is that as the handles are resized, the text may start 
to extend beyond the horizontal border of the container object. There are a few 
possible solutions to that, but I'll leave that for you or someone else to 
explore as I haven't fixed that problem yet myself.

Original comment by stephenk...@gmail.com on 22 Aug 2011 at 12:27