INDEX CLUSTER FEATURES SHORT FRAMES NO FRAMES

indexing

title: "Ancestor of WEL_OPEN_FILE_DIALOG and WEL_SAVE_FILE_DIALOG. ", "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-2001 Object Tools ", "All rights reserved. Duplication and distribution prohibited", "May be used only with Visual Eiffel under terms of user ", "license "
cluster: wel
deferred class WEL_FILE_DIALOG
inherit

WEL_STANDARD_DIALOG
rename
make as standard_dialog_make
end

WEL_BIT_OPERATIONS
export
{NONE}
all
end

WEL_OFN_CONSTANTS
export
{NONE}
all
end
feature -- Access

flags: INTEGER
-- Dialog box creation flags.
-- Can be a combination of the values defined in
-- class WEL_OFN_CONSTANTS.

file_name: STRING
-- File name selected (including path).
require
selected: selected
ensure
result_not_void: Result /= void

file_title: STRING
-- Title of the selected file (without path).
require
selected: selected
ensure
result_not_void: Result /= void

title: STRING
-- Title of the current dialog
ensure
result_not_void: Result /= void

file_name_offset: INTEGER
-- Specifies the offset from the beginning of the path
-- to the file name in the string `file_name'.
require
selected: selected
ensure
result_greater_than_or_equal_to_one: Result >= 1

file_extension_offset: INTEGER
-- Specifies the offset from the beginning of the path
-- to the file name extension in the string `file_name'.
require
selected: selected
ensure
result_greater_than_or_equal_to_one: Result >= 1

filter_index: INTEGER
-- Index of the selected filter
require
selected: selected
ensure
positive_result: Result >= 0

Max_file_name_length: INTEGER
feature -- Element change

set_flags (a_flags: INTEGER)
-- Set `flags' with `a_flags'.
-- See class WEL_OFN_CONSTANTS for `a_flags' values.
ensure
flags_set: flags = a_flags

add_flag (a_flags: INTEGER)
-- Add `a_flags' to `flags'.
-- See class WEL_OFN_CONSTANTS for `a_flags' values.
ensure
has_flag: has_flag (a_flags)

remove_flag (a_flags: INTEGER)
-- Remove `a_flags' from `flags'.
-- See class WEL_OFN_CONSTANTS for `a_flags' values.
ensure
has_not_flag: not has_flag (a_flags)

set_file_name (a_file_name: STRING)
-- Set `file_name' with `a_file' and initialize
-- the file name edit control.
require
a_file_name_not_void: a_file_name /= void
a_file_name_count_ok: a_file_name.count <= max_file_name_length
ensure
file_name_set: file_name.is_equal (a_file_name)

set_title (a_title: STRING)
-- Set `title' with `a_title' and use this string to
-- display the title.
require
a_title_not_void: a_title /= void
ensure
title_set: title.is_equal (a_title)

set_default_title
-- Set the title bar with the default value ("Save As"
-- or "Open")
ensure
default_title_set: title.is_equal ()

set_filter (filter_names, filter_patterns: ARRAY [STRING])
-- Set the file type combo box.
-- `filter_names' is an array of string containing
-- the filter names and `filter_patterns' is an
-- array of string containing the filter patterns.
-- Example:
-- filter_names = <<"Text file", "All file">>
-- filter_patterns = <<"*.txt", "*.*">>
require
filter_names_not_void: filter_names /= void
filter_patterns_not_void: filter_patterns /= void
same_count: filter_names.count = filter_patterns.count

set_filter_index (a_filter_index: INTEGER)
-- Set `filter_index' with `a_filter_index'.
require
positive_filter_index: a_filter_index >= 0
ensure
filter_index_set: filter_index = a_filter_index

set_initial_directory (directory: STRING)
-- Set the initial directory with `directory'.
require
directory_not_void: directory /= void

set_initial_directory_as_current
-- Set the initial directory as the current one.

set_default_extension (extension: STRING)
-- Set the default extension with `extension'.
-- This extension will be automatically added to the
-- file name if the user fails to type an extension.
require
extension_not_void: extension /= void
feature -- Status report

has_flag (a_flags: INTEGER): BOOLEAN
-- Is `a_flags' set in `flags'?
-- See class WEL_OFN_CONSTANTS for `a_flags' values.
feature -- Measurement

structure_size: INTEGER
-- Size to allocate (in bytes)
invariant

str_file_name_not_void: str_file_name /= void
str_file_name_exists: str_file_name.exists
str_file_title_not_void: str_file_title /= void
str_file_title_exists: str_file_title.exists
str_title_not_void: str_title /= void
str_title_exists: str_title.exists
end -- class WEL_FILE_DIALOG

INDEX CLUSTER FEATURES SHORT FRAMES NO FRAMES