Class: Wx::RTC::RichTextFileHandler
- Defined in:
- lib/wx/doc/gen/rtc/rich_text_file_handler.rb
Overview
The base class for file handlers.
Category: Rich Text
Direct Known Subclasses
RichTextHTMLHandler, RichTextPlainTextHandler, RichTextXMLHandler
Instance Method Summary collapse
-
#can_handle(filename) ⇒ Boolean
(also: #can_handle?)
Returns true if we handle this filename (if using files).
-
#can_load ⇒ Boolean
(also: #can_load?)
Returns true if we can load using this handler.
-
#can_save ⇒ Boolean
(also: #can_save?)
Returns true if we can save using this handler.
-
#get_encoding ⇒ Wx::String
(also: #encoding)
Returns the encoding to use when saving a file.
-
#get_extension ⇒ String
(also: #extension)
Returns the default extension to recognise.
-
#get_flags ⇒ Integer
(also: #flags)
Returns flags controlling how loading and saving is done.
-
#get_name ⇒ String
(also: #name)
Returns the name of the handler.
-
#get_type ⇒ Integer
(also: #type)
Returns the handler type.
-
#initialize(name = (''), ext = (''), type = 0) ⇒ Wx::RTC::RichTextFileHandler
constructor
Creates a file handler object.
-
#is_visible ⇒ Boolean
(also: #visible?)
Returns true if this handler should be visible to the user.
- #load_file(*args) ⇒ Object
- #save_file(*args) ⇒ Object
-
#set_encoding(encoding) ⇒ void
(also: #encoding=)
Sets the encoding to use when saving a file.
-
#set_extension(ext) ⇒ void
(also: #extension=)
Sets the default extension to recognise.
-
#set_flags(flags) ⇒ void
(also: #flags=)
Sets flags that change the behaviour of loading or saving.
-
#set_name(name) ⇒ void
(also: #name=)
Sets the name of the handler.
-
#set_type(type) ⇒ void
(also: #type=)
Sets the handler type.
-
#set_visible(visible) ⇒ void
(also: #visible=)
Sets whether the handler should be visible to the user (via the application’s load and save dialogs).
Methods inherited from Object
#clone, #dup, #is_same_as, #un_share
Constructor Details
#initialize(name = (''), ext = (''), type = 0) ⇒ Wx::RTC::RichTextFileHandler
Creates a file handler object.
26 |
# File 'lib/wx/doc/gen/rtc/rich_text_file_handler.rb', line 26 def initialize(name=(''), ext=(''), type=0) end |
Instance Method Details
#can_handle(filename) ⇒ Boolean Also known as: can_handle?
Returns true if we handle this filename (if using files).
By default, checks the extension.
61 |
# File 'lib/wx/doc/gen/rtc/rich_text_file_handler.rb', line 61 def can_handle(filename) end |
#can_load ⇒ Boolean Also known as: can_load?
Returns true if we can load using this handler.
71 |
# File 'lib/wx/doc/gen/rtc/rich_text_file_handler.rb', line 71 def can_load; end |
#can_save ⇒ Boolean Also known as: can_save?
Returns true if we can save using this handler.
66 |
# File 'lib/wx/doc/gen/rtc/rich_text_file_handler.rb', line 66 def can_save; end |
#get_encoding ⇒ Wx::String Also known as: encoding
Returns the encoding to use when saving a file.
If empty, a suitable encoding is chosen.
144 |
# File 'lib/wx/doc/gen/rtc/rich_text_file_handler.rb', line 144 def get_encoding; end |
#get_extension ⇒ String Also known as: extension
Returns the default extension to recognise.
104 |
# File 'lib/wx/doc/gen/rtc/rich_text_file_handler.rb', line 104 def get_extension; end |
#get_flags ⇒ Integer Also known as: flags
Returns flags controlling how loading and saving is done.
129 |
# File 'lib/wx/doc/gen/rtc/rich_text_file_handler.rb', line 129 def get_flags; end |
#get_name ⇒ String Also known as: name
Returns the name of the handler.
93 |
# File 'lib/wx/doc/gen/rtc/rich_text_file_handler.rb', line 93 def get_name; end |
#get_type ⇒ Integer Also known as: type
Returns the handler type.
115 |
# File 'lib/wx/doc/gen/rtc/rich_text_file_handler.rb', line 115 def get_type; end |
#is_visible ⇒ Boolean Also known as: visible?
Returns true if this handler should be visible to the user.
76 |
# File 'lib/wx/doc/gen/rtc/rich_text_file_handler.rb', line 76 def is_visible; end |
#load_file(buffer, stream) ⇒ Boolean #load_file(buffer, filename) ⇒ Boolean
40 |
# File 'lib/wx/doc/gen/rtc/rich_text_file_handler.rb', line 40 def load_file(*args) end |
#save_file(buffer, stream) ⇒ Boolean #save_file(buffer, filename) ⇒ Boolean
54 |
# File 'lib/wx/doc/gen/rtc/rich_text_file_handler.rb', line 54 def save_file(*args) end |
#set_encoding(encoding) ⇒ void Also known as: encoding=
This method returns an undefined value.
Sets the encoding to use when saving a file.
If empty, a suitable encoding is chosen.
137 |
# File 'lib/wx/doc/gen/rtc/rich_text_file_handler.rb', line 137 def set_encoding(encoding) end |
#set_extension(ext) ⇒ void Also known as: extension=
This method returns an undefined value.
Sets the default extension to recognise.
99 |
# File 'lib/wx/doc/gen/rtc/rich_text_file_handler.rb', line 99 def set_extension(ext) end |
#set_flags(flags) ⇒ void Also known as: flags=
This method returns an undefined value.
Sets flags that change the behaviour of loading or saving.
See the documentation for each handler class to see what flags are relevant for each handler. You call this function directly if you are using a file handler explicitly (without going through the text control or buffer LoadFile/SaveFile API). Or, you can call the control or buffer’s SetHandlerFlags function to set the flags that will be used for subsequent load and save operations.
124 |
# File 'lib/wx/doc/gen/rtc/rich_text_file_handler.rb', line 124 def set_flags(flags) end |
#set_name(name) ⇒ void Also known as: name=
This method returns an undefined value.
Sets the name of the handler.
88 |
# File 'lib/wx/doc/gen/rtc/rich_text_file_handler.rb', line 88 def set_name(name) end |
#set_type(type) ⇒ void Also known as: type=
This method returns an undefined value.
Sets the handler type.
110 |
# File 'lib/wx/doc/gen/rtc/rich_text_file_handler.rb', line 110 def set_type(type) end |
#set_visible(visible) ⇒ void Also known as: visible=
This method returns an undefined value.
Sets whether the handler should be visible to the user (via the application’s load and save dialogs).
82 |
# File 'lib/wx/doc/gen/rtc/rich_text_file_handler.rb', line 82 def set_visible(visible) end |