EDOBE XDOM TAKE 6 IR - PRODUCTSHEET Especificações Página 77

  • Descarregar
  • Adicionar aos meus manuais
  • Imprimir
  • Página
    / 304
  • Índice
  • MARCADORES
  • Avaliado. / 5. Com base em avaliações de clientes
Vista de página 76
CHAPTER 4: User-Interface Tools Drawing objects 77
Drawing objects
ScriptUI allows you to draw directly on controls to customize their appearance. You do this by calling
methods of the ScriptUIGraphics object
in response to the onDraw event (see Defining behavior with
event callbacks and listeners” on page 80). These methods take as parameters a number of helper objects
that encapsulate drawing information, including the following:
Bounds
Defines the boundaries of a window within the screens coordinate space, or of a
user-interface element within the container’s coordinate space. Contains an array,
[left,
top, right, bottom], that defines the coordinates of the upper left and lower right
corners of the element.
A
Bounds object is created when you set an element’s bounds property, and this property
returns a
Bounds object.
X An object must contain properties named left, top, right, bottom, or x, y, width,
height.
X An array must have values in the order [left, top, right, bottom].
Dimension
Defines the size of a Window or user-interface element. Contains an array, [width,
height], that defines the element’s size in pixels.
A
Dimension object is created when you set an element’s size or preferredSize
property. (A
preferredSize of -1 causes the size to be calculated automatically.)
X An object must contain properties named width and height.
X An array must have values in the order [width, height].
Margins
Defines the number of pixels between the edges of a container and its outermost child
elements. Contains an array
[left, top, right, bottom] whose elements define the
margins between the left edge of a container and its leftmost child element, and so on.
A
Margins object is created when you set an elements margins property.
X An object must contain properties named left, top, right, and bottom.
X An array must have values in the order [left, top, right, bottom].
You can also set the
margins property to a number; all of the array values are then set to
this number.
Point
Defines the location of a Window or user-interface element. Contains an array, [x, y],
whose values represent the origin point of the element as horizontal and vertical pixel
offsets from the origin of the element's coordinate space.
A
Point object is created when you set an element’s location property.
X An object must contain properties named x and y.
X An array must have values in the order [x, y].
Vista de página 76
1 2 ... 72 73 74 75 76 77 78 79 80 81 82 ... 303 304

Comentários a estes Manuais

Sem comentários