From 021866de868fd074526fc63270639ec2f3ce9aa5 Mon Sep 17 00:00:00 2001 From: mitchell <70453897+667e-11@users.noreply.github.com> Date: Sat, 4 Jul 2020 23:22:03 -0400 Subject: Added `buffer:style_of_name()` as an analogue to `buffer:name_of_style()`. --- core/.buffer.luadoc | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'core/.buffer.luadoc') diff --git a/core/.buffer.luadoc b/core/.buffer.luadoc index 810075fd..175e1098 100644 --- a/core/.buffer.luadoc +++ b/core/.buffer.luadoc @@ -1782,6 +1782,15 @@ function new() end -- @param end_pos The end position of the range of text to get in *buffer*. function text_range(buffer, start_pos, end_pos) end +--- +-- Returns the style number associated with string *style_name*, or +-- `view.STYLE_DEFAULT` if *style_name* is not in use. +-- @param buffer A buffer. +-- @param string The style name to get the number of. +-- @return style number, between `1` and `256`. +-- @see name_of_style +function style_of_name(buffer, style_name) end + --- -- Reloads the buffer's file contents, discarding any changes. -- @param buffer A buffer. -- cgit v1.2.3