]> code.delx.au - gnu-emacs/blobdiff - lisp/term/x-win.el
* term/x-win.el (x-select-text, x-cut-buffer-or-selection-value):
[gnu-emacs] / lisp / term / x-win.el
index 8123d509f1c1e6da4a491e1403113c6e499f7b93..0e68fa575eb9155616ccd347241910c33494666c 100644 (file)
@@ -2164,8 +2164,8 @@ in the clipboard."
        (t
         (setq x-last-selected-text-cut text
               x-last-selected-text-cut-encoded
-              (encode-coding-string text (or locale-coding-system
-                                             'iso-latin-1)))
+              ;; ICCCM says cut buffer always contain ISO-Latin-1
+              (encode-coding-string text 'iso-latin-1))
         (x-set-cut-buffer x-last-selected-text-cut-encoded push)))
   (x-set-selection 'PRIMARY text)
   (setq x-last-selected-text-primary text)
@@ -2346,8 +2346,8 @@ order until succeed.")
           (t
            (setq x-last-selected-text-cut-encoded cut-text
                  x-last-selected-text-cut
-                 (decode-coding-string cut-text (or locale-coding-system
-                                                    'iso-latin-1))))))
+                 ;; ICCCM says cut buffer always contain ISO-Latin-1
+                 (decode-coding-string cut-text 'iso-latin-1)))))
 
     ;; As we have done one selection, clear this now.
     (setq next-selection-coding-system nil)
@@ -2448,12 +2448,15 @@ order until succeed.")
                               (cons '(user-size . t) parsed))))
        ;; All geometry parms apply to the initial frame.
        (setq initial-frame-alist (append initial-frame-alist parsed))
-       ;; The size parms apply to all frames.
-       (if (assq 'height parsed)
+       ;; The size parms apply to all frames.  Don't set it if there are
+       ;; sizes there already (from command line).
+       (if (and (assq 'height parsed)
+                (not (assq 'height default-frame-alist)))
            (setq default-frame-alist
                  (cons (cons 'height (cdr (assq 'height parsed)))
                        default-frame-alist)))
-       (if (assq 'width parsed)
+       (if (and (assq 'width parsed)
+                (not (assq 'width default-frame-alist)))
            (setq default-frame-alist
                  (cons (cons 'width (cdr (assq 'width parsed)))
                        default-frame-alist))))))