Skip to content

Commit a8d5496

Browse files
committed
[fix] draw font wsize next-line visually
1 parent c5b1b95 commit a8d5496

File tree

2 files changed

+7
-8
lines changed

2 files changed

+7
-8
lines changed

src/handler/theme/handler.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ void ekg::handler::theme::init() {
8989
ekg::theme_t black_light_pinky_theme {
9090
.tag = "black-light-pinky",
9191
.author = "Rina Wilk",
92-
.description = "oiiiiiiiii eu amo vc serpa, lindo maravilhoso"
92+
.description = "misses"
9393
};
9494

9595
black_light_pinky_theme.layout_offset = 2.0f;
@@ -146,7 +146,7 @@ void ekg::handler::theme::init() {
146146

147147
ekg::theme_t black_pinky {
148148
.tag = "black-pinky",
149-
.author = "serpa",
149+
.author = "weasted",
150150
.description = "colors for show colors"
151151
};
152152

@@ -193,7 +193,7 @@ void ekg::handler::theme::init() {
193193
black_pinky.popup_color_scheme.outline = {50, 50, 50, 100};
194194
black_pinky.popup_color_scheme.popup_mode = true;
195195

196-
black_pinky.textbox_color_scheme.background = {20, 34, 21, 255};
196+
black_pinky.textbox_color_scheme.background = {0, 0, 0, 255};
197197
black_pinky.textbox_color_scheme.outline = {190, 190, 190, 100};
198198
black_pinky.textbox_color_scheme.text_foreground = {242, 242, 242, 255};
199199
black_pinky.textbox_color_scheme.text_cursor_foreground = {141, 141, 141, 255};

src/ui/textbox/widget.cpp

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,7 @@ void ekg::ui::refresh_cursors_pos(
8888
: cursor.b.x - (origin.a.x - origin.b.x);
8989
cursor.b.y += displacement_b.y;
9090
}
91+
9192
break;
9293
case ekg::ui::textbox_operation::erase_inline:
9394
if (cursor.a.y > origin.b.y) {
@@ -1500,11 +1501,11 @@ void ekg::ui::buffering(
15001501
bool is_next_line_selected_in_some_way {};
15011502

15021503
if (
1503-
!is_complete_line_selected
1504-
&&
15051504
is_last_char_from_line
15061505
&&
15071506
(is_next_line_selected_in_some_way = ekg::ui::find_cursor(textbox, next_line_index, nearest_cursor))
1507+
&&
1508+
!is_complete_line_selected
15081509
) {
15091510
glyph_wsize += draw_font.space_wsize;
15101511
}
@@ -1515,8 +1516,6 @@ void ekg::ui::buffering(
15151516
&&
15161517
is_next_line_selected_in_some_way
15171518
&&
1518-
is_inline_selected
1519-
&&
15201519
!ekg::ui::find_cursor(textbox, next_char_index, nearest_cursor)
15211520
) {
15221521
cursor.rect.x = textbox.color_scheme.gutter_margin;
@@ -1535,7 +1534,7 @@ void ekg::ui::buffering(
15351534
}
15361535

15371536
if (is_inline_selected) {
1538-
cursor.rect.x = pos.x + end_cursor_position;
1537+
cursor.rect.x = pos.x;
15391538
cursor.rect.y = pos.y;
15401539
cursor.rect.w = glyph_wsize;
15411540
cursor.rect.h = textbox.widget.rect_text_size.h;

0 commit comments

Comments
 (0)