diff options
author | mitchell <70453897+667e-11@users.noreply.github.com> | 2020-05-25 21:16:01 -0400 |
---|---|---|
committer | mitchell <70453897+667e-11@users.noreply.github.com> | 2020-05-25 21:16:01 -0400 |
commit | f2374c4aba53fa462dc88d4104e10d8cb97e61ba (patch) | |
tree | 5e5a9d26a5ad8915c0e12187dd059b1109fcf22d /core/iface.lua | |
parent | effc636745e8d9c680c3acf42e8e25eed10cd903 (diff) |
Allow views to be used as buffers and update API.
This allows for a superficial separation of buffer- and view-specific Scintilla
functionality. buffers and views can now be used interchangeably for the most
part, and the APIs are guidance, not hard requirements. User scripts do not
require any modification and will continue to function normally.
Diffstat (limited to 'core/iface.lua')
-rw-r--r-- | core/iface.lua | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/core/iface.lua b/core/iface.lua index fdaab1ed..05e80131 100644 --- a/core/iface.lua +++ b/core/iface.lua @@ -52,11 +52,11 @@ M.events = {[2000]={"style_needed","position"},[2001]={"char_added","ch","charac local marker_number, indic_number, list_type, image_type = 0, 0, 0, 0 --- --- Returns a unique marker number for use with `buffer.marker_define()`. +-- Returns a unique marker number for use with `view.marker_define()`. -- Use this function for custom markers in order to prevent clashes with -- identifiers of other custom markers. -- @usage local marknum = _SCINTILLA.next_marker_number() --- @see buffer.marker_define +-- @see view.marker_define -- @name next_marker_number function M.next_marker_number() assert(marker_number < M.constants.MARKER_MAX, 'too many markers in use') @@ -69,7 +69,7 @@ end -- Use this function for custom indicators in order to prevent clashes with -- identifiers of other custom indicators. -- @usage local indic_num = _SCINTILLA.next_indic_number() --- @see buffer.indic_style +-- @see view.indic_style -- @name next_indic_number function M.next_indic_number() assert(indic_number < M.constants.INDICATOR_MAX, 'too many indicators in use') @@ -92,12 +92,12 @@ end --- -- Returns a unique image type identier number for use with --- `buffer.register_image()` and `buffer.register_rgba_image()`. +-- `view.register_image()` and `view.register_rgba_image()`. -- Use this function for custom image types in order to prevent clashes with -- identifiers of other custom image types. -- @usage local image_type = _SCINTILLA.next_image_type() --- @see buffer.register_image --- @see buffer.register_rgba_image +-- @see view.register_image +-- @see view.register_rgba_image -- @name next_image_type function M.next_image_type() image_type = image_type + 1 |