From: martin rudalics <rudalics@gmx.at>
To: Constantine Vetoshev <vetoshev@gmail.com>
Cc: 18601@debbugs.gnu.org
Subject: bug#18601: 24.3.94; set-fringe-mode with left fringe 0 breaks window width calculations on Mac OS
Date: Fri, 03 Oct 2014 08:54:37 +0200 [thread overview]
Message-ID: <542E482D.6040001@gmx.at> (raw)
In-Reply-To: <CA+CaSqpxUmJptv2fpLbDN3fLR5QKGx5zVxwYoZFcbjYGiodccQ@mail.gmail.com>
> After (set-fringe-mode '(0 . 2)), executing (window--dump-frame) puts
> the following contents into *window-frame-dump*:
> frame pixel: 600 x 494 cols/lines: 86 x 35 units: 7 x 14
> width left fringe: 0
> width right fringe: 7
> After (set-fringe-mode '(1 . 2)), executing (window--dump-frame) puts
> the following contents into *window-frame-dump*:
> body pixel: 574 x 462 char: 82 x 33
> width left fringe: 3
> width right fringe: 4
Here is the old fringe compensation code at work which apaprently adds 4
or 5 pixels to the specified value in order to get the sum of the widths
of the fringes equal to 7 (the frame's nominal character width). I
removed that code for NS on Emacs 25 but never did so for Emacs 24-4.
Even now I don't know whether it works correctly (see also bug #16856).
In any case I don't see why this should have any impact on what happens
in ansi-term. Apparently `term-window-width' kicks in and due to
(/= (frame-parameter nil 'right-fringe) 0))
it eventually stores in `term-width' a value that is one less than if
both fringes are present.
Since Eli now confirmed that what you observe is a result of one of his
fixes all I can suggest at the moment is to play with
(defun term-window-width ()
(if (and (not (featurep 'xemacs))
(display-graphic-p)
overflow-newline-into-fringe
(/= (frame-parameter nil 'right-fringe) 0))
(window-body-width)
(1- (window-body-width))))
What happens when you make it always return (window-body-width)?
(defun term-window-width ()
(window-body-width))
martin
next prev parent reply other threads:[~2014-10-03 6:54 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-10-02 8:38 bug#18601: 24.3.94; set-fringe-mode with left fringe 0 breaks window width calculations on Mac OS Constantine Vetoshev
2014-10-02 18:44 ` martin rudalics
2014-10-02 19:22 ` Constantine Vetoshev
2014-10-02 19:51 ` Eli Zaretskii
2014-10-02 20:37 ` martin rudalics
2014-10-03 6:19 ` Eli Zaretskii
2014-10-03 6:55 ` martin rudalics
2014-10-03 6:54 ` martin rudalics [this message]
2014-10-03 17:55 ` Constantine Vetoshev
2014-10-03 18:36 ` Eli Zaretskii
2014-10-03 20:53 ` Constantine Vetoshev
2014-10-04 7:08 ` Eli Zaretskii
2014-10-04 17:45 ` Constantine Vetoshev
2014-10-04 18:49 ` Eli Zaretskii
2014-10-04 20:48 ` Constantine Vetoshev
2014-10-06 6:49 ` martin rudalics
2014-10-06 15:10 ` Eli Zaretskii
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=542E482D.6040001@gmx.at \
--to=rudalics@gmx.at \
--cc=18601@debbugs.gnu.org \
--cc=vetoshev@gmail.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 external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.