diff options
| author | Jack Jamison <jackqjamison@gmail.com> | 2025-11-09 02:18:03 -0500 |
|---|---|---|
| committer | Jack Jamison <jackqjamison@gmail.com> | 2025-11-09 02:18:03 -0500 |
| commit | c078f5275f27a8812301a7d9c795ab4284d69bd3 (patch) | |
| tree | 6245399e52c1c01c0a6630db3a8739581df01f12 /layout.c | |
| parent | d0b1b2db2210d4fe31701d144d03a37ea55ece00 (diff) | |
improve prompt layout
Diffstat (limited to 'layout.c')
| -rw-r--r-- | layout.c | 3 |
1 files changed, 1 insertions, 2 deletions
@@ -4,7 +4,6 @@ void calculate_layout(client_state* state, rect_t* prompt, rect_t* input, rect_t* options, bool recalc_options, bool recalc_pages) { if (state->prompt && *state->prompt) { - *prompt = (rect_t){ .x = 0, .y = state->line_height * state->lines, .dx = state->prompt_text_buffer.pixel_len + state->horizontal_spacing, .dy = state->line_height }; } else { @@ -13,7 +12,7 @@ void calculate_layout(client_state* state, rect_t* prompt, rect_t* input, rect_t // calculate input rect *input = (rect_t){ .x = prompt->dx, .y = state->line_height * state->lines, .dx = state->width - prompt->dx, .dy = state->line_height }; if (state->lines == 0 && array_size(state->filtered_items) != 0) { - input->dx = state->width / 3.0f - input->x; + input->dx = state->width / 3.0f; } // calculate options rect |
