aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStefan Kangas2022-07-31 06:30:25 +0200
committerStefan Kangas2022-07-31 06:30:25 +0200
commitd9bd334ef367f3e16967ae2ed714ff419f2b5328 (patch)
treee08882a1e9ec3c67c175a6e3dd63ef7f5e7f6d1f
parent3d6af11c42453065d5ace1223fe99228b7927318 (diff)
parenteb11dae499fc395bbf3d51883ced6244c91019cf (diff)
downloademacs-d9bd334ef367f3e16967ae2ed714ff419f2b5328.tar.gz
emacs-d9bd334ef367f3e16967ae2ed714ff419f2b5328.zip
Merge from origin/emacs-28
eb11dae499 Improve documentation of column-related functions c95a34c960 * src/macfont.m (macfont_open): Initialize font->space_wid... 31a6a37d45 Improve indexing of keymap variables
-rw-r--r--doc/lispref/display.texi2
-rw-r--r--doc/lispref/keymaps.texi1
-rw-r--r--doc/lispref/maps.texi4
-rw-r--r--doc/lispref/text.texi7
-rw-r--r--src/indent.c9
-rw-r--r--src/macfont.m3
6 files changed, 24 insertions, 2 deletions
diff --git a/doc/lispref/display.texi b/doc/lispref/display.texi
index d2e075c54ec..ace67fbedb7 100644
--- a/doc/lispref/display.texi
+++ b/doc/lispref/display.texi
@@ -7477,6 +7477,7 @@ the usual Emacs @code{highlight} face.
7477 7477
7478@item keymap 7478@item keymap
7479@kindex keymap @r{(button property)} 7479@kindex keymap @r{(button property)}
7480@vindex button-map
7480The button's keymap, defining bindings active within the button 7481The button's keymap, defining bindings active within the button
7481region. By default this is the usual button region keymap, stored 7482region. By default this is the usual button region keymap, stored
7482in the variable @code{button-map}, which defines @key{RET} and 7483in the variable @code{button-map}, which defines @key{RET} and
@@ -7691,6 +7692,7 @@ Return @code{t} if button-type @var{type} is a subtype of @var{supertype}.
7691These are commands and functions for locating and operating on 7692These are commands and functions for locating and operating on
7692buttons in an Emacs buffer. 7693buttons in an Emacs buffer.
7693 7694
7695@cindex buffer-button-map
7694@code{push-button} is the command that a user uses to actually push 7696@code{push-button} is the command that a user uses to actually push
7695a button, and is bound by default in the button itself to @key{RET} 7697a button, and is bound by default in the button itself to @key{RET}
7696and to @key{mouse-2} using a local keymap in the button's overlay or 7698and to @key{mouse-2} using a local keymap in the button's overlay or
diff --git a/doc/lispref/keymaps.texi b/doc/lispref/keymaps.texi
index f5341f40f0a..5cb5367bc0e 100644
--- a/doc/lispref/keymaps.texi
+++ b/doc/lispref/keymaps.texi
@@ -1882,6 +1882,7 @@ to make entries in @code{input-decode-map} beyond those that can be
1882deduced from Termcap and Terminfo. @xref{Terminal-Specific}. 1882deduced from Termcap and Terminfo. @xref{Terminal-Specific}.
1883@end defvar 1883@end defvar
1884 1884
1885@cindex function-key-map
1885@defvar local-function-key-map 1886@defvar local-function-key-map
1886This variable holds a keymap similar to @code{input-decode-map} except 1887This variable holds a keymap similar to @code{input-decode-map} except
1887that it describes key sequences which should be translated to 1888that it describes key sequences which should be translated to
diff --git a/doc/lispref/maps.texi b/doc/lispref/maps.texi
index 90497728a1c..d18b553dc19 100644
--- a/doc/lispref/maps.texi
+++ b/doc/lispref/maps.texi
@@ -125,6 +125,7 @@ setup-language-environment-map, describe-language-environment-map,
125menu-bar-epatch-menu, menu-bar-ediff-merge-menu, menu-bar-ediff-menu, etc. 125menu-bar-epatch-menu, menu-bar-ediff-merge-menu, menu-bar-ediff-menu, etc.
126@end ignore 126@end ignore
127 127
128@cindex minibuffer-inactive-mode-map
128@item minibuffer-inactive-mode-map 129@item minibuffer-inactive-mode-map
129A full keymap used in the minibuffer when it is not active.@* 130A full keymap used in the minibuffer when it is not active.@*
130@xref{Minibuffer Edit,, Editing in the Minibuffer, emacs, The GNU Emacs Manual}. 131@xref{Minibuffer Edit,, Editing in the Minibuffer, emacs, The GNU Emacs Manual}.
@@ -156,6 +157,7 @@ The global keymap used for the @kbd{C-x @key{RET}} prefix key.
156@vindex narrow-map 157@vindex narrow-map
157A sparse keymap for subcommands of the prefix @kbd{C-x n}. 158A sparse keymap for subcommands of the prefix @kbd{C-x n}.
158 159
160@cindex prog-mode-map
159@item prog-mode-map 161@item prog-mode-map
160The keymap used by Prog mode.@* 162The keymap used by Prog mode.@*
161@xref{Basic Major Modes}. 163@xref{Basic Major Modes}.
@@ -171,6 +173,7 @@ for multi-buffer replacements. @xref{Search and Replace, query-replace-map}.
171@item search-map 173@item search-map
172A sparse keymap that provides global bindings for search-related commands. 174A sparse keymap that provides global bindings for search-related commands.
173 175
176@cindex special-mode-map
174@item special-mode-map 177@item special-mode-map
175The keymap used by Special mode.@* 178The keymap used by Special mode.@*
176@xref{Basic Major Modes}. 179@xref{Basic Major Modes}.
@@ -179,6 +182,7 @@ The keymap used by Special mode.@*
179The global keymap used for the @kbd{C-x t} prefix key for tab-bar related commands.@* 182The global keymap used for the @kbd{C-x t} prefix key for tab-bar related commands.@*
180@xref{Tab Bars,,, emacs, The GNU Emacs Manual}. 183@xref{Tab Bars,,, emacs, The GNU Emacs Manual}.
181 184
185@cindex tab-bar-map
182@item tab-bar-map 186@item tab-bar-map
183The keymap defining the contents of the tab bar.@* 187The keymap defining the contents of the tab bar.@*
184@xref{Tab Bars,,, emacs, The GNU Emacs Manual}. 188@xref{Tab Bars,,, emacs, The GNU Emacs Manual}.
diff --git a/doc/lispref/text.texi b/doc/lispref/text.texi
index 8b0e1981955..c2161b9341d 100644
--- a/doc/lispref/text.texi
+++ b/doc/lispref/text.texi
@@ -2366,6 +2366,9 @@ begins. @xref{Usual Display}.
2366amount of horizontal scrolling. Consequently, a column value can be 2366amount of horizontal scrolling. Consequently, a column value can be
2367arbitrarily high. The first (or leftmost) column is numbered 0. They 2367arbitrarily high. The first (or leftmost) column is numbered 0. They
2368also ignore overlays and text properties, aside from invisibility. 2368also ignore overlays and text properties, aside from invisibility.
2369Invisible text is considered as having zero width, unless
2370@code{buffer-invisibility-spec} specifies that invisible text should
2371be displayed as ellipsis (@pxref{Invisible Text}).
2369 2372
2370@defun current-column 2373@defun current-column
2371This function returns the horizontal position of point, measured in 2374This function returns the horizontal position of point, measured in
@@ -2439,6 +2442,10 @@ This function returns the indentation of the current line, which is
2439the horizontal position of the first nonblank character. If the 2442the horizontal position of the first nonblank character. If the
2440contents are entirely blank, then this is the horizontal position of the 2443contents are entirely blank, then this is the horizontal position of the
2441end of the line. 2444end of the line.
2445
2446This function considers invisible text as having zero width, unless
2447@code{buffer-invisibility-spec} specifies that invisible text should
2448be displayed as ellipsis. @xref{Invisible Text}.
2442@end defun 2449@end defun
2443 2450
2444@deffn Command indent-to column &optional minimum 2451@deffn Command indent-to column &optional minimum
diff --git a/src/indent.c b/src/indent.c
index e90e3fde203..fd2e7636656 100644
--- a/src/indent.c
+++ b/src/indent.c
@@ -882,8 +882,10 @@ The return value is the column where the insertion ends. */)
882DEFUN ("current-indentation", Fcurrent_indentation, Scurrent_indentation, 882DEFUN ("current-indentation", Fcurrent_indentation, Scurrent_indentation,
883 0, 0, 0, 883 0, 0, 0,
884 doc: /* Return the indentation of the current line. 884 doc: /* Return the indentation of the current line.
885This is the horizontal position of the character 885This is the horizontal position of the character following any initial
886following any initial whitespace. */) 886whitespace.
887Text that has an invisible property is considered as having width 0, unless
888`buffer-invisibility-spec' specifies that it is replaced by an ellipsis. */)
887 (void) 889 (void)
888{ 890{
889 ptrdiff_t posbyte; 891 ptrdiff_t posbyte;
@@ -1001,6 +1003,9 @@ as displayed of the previous characters in the line.
1001This function ignores line-continuation; 1003This function ignores line-continuation;
1002there is no upper limit on the column number a character can have 1004there is no upper limit on the column number a character can have
1003and horizontal scrolling has no effect. 1005and horizontal scrolling has no effect.
1006Text that has an invisible property is considered as having width 0,
1007unless `buffer-invisibility-spec' specifies that it is replaced by
1008an ellipsis.
1004 1009
1005If specified column is within a character, point goes after that character. 1010If specified column is within a character, point goes after that character.
1006If it's past end of line, point goes to end of line. 1011If it's past end of line, point goes to end of line.
diff --git a/src/macfont.m b/src/macfont.m
index fe30908f5d6..4de056cb361 100644
--- a/src/macfont.m
+++ b/src/macfont.m
@@ -2645,6 +2645,9 @@ macfont_open (struct frame * f, Lisp_Object entity, int pixel_size)
2645 font->pixel_size = size; 2645 font->pixel_size = size;
2646 font->driver = &macfont_driver; 2646 font->driver = &macfont_driver;
2647 font->encoding_charset = font->repertory_charset = -1; 2647 font->encoding_charset = font->repertory_charset = -1;
2648 /* Clear font->space_width so macfont_monospace_width_multiplier may
2649 not be confused by an uninitialized value. */
2650 font->space_width = 0;
2648 2651
2649 block_input (); 2652 block_input ();
2650 2653