the extent of the component or not
atk.component_mixin
Module for [Component] interface mixin
Templates 2
The ATK interface provided by UI components which occupy a physical area on the screen. which the user can activate/interact with.
#AtkComponent should be implemented by most if not all UI elements with an actual on-screen presence, i.e. components which can be said to have a screen-coordinate bounding box. Virtually all widgets will need to have #AtkComponent implementations provided for their corresponding #AtkObject class. In short, only UI elements which are not GUI elements will omit this ATK interface.
A possible exception might be textual information with a transparent background, in which case text glyph bounding box information is provided by #AtkText.
Checks whether the specified point is within the extent of the component.
Toolkit implementor note: ATK provides a default implementation for this virtual method. In general there are little reason to re-implement it.
Parameters
x | x coordinate |
y | y coordinate |
coordType | specifies whether the coordinates are relative to the screen or to the components top level window |
Returns
Returns the alpha value (i.e. the opacity) for this component, on a scale from 0 (fully transparent) to 1.0 (fully opaque).
Returns
Gets the rectangle which gives the extent of the component.
If the extent can not be obtained (e.g. a non-embedded plug or missing support), all of x, y, width, height are set to -1.
Parameters
x | address of #gint to put x coordinate |
y | address of #gint to put y coordinate |
width | address of #gint to put width |
height | address of #gint to put height |
coordType | specifies whether the coordinates are relative to the screen or to the components top level window |
Gets the layer of the component.
Returns
Gets the zorder of the component. The value G_MININT will be returned if the layer of the component is not ATK_LAYER_MDI or ATK_LAYER_WINDOW.
Returns
which the component is shown in relation to other components in the same container.
Gets the position of component in the form of a point specifying component's top-left corner.
If the position can not be obtained (e.g. a non-embedded plug or missing support), x and y are set to -1.
Parameters
x | address of #gint to put x coordinate position |
y | address of #gint to put y coordinate position |
coordType | specifies whether the coordinates are relative to the screen or to the components top level window |
Deprecated
Gets the size of the component in terms of width and height.
If the size can not be obtained (e.g. a non-embedded plug or missing support), width and height are set to -1.
Parameters
width | address of #gint to put width of component |
height | address of #gint to put height of component |
Deprecated
Grabs focus for this component.
Returns
Gets a reference to the accessible child, if one exists, at the coordinate point specified by x and y.
Parameters
x | x coordinate |
y | y coordinate |
coordType | specifies whether the coordinates are relative to the screen or to the components top level window |
Returns
child, if one exists
Remove the handler specified by handler_id from the list of functions to be executed when this object receives focus events (in or out).
Parameters
handlerId | the handler id of the focus handler to be removed from component |
Deprecated
lose the focus, use the #AtkObject::state-change "focused" notification instead.
Makes component visible on the screen by scrolling all necessary parents.
Contrary to atk_component_set_position, this does not actually move component in its parent, this only makes the parents scroll so that the object shows up on the screen, given its current position within the parents.
Parameters
type | specify where the object should be made visible. |
Returns
Move the top-left of component to a given position of the screen by scrolling all necessary parents.
Parameters
coords | specify whether coordinates are relative to the screen or to the parent object. |
x | x-position where to scroll to |
y | y-position where to scroll to |
Returns
Sets the extents of component.
Parameters
x | x coordinate |
y | y coordinate |
width | width to set for component |
height | height to set for component |
coordType | specifies whether the coordinates are relative to the screen or to the components top level window |
Returns
Sets the position of component.
Contrary to atk_component_scroll_to, this does not trigger any scrolling, this just moves component in its parent.
Parameters
x | x coordinate |
y | y coordinate |
coordType | specifies whether the coordinates are relative to the screen or to the component's top level window |
Returns
Set the size of the component in terms of width and height.
Parameters
width | width to set for component |
height | height to set for component |
Returns
Connect to BoundsChanged signal.
The 'bounds-changed" signal is emitted when the position or size of the component changes.
Parameters
callback | signal callback delegate or function to connect void callback(atk.types.Rectangle arg1, atk.component.Component component) arg1 The AtkRectangle giving the new position and size. (optional) component the instance the signal is connected to (optional) |
after | Yes.After to execute callback after default handler, No.After to execute before (default) |