From: Ryan Davis <ryand-ruby@zenspider.com>
To: emacs-devel@gnu.org
Subject: patch for nsterm.m to fix visual-bell
Date: Mon, 29 Jun 2009 20:53:23 -0700 [thread overview]
Message-ID: <5CB755FC-9A86-4DD5-8F16-69EC81BD77EB@zenspider.com> (raw)
Current visual-bell on nextstep emacs is a small black square right in
the middle of the frame. I find it incredibly jarring and it often
breaks my concentration.
This patch changes it to be 1 line height at the bottom of the window
over the minibuffer much like the previous visual-bell in 22.3. 22.3
also has a line at the top but I didn't want to futz with the patch
more than I had to lest it not get accepted. The patch is available at:
http://paste.segment7.net/q
or below:
Index: src/nsterm.m
===================================================================
RCS file: /cvsroot/emacs/emacs/src/nsterm.m,v
retrieving revision 1.76
diff -u -r1.76 nsterm.m
--- src/nsterm.m 26 Jun 2009 18:37:41 -0000 1.76
+++ src/nsterm.m 30 Jun 2009 03:51:45 -0000
@@ -836,13 +836,10 @@
if (view != nil)
{
NSRect r, surr;
- NSPoint dim = NSMakePoint (128, 128);
r = [view bounds];
- r.origin.x += (r.size.width - dim.x) / 2;
- r.origin.y += (r.size.height - dim.y) / 2;
- r.size.width = dim.x;
- r.size.height = dim.y;
+ r.origin.y += r.size.height - FRAME_LINE_HEIGHT(frame) - 2;
+ r.size.height = FRAME_LINE_HEIGHT(frame) + 2;
surr = NSInsetRect (r, -2, -2);
ns_focus (frame, &surr, 1);
[[view window] cacheImageInRect: [view convertRect: surr
toView:nil]];
next reply other threads:[~2009-06-30 3:53 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-06-30 3:53 Ryan Davis [this message]
2009-06-30 20:19 ` patch for nsterm.m to fix visual-bell Stefan Monnier
2009-07-01 0:03 ` Miles Bader
2009-07-01 15:06 ` Stefan Monnier
2009-07-01 15:16 ` Miles Bader
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=5CB755FC-9A86-4DD5-8F16-69EC81BD77EB@zenspider.com \
--to=ryand-ruby@zenspider.com \
--cc=emacs-devel@gnu.org \
/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).