Peter, I have observed this since the new field control was introduced in 5.somthing. I have to keep adjusting my code to take into account for minor changes as new LC versions get released. I have submitted a bug report. http://quality.runrev.com/show_bug.cgi?id=12176 Check out the demo stack. This is related to bug reports 11640/11904
Ralph DiMola IT Director Evergreen Information Services rdim...@evergreeninfo.net -----Original Message----- From: use-livecode [mailto:use-livecode-boun...@lists.runrev.com] On Behalf Of Peter Haworth Sent: Thursday, July 10, 2014 1:07 PM To: How to use LiveCode Subject: formattedWidth I recently posted about how to adjust the size of different cards within a stack and part of the solution I tried was using the formattedWidth and formattedHeight properties (actually the effective versions of them). I'm now seeing that the formattedWidth (and probably formattedHeight) return very unexpected values. The dictionary says it returns the width of a rectangle that contains all objects in the card whose visible property is true but I'm not seeing that. Make yourself a stack with a field on it with it's left edge in the middle of the stack and it's right edge somewhere off the right edge of the stack. Put a button on the card with the following code: get the rectangle of this stack put item 1 of it + the formattedWidth of this card into item 3 of it set the rectangle of this stack to it When you click the button, the stack will resize to the width of the field, in other words, the right edge of the field will still be off the right edge of the stack. The only way this works correctly is if the field's left edge is at the left edge of the stack. I'm sure this is way formattedWIdth has always worked so it's not likely to be changed but it seems to be a not very useful implementation to me. Is there some other property that can be used to set the width of a stack to something that really does include all the objects on it? Pete lcSQL Software <http://www.lcsql.com> Home of lcStackBrowser <http://www.lcsql.com/lcstackbrowser.html> and SQLiteAdmin <http://www.lcsql.com/sqliteadmin.html> _______________________________________________ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode _______________________________________________ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode