/[grub]/grub2/include/grub/term.h
ViewVC logotype

Diff of /grub2/include/grub/term.h

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.6 by okuji, Sun Apr 4 13:46:00 2004 UTC revision 1.7 by okuji, Sat Feb 19 20:56:07 2005 UTC
# Line 1  Line 1 
1  /*  /*
2   *  GRUB  --  GRand Unified Bootloader   *  GRUB  --  GRand Unified Bootloader
3   *  Copyright (C) 2002,2003  Free Software Foundation, Inc.   *  Copyright (C) 2002,2003,2005  Free Software Foundation, Inc.
4   *   *
5   *  GRUB is free software; you can redistribute it and/or modify   *  GRUB is free software; you can redistribute it and/or modify
6   *  it under the terms of the GNU General Public License as published by   *  it under the terms of the GNU General Public License as published by
# Line 55  grub_term_color_state; Line 55  grub_term_color_state;
55  /* Set when the terminal needs to be initialized.  */  /* Set when the terminal needs to be initialized.  */
56  #define GRUB_TERM_NEED_INIT     (1 << 16)  #define GRUB_TERM_NEED_INIT     (1 << 16)
57    
58    
59    /* Unicode characters for fancy graphics.  */
60    #define GRUB_TERM_DISP_LEFT     0x2190
61    #define GRUB_TERM_DISP_UP       0x2191
62    #define GRUB_TERM_DISP_RIGHT    0x2192
63    #define GRUB_TERM_DISP_DOWN     0x2193
64    #define GRUB_TERM_DISP_HLINE    0x2501
65    #define GRUB_TERM_DISP_VLINE    0x2503
66    #define GRUB_TERM_DISP_UL       0x250F
67    #define GRUB_TERM_DISP_UR       0x2513
68    #define GRUB_TERM_DISP_LL       0x2517
69    #define GRUB_TERM_DISP_LR       0x251B
70    
71    
72    /* Menu-related geometrical constants.  */
73    
74    /* FIXME: These should be dynamically obtained from a terminal.  */
75    #define GRUB_TERM_WIDTH         80
76    #define GRUB_TERM_HEIGHT        25
77    
78    /* The number of lines of "GRUB version..." at the top.  */
79    #define GRUB_TERM_INFO_HEIGHT   1
80    
81    /* The number of columns/lines between messages/borders/etc.  */
82    #define GRUB_TERM_MARGIN        1
83    
84    /* The number of columns of scroll information.  */
85    #define GRUB_TERM_SCROLL_WIDTH  1
86    
87    /* The Y position of the top border.  */
88    #define GRUB_TERM_TOP_BORDER_Y  (GRUB_TERM_MARGIN + GRUB_TERM_INFO_HEIGHT \
89                                     + GRUB_TERM_MARGIN)
90    
91    /* The X position of the left border.  */
92    #define GRUB_TERM_LEFT_BORDER_X GRUB_TERM_MARGIN
93    
94    /* The width of the border.  */
95    #define GRUB_TERM_BORDER_WIDTH  (GRUB_TERM_WIDTH \
96                                     - GRUB_TERM_MARGIN * 3 \
97                                     - GRUB_TERM_SCROLL_WIDTH)
98    
99    /* The number of lines of messages at the bottom.  */
100    #define GRUB_TERM_MESSAGE_HEIGHT        8
101    
102    /* The height of the border.  */
103    #define GRUB_TERM_BORDER_HEIGHT (GRUB_TERM_HEIGHT \
104                                     - GRUB_TERM_TOP_BORDER_Y \
105                                     - GRUB_TERM_MESSAGE_HEIGHT)
106    
107    /* The number of entries shown at a time.  */
108    #define GRUB_TERM_NUM_ENTRIES   (GRUB_TERM_BORDER_HEIGHT - 2)
109    
110    /* The Y position of the first entry.  */
111    #define GRUB_TERM_FIRST_ENTRY_Y (GRUB_TERM_TOP_BORDER_Y + 1)
112    
113    /* The max column number of an entry. The last "-1" is for a
114       continuation marker.  */
115    #define GRUB_TERM_ENTRY_WIDTH   (GRUB_TERM_BORDER_WIDTH - 2 \
116                                     - GRUB_TERM_MARGIN * 2 - 1)
117    
118    /* The standard X position of the cursor.  */
119    #define GRUB_TERM_CURSOR_X      (GRUB_TERM_LEFT_BORDER_X \
120                                     + GRUB_TERM_BORDER_WIDTH \
121                                     - GRUB_TERM_MARGIN \
122                                     - 1)
123    
124    
125  struct grub_term  struct grub_term
126  {  {
127    /* The terminal name.  */    /* The terminal name.  */

Legend:
Removed from v.1.6  
changed lines
  Added in v.1.7

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26