Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Full disclosure



This works for me:

on clicked the_object
set object_name to name of the_object as string
if object_name = "disclosure" then
if state of the_object = 0 then
set the_delta to 200
else
set the_delta to -200
end if
tell window of the_object
set {x1, y1, x2, y2} to bounds
set bounds to {x1, (y1 + the_delta), x2, y2}
end tell
end if
end clicked

Jon

> I'd also like to see an example of how to use disclosure arrows. I'm
> interested in something similar to the Finder's Info window. Without thinking
> too much about it, I'd imagined having several custom views, nestled one above
> the other in a window. Each custom view has the disclosure button at the top.
> When the disclosure button is clicked, the height of the custom view
> containing it is toggled between tall and short, and the size of the window
> adjusted accordingly.
>
> The second thing is that the bounds of a window requires a _4_ integer list,
> specifying the coordinates of opposing corners {left, bottom, right, top}; for
> example, {0, 0, 500, 250}.
>
> MarkB
>
> On 2003 Dec 09, at 13:51, T.J. Mahaffey wrote:
>
>> Has anyone had success making a disclosure arrow work?
>>
>> I'm trying to do something like:
>>
>>
>> ===
>> on click
>> set bounds of window "main" to {350, 400}
>> end click
>> ===
>>
>> But I'm throwing an error, despite defining the window's resize as true.
>>
>> Can someone post a working example?
>> --
>> T.J. Mahaffey
>> email@hidden
_______________________________________________
applescript-studio mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-studio
Do not post admin requests to the list. They will be ignored.



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.