ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/cvsroot/rxvt-unicode/src/menubar.C
(Generate patch)

Comparing cvsroot/rxvt-unicode/src/menubar.C (file contents):
Revision 1.14 by pcg, Wed Mar 17 03:47:12 2004 UTC vs.
Revision 1.18 by root, Sun Aug 15 00:37:04 2004 UTC

1/*--------------------------------*-C-*---------------------------------* 1/*--------------------------------*-C-*---------------------------------*
2 * File: menubar.c 2 * File: menubar.C
3 *----------------------------------------------------------------------* 3 *----------------------------------------------------------------------*
4 * 4 *
5 * Copyright (c) 1997,1998 mj olesen <olesen@me.QueensU.CA> 5 * Copyright (c) 1997,1998 mj olesen <olesen@me.QueensU.CA>
6 * Copyright (c) 2004 Marc Lehmann <pcg@goof.com>
6 * 7 *
7 * This program is free software; you can redistribute it and/or modify 8 * This program is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by 9 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation; either version 2 of the License, or 10 * the Free Software Foundation; either version 2 of the License, or
10 * (at your option) any later version. 11 * (at your option) any later version.
28 29
29#include "rxvt.h" /* NECESSARY */ 30#include "rxvt.h" /* NECESSARY */
30#ifdef MENUBAR 31#ifdef MENUBAR
31#include "version.h" 32#include "version.h"
32#include "menubar.h" 33#include "menubar.h"
33#include "menubar.intpro" /* PROTOS for internal routines */
34 34
35#define Menu_PixelWidth(menu) \ 35#define Menu_PixelWidth(menu) \
36 (2 * SHADOW + Width2Pixel ((menu)->width + 3 * HSPACE)) 36 (2 * SHADOW + Width2Pixel ((menu)->width + 3 * HSPACE))
37 37
38static const struct 38static const struct
1706 } 1706 }
1707 } 1707 }
1708 else if ((n = rxvt_Str_match (str, "pixmap:")) != 0) 1708 else if ((n = rxvt_Str_match (str, "pixmap:")) != 0)
1709 { 1709 {
1710 str += n; 1710 str += n;
1711 xterm_seq (XTerm_Pixmap, str, CHAR_ST); 1711 process_xterm_seq (XTerm_Pixmap, str, CHAR_ST);
1712 } 1712 }
1713#if (MENUBAR_MAX > 1) 1713#if (MENUBAR_MAX > 1)
1714 else if ((n = rxvt_Str_match (str, "rm")) != 0) 1714 else if ((n = rxvt_Str_match (str, "rm")) != 0)
1715 { 1715 {
1716 str += n; 1716 str += n;
1759 sprintf (buffer, "/tmp/" RESCLASS "-%u", 1759 sprintf (buffer, "/tmp/" RESCLASS "-%u",
1760 (unsigned int)getpid ()); 1760 (unsigned int)getpid ());
1761 1761
1762 if ((fp = fopen (buffer, "wb")) != NULL) 1762 if ((fp = fopen (buffer, "wb")) != NULL)
1763 { 1763 {
1764 xterm_seq (XTerm_title, buffer, CHAR_ST); 1764 process_xterm_seq (XTerm_title, buffer, CHAR_ST);
1765 menubar_dump (fp); 1765 menubar_dump (fp);
1766 fclose (fp); 1766 fclose (fp);
1767 } 1767 }
1768 } 1768 }
1769 else if (!STRCMP (str, "next")) 1769 else if (!STRCMP (str, "next"))
2034 if (menubarGC == None) 2034 if (menubarGC == None)
2035 { 2035 {
2036 /* Create the graphics context */ 2036 /* Create the graphics context */
2037 XGCValues gcvalue; 2037 XGCValues gcvalue;
2038 2038
2039 gcvalue.foreground = (XDEPTH <= 2 ? PixColors[Color_fg] 2039 gcvalue.foreground = (display->depth <= 2 ? PixColors[Color_fg]
2040 : PixColors[Color_Black]); 2040 : PixColors[Color_Black]);
2041 menubarGC = XCreateGC (display->display, menuBar.win, 2041 menubarGC = XCreateGC (display->display, menuBar.win,
2042 GCForeground, &gcvalue); 2042 GCForeground, &gcvalue);
2043 2043
2044 } 2044 }

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines