[vte/vte-next: 140/223] Move enums to vteenums.h



commit 6bdb04bec4c0bf7250cda4830075b0f92f799e5d
Author: Christian Persch <chpe gnome org>
Date:   Thu Jun 9 23:47:16 2011 +0200

    Move enums to vteenums.h
    
    This is necessary for the next commit.

 src/Makefile.am |    7 ++--
 src/vte.h       |   64 +--------------------------------------
 src/vteenums.h  |   91 +++++++++++++++++++++++++++++++++++++++++++++++++++++++
 3 files changed, 96 insertions(+), 66 deletions(-)
---
diff --git a/src/Makefile.am b/src/Makefile.am
index 0dc1173..ed388ad 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -5,7 +5,7 @@ EXTRA_DIST = iso2022.txt palette.c
 # The library
 
 headerdir = $(includedir)/vte-$(VTE_API_VERSION)/vte
-header_HEADERS = vte.h vtebuffer.h vtepty.h vtetypebuiltins.h vteversion.h
+header_HEADERS = vte.h vtebuffer.h vteenums.h vtepty.h vtetypebuiltins.h vteversion.h
 
 lib_LTLIBRARIES = libvte VTE_LIBRARY_SUFFIX_U@.la
 
@@ -53,6 +53,7 @@ libvte VTE_LIBRARY_SUFFIX_U@_la_SOURCES = \
 	trie.h \
 	vte.c \
 	vte.h \
+	vteenums.h \
 	vte-private.h \
 	vteaccess.c \
 	vteaccess.h \
@@ -119,13 +120,13 @@ marshal.h: marshal.list
 
 vtetypebuiltins.h: stamp-vtetypebuiltins.h
 	@true
-stamp-vtetypebuiltins.h: vtetypebuiltins.h.template vte.h vtepty.h
+stamp-vtetypebuiltins.h: vtetypebuiltins.h.template vteenums.h vtepty.h
 	$(AM_V_GEN) $(GLIB_MKENUMS) --template $< $(filter %.h,$^) > xgen-vtbh \
 	&& (cmp -s xgen-vtbh vtetypebuiltins.h || cp xgen-vtbh vtetypebuiltins.h ) \
 	&& rm -f xgen-vtbh \
 	&& echo timestamp > $(@F)
 
-vtetypebuiltins.c: vtetypebuiltins.c.template vte.h vtepty.h
+vtetypebuiltins.c: vtetypebuiltins.c.template vteenums.h vtepty.h
 	$(AM_V_GEN) $(GLIB_MKENUMS) --template $< $(filter %.h,$^) > xgen-vtbc \
 	&& (cmp -s xgen-vtbc vtetypebuiltins.c || cp xgen-vtbc vtetypebuiltins.c ) \
 	&& rm -f xgen-vtbc
diff --git a/src/vte.h b/src/vte.h
index d58aa6f..b249f14 100644
--- a/src/vte.h
+++ b/src/vte.h
@@ -26,6 +26,7 @@
 
 #define __VTE_VTE_H_INSIDE__ 1
 
+#include "vteenums.h"
 #include "vtepty.h"
 #include "vtebuffer.h"
 
@@ -118,69 +119,6 @@ struct _VteTerminalClass {
 };
 
 /**
- * VteTerminalEraseBinding:
- * @VTE_ERASE_AUTO: For backspace, attempt to determine the right value from the terminal's IO settings.  For delete, use the control sequence.
- * @VTE_ERASE_ASCII_BACKSPACE: Send an ASCII backspace character (0x08).
- * @VTE_ERASE_ASCII_DELETE: Send an ASCII delete character (0x7F).
- * @VTE_ERASE_DELETE_SEQUENCE: Send the "@@7" control sequence.
- * @VTE_ERASE_TTY: Send terminal's "erase" setting.
- *
- * An enumerated type which can be used to indicate which string the terminal
- * should send to an application when the user presses the Delete or Backspace
- * keys.
- */
-typedef enum {
-	VTE_ERASE_AUTO,
-	VTE_ERASE_ASCII_BACKSPACE,
-	VTE_ERASE_ASCII_DELETE,
-	VTE_ERASE_DELETE_SEQUENCE,
-	VTE_ERASE_TTY
-} VteTerminalEraseBinding;
-
-/**
- * VteTerminalCursorBlinkMode:
- * @VTE_CURSOR_BLINK_SYSTEM: Follow GTK+ settings for cursor blinking.
- * @VTE_CURSOR_BLINK_ON: Cursor blinks.
- * @VTE_CURSOR_BLINK_OFF: Cursor does not blink.
- *
- * An enumerated type which can be used to indicate the cursor blink mode
- * for the terminal.
- */
-typedef enum {
-        VTE_CURSOR_BLINK_SYSTEM,
-        VTE_CURSOR_BLINK_ON,
-        VTE_CURSOR_BLINK_OFF
-} VteTerminalCursorBlinkMode;
-
-/**
- * VteTerminalCursorShape:
- * @VTE_CURSOR_SHAPE_BLOCK: Draw a block cursor.  This is the default.
- * @VTE_CURSOR_SHAPE_IBEAM: Draw a vertical bar on the left side of character.
- * This is similar to the default cursor for other GTK+ widgets.
- * @VTE_CURSOR_SHAPE_UNDERLINE: Draw a horizontal bar below the character.
- *
- * An enumerated type which can be used to indicate what should the terminal
- * draw at the cursor position.
- */
-typedef enum {
-        VTE_CURSOR_SHAPE_BLOCK,
-        VTE_CURSOR_SHAPE_IBEAM,
-        VTE_CURSOR_SHAPE_UNDERLINE
-} VteTerminalCursorShape;
-
-/**
- * VteTerminalEffect:
- * @VTE_TERMINAL_EFFECT_REVERSE: Text is draw with foreground and background color reversed.
- * @VTE_TERMINAL_EFFECT_COLOR: Text is drawn with the background color from the corresponding style property.
- *
- * Since: 0.30
- */
-typedef enum {
-        VTE_TERMINAL_EFFECT_REVERSE,
-        VTE_TERMINAL_EFFECT_COLOR
-} VteTerminalEffect;
-
-/**
  * VTE_STYLE_CLASS_TERMINAL:
  *
  * A CSS class to match terminals.
diff --git a/src/vteenums.h b/src/vteenums.h
new file mode 100644
index 0000000..afa00bc
--- /dev/null
+++ b/src/vteenums.h
@@ -0,0 +1,91 @@
+/*
+ * Copyright (C) 2001,2002,2003,2009,2010 Red Hat, Inc.
+ *
+ * This is free software; you can redistribute it and/or modify it under
+ * the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public
+ * License along with this program; if not, write to the Free Software
+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+
+#if !defined (__VTE_VTE_H_INSIDE__) && !defined (VTE_COMPILATION)
+#error "Only <vte/vte.h> can be included directly."
+#endif
+
+#ifndef VTE_ENUMS_H
+#define VTE_ENUMS_H
+
+G_BEGIN_DECLS
+
+/**
+ * VteTerminalEraseBinding:
+ * @VTE_ERASE_AUTO: For backspace, attempt to determine the right value from the terminal's IO settings.  For delete, use the control sequence.
+ * @VTE_ERASE_ASCII_BACKSPACE: Send an ASCII backspace character (0x08).
+ * @VTE_ERASE_ASCII_DELETE: Send an ASCII delete character (0x7F).
+ * @VTE_ERASE_DELETE_SEQUENCE: Send the "@@7" control sequence.
+ * @VTE_ERASE_TTY: Send terminal's "erase" setting.
+ *
+ * An enumerated type which can be used to indicate which string the terminal
+ * should send to an application when the user presses the Delete or Backspace
+ * keys.
+ */
+typedef enum {
+	VTE_ERASE_AUTO,
+	VTE_ERASE_ASCII_BACKSPACE,
+	VTE_ERASE_ASCII_DELETE,
+	VTE_ERASE_DELETE_SEQUENCE,
+	VTE_ERASE_TTY
+} VteTerminalEraseBinding;
+
+/**
+ * VteTerminalCursorBlinkMode:
+ * @VTE_CURSOR_BLINK_SYSTEM: Follow GTK+ settings for cursor blinking.
+ * @VTE_CURSOR_BLINK_ON: Cursor blinks.
+ * @VTE_CURSOR_BLINK_OFF: Cursor does not blink.
+ *
+ * An enumerated type which can be used to indicate the cursor blink mode
+ * for the terminal.
+ */
+typedef enum {
+        VTE_CURSOR_BLINK_SYSTEM,
+        VTE_CURSOR_BLINK_ON,
+        VTE_CURSOR_BLINK_OFF
+} VteTerminalCursorBlinkMode;
+
+/**
+ * VteTerminalCursorShape:
+ * @VTE_CURSOR_SHAPE_BLOCK: Draw a block cursor.  This is the default.
+ * @VTE_CURSOR_SHAPE_IBEAM: Draw a vertical bar on the left side of character.
+ * This is similar to the default cursor for other GTK+ widgets.
+ * @VTE_CURSOR_SHAPE_UNDERLINE: Draw a horizontal bar below the character.
+ *
+ * An enumerated type which can be used to indicate what should the terminal
+ * draw at the cursor position.
+ */
+typedef enum {
+        VTE_CURSOR_SHAPE_BLOCK,
+        VTE_CURSOR_SHAPE_IBEAM,
+        VTE_CURSOR_SHAPE_UNDERLINE
+} VteTerminalCursorShape;
+
+/**
+ * VteTerminalEffect:
+ * @VTE_TERMINAL_EFFECT_REVERSE: Text is draw with foreground and background color reversed.
+ * @VTE_TERMINAL_EFFECT_COLOR: Text is drawn with the background color from the corresponding style property.
+ */
+typedef enum {
+        VTE_TERMINAL_EFFECT_REVERSE,
+        VTE_TERMINAL_EFFECT_COLOR
+} VteTerminalEffect;
+
+G_END_DECLS
+
+#endif /* VTE_ENUMS_H */



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]