aboutsummaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authormitchell <70453897+667e-11@users.noreply.github.com>2020-07-04 23:22:03 -0400
committermitchell <70453897+667e-11@users.noreply.github.com>2020-07-04 23:22:03 -0400
commit021866de868fd074526fc63270639ec2f3ce9aa5 (patch)
treee86d22cad0ba6d50f5db7c6768728ecf46a188e8 /modules
parent9835ab92e265f4c83634f1bec49b4592e2deda8c (diff)
downloadtextadept-021866de868fd074526fc63270639ec2f3ce9aa5.tar.gz
textadept-021866de868fd074526fc63270639ec2f3ce9aa5.zip
Added `buffer:style_of_name()` as an analogue to `buffer:name_of_style()`.
Diffstat (limited to 'modules')
-rw-r--r--modules/textadept/run.lua6
1 files changed, 3 insertions, 3 deletions
diff --git a/modules/textadept/run.lua b/modules/textadept/run.lua
index 2694166f..561d873a 100644
--- a/modules/textadept/run.lua
+++ b/modules/textadept/run.lua
@@ -413,9 +413,9 @@ function M.goto_error(line_num, next)
end
if detail.message then
buffer.annotation_text[detail.line] = detail.message
- local GETNAMEDSTYLE = _SCINTILLA.properties.named_styles[1]
- local style = buffer:private_lexer_call(GETNAMEDSTYLE, 'error')
- if not detail.warning then buffer.annotation_style[detail.line] = style end
+ if not detail.warning then
+ buffer.annotation_style[detail.line] = buffer:style_of_name('error')
+ end
end
end
events.connect(events.KEYPRESS, function(code)