[libvtemm] Some fixes to previous commit.



commit 0c596dcd7e575bd53ec1013cafa4e3686cd7ad7b
Author: Krzesimir Nowak <qdlacz gmail com>
Date:   Tue May 12 14:45:19 2009 +0200

    Some fixes to previous commit.
    
    * examples/simple/simple.h: Fixed include (<gtkmmh> -> <gtkmm.h>).
    * src/libvtemm/g/terminal.hg: Added '#include <libvtemm/cursorposition.h'.
    * src/libvtemm-1.0.pc.in: Renamed to libvtemm-1.1.pc.in.
    * src/libvtemm/cursorposition.(cc|h): Add them to git.
---
 examples/simple/simple.h                       |    2 +-
 src/{libvtemm-1.0.pc.in => libvtemm-1.1.pc.in} |    0
 src/libvtemm/cursorposition.cc                 |   52 +++++++++++++++++++++
 src/libvtemm/cursorposition.h                  |   59 ++++++++++++++++++++++++
 src/libvtemm/g/terminal.hg                     |    1 +
 5 files changed, 113 insertions(+), 1 deletions(-)

diff --git a/examples/simple/simple.h b/examples/simple/simple.h
index 5127a6e..c741ecc 100644
--- a/examples/simple/simple.h
+++ b/examples/simple/simple.h
@@ -21,7 +21,7 @@
 #ifndef LIBVTEMM_EXAMPLE_SIMPLE_H
 #define LIBVTEMM_EXAMPLE_SIMPLE_H
 
-#include <gtkmmh>
+#include <gtkmm.h>
 #include <libvtemm.h>
 
 class Simple : public Gtk::Window
diff --git a/src/libvtemm-1.0.pc.in b/src/libvtemm-1.1.pc.in
similarity index 100%
rename from src/libvtemm-1.0.pc.in
rename to src/libvtemm-1.1.pc.in
diff --git a/src/libvtemm/cursorposition.cc b/src/libvtemm/cursorposition.cc
new file mode 100644
index 0000000..0707a59
--- /dev/null
+++ b/src/libvtemm/cursorposition.cc
@@ -0,0 +1,52 @@
+/* cursorposition.cc
+ *
+ * Copyright (C) 2008, 2009 libvtemm Development Team
+ *
+ * This file is part of libvtemm.
+ *
+ * libvtemm is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * libvtemm 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 Lesser Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser Public License
+ * along with libvtemm.  If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#include <libvtemm/cursorposition.h>
+
+namespace Gnome
+{
+
+namespace Vte
+{
+
+CursorPosition::CursorPosition(long column, long row)
+:
+  m_column(column),
+  m_row(row)
+{
+}
+
+CursorPosition::~CursorPosition()
+{
+}
+
+long CursorPosition::get_column() const
+{
+  return m_column;
+}
+
+long CursorPosition::get_row() const
+{
+  return m_row;
+}
+
+} // namespace Vte
+
+} // namespace Gnome
diff --git a/src/libvtemm/cursorposition.h b/src/libvtemm/cursorposition.h
new file mode 100644
index 0000000..3c5b7d1
--- /dev/null
+++ b/src/libvtemm/cursorposition.h
@@ -0,0 +1,59 @@
+/* cursorposition.h
+ *
+ * Copyright (C) 2008, 2009 libvtemm Development Team
+ *
+ * This file is part of libvtemm.
+ *
+ * libvtemm is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Lesser Public License as published by
+ * the Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * libvtemm 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 Lesser Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser Public License
+ * along with libvtemm.  If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#ifndef _LIBVTEMM_CURSOR_POSITION_H_
+#define _LIBVTEMM_CURSOR_POSITION_H_
+
+namespace Gnome
+{
+
+namespace Vte
+{
+/** CursorPosition - simple struct holding cursor position.
+ */
+class CursorPosition
+{
+public:
+/** The only way to fill #Gnome::Vte::CursorPosition class.
+ * @param column Cursor's column position.
+ * @param row Cursor's row position.
+ */
+  CursorPosition(long column, long row);
+  virtual ~CursorPosition();
+
+/** Gets column position.
+ * @return Column position.
+ */
+  long get_column() const;
+
+/** Gets row position.
+ * @return Row position.
+ */
+  long get_row() const;
+private:
+  long m_column;
+  long m_row;
+};
+
+} // namespace Vte
+
+} // namespace Gnome
+
+#endif // _LIBVTEMM_CURSOR_POSITION_H_
diff --git a/src/libvtemm/g/terminal.hg b/src/libvtemm/g/terminal.hg
index 8a82b20..44118fe 100644
--- a/src/libvtemm/g/terminal.hg
+++ b/src/libvtemm/g/terminal.hg
@@ -26,6 +26,7 @@ _PINCLUDE(gtkmm/private/widget_p.h)
 #include <gdkmm.h>
 #include <glibmm.h>
 #include <gtkmm.h>
+#include <libvtemm/cursorposition.h>
 #include <libvtemm/textandcharattrs.h>
 #include <pangomm.h>
 #include <sigc++/sigc++.h>



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