Index

Package: Scrollbars

Description

package Widgets.Scrollbars is

Classes

Scrollbar (abstract)

type Scrollbar is abstract new Widget and Resize_Listener with private;

Ancestors:

Immediate Children:

Primitive operations:

Calculate_Button
Construct (overriding Widgets.Construct)
Delete (overriding Widgets.Delete)
Handle_Action (overriding Widgets.Handle_Action)
Handle_Mouse_Release (overriding Widgets.Handle_Mouse_Release)
Objects.Construct (Inherited)
Widgets.Activate_Popup (Inherited)
Widgets.Bring_To_Front (Inherited)
Widgets.Draw (Inherited)
Widgets.Draw_Content (Inherited)
Widgets.Find_Widget (Inherited)
Widgets.Get_Color (Inherited)
Widgets.Get_Min_Height (Inherited)
Widgets.Get_Min_Width (Inherited)
Widgets.Get_Process_Name (Inherited)
Widgets.Get_View (Inherited)
Widgets.Get_Window (Inherited)
Widgets.Handle_Ancestor_Hidden (Inherited)
Widgets.Handle_Ancestor_Unhidden (Inherited)
Widgets.Handle_Blur (Inherited)
Widgets.Handle_Click (Inherited)
Widgets.Handle_Descendant_Hidden (Inherited)
Widgets.Handle_Descendant_Unhidden (Inherited)
Widgets.Handle_Disabled (Inherited)
Widgets.Handle_Enabled (Inherited)
Widgets.Handle_Enter (Inherited)
Widgets.Handle_Exit (Inherited)
Widgets.Handle_Focus (Inherited)
Widgets.Handle_Hidden (Inherited)
Widgets.Handle_Key_Held (Inherited)
Widgets.Handle_Key_Press (Inherited)
Widgets.Handle_Key_Release (Inherited)
Widgets.Handle_Mouse_Held (Inherited)
Widgets.Handle_Mouse_Move (Inherited)
Widgets.Handle_Mouse_Press (Inherited)
Widgets.Handle_Mouse_Scroll (Inherited)
Widgets.Handle_Resize (Inherited)
Widgets.Handle_Unhidden (Inherited)
Widgets.Pack (Inherited)
Widgets.Set_Color (Inherited)
Widgets.Set_Dirty (Inherited)
Widgets.Set_Parent (Inherited)
Widgets.Set_Zoom (Inherited)
Widgets.To_String (Inherited)
Widgets.Translate_To_Content (Inherited)
Widgets.Translate_To_Window (Inherited)
An abstract scrollbar widget. A scrollbar has a client widget that it is responsible for scrolling. The amount that can be scrolled is the difference between the client's content region and its viewport.

H_Scrollbar

type H_Scrollbar is new Scrollbar with private;

Ancestors:

Primitive operations:

Calculate_Button (overriding Calculate_Button)
Construct (Inherited)
Delete (Inherited)
Draw_Content (overriding Widgets.Draw_Content)
Handle_Action (Inherited)
Handle_Mouse_Held (overriding Widgets.Handle_Mouse_Held)
Handle_Mouse_Move (overriding Widgets.Handle_Mouse_Move)
Handle_Mouse_Press (overriding Widgets.Handle_Mouse_Press)
Handle_Mouse_Release (Inherited)
Objects.Construct (Inherited)
Widgets.Activate_Popup (Inherited)
Widgets.Bring_To_Front (Inherited)
Widgets.Draw (Inherited)
Widgets.Find_Widget (Inherited)
Widgets.Get_Color (Inherited)
Widgets.Get_Min_Height (Inherited)
Widgets.Get_Min_Width (Inherited)
Widgets.Get_Process_Name (Inherited)
Widgets.Get_View (Inherited)
Widgets.Get_Window (Inherited)
Widgets.Handle_Ancestor_Hidden (Inherited)
Widgets.Handle_Ancestor_Unhidden (Inherited)
Widgets.Handle_Blur (Inherited)
Widgets.Handle_Click (Inherited)
Widgets.Handle_Descendant_Hidden (Inherited)
Widgets.Handle_Descendant_Unhidden (Inherited)
Widgets.Handle_Disabled (Inherited)
Widgets.Handle_Enabled (Inherited)
Widgets.Handle_Enter (Inherited)
Widgets.Handle_Exit (Inherited)
Widgets.Handle_Focus (Inherited)
Widgets.Handle_Hidden (Inherited)
Widgets.Handle_Key_Held (Inherited)
Widgets.Handle_Key_Press (Inherited)
Widgets.Handle_Key_Release (Inherited)
Widgets.Handle_Mouse_Scroll (Inherited)
Widgets.Handle_Resize (Inherited)
Widgets.Handle_Unhidden (Inherited)
Widgets.Pack (Inherited)
Widgets.Set_Color (Inherited)
Widgets.Set_Dirty (Inherited)
Widgets.Set_Parent (Inherited)
Widgets.Set_Zoom (Inherited)
Widgets.To_String (Inherited)
Widgets.Translate_To_Content (Inherited)
Widgets.Translate_To_Window (Inherited)
A horizontal scrollbar widget.

V_Scrollbar

type V_Scrollbar is new Scrollbar with private;

Ancestors:

Primitive operations:

Calculate_Button (overriding Calculate_Button)
Construct (Inherited)
Delete (Inherited)
Draw_Content (overriding Widgets.Draw_Content)
Handle_Action (Inherited)
Handle_Mouse_Held (overriding Widgets.Handle_Mouse_Held)
Handle_Mouse_Move (overriding Widgets.Handle_Mouse_Move)
Handle_Mouse_Press (overriding Widgets.Handle_Mouse_Press)
Handle_Mouse_Release (Inherited)
Objects.Construct (Inherited)
Widgets.Activate_Popup (Inherited)
Widgets.Bring_To_Front (Inherited)
Widgets.Draw (Inherited)
Widgets.Find_Widget (Inherited)
Widgets.Get_Color (Inherited)
Widgets.Get_Min_Height (Inherited)
Widgets.Get_Min_Width (Inherited)
Widgets.Get_Process_Name (Inherited)
Widgets.Get_View (Inherited)
Widgets.Get_Window (Inherited)
Widgets.Handle_Ancestor_Hidden (Inherited)
Widgets.Handle_Ancestor_Unhidden (Inherited)
Widgets.Handle_Blur (Inherited)
Widgets.Handle_Click (Inherited)
Widgets.Handle_Descendant_Hidden (Inherited)
Widgets.Handle_Descendant_Unhidden (Inherited)
Widgets.Handle_Disabled (Inherited)
Widgets.Handle_Enabled (Inherited)
Widgets.Handle_Enter (Inherited)
Widgets.Handle_Exit (Inherited)
Widgets.Handle_Focus (Inherited)
Widgets.Handle_Hidden (Inherited)
Widgets.Handle_Key_Held (Inherited)
Widgets.Handle_Key_Press (Inherited)
Widgets.Handle_Key_Release (Inherited)
Widgets.Handle_Mouse_Scroll (Inherited)
Widgets.Handle_Resize (Inherited)
Widgets.Handle_Unhidden (Inherited)
Widgets.Pack (Inherited)
Widgets.Set_Color (Inherited)
Widgets.Set_Dirty (Inherited)
Widgets.Set_Parent (Inherited)
Widgets.Set_Zoom (Inherited)
Widgets.To_String (Inherited)
Widgets.Translate_To_Content (Inherited)
Widgets.Translate_To_Window (Inherited)
A vertical scrollbar widget.

Types

A_H_Scrollbar

type A_H_Scrollbar is access all H_Scrollbar'Class;

A_V_Scrollbar

type A_V_Scrollbar is access all V_Scrollbar'Class;

Subprograms & Entries

Calculate_Button (abstract)

procedure Calculate_Button
( this: access Scrollbar;
min, max: out Integer ) is abstract;
Calculates where the scroll button will be drawn on the scrollbar, based on the size of the client widget and the location and size of its viewport. 'min' and 'max' are in the range of 0..[scroll_dimension]-1, in pixels. For example, if this is a horizontal scrollbar for a client that is completely visible in the horizontal dimension, then 'min' will return 0 and 'max' will return Scrollbar.Get_Width - 1. This is because the button should entirely fill the area scrollbar.

Set_Client

procedure Set_Client
( this: not null access Scrollbar'Class;
client: A_Widget );
Sets the client widget of the scrollbar; ie: the widget that will be controlled. 'client' will not belong to the scrollbar. The client of a scrollbar should be removed before its deleted. If 'client' is null, the scrollbar will have no client.

Create_H_Scrollbar

function Create_H_Scrollbar
( view: not null access Game_Views.Game_View'Class;
id: String ) return A_H_Scrollbar;
Creates a horizontal scrollbar within 'view' with widget id 'id'.

Create_V_Scrollbar

function Create_V_Scrollbar
( view: not null access Game_Views.Game_View'Class;
id: String ) return A_V_Scrollbar;
Creates a vertical scrollbar within 'view' with widget id 'id'.