diff --git a/.gitignore b/.gitignore index 7095bec3..21d33221 100644 --- a/.gitignore +++ b/.gitignore @@ -37,6 +37,9 @@ eek/eek-marshalers.[ch] eek/*.pc eek/*.gir eek/*.typelib +eekboard/*.pc +eekboard/*.gir +eekboard/*.typelib tests/eek-simple-test tests/eek-xkb-test tests/eek-xml-test @@ -54,6 +57,16 @@ docs/reference/eek/eek.args docs/reference/eek/eek.hierarchy docs/reference/eek/eek.interfaces docs/reference/eek/eek.prerequisites +docs/reference/eekboard/*.stamp +docs/reference/eekboard/*.txt +!/docs/reference/eekboard/eekboard-sections.txt +docs/reference/eekboard/xml +docs/reference/eekboard/html +docs/reference/eekboard/eekboard.signals +docs/reference/eekboard/eekboard.args +docs/reference/eekboard/eekboard.hierarchy +docs/reference/eekboard/eekboard.interfaces +docs/reference/eekboard/eekboard.prerequisites po/*.gmo po/Makefile.in.in po/POTFILES diff --git a/Makefile.am b/Makefile.am index f7761776..d9db69df 100644 --- a/Makefile.am +++ b/Makefile.am @@ -17,6 +17,5 @@ # 02110-1301 USA ACLOCAL_AMFLAGS = -I m4 -SUBDIRS = eek src tests bindings docs po +SUBDIRS = eek eekboard src tests bindings docs po DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc --enable-introspection -EXTRA_DIST = eekboard-sample.conf diff --git a/configure.ac b/configure.ac index 5176125e..799945fb 100644 --- a/configure.ac +++ b/configure.ac @@ -191,6 +191,7 @@ GOBJECT_INTROSPECTION_CHECK([0.6.7]) AC_CONFIG_HEADERS([config.h]) AC_CONFIG_FILES([Makefile eek/Makefile +eekboard/Makefile src/Makefile tests/Makefile bindings/Makefile @@ -198,12 +199,14 @@ bindings/vala/Makefile docs/Makefile docs/reference/Makefile docs/reference/eek/Makefile +docs/reference/eekboard/Makefile po/Makefile.in eek/eek-${EEK_API_VERSION}.pc eek/eek-clutter-${EEK_API_VERSION}.pc eek/eek-gtk-${EEK_API_VERSION}.pc eek/eek-xkb-${EEK_API_VERSION}.pc -eek/eek-xkl-${EEK_API_VERSION}.pc]) +eek/eek-xkl-${EEK_API_VERSION}.pc +eekboard/eekboard-${EEK_API_VERSION}.pc]) AC_OUTPUT AC_MSG_RESULT([ Build options: diff --git a/docs/reference/Makefile.am b/docs/reference/Makefile.am index d84c93aa..62f0a4ef 100644 --- a/docs/reference/Makefile.am +++ b/docs/reference/Makefile.am @@ -16,4 +16,4 @@ # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA # 02110-1301 USA -SUBDIRS = eek +SUBDIRS = eek eekboard diff --git a/docs/reference/eekboard/Makefile.am b/docs/reference/eekboard/Makefile.am new file mode 100644 index 00000000..af14d132 --- /dev/null +++ b/docs/reference/eekboard/Makefile.am @@ -0,0 +1,120 @@ +# Copyright (C) 2010-2011 Daiki Ueno +# Copyright (C) 2010-2011 Red Hat, Inc. + +# This library is free software; you can redistribute it and/or +# modify it under the terms of the GNU Lesser General Public License +# as published by the Free Software Foundation; either version 2 of +# the License, or (at your option) any later version. + +# This library 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 General Public License for more details. + +# You should have received a copy of the GNU Lesser General Public +# License along with this library; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +# 02110-1301 USA + +## Process this file with automake to produce Makefile.in + +# We require automake 1.6 at least. +AUTOMAKE_OPTIONS = 1.6 + +# This is a blank Makefile.am for using gtk-doc. +# Copy this to your project's API docs directory and modify the variables to +# suit your project. See the GTK+ Makefiles in gtk+/docs/reference for examples +# of using the various options. + +# The name of the module, e.g. 'glib'. +DOC_MODULE=eekboard + +# Uncomment for versioned docs and specify the version of the module, e.g. '2'. +#DOC_MODULE_VERSION=2 + + +# The top-level SGML file. You can change this if you want to. +DOC_MAIN_SGML_FILE=$(DOC_MODULE)-docs.sgml + +# The directory containing the source code. Relative to $(srcdir). +# gtk-doc will search all .c & .h files beneath here for inline comments +# documenting the functions and macros. +# e.g. DOC_SOURCE_DIR=../../../gtk +DOC_SOURCE_DIR=../../../eekboard + +# Extra options to pass to gtkdoc-scangobj. Not normally needed. +SCANGOBJ_OPTIONS= + +# Extra options to supply to gtkdoc-scan. +# e.g. SCAN_OPTIONS=--deprecated-guards="GTK_DISABLE_DEPRECATED" +SCAN_OPTIONS= + +# Extra options to supply to gtkdoc-mkdb. +# e.g. MKDB_OPTIONS=--sgml-mode --output-format=xml +MKDB_OPTIONS=--sgml-mode --output-format=xml + +# Extra options to supply to gtkdoc-mktmpl +# e.g. MKTMPL_OPTIONS=--only-section-tmpl +MKTMPL_OPTIONS= + +# Extra options to supply to gtkdoc-mkhtml +MKHTML_OPTIONS= + +# Extra options to supply to gtkdoc-fixref. Not normally needed. +# e.g. FIXXREF_OPTIONS=--extra-dir=../gdk-pixbuf/html --extra-dir=../gdk/html +FIXXREF_OPTIONS= + +# Used for dependencies. The docs will be rebuilt if any of these change. +# e.g. HFILE_GLOB=$(top_srcdir)/gtk/*.h +# e.g. CFILE_GLOB=$(top_srcdir)/gtk/*.c +HFILE_GLOB=$(top_srcdir)/eekboard/*.h +CFILE_GLOB=$(top_srcdir)/eekboard/*.c + +# Extra header to include when scanning, which are not under DOC_SOURCE_DIR +# e.g. EXTRA_HFILES=$(top_srcdir}/contrib/extra.h +EXTRA_HFILES= + +# Header files to ignore when scanning. Use base file name, no paths +# e.g. IGNORE_HFILES=gtkdebug.h gtkintl.h +IGNORE_HFILES=config.h + +# Images to copy into HTML directory. +# e.g. HTML_IMAGES=$(top_srcdir)/gtk/stock-icons/stock_about_24.png +HTML_IMAGES= + +# Extra SGML files that are included by $(DOC_MAIN_SGML_FILE). +# e.g. content_files=running.sgml building.sgml changes-2.0.sgml +# content_files=eekboard-overview.xml + +# SGML files where gtk-doc abbrevations (#GtkWidget) are expanded +# These files must be listed here *and* in content_files +# e.g. expand_content_files=running.sgml +# expand_content_files=eekboard-overview.xml + +# CFLAGS and LDFLAGS for compiling gtkdoc-scangobj with your library. +# Only needed if you are using gtkdoc-scangobj to dynamically query widget +# signals and properties. +# e.g. GTKDOC_CFLAGS=-I$(top_srcdir) -I$(top_builddir) $(GTK_DEBUG_FLAGS) +# e.g. GTKDOC_LIBS=$(top_builddir)/gtk/$(gtktargetlib) +GTKDOC_CFLAGS = $(GIO2_CFLAGS) +GTKDOC_LIBS = $(top_builddir)/eekboard/libeekboard.la + +# This includes the standard gtk-doc make rules, copied by gtkdocize. +include $(top_srcdir)/gtk-doc.make + +# Other files to distribute +# e.g. EXTRA_DIST += version.xml.in +EXTRA_DIST += + +# Files not to distribute +# for --rebuild-types in $(SCAN_OPTIONS), e.g. $(DOC_MODULE).types +# for --rebuild-sections in $(SCAN_OPTIONS) e.g. $(DOC_MODULE)-sections.txt +#DISTCLEANFILES += + +# Comment this out if you want your docs-status tested during 'make check' +if ENABLE_GTK_DOC +#TESTS_ENVIRONMENT = cd $(srcsrc) && +#TESTS = $(GTKDOC_CHECK) +endif + +-include $(top_srcdir)/gtk-doc.mk diff --git a/docs/reference/eekboard/eekboard-docs.sgml b/docs/reference/eekboard/eekboard-docs.sgml new file mode 100644 index 00000000..77a49249 --- /dev/null +++ b/docs/reference/eekboard/eekboard-docs.sgml @@ -0,0 +1,32 @@ + + +]> + + + eekboard Reference Manual + + for eekboard [VERSION]. + The latest version of this documentation can be found on-line at + http://[SERVER]/eekboard/. + + + + + [Insert title here] + + + + + Object Hierarchy + + + + API Index + + + + + diff --git a/docs/reference/eekboard/eekboard-sections.txt b/docs/reference/eekboard/eekboard-sections.txt new file mode 100644 index 00000000..d3dd4bad --- /dev/null +++ b/docs/reference/eekboard/eekboard-sections.txt @@ -0,0 +1,20 @@ +
+eekboard-proxy +EekboardProxy +EekboardProxyClass +eekboard_proxy_new +eekboard_proxy_set_keyboard +eekboard_proxy_set_group +eekboard_proxy_show +eekboard_proxy_hide +eekboard_proxy_press_key +eekboard_proxy_release_key + +EEKBOARD_PROXY +EEKBOARD_IS_PROXY +EEKBOARD_TYPE_PROXY +EEKBOARD_PROXY_CLASS +EEKBOARD_IS_PROXY_CLASS +EEKBOARD_PROXY_GET_CLASS +
+ diff --git a/docs/reference/eekboard/eekboard.types b/docs/reference/eekboard/eekboard.types new file mode 100644 index 00000000..e69de29b diff --git a/eekboard-sample.conf b/eekboard-sample.conf deleted file mode 100644 index 9a49b751..00000000 --- a/eekboard-sample.conf +++ /dev/null @@ -1,23 +0,0 @@ - - - - Thai Kinesis - kinesis - pc+us+th(pat) - - - Tifinagh Typematrix - tm2030USB-106 - pc+us+ma(tifinagh-extended-phonetic) - - - Indic Bengali Microsoft Natural - microsoft - pc+us+in(ben) - - - US Generic 104-key PC - pc104 - pc+us - - \ No newline at end of file diff --git a/eekboard/Makefile.am b/eekboard/Makefile.am new file mode 100644 index 00000000..68b7b1a2 --- /dev/null +++ b/eekboard/Makefile.am @@ -0,0 +1,57 @@ +# Copyright (C) 2011 Daiki Ueno +# Copyright (C) 2011 Red Hat, Inc. + +# This library is free software; you can redistribute it and/or +# modify it under the terms of the GNU Lesser General Public License +# as published by the Free Software Foundation; either version 2 of +# the License, or (at your option) any later version. + +# This library 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 General Public License for more details. + +# You should have received a copy of the GNU Lesser General Public +# License along with this library; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +# 02110-1301 USA + +lib_LTLIBRARIES = libeekboard.la + +libeekboard_headers = eekboard.h eekboard-proxy.h +libeekboard_sources = eekboard-proxy.c + +libeekboard_la_SOURCES = $(libeekboard_sources) +libeekboard_la_CFLAGS = -I$(top_srcdir) $(GIO2_CFLAGS) +libeekboard_la_LIBADD = $(top_builddir)/eek/libeek.la $(GIO2_LIBS) + +pkgconfigdir = $(libdir)/pkgconfig +pkgconfig_DATA = \ + eekboard-$(EEK_API_VERSION).pc +DISTCLEANFILES = \ + $(pkgconfig_DATA) + +CLEANFILES = + +-include $(INTROSPECTION_MAKEFILE) +INTROSPECTION_GIRS = +INTROSPECTION_SCANNER_ARGS = --add-include-path=$(builddir) +INTROSPECTION_COMPILER_ARGS = --includedir=$(srcdir) + +if HAVE_INTROSPECTION +Eekboard@EEK_LIBRARY_SUFFIX@.gir: libeekboard.la +Eekboard@EEK_LIBRARY_SUFFIX_U@_gir_INCLUDES = Eek@EEK_LIBRARY_SUFFIX@ +Eekboard@EEK_LIBRARY_SUFFIX_U@_gir_CFLAGS = $(libeekboard_la_CFLAGS) +Eekboard@EEK_LIBRARY_SUFFIX_U@_gir_LIBS = libeekboard.la +Eekboard@EEK_LIBRARY_SUFFIX_U@_gir_FILES = $(libeekboard_sources) $(libeekboard_headers) + +INTROSPECTION_GIRS += Eekboard@EEK_LIBRARY_SUFFIX@.gir + +girdir = $(datadir)/gir-1.0 +gir_DATA = $(INTROSPECTION_GIRS) + +typelibdir = $(libdir)/girepository-1.0 +typelib_DATA = $(INTROSPECTION_GIRS:.gir=.typelib) + +CLEANFILES += $(gir_DATA) $(typelib_DATA) +endif diff --git a/eekboard/eekboard-0.90.pc.in b/eekboard/eekboard-0.90.pc.in new file mode 100644 index 00000000..43fd130c --- /dev/null +++ b/eekboard/eekboard-0.90.pc.in @@ -0,0 +1,30 @@ +# Copyright (C) 2010-2011 Daiki Ueno +# Copyright (C) 2010-2011 Red Hat, Inc. + +# This library is free software; you can redistribute it and/or +# modify it under the terms of the GNU Lesser General Public License +# as published by the Free Software Foundation; either version 2 of +# the License, or (at your option) any later version. + +# This library 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 General Public License for more details. + +# You should have received a copy of the GNU Lesser General Public +# License along with this library; if not, write to the Free Software +# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA +# 02110-1301 USA + +prefix=@prefix@ +exec_prefix=@exec_prefix@ +libdir=@libdir@ +includedir=@includedir@ + +Name: Eekboard +Description: A Library to Create Keyboard-like UI +URL: http://ueno.github.com/eekboard/ +Version: @VERSION@ +Requires: gobject-2.0 +Libs: -L${libdir} -leek +Cflags: -I${includedir}/eekboard-@EEK_API_VERSION@ diff --git a/src/proxy.c b/eekboard/eekboard-proxy.c similarity index 99% rename from src/proxy.c rename to eekboard/eekboard-proxy.c index e1cbfbca..07d4adc1 100644 --- a/src/proxy.c +++ b/eekboard/eekboard-proxy.c @@ -19,7 +19,7 @@ #include "config.h" #endif /* HAVE_CONFIG_H */ -#include "proxy.h" +#include "eekboard-proxy.h" enum { KEY_PRESSED, diff --git a/src/proxy.h b/eekboard/eekboard-proxy.h similarity index 100% rename from src/proxy.h rename to eekboard/eekboard-proxy.h diff --git a/eekboard/eekboard.h b/eekboard/eekboard.h new file mode 100644 index 00000000..7e360673 --- /dev/null +++ b/eekboard/eekboard.h @@ -0,0 +1,23 @@ +/* + * Copyright (C) 2011 Daiki Ueno + * Copyright (C) 2011 Red Hat, Inc. + * + * This program 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, see . + */ +#ifndef EEKBOARD_H +#define EEKBOARD_H 1 + +#include "eekboard/eekboard-proxy.h" + +#endif /* EEKBOARD_H */ diff --git a/src/Makefile.am b/src/Makefile.am index af3e0ff3..4c8fbef3 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -22,15 +22,6 @@ bin_PROGRAMS = \ eekboard-client \ eekboard-server \ eekboard-xml -noinst_LIBRARIES = libeekboard.a - -libeekboard_a_headers = proxy.h - -libeekboard_a_CFLAGS = \ - -I$(top_srcdir) \ - $(GIO2_CFLAGS) - -libeekboard_a_SOURCES = proxy.c eekboard_system_client_CFLAGS = \ -I$(top_srcdir) \ @@ -41,8 +32,7 @@ eekboard_system_client_CFLAGS = \ $(LIBXKLAVIER_CFLAGS) eekboard_system_client_LDADD = \ - libeekboard.a \ - $(top_builddir)/eek/libeek.la \ + $(top_builddir)/eekboard/libeekboard.la \ $(top_builddir)/eek/libeek-xkl.la \ $(GIO2_LIBS) \ $(GTK_LIBS) \ @@ -73,8 +63,7 @@ eekboard_server_CFLAGS = \ $(GTK_CFLAGS) eekboard_server_LDADD = \ - libeekboard.a \ - $(top_builddir)/eek/libeek.la \ + $(top_builddir)/eekboard/libeekboard.la \ $(top_builddir)/eek/libeek-gtk.la \ $(GIO2_LIBS) \ $(GTK_LIBS) @@ -92,8 +81,7 @@ eekboard_client_CFLAGS = \ $(GIO2_CFLAGS) eekboard_client_LDADD = \ - libeekboard.a \ - $(top_builddir)/eek/libeek.la \ + $(top_builddir)/eekboard/libeekboard.la \ $(GIO2_LIBS) eekboard_client_SOURCES = client-main.c @@ -115,8 +103,11 @@ eekboard_xml_LDADD = \ eekboard_xml_headers = xklutil.h eekboard_xml_SOURCES = xklutil.c xml-main.c +eekboarddir = $(includedir)/eekboard-$(EEK_API_VERSION)/eekboard +eekboard_HEADERS = \ + $(libeekboard_headers) + noinst_HEADERS = \ - $(libeekboard_a_headers) \ $(eekboard_system_client_headers) \ $(eekboard_client_headers) \ $(eekboard_server_headers) \ diff --git a/src/client-main.c b/src/client-main.c index 21ed6650..94ceb1e7 100644 --- a/src/client-main.c +++ b/src/client-main.c @@ -19,7 +19,7 @@ #include "config.h" #endif /* HAVE_CONFIG_H */ -#include "proxy.h" +#include "eekboard/eekboard.h" static gchar *opt_set_keyboard = NULL; static gint opt_set_group = -1; diff --git a/src/system-client.c b/src/system-client.c index d09d7d87..e61c3516 100644 --- a/src/system-client.c +++ b/src/system-client.c @@ -33,8 +33,8 @@ #include "eek/eek.h" #include "eek/eek-xkl.h" +#include "eekboard/eekboard.h" #include "system-client.h" -#include "proxy.h" #define CSW 640 #define CSH 480