From: storm@cua.dk (Kim F. Storm)
Cc: "Jan D." <jan.h.d@swipnet.se>, emacs-devel@gnu.org
Subject: Re: FIX: byte-code: Wrong type argument: number-or-marker-p, (+ -21)
Date: 17 Nov 2003 15:06:15 +0100 [thread overview]
Message-ID: <m3ekw7ytrc.fsf@kfs-l.imdomain.dk> (raw)
In-Reply-To: <m365hjcncq.fsf@appel.flower>
Jan Nieuwenhuizen <janneke@gnu.org> writes:
> "Jan D." <jan.h.d@swipnet.se> writes:
>
> > These lines in frame-notice-user-settings triggers the error:
> > (let* ...
> > (top (frame-parameter frame-initial-frame 'top)))
> > (when (and (consp initial-top) (eq '- (car initial-top)))
> > (setq newparms
> > (append newparms
> > `((top . ,(+ top (* lines char-height))))
> > nil)))
>
> Thanks. Why did debug-on-error not show me a backtrace?
>
> > When the top of the frame is over the top of the display:
> >
> > (frame-parameter (selected-frame) 'top)
> > (+ -21)
> >
> > Ditto for left.
>
> I could not trigger the error for left.
>
> > Someone better in lisp than me can probably fix
> > frame-notice-user-settings so it works ok.
>
> I'm not sure that I qualify, but below is a fix.
>
> Greetings,
> Jan.
>
>
> 2003-11-16 Jan Nieuwenhuizen <jan.nieuwenhuizen@aspiratie.nl>
>
> * frame.el (frame-notice-user-settings): Fix for TOP parameter
> of CONS flavour.
>
> --- frame.el.~1.205.~ 2003-10-02 16:06:45.000000000 +0200
> +++ frame.el 2003-11-16 23:03:18.000000000 +0100
> @@ -333,7 +333,12 @@ React to settings of `default-frame-alis
> (newparms (list (cons 'height (- height lines))))
> (initial-top (cdr (assq 'top
> frame-initial-geometry-arguments)))
> - (top (frame-parameter frame-initial-frame 'top)))
> + (fif-top (frame-parameter frame-initial-frame 'top))
> + (top (if (consp fif-top)
> + (cond ((eq '+ (car fif-top)) (cadr fif-top))
> + ((eq '- (car fif-top)) (- 0 (cadr fif-top)))
> + (t 0))
> + fif-top)))
> (when (and (consp initial-top) (eq '- (car initial-top)))
> (setq newparms
> (append newparms
`((top . ,(+ top (* lines char-height))))
nil)))
This still looks bogus to me, as the new parameter doesn't preserve
the (+ ...) or (- ...) form of the original setting, but uses the
calculated value directly. Shouldn't it preserve the top/left (+) or
bottom/right (-) indication?
--
Kim F. Storm <storm@cua.dk> http://www.cua.dk
next prev parent reply other threads:[~2003-11-17 14:06 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-11-12 15:33 byte-code: Wrong type argument: number-or-marker-p, (+ -21) Jan Nieuwenhuizen
2003-11-14 22:47 ` Jan D.
2003-11-17 10:15 ` FIX: " Jan Nieuwenhuizen
2003-11-17 14:06 ` Kim F. Storm [this message]
2003-11-17 13:43 ` Jan Nieuwenhuizen
2003-11-19 13:26 ` Jan Nieuwenhuizen
2003-11-19 17:07 ` Kim F. Storm
2003-11-19 21:07 ` Jan Nieuwenhuizen
2003-11-19 23:46 ` Kim F. Storm
2003-11-20 9:59 ` FIX#3: " Jan Nieuwenhuizen
2003-11-23 21:32 ` Jan D.
2003-12-06 16:14 ` Geometry interpretation change? (was: FIX#3: byte-code: Wrong type argument: number-or-marker-p, (+ -21)) Jan D.
2003-12-07 0:57 ` Kim F. Storm
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=m3ekw7ytrc.fsf@kfs-l.imdomain.dk \
--to=storm@cua.dk \
--cc=emacs-devel@gnu.org \
--cc=jan.h.d@swipnet.se \
/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).