[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: new frames ignore default frame positions
From: |
YAMAMOTO Mitsuharu |
Subject: |
Re: new frames ignore default frame positions |
Date: |
Sat, 08 May 2004 19:14:10 +0900 |
User-agent: |
Wanderlust/2.10.1 (Watching The Wheels) SEMI/1.14.5 (Awara-Onsen) FLIM/1.14.5 (Demachiyanagi) APEL/10.6 Emacs/21.3.50 (sparc-sun-solaris2.8) MULE/5.0 (SAKAKI) |
>>>>> On Mon, 1 Mar 2004 09:47:03 +0000, David Reitter <address@hidden> said:
> (On OS X 10.3, CVS checkout)
> It looks like new frames, for example created by
> find-file-other-frame, ignore the position defaults
> (top, left) set in default-frame-alist.
Please try the following patch.
YAMAMOTO Mitsuharu
address@hidden
Index: src/macterm.c
===================================================================
RCS file: /cvsroot/emacs/emacs/src/macterm.c,v
retrieving revision 1.67
diff -c -r1.67 macterm.c
*** src/macterm.c 7 May 2004 17:46:50 -0000 1.67
--- src/macterm.c 8 May 2004 09:45:33 -0000
***************
*** 8698,8704 ****
ROWS Macintosh window, using font with name FONTNAME and size
FONTSIZE. */
void
! NewMacWindow (FRAME_PTR fp)
{
mac_output *mwp;
#if TARGET_API_MAC_CARBON
--- 8700,8706 ----
ROWS Macintosh window, using font with name FONTNAME and size
FONTSIZE. */
void
! make_mac_frame (FRAME_PTR fp)
{
mac_output *mwp;
#if TARGET_API_MAC_CARBON
***************
*** 8717,8724 ****
making_terminal_window = 0;
}
else
! if (!(mwp->mWP = GetNewCWindow (WINDOW_RESOURCE, NULL, (WindowPtr) -1)))
! abort ();
SetWRefCon (mwp->mWP, (long) mwp);
/* so that update events can find this mac_output struct */
--- 8719,8738 ----
making_terminal_window = 0;
}
else
! {
! #if TARGET_API_MAC_CARBON
! Rect r;
!
! SetRect (&r, 0, 0, 1, 1);
! if (CreateNewWindow (kDocumentWindowClass,
! kWindowStandardDocumentAttributes
! /* | kWindowToolbarButtonAttribute */,
! &r, &mwp->mWP) != noErr)
! #else
! if (!(mwp->mWP = GetNewCWindow (WINDOW_RESOURCE, NULL, (WindowPtr) -1)))
! #endif
! abort ();
! }
SetWRefCon (mwp->mWP, (long) mwp);
/* so that update events can find this mac_output struct */
***************
*** 8730,8749 ****
SetPort (mwp->mWP);
#endif
- mwp->fontset = -1;
-
SizeWindow (mwp->mWP, FRAME_PIXEL_WIDTH (fp), FRAME_PIXEL_HEIGHT (fp),
false);
- ShowWindow (mwp->mWP);
-
}
void
! make_mac_frame (struct frame *f)
{
! FRAME_DESIRED_CURSOR (f) = FILLED_BOX_CURSOR;
! NewMacWindow(f);
f->output_data.mac->cursor_pixel = 0;
f->output_data.mac->border_pixel = 0x00ff00;
--- 8744,8774 ----
SetPort (mwp->mWP);
#endif
SizeWindow (mwp->mWP, FRAME_PIXEL_WIDTH (fp), FRAME_PIXEL_HEIGHT (fp),
false);
}
void
! make_mac_terminal_frame (struct frame *f)
{
! Lisp_Object frame;
! XSETFRAME (frame, f);
!
! f->output_method = output_mac;
! f->output_data.mac = (struct mac_output *)
! xmalloc (sizeof (struct mac_output));
! bzero (f->output_data.mac, sizeof (struct mac_output));
!
! XSETFRAME (FRAME_KBOARD (f)->Vdefault_minibuffer_frame, f);
!
! FRAME_COLS (f) = 96;
! FRAME_LINES (f) = 4;
!
! FRAME_CAN_HAVE_SCROLL_BARS (f) = 1;
! FRAME_VERTICAL_SCROLL_BAR_TYPE (f) = vertical_scroll_bar_right;
!
! FRAME_DESIRED_CURSOR (f) = FILLED_BOX_CURSOR;
f->output_data.mac->cursor_pixel = 0;
f->output_data.mac->border_pixel = 0x00ff00;
***************
*** 8751,8758 ****
f->output_data.mac->cursor_foreground_pixel = 0x0000ff;
FRAME_FONTSET (f) = -1;
- f->output_data.mac->scroll_bar_foreground_pixel = -1;
- f->output_data.mac->scroll_bar_background_pixel = -1;
f->output_data.mac->explicit_parent = 0;
f->left_pos = 4;
f->top_pos = 4;
--- 8776,8781 ----
***************
*** 8760,8796 ****
f->internal_border_width = 0;
- f->output_method = output_mac;
-
f->auto_raise = 1;
f->auto_lower = 1;
f->new_text_cols = 0;
f->new_text_lines = 0;
- }
-
- void
- make_mac_terminal_frame (struct frame *f)
- {
- Lisp_Object frame;
-
- XSETFRAME (frame, f);
-
- f->output_method = output_mac;
- f->output_data.mac = (struct mac_output *)
- xmalloc (sizeof (struct mac_output));
- bzero (f->output_data.mac, sizeof (struct mac_output));
- FRAME_FONTSET (f) = -1;
- f->output_data.mac->scroll_bar_foreground_pixel = -1;
- f->output_data.mac->scroll_bar_background_pixel = -1;
-
- XSETFRAME (FRAME_KBOARD (f)->Vdefault_minibuffer_frame, f);
-
- FRAME_COLS (f) = 96;
- FRAME_LINES (f) = 4;
-
- FRAME_CAN_HAVE_SCROLL_BARS (f) = 1;
- FRAME_VERTICAL_SCROLL_BAR_TYPE (f) = vertical_scroll_bar_right;
make_mac_frame (f);
--- 8783,8793 ----
***************
*** 8808,8813 ****
--- 8805,8812 ----
Fmodify_frame_parameters (frame,
Fcons (Fcons (Qbackground_color,
build_string ("white")), Qnil));
+
+ ShowWindow (f->output_data.mac->mWP);
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: new frames ignore default frame positions,
YAMAMOTO Mitsuharu <=