Plank.PositionManager – plank – Vala Binding Reference

Plank.PositionManager – plank Reference Manual

# PositionManager

## Object Hierarchy:

## Description:

public class PositionManager : Object

Handles computing any size/position information for the dock.

Namespace: Plank
Package: plank

## Content:

### Properties:

- public DockController controller { construct; }
- public bool screen_is_composited { get; }
- public int LineWidth { get; }
  Theme-based line-width.
- public int IconSize { get; }
  Cached current icon size for the dock.
- public int ZoomIconSize { get; }
  Cached current icon size for the dock.
- public PositionType Position { get; }
  Cached position of the dock.
- public Align Alignment { get; }
  Cached alignment of the dock.
- public Align ItemsAlignment { get; }
  Cached alignment of the items.
- public int Offset { get; }
  Cached offset of the dock.
- public int IndicatorSize { get; }
  Theme-based indicator size, scaled by icon size.
- public int IconShadowSize { get; }
  Theme-based icon-shadow size, scaled by icon size.
- public int GlowSize { get; }
  Theme-based urgent glow size, scaled by icon size.
- public int HorizPadding { get; }
  Theme-based horizontal padding, scaled by icon size.
- public int TopPadding { get; }
  Theme-based top padding, scaled by icon size.
- public int BottomPadding { get; }
  Theme-based bottom padding, scaled by icon size.
- public int ItemPadding { get; }
  Theme-based item padding, scaled by icon size.
- public int UrgentBounceHeight { get; }
  Theme-based urgent-bounce height, scaled by icon size.
- public int LaunchBounceHeight { get; }
  Theme-based launch-bounce height, scaled by icon size.
- public int MaxItemCount { get; }
  The maximum item count which fit the dock in its maximum size with the current theme and icon-size.

### Static methods:

- public static string[] get_monitor_plug_names (Screen screen)

### Creation methods:

- public PositionManager (DockController controller)
  Creates a new position manager.

### Methods:

- public void initialize ()
  Initializes the position manager.
- public void update (DockTheme theme)
  Updates all internal caches.
- public bool is_horizontal_dock ()
  Return whether or not a dock is a horizontal dock.
- public Rectangle get_cursor_region ()
  Returns the cursor region for the dock. This is the region that the cursor can interact with the dock.
- public Rectangle get_static_dock_region ()
  Returns the static dock region for the dock. This is the region that the dock occupies when not hidden.
- public void update_regions ()
  Call when any cached region needs updating.
- public DockItemDrawValue get_draw_value_for_item (DockItem item)
  The draw-value for a dock item.
- public void update_draw_values (ArrayList<weak DockItem> items, DrawValueFunc? func = null, DrawValuesFunc? post_func = null)
  Update and recalculated all internal draw-values using the given methodes for custom manipulations.
- public Rectangle get_hover_region_for_element (DockElement element)
  The cursor region for interacting with a dock element.
- public weak DockItem? get_nearest_item_at (int x, int y, DockContainer? container = null)
  Get the item which is the nearest at the given coordinates. If a container is given the result will be restricted to its children.
- public weak DockItem? get_current_target_item (DockContainer? container = null)
  Get the item which is the appropriate target for a drag'n'drop action. The returned item may not hovered and is meant to be used as target for e.g. DockContainer.add/move_to functions. If a container is given the result will be restricted to its children.
- public void get_menu_position (DockItem hovered, Requisition requisition, out int x, out int y)
  Get's the x and y position to display a menu for a dock item.
- public void get_hover_position (DockItem hovered, out int x, out int y)
  Get's the x and y position to display a hover window for a dock item.
- public void get_hover_position_at (ref int x, ref int y)
  Get's the x and y position to display a hover window for the given coordinates.
- public void get_urgent_glow_position (DockItem item, out int x, out int y)
  Get's the x and y position to display the urgent-glow for a dock item.
- public void update_dock_position ()
  Caches the x and y position of the dock window.
- public void get_dock_draw_position (out int x, out int y)
  Get's the x and y position to display the main dock buffer.
- public Rectangle get_dock_window_region ()
  Get's the region to display the dock window at.
- public void get_background_padding (out int x, out int y)
  Get's the padding between background and icons of the dock.
- public Rectangle get_background_region ()
  Get's the region for background of the dock.
- public Rectangle get_icon_geometry (ApplicationDockItem item, bool for_hidden)
  Get the item's icon geometry for the dock.
- public void get_struts (ref ulong[] struts)
  Computes the struts for the dock.
- public Rectangle get_barrier ()

### Inherited Members:

All known members inherited from class GLib.Object

- @new
- new_valist
- newv
- add_toggle_ref
- add_weak_pointer
- bind_property
- connect
- constructed
- disconnect
- dispose
- dup_data
- dup_qdata
- freeze_notify
- @get

- get_class
- get_data
- get_property
- get_qdata
- get_type
- notify_property
- @ref
- ref_sink
- replace_data
- replace_qdata
- remove_toggle_ref
- remove_weak_pointer
- @set

- set_data
- set_data_full
- set_property
- set_qdata
- set_qdata_full
- steal_data
- steal_qdata
- thaw_notify
- unref
- weak_ref
- weak_unref
- notify
- ref_count