diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/xdisp.c | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/src/xdisp.c b/src/xdisp.c index 8aa38c8034c..1f3a8136f8b 100644 --- a/src/xdisp.c +++ b/src/xdisp.c | |||
| @@ -22664,6 +22664,14 @@ maybe_produce_line_number (struct it *it) | |||
| 22664 | empty lines beyond EOB. */ | 22664 | empty lines beyond EOB. */ |
| 22665 | && it->what != IT_EOB) | 22665 | && it->what != IT_EOB) |
| 22666 | tem_it.face_id = current_lnum_face_id; | 22666 | tem_it.face_id = current_lnum_face_id; |
| 22667 | else if (display_line_numbers_major_tick > 0 | ||
| 22668 | && (lnum_to_display % display_line_numbers_major_tick == 0)) | ||
| 22669 | tem_it.face_id = merge_faces (it->w, Qline_number_major_tick, | ||
| 22670 | 0, DEFAULT_FACE_ID); | ||
| 22671 | else if (display_line_numbers_minor_tick > 0 | ||
| 22672 | && (lnum_to_display % display_line_numbers_minor_tick == 0)) | ||
| 22673 | tem_it.face_id = merge_faces (it->w, Qline_number_minor_tick, | ||
| 22674 | 0, DEFAULT_FACE_ID); | ||
| 22667 | else | 22675 | else |
| 22668 | tem_it.face_id = lnum_face_id; | 22676 | tem_it.face_id = lnum_face_id; |
| 22669 | if (beyond_zv | 22677 | if (beyond_zv |
| @@ -34125,6 +34133,8 @@ be let-bound around code that needs to disable messages temporarily. */); | |||
| 34125 | /* Names of the faces used to display line numbers. */ | 34133 | /* Names of the faces used to display line numbers. */ |
| 34126 | DEFSYM (Qline_number, "line-number"); | 34134 | DEFSYM (Qline_number, "line-number"); |
| 34127 | DEFSYM (Qline_number_current_line, "line-number-current-line"); | 34135 | DEFSYM (Qline_number_current_line, "line-number-current-line"); |
| 34136 | DEFSYM (Qline_number_major_tick, "line-number-major-tick"); | ||
| 34137 | DEFSYM (Qline_number_minor_tick, "line-number-minor-tick"); | ||
| 34128 | /* Name of a text property which disables line-number display. */ | 34138 | /* Name of a text property which disables line-number display. */ |
| 34129 | DEFSYM (Qdisplay_line_numbers_disable, "display-line-numbers-disable"); | 34139 | DEFSYM (Qdisplay_line_numbers_disable, "display-line-numbers-disable"); |
| 34130 | 34140 | ||
| @@ -34760,6 +34770,20 @@ if the font in fill-column-indicator face does not support Unicode characters. | |||
| 34760 | DEFSYM (Qdisplay_fill_column_indicator_character, "display-fill-column-indicator-character"); | 34770 | DEFSYM (Qdisplay_fill_column_indicator_character, "display-fill-column-indicator-character"); |
| 34761 | Fmake_variable_buffer_local (Qdisplay_fill_column_indicator_character); | 34771 | Fmake_variable_buffer_local (Qdisplay_fill_column_indicator_character); |
| 34762 | 34772 | ||
| 34773 | DEFVAR_INT ("display-line-numbers-major-tick", display_line_numbers_major_tick, | ||
| 34774 | doc: /* If an integer N > 0, highlight line number of every Nth line. | ||
| 34775 | The line number is shown with the `line-number-major-tick' face. | ||
| 34776 | Otherwise, no special highlighting is done every Nth line. | ||
| 34777 | Note that major ticks take precedence over minor ticks. */); | ||
| 34778 | display_line_numbers_major_tick = 0; | ||
| 34779 | |||
| 34780 | DEFVAR_INT ("display-line-numbers-minor-tick", display_line_numbers_minor_tick, | ||
| 34781 | doc: /* If an integer N > 0, highlight line number of every Nth line. | ||
| 34782 | The line number is shown with the `line-number-minor-tick' face. | ||
| 34783 | Otherwise, no special highlighting is done every Nth line. | ||
| 34784 | Note that major ticks take precedence over minor ticks. */); | ||
| 34785 | display_line_numbers_minor_tick = 0; | ||
| 34786 | |||
| 34763 | DEFVAR_BOOL ("inhibit-eval-during-redisplay", inhibit_eval_during_redisplay, | 34787 | DEFVAR_BOOL ("inhibit-eval-during-redisplay", inhibit_eval_during_redisplay, |
| 34764 | doc: /* Non-nil means don't eval Lisp during redisplay. */); | 34788 | doc: /* Non-nil means don't eval Lisp during redisplay. */); |
| 34765 | inhibit_eval_during_redisplay = false; | 34789 | inhibit_eval_during_redisplay = false; |