Adobe 12040118 - After Effects Standard Using Manual page 203

Using help
Hide thumbs Also See for 12040118 - After Effects Standard:
Table of Contents

Advertisement

Adobe After Effects Help
Using Help
You can control the size of each 'step' by setting the stepdelta property. Clicking ahead of or behind the position
indicator makes the position indicator jump a fixed number of values toward the point where you clicked. You
can control the size of this jump by setting the jumpdelta property.
You can create scrollbars with horizontal or vertical orientation; if width is greater than height, the orientation
is horizontal, otherwise it is vertical. The following example creates a Scrollbar element with associated
StaticText and EditText elements within a panel:
d l g . s i ze Pn l = d l g .a d d ( 'p a n e l ', [ 6 0 , 2 4 0 , 3 2 0 , 3 1 5 ] , ' D i m e n s i o n s' ) ;
d l g . s i ze Pn l . w i d t h S t = d l g . s i ze Pn l . a d d ( 's t a t i c tex t', [ 1 5 , 1 5 , 6 5 , 3 5 ] ,
'Wi dth :';
d l g . s i ze Pn l . w i d t h S c r l = d l g . s i ze Pn l . a d d ( 's c ro l l b a r ',
[75,15,195, 35], 300, 300, 800) ;
d l g . s i ze Pn l . w i d t h Et = d l g . s i ze Pn l . a d d ( 'e d i t tex t', [ 2 0 5 , 1 5 , 2 4 5 , 3 5 ] ) ;
Note that the last 3 arguments to the add() method that creates the scrollbar define the values for the value,
minvalue and maxvalue properties. Scrollbars are often created with an associated EditText field to display the
current value of the scrollbar, and to allow setting the scrollbar's position to a specific value.
Creating a window using window resource specifications
A specially formatted string provides a simple and compact means of creating a window and its component
elements as a resource specification. A resource specification allows you to define and configure multiple
window components in one easy-to-reference script.
The special string is passed as the type parameter to the Window constructor function, as follows:
/ / c re a te a n e w d i a l o g f ro m a re s o u rce s p e c i fi c a t i o n
var aler tBuilderResource =
"d ialo g { tex t: 'Aler t B ox Bu ilde r', b ou n ds: [100, 100, 480, 490], \
m s g Pn l : Pa n e l { tex t : ' Me s s a g e s', b o u n d s : [ 2 5 , 1 5 , 3 5 5 , 1 3 0 ] , \
t i t l e S t : S t a t i c Tex t { tex t : ' A l e r t b ox t i t l e : ', \
b o u n d s : [ 1 5 , 1 5 , 1 0 5 , 3 5 ] } , \
titl eEt:E di tText { text:'S a mple Ale r t', bound s: [115, 15, 315, 35] }, \
msg S t: S ta ticTex t { tex t:'Ale r t me ssa g e : ', \
b o u n d s : [ 1 5 , 6 5 , 1 0 5 , 8 5 ] } , \
msg Et: E d itText { tex t:'<yo u r me ssa ge h ere >', \
bounds:[115,45,315,105], proper ties:{multiline:t r ue} } \
}, \
hasBt nsCb: Checkbox { text:'Has aler t buttons?', alig nment:'center', \
aler tBt nsPn l: Pa n el { tex t:'Bu t ton a lig n me n t', b ou nd s: [45, 180, 335, 225], \
ali g n Left R b:R a d ioBu tton { tex t : 'Le f t', b ound s: [15, 15, 95, 35] }, \
alig nCenterRb:RadioButton { text:'Center', \
b o u n d s : [ 1 0 5 , 1 5 , 1 8 5 , 3 5 ] } , \
ali g n R ig ht R b:R a d ioBu tton { tex t: 'R ig h t', bound s: [195, 15, 275, 35] } \
}, \
si zePnl: Pa n el { text: 'Dime n sio n s', b ou n ds: [60, 240, 320, 315], \
w i d t h S t : S t a t i c Tex t { tex t : ' Wi d t h : ', b o u n d s : [ 1 5 , 1 5 , 6 5 , 3 5 ] } , \
w idth S crl: S cro llba r { minv a lu e : 300, ma x v alue : 800, \
w i d t h Et : E d i t Tex t { b o u n d s : [ 2 0 5 , 1 5 , 2 4 5 , 3 5 ] } , \
h e i g h t S t : S t a t i c Tex t { tex t : ' He i g h t : ', b o u n d s : [ 1 5 , 4 5 , 6 5 , 6 5 ] } , \
heig h tS crl: S cro llba r { minv a lu e : 200, ma x valu e: 600, \
heig h tEt:E dit Text { bo u n ds:[2 05, 45, 245, 6 5] } \
}, \
b t n Pn l : Pa n e l { tex t : ' Bu i l d i t', b o u n d s : [ 1 5 , 3 3 0 , 3 6 5 , 3 7 5 ] , \
test Bt n :Bu t ton { text: 'Test', b ou n ds: [15, 1 5, 115, 35] }, \
buildBt n:Button { text:'Build', bounds:[125,15,225,35], \
Using Help
b o u n d s : [ 1 2 5 , 1 4 5 , 2 5 5 , 1 6 5 ] } , \
b o u n d s : [ 7 5 , 1 5 , 1 9 5 , 3 5 ] } , \
b o u n d s : [ 7 5 , 4 5 , 1 9 5 , 6 5 ] } , \
proper ties:{name:'ok'} }, \
Creating User Interface Elements
Back
Back
203
203

Advertisement

Table of Contents
loading

This manual is also suitable for:

After effects

Table of Contents