From: Eli Zaretskii <eliz@gnu.org>
To: Keith David Bershatsky <esq@lawlist.com>
Cc: 30226@debbugs.gnu.org
Subject: bug#30226: Fixing it->pixel_width / it->current_x when tabs and line numbers.
Date: Mon, 19 Feb 2018 18:28:38 +0200 [thread overview]
Message-ID: <83woz97xl5.fsf@gnu.org> (raw)
In-Reply-To: <m2zi45g1u1.wl%esq@lawlist.com> (message from Keith David Bershatsky on Sun, 18 Feb 2018 18:17:26 -0800)
> Date: Sun, 18 Feb 2018 18:17:26 -0800
> From: Keith David Bershatsky <esq@lawlist.com>
> Cc: 30226@debbugs.gnu.org
>
> A major break-through in the tracing of bug 30226 .... it->current_x differs between the real thing (when display_line calls PRODUCE_GLYPHS), versus the simulation (when move_it_in_display_line_to calls PRODUCE_GLYPHS), _because_ maybe_produce_line_number advances it->current_x in the former but _not_ the latter.
How do you see that maybe_produce_line_number doesn't advance
current_x? AFAICS, it does that unconditionally:
for ( ; g < e; g++)
{
it->current_x += g->pixel_width; <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
/* The following is important when this function is called
from move_it_in_display_line_to: HPOS is incremented only
when we are in the visible portion of the glyph row. */
if (it->current_x > it->first_visible_x)
it->hpos++;
if (p)
{
*p++ = *g;
(*u)++;
}
}
Did you mean hpos instead? Or did you mean that
maybe_produce_line_number is not called from
move_it_in_display_line_to in some case, whereas it is called from
display_line? Or something else?
> SOLUTION (suggested): Revise move_it_in_display_line_to advance X by simulating a call to maybe_produce_line_number and permitting that function to advance X.
But this is already done...
next prev parent reply other threads:[~2018-02-19 16:28 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-01-23 7:32 bug#30226: Fixing it->pixel_width / it->current_x when tabs and line numbers Keith David Bershatsky
2018-01-23 7:52 ` Keith David Bershatsky
2018-01-27 14:56 ` Eli Zaretskii
2018-01-27 21:20 ` Keith David Bershatsky
2018-01-28 18:15 ` Eli Zaretskii
2018-01-28 19:52 ` Keith David Bershatsky
2018-01-29 16:14 ` Eli Zaretskii
2018-01-31 8:03 ` Keith David Bershatsky
2018-02-04 19:21 ` Keith David Bershatsky
2018-02-19 2:17 ` Keith David Bershatsky
2018-02-19 16:28 ` Eli Zaretskii [this message]
2018-02-19 18:52 ` Keith David Bershatsky
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=83woz97xl5.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=30226@debbugs.gnu.org \
--cc=esq@lawlist.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).