INDEX CLUSTER FEATURES SHORT FRAMES NO FRAMES

indexing

title: "A bar with a scroll box which indicates a position. ", "WEL: library of reusable components for Eiffel. ", "Based on WEL library for ISE Eiffel, used with permission. "
project: "Windows Eiffel Library"
copyright: "(c) 1986-1997 Interactive Software Engineering Inc. ", "Modifications and extensions: ", "(c) 1997 Object Tools ", "All rights reserved. Duplication and distribution prohibited", "May be used only with Visual Eiffel under terms of user ", "license "
cluster: wel
class WEL_SCROLL_BAR
inherit

WEL_BAR
end

WEL_SBS_CONSTANTS
export
{NONE}
all
end
creation

make_by_id,
make_horizontal,
make_vertical
feature {NONE}-- Initialization

make_vertical (a_parent: WEL_WINDOW; a_x, a_y, a_width, a_height, an_id: INTEGER)
-- Make a vertical scroll bar.
require
a_parent_not_void: a_parent /= void
ensure
parent_set: parent = a_parent
exists: exists
id_set: id = an_id
position_equal_zero: position = 0
minimum_equal_zero: minimum = 0
maximum_equal_zero: maximum = 0

make_horizontal (a_parent: WEL_WINDOW; a_x, a_y, a_width, a_height, an_id: INTEGER)
-- Make a horizontal scroll bar.
require
a_parent_not_void: a_parent /= void
ensure
parent_set: parent = a_parent
exists: exists
id_set: id = an_id
position_equal_zero: position = 0
minimum_equal_zero: minimum = 0
maximum_equal_zero: maximum = 0
feature -- Access

line: INTEGER

page: INTEGER

position: INTEGER
-- Current position of the scroll box

minimum: INTEGER
-- Minimum position

maximum: INTEGER
-- Maximum position
feature -- Element change

set_position (new_position: INTEGER)
-- Set `position' with `new_position'

set_range (a_minimum, a_maximum: INTEGER)
-- Set `minimum' and `maximum' with
-- `a_minimum' and `a_maximum'

set_line (line_magnitude: INTEGER)
-- Set `line' with `line_magnitude'.
require
positive_line: line >= 0
ensure
line_set: line = line_magnitude

set_page (page_magnitude: INTEGER)
-- Set `page' with `page_magnitude'.
require
positive_page: page >= 0
ensure
page_set: page = page_magnitude
feature -- Basic operations

on_scroll (scroll_code, pos: INTEGER)
-- Process the scroll messages.
-- Typically, this routine will be called from
-- `on_vertical_scroll_control' or
-- `on_horizontal_scroll_control' of the parent window.
require
exists: exists
invariant

positive_line: line >= 0
positive_page: page >= 0
end -- class WEL_SCROLL_BAR

INDEX CLUSTER FEATURES SHORT FRAMES NO FRAMES