[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Question about dubious code for terminal frames
From: |
martin rudalics |
Subject: |
Re: Question about dubious code for terminal frames |
Date: |
Mon, 2 Sep 2024 18:20:24 +0200 |
User-agent: |
Mozilla Thunderbird |
> Get the physical dimensions and then what? We must record the
> dimensions in the frames and windows that share that terminal. Which
> is what change_frame_size does.
>
>> Outside of get_tty_size I'd make FrameCols/Rows const. I guess that
>> frame size changes could remain as is. Only that setting FrameCols/Rows
>> is none of their business. It's an input for them, not an output.
>
> Martin will correct me if I'm wrong, but I think the current code
> already does what you want: it only changes FrameCols/Rows when the
> terminal was really resized.
I started reading this thread just now and I have to go through the
preceding posts to even understand the problem. The only thing I can
say at the moment is that I locally made a change to adjust_frame_size
where I moved the assignment of the new frame values headed by
/* Assign new sizes. */
up in the code. The context is now as:
dos_set_window_size (&dos_new_text_lines, &new_text_cols);
new_text_lines = dos_new_text_lines - FRAME_TOP_MARGIN (f);
#endif
/* Assign new sizes. Do it here to make sure that frame based
redisplay gets congruent sizes for the dimensions of the frame
matrix and the combined window matrices. */
FRAME_COLS (f) = new_text_cols;
FRAME_LINES (f) = new_text_lines;
FRAME_TEXT_WIDTH (f) = new_text_width;
FRAME_TEXT_HEIGHT (f) = new_text_height;
FRAME_PIXEL_WIDTH (f) = new_native_width;
FRAME_PIXEL_HEIGHT (f) = new_native_height;
FRAME_TOTAL_COLS (f) = FRAME_PIXEL_WIDTH (f) / FRAME_COLUMN_WIDTH (f);
FRAME_TOTAL_LINES (f) = FRAME_PIXEL_HEIGHT (f) / FRAME_LINE_HEIGHT (f);
if (new_inner_width != old_inner_width)
{
resize_frame_windows (f, new_inner_width, true);
From the modified comment I conjecture that there must have been some
problem with frame based redisplay but I can't recall what it was and
whether it's relevant for the problems in this thread.
martin
- Re: Question about dubious code for terminal frames, (continued)
- Re: Question about dubious code for terminal frames, Gerd Möllmann, 2024/09/02
- Re: Question about dubious code for terminal frames, Eli Zaretskii, 2024/09/02
- Re: Question about dubious code for terminal frames, Gerd Möllmann, 2024/09/02
- Re: Question about dubious code for terminal frames, Eli Zaretskii, 2024/09/02
- Re: Question about dubious code for terminal frames, Gerd Möllmann, 2024/09/02
- Re: Question about dubious code for terminal frames, Eli Zaretskii, 2024/09/02
- Re: Question about dubious code for terminal frames, Gerd Möllmann, 2024/09/02
- Re: Question about dubious code for terminal frames, Eli Zaretskii, 2024/09/02
- Re: Question about dubious code for terminal frames, Gerd Möllmann, 2024/09/02
- Re: Question about dubious code for terminal frames, Eli Zaretskii, 2024/09/02
- Re: Question about dubious code for terminal frames,
martin rudalics <=
- Re: Question about dubious code for terminal frames, Gerd Möllmann, 2024/09/02
- Re: Question about dubious code for terminal frames, martin rudalics, 2024/09/02
- Re: Question about dubious code for terminal frames, Gerd Möllmann, 2024/09/02
- Re: Question about dubious code for terminal frames, Eli Zaretskii, 2024/09/02