diff options
Diffstat (limited to 'modules')
-rw-r--r-- | modules/textadept/adeptsense.lua | 2 | ||||
-rw-r--r-- | modules/textadept/editing.lua | 6 | ||||
-rw-r--r-- | modules/textadept/find.lua | 12 | ||||
-rw-r--r-- | modules/textadept/keys.lua | 2 | ||||
-rw-r--r-- | modules/textadept/menu.lua | 2 |
5 files changed, 12 insertions, 12 deletions
diff --git a/modules/textadept/adeptsense.lua b/modules/textadept/adeptsense.lua index be350c75..4987f0cf 100644 --- a/modules/textadept/adeptsense.lua +++ b/modules/textadept/adeptsense.lua @@ -827,7 +827,7 @@ function M.goto_ctag(sense, kind, title) if not tonumber(line) then -- /^ ... $/ buffer.target_start, buffer.target_end = 0, buffer.length - buffer.search_flags = buffer.SCFIND_REGEXP + buffer.search_flags = buffer.FIND_REGEXP if buffer:search_in_target(line:sub(2, -2)) >= 0 then buffer:goto_pos(buffer.target_start) end diff --git a/modules/textadept/editing.lua b/modules/textadept/editing.lua index 8f6d93a2..72a905e5 100644 --- a/modules/textadept/editing.lua +++ b/modules/textadept/editing.lua @@ -223,9 +223,9 @@ function M.autocomplete_word(words) end local patt = '^['..buffer.word_chars..']+' buffer.target_start, buffer.target_end = 0, buffer.length - buffer.search_flags = buffer.SCFIND_WORDSTART + buffer.search_flags = buffer.FIND_WORDSTART if not buffer.auto_c_ignore_case then - buffer.search_flags = buffer.search_flags + buffer.SCFIND_MATCHCASE + buffer.search_flags = buffer.search_flags + buffer.FIND_MATCHCASE end local match_pos = buffer:search_in_target(root) while match_pos ~= -1 do @@ -489,7 +489,7 @@ function M.highlight_word() end if s == e then return end local word = buffer:text_range(s, e) - buffer.search_flags = buffer.SCFIND_WHOLEWORD + buffer.SCFIND_MATCHCASE + buffer.search_flags = buffer.FIND_WHOLEWORD + buffer.FIND_MATCHCASE buffer.target_start, buffer.target_end = 0, buffer.length while buffer:search_in_target(word) > -1 do local len = buffer.target_end - buffer.target_start diff --git a/modules/textadept/find.lua b/modules/textadept/find.lua index b4be38b5..82b5f4c4 100644 --- a/modules/textadept/find.lua +++ b/modules/textadept/find.lua @@ -115,8 +115,8 @@ local function find_(text, next, flags, no_wrap, wrapped) if text == '' then return end if not flags then flags = 0 - if M.match_case then flags = flags + buffer.SCFIND_MATCHCASE end - if M.whole_word then flags = flags + buffer.SCFIND_WHOLEWORD end + if M.match_case then flags = flags + buffer.FIND_MATCHCASE end + if M.whole_word then flags = flags + buffer.FIND_WHOLEWORD end if M.lua then flags = flags + 8 end if M.in_files then flags = flags + 16 end end @@ -171,7 +171,7 @@ events.connect(events.FIND, find_) -- Finds and selects text incrementally in the current buffer from a starting -- position. --- Flags other than `SCFIND_MATCHCASE` are ignored. +-- Flags other than `FIND_MATCHCASE` are ignored. -- @param text The text to find. -- @param next Flag indicating whether or not the search direction is forward. -- @param anchor Flag indicating whether or not to search from the current @@ -181,7 +181,7 @@ local function find_incremental(text, next, anchor) M.incremental_start = buffer.current_pos + (next and 1 or -1) end buffer:goto_pos(M.incremental_start or 0) - find_(text, next, M.match_case and buffer.SCFIND_MATCHCASE or 0) + find_(text, next, M.match_case and buffer.FIND_MATCHCASE or 0) end --- @@ -356,11 +356,11 @@ function M.goto_file_found(line, next) if next then buffer:line_end() else buffer:home() end buffer:search_anchor() local f = buffer['search_'..(next and 'next' or 'prev')] - local pos = f(buffer, buffer.SCFIND_REGEXP, '^.+:[0-9]+:.+$') + local pos = f(buffer, buffer.FIND_REGEXP, '^.+:[0-9]+:.+$') if pos == -1 then buffer:goto_line(next and 0 or buffer.line_count) buffer:search_anchor() - pos = f(buffer, buffer.SCFIND_REGEXP, '^.+:[0-9]+:.+$') + pos = f(buffer, buffer.FIND_REGEXP, '^.+:[0-9]+:.+$') end if pos == -1 then if CURSES then view:goto_buffer(cur_buf) end return end line = buffer:line_from_position(pos) diff --git a/modules/textadept/keys.lua b/modules/textadept/keys.lua index c140c095..d6353d1b 100644 --- a/modules/textadept/keys.lua +++ b/modules/textadept/keys.lua @@ -547,7 +547,7 @@ if not CURSES then {utils.toggle_property, 'indentation_guides'} keys[not OSX and 'caS' or 'cS'] = {utils.toggle_property, 'view_ws'} keys[not OSX and 'caV' or 'cV'] = - {utils.toggle_property, 'virtual_space_options', buffer.SCVS_USERACCESSIBLE} + {utils.toggle_property, 'virtual_space_options', buffer.VS_USERACCESSIBLE} end keys[not OSX and not CURSES and 'c=' or 'm='] = buffer.zoom_in keys[not OSX and not CURSES and 'c-' or 'm-'] = buffer.zoom_out diff --git a/modules/textadept/menu.lua b/modules/textadept/menu.lua index fbb74499..2f984d8a 100644 --- a/modules/textadept/menu.lua +++ b/modules/textadept/menu.lua @@ -180,7 +180,7 @@ local menubar = { {_L['Toggle View White_space'], {utils.toggle_property, 'view_ws'}}, {_L['Toggle _Virtual Space'], {utils.toggle_property, 'virtual_space_options', - buffer.SCVS_USERACCESSIBLE}}, + buffer.VS_USERACCESSIBLE}}, SEPARATOR, {_L['Zoom _In'], buffer.zoom_in}, {_L['Zoom _Out'], buffer.zoom_out}, |