Mercurial > vim
comparison src/textprop.c @ 29696:c1c599a367d4 v9.0.0188
patch 9.0.0188: strange effects when using "text_align" with non-zero column
Commit: https://github.com/vim/vim/commit/82b14c143aa1e70d55509cc9fa408828e90c93de
Author: Bram Moolenaar <Bram@vim.org>
Date: Wed Aug 10 19:50:47 2022 +0100
patch 9.0.0188: strange effects when using "text_align" with non-zero column
Problem: Strange effects when using virtual text with "text_align" and
non-zero column. (Martin Tournoij)
Solution: Give an error. (closes #10888)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Wed, 10 Aug 2022 21:00:04 +0200 |
parents | 6569c71c5ca5 |
children | d97b2ce26258 |
comparison
equal
deleted
inserted
replaced
29695:78eecd33c951 | 29696:c1c599a367d4 |
---|---|
486 { | 486 { |
487 char_u *p = dict_get_string(dict, "text_align", FALSE); | 487 char_u *p = dict_get_string(dict, "text_align", FALSE); |
488 | 488 |
489 if (p == NULL) | 489 if (p == NULL) |
490 goto theend; | 490 goto theend; |
491 if (start_col != 0) | |
492 { | |
493 emsg(_(e_can_only_use_text_align_when_column_is_zero)); | |
494 goto theend; | |
495 } | |
491 if (STRCMP(p, "right") == 0) | 496 if (STRCMP(p, "right") == 0) |
492 flags |= TP_FLAG_ALIGN_RIGHT; | 497 flags |= TP_FLAG_ALIGN_RIGHT; |
493 else if (STRCMP(p, "below") == 0) | 498 else if (STRCMP(p, "below") == 0) |
494 flags |= TP_FLAG_ALIGN_BELOW; | 499 flags |= TP_FLAG_ALIGN_BELOW; |
495 else if (STRCMP(p, "after") != 0) | 500 else if (STRCMP(p, "after") != 0) |