unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Aaron Jensen <aaronjensen@gmail.com>
To: martin rudalics <rudalics@gmx.at>
Cc: 30141@debbugs.gnu.org
Subject: bug#30141: (26.0.91; text-pixel dimensions not properly saved by desktop-save-mode sometimes)
Date: Thu, 15 Mar 2018 08:24:22 -0700	[thread overview]
Message-ID: <CAHyO48wH-mGpzyhWomFfW9U55+MW0mHZOxnMnCxV-6VTxFAoww@mail.gmail.com> (raw)
In-Reply-To: <5AAA2CD8.7050307@gmx.at>

[-- Attachment #1: Type: text/plain, Size: 543 bytes --]

On Thu, Mar 15, 2018 at 1:20 AM, martin rudalics <rudalics@gmx.at> wrote:
> Can you please resend the patch.  The column number of the first paren
> in
>
>               (cons nil
>                     (and mb-frame
>                          (frameset-frame-id mb-frame)))))))))
>
> here is 13 but 14 according to you patch.  So I can't convince git of
> applying it regardless of whether I use the --ignore-whitespace or the
> --ignore-space-change option.

I may have made the patch off of emacs-26. How about this one, it's
off of master.

[-- Attachment #2: 0001-Save-frame-pixel-width-height-if-frame-resize-pixelw.patch --]
[-- Type: application/octet-stream, Size: 2002 bytes --]

From ac2722e3249bd9e354bca2b348844ba90914a6dd Mon Sep 17 00:00:00 2001
From: Aaron Jensen <aaronjensen@gmail.com>
Date: Wed, 14 Mar 2018 07:51:25 -0700
Subject: [PATCH] Save frame pixel/width height if frame-resize-pixelwise is
 non-nil

* lisp/frameset.el (frameset--record-relationships): Replace check for
  text width/height and replace with check for
  frame-resize-pixelwise. (bug#30141)
---
 lisp/frameset.el | 25 ++++++++++---------------
 1 file changed, 10 insertions(+), 15 deletions(-)

diff --git a/lisp/frameset.el b/lisp/frameset.el
index 0e3363d7ae..8bccc8b1d2 100644
--- a/lisp/frameset.el
+++ b/lisp/frameset.el
@@ -800,22 +800,17 @@ frameset--record-relationships
              (cons nil
                    (and mb-frame
                         (frameset-frame-id mb-frame)))))))))
-  ;; Now store text-pixel width and height if it differs from the calculated
-  ;; width and height and the frame is not fullscreen.
+  ;; Now store text-pixel width and height if `frame-resize-pixelwise'
+  ;; is set.
   (dolist (frame frame-list)
-    (unless (frame-parameter frame 'fullscreen)
-      (unless (eq (* (frame-parameter frame 'width)
-                     (frame-char-width frame))
-                  (frame-text-width frame))
-        (set-frame-parameter
-         frame 'frameset--text-pixel-width
-         (frame-text-width frame)))
-      (unless (eq (* (frame-parameter frame 'height)
-                     (frame-char-height frame))
-                  (frame-text-height frame))
-        (set-frame-parameter
-         frame 'frameset--text-pixel-height
-         (frame-text-height frame))))))
+    (when (and frame-resize-pixelwise
+               (not (frame-parameter frame 'fullscreen)))
+      (set-frame-parameter
+       frame 'frameset--text-pixel-width
+       (frame-text-width frame))
+      (set-frame-parameter
+       frame 'frameset--text-pixel-height
+       (frame-text-height frame)))))
 
 ;;;###autoload
 (cl-defun frameset-save (frame-list
-- 
2.15.1


  reply	other threads:[~2018-03-15 15:24 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-17  1:24 bug#30141: 26.0.91; text-pixel dimensions not properly saved by desktop-save-mode sometimes Aaron Jensen
2018-01-17  5:43 ` bug#30141: (26.0.91; text-pixel dimensions not properly saved by desktop-save-mode sometimes) Aaron Jensen
2018-01-17  8:49   ` Robert Pluim
2018-01-17 11:45     ` Aaron Jensen
2018-01-17  9:12   ` martin rudalics
2018-01-17 11:50     ` Aaron Jensen
2018-01-17 11:59       ` Aaron Jensen
2018-01-19 18:55       ` martin rudalics
2018-01-19 19:00         ` Aaron Jensen
2018-01-20 10:35           ` martin rudalics
2018-01-20 10:50             ` Eli Zaretskii
2018-01-20 14:07               ` martin rudalics
2018-01-20 14:33                 ` Eli Zaretskii
2018-01-22  9:54                   ` martin rudalics
2018-02-13 10:23                     ` martin rudalics
2018-03-12 22:18           ` Aaron Jensen
2018-03-13  7:26             ` martin rudalics
2018-03-13 15:32               ` Aaron Jensen
2018-03-14  8:14                 ` martin rudalics
2018-03-14 14:59                   ` Aaron Jensen
2018-03-14 15:15                     ` Aaron Jensen
2018-03-14 20:05                       ` martin rudalics
2018-03-14 20:12                         ` Aaron Jensen
2018-03-15  8:20                           ` martin rudalics
2018-03-15 15:24                             ` Aaron Jensen [this message]
2018-03-17 10:05                               ` martin rudalics
2018-03-17 10:11                                 ` Noam Postavsky
2018-03-17 11:08                                   ` martin rudalics
2018-03-17 11:16                                     ` Eli Zaretskii
2018-03-17 11:28                                       ` martin rudalics
2018-03-17 16:32                                 ` Aaron Jensen
2018-01-17  9:12 ` bug#30141: 26.0.91; text-pixel dimensions not properly saved by desktop-save-mode sometimes martin rudalics

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=CAHyO48wH-mGpzyhWomFfW9U55+MW0mHZOxnMnCxV-6VTxFAoww@mail.gmail.com \
    --to=aaronjensen@gmail.com \
    --cc=30141@debbugs.gnu.org \
    --cc=rudalics@gmx.at \
    /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).