diff options
author | Patrick J Volkerding <volkerdi@slackware.com> | 2011-04-25 13:37:00 +0000 |
---|---|---|
committer | Eric Hameleers <alien@slackware.com> | 2018-05-31 22:45:18 +0200 |
commit | 75a4a592e5ccda30715f93563d741b83e0dcf39e (patch) | |
tree | 502f745607e77a2c4386ad38d818ddcafe81489c /source/x/scim-bridge | |
parent | b76270bf9e6dd375e495fec92140a79a79415d27 (diff) | |
download | current-75a4a592e5ccda30715f93563d741b83e0dcf39e.tar.gz current-75a4a592e5ccda30715f93563d741b83e0dcf39e.tar.xz |
Slackware 13.37slackware-13.37
Mon Apr 25 13:37:00 UTC 2011
Slackware 13.37 x86_64 stable is released!
Thanks to everyone who pitched in on this release: the Slackware team,
the folks producing upstream code, and linuxquestions.org for providing
a great forum for collaboration and testing.
The ISOs are off to be replicated, a 6 CD-ROM 32-bit set and a
dual-sided
32-bit/64-bit x86/x86_64 DVD. Please consider supporting the Slackware
project by picking up a copy from store.slackware.com. We're taking
pre-orders now, and offer a discount if you sign up for a subscription.
As always, thanks to the Slackware community for testing, suggestions,
and feedback. :-)
Have fun!
Diffstat (limited to 'source/x/scim-bridge')
7 files changed, 212 insertions, 4 deletions
diff --git a/source/x/scim-bridge/patches/scim-bridge-0.4.16-scim-bridge-agent-application.cpp.patch b/source/x/scim-bridge/patches/scim-bridge-0.4.16-scim-bridge-agent-application.cpp.patch new file mode 100644 index 000000000..f925507a7 --- /dev/null +++ b/source/x/scim-bridge/patches/scim-bridge-0.4.16-scim-bridge-agent-application.cpp.patch @@ -0,0 +1,11 @@ +--- scim-bridge-0.4.16/agent/scim-bridge-agent-application.cpp.bak 2009-01-18 01:04:20.000000000 +0800 ++++ scim-bridge-0.4.16/agent/scim-bridge-agent-application.cpp 2010-09-11 22:38:27.196979199 +0800 +@@ -65,7 +65,7 @@ + unsigned int tmp_uint; + + int option = 0; +- while (option != EOF) { ++ while (option != -1) { + option = getopt_long (argc, argv, short_options, long_options, NULL); + switch (option) { + case 'v': diff --git a/source/x/scim-bridge/patches/scim-bridge-0.4.16-scim-bridge-agent-imcontext.cpp.patch b/source/x/scim-bridge/patches/scim-bridge-0.4.16-scim-bridge-agent-imcontext.cpp.patch new file mode 100644 index 000000000..85732013d --- /dev/null +++ b/source/x/scim-bridge/patches/scim-bridge-0.4.16-scim-bridge-agent-imcontext.cpp.patch @@ -0,0 +1,48 @@ +--- scim-bridge-0.4.16/agent/scim-bridge-agent-imcontext.cpp.bak 2009-02-03 22:36:14.000000000 +0800 ++++ scim-bridge-0.4.16/agent/scim-bridge-agent-imcontext.cpp 2010-09-11 23:25:00.636978519 +0800 +@@ -60,6 +60,8 @@ + + static bool on_the_spot_enabled = true; + ++static String help_hotkeys = ""; ++ + /* Class definition */ + class ScimBridgeAgentIMContextImpl: public ScimBridgeAgentIMContext + { +@@ -274,6 +276,12 @@ + } + + ++void ScimBridgeAgentIMContext::set_help_hotkeys (const String &hotkey_str) ++{ ++ help_hotkeys = hotkey_str; ++} ++ ++ + ScimBridgeAgentIMContextImpl::ScimBridgeAgentIMContextImpl (ScimBridgeAgentClientListener *new_client_listener): + client_listener (new_client_listener), imengine (NULL), enabled (false), focused(false) ,preedit_mode (PREEDIT_ANY), + preedit_shown (false), preedit_cursor_position (0) +@@ -654,6 +662,8 @@ + + void ScimBridgeAgentIMContextImpl::focus_out () + { ++ if (!imengine_shared && imengine == NULL) alloc_imengine (); ++ + ScimBridgeAgentIMContext *focused_imcontext = static_cast<ScimBridgeAgentIMContext*> (get_imengine ()->get_frontend_data ()); + + if ( !focused ) +@@ -923,9 +933,11 @@ + + void ScimBridgeAgentIMContextImpl::panel_request_help () + { +- String help = String ("Smart Common Input Method platform ") + +- String (SCIM_VERSION) + +- String ("\n(C) 2002-2005 James Su <suzhe@tsinghua.org.cn>\n\n"); ++ String help = String ("SCIM Bridge") + ++ String (VERSION) + ++ String ("\n(C) 2006-2008 Ryo Dairiki <ryo-dairiki@users.sourceforge.net>\n") + ++ help_hotkeys + ++ String ("\n\n"); + + IMEngineFactoryPointer factory = scim_backend->get_factory (get_imengine ()->get_factory_uuid ()); + if (factory.null ()) factory = fallback_imengine_factory; diff --git a/source/x/scim-bridge/patches/scim-bridge-0.4.16-scim-bridge-agent-imcontext.h.patch b/source/x/scim-bridge/patches/scim-bridge-0.4.16-scim-bridge-agent-imcontext.h.patch new file mode 100644 index 000000000..f16b34c14 --- /dev/null +++ b/source/x/scim-bridge/patches/scim-bridge-0.4.16-scim-bridge-agent-imcontext.h.patch @@ -0,0 +1,24 @@ +--- scim-bridge-0.4.16/agent/scim-bridge-agent-imcontext.h.bak 2008-11-02 14:44:49.000000000 +0800 ++++ scim-bridge-0.4.16/agent/scim-bridge-agent-imcontext.h 2010-09-11 23:12:18.085979961 +0800 +@@ -130,6 +130,21 @@ + static void set_enabled_by_default (bool enabled); + + /** ++ * Get the hotkey help messages. ++ * ++ * @return help messages about hotkeys. ++ */ ++ static scim::String get_help_hotkeys (); ++ ++ /** ++ * Set the hotkey help messages. ++ * ++ * @param hotkey_str Help message about hotkeys. ++ * ++ */ ++ static void set_help_hotkeys (const scim::String &hotkey_str); ++ ++ /** + * Destructor. + */ + virtual ~ScimBridgeAgentIMContext () {} diff --git a/source/x/scim-bridge/patches/scim-bridge-0.4.16-scim-bridge-agent.cpp.patch b/source/x/scim-bridge/patches/scim-bridge-0.4.16-scim-bridge-agent.cpp.patch new file mode 100644 index 000000000..27c5cb73b --- /dev/null +++ b/source/x/scim-bridge/patches/scim-bridge-0.4.16-scim-bridge-agent.cpp.patch @@ -0,0 +1,30 @@ +--- scim-bridge-0.4.16/agent/scim-bridge-agent.cpp.bak 2009-03-08 21:07:29.000000000 +0800 ++++ scim-bridge-0.4.16/agent/scim-bridge-agent.cpp 2010-09-11 22:59:34.476979479 +0800 +@@ -542,6 +542,27 @@ + scim_global_config_flush (); + + scim_keyboard_layout = scim_get_default_keyboard_layout (); ++ ++ // Hot key name, hot key config key. ++ // ! Update hotkey_list_length according to updated list length. ++ int hotkey_list_length = 6; ++ String hotkey_list[][2] = { ++ { "Toggle on/off - ", "/Hotkeys/FrontEnd/Trigger" }, ++ { "Turn on - ", "/Hotkeys/FrontEnd/On" }, ++ { "Turn off - ", "/Hotkeys/FrontEnd/Off" }, ++ { "Next input method - ", "/Hotkeys/FrontEnd/NextFactory" }, ++ { "Previous input method - ", "/Hotkeys/FrontEnd/PreviousFactory" }, ++ { "Show input method menu - ", "/Hotkeys/FrontEnd/ShowFactoryMenu" } ++ }; ++ ++ // Undefined hot keys are hidden from help window. ++ String help_hotkeys = "\nGlobal Hotkeys:"; ++ for ( int i = 0; i < hotkey_list_length; i++ ) { ++ String tmp_hotkeys = scim_config->read (String (hotkey_list[i][1]), String ("")); ++ if ( tmp_hotkeys != "" ) ++ help_hotkeys += "\n" + hotkey_list[i][0] + "<" + tmp_hotkeys + ">"; ++ } ++ ScimBridgeAgentIMContext::set_help_hotkeys (help_hotkeys); + } + + diff --git a/source/x/scim-bridge/patches/scim-bridge-0.4.16-scim-bridge-client-imcontext-gtk.c.patch b/source/x/scim-bridge/patches/scim-bridge-0.4.16-scim-bridge-client-imcontext-gtk.c.patch new file mode 100644 index 000000000..21f1f824e --- /dev/null +++ b/source/x/scim-bridge/patches/scim-bridge-0.4.16-scim-bridge-client-imcontext-gtk.c.patch @@ -0,0 +1,47 @@ +--- scim-bridge-0.4.16/client-gtk/scim-bridge-client-imcontext-gtk.c.bak 2008-11-02 14:44:23.000000000 +0800 ++++ scim-bridge-0.4.16/client-gtk/scim-bridge-client-imcontext-gtk.c 2010-09-11 23:19:10.556978680 +0800 +@@ -35,6 +35,8 @@ + #include "scim-bridge-output.h" + #include "scim-bridge-string.h" + ++#define SEND_EVENT_MASK 0x02 ++ + /* Typedef */ + struct _ScimBridgeClientIMContext + { +@@ -200,7 +202,7 @@ + { + scim_bridge_pdebugln (7, "key_snooper ()"); + +- if (!event->send_event && scim_bridge_client_is_messenger_opened () && focused_imcontext != NULL) { ++ if (!(event->send_event & SEND_EVENT_MASK) && scim_bridge_client_is_messenger_opened () && focused_imcontext != NULL) { + if (focused_imcontext->client_window != NULL) { + int new_window_x; + int new_window_y; +@@ -556,7 +558,7 @@ + { + GdkEventKey gdk_event; + scim_bridge_key_event_bridge_to_gdk (&gdk_event, imcontext->client_window, key_event); +- gdk_event.send_event = TRUE; ++ gdk_event.send_event |= SEND_EVENT_MASK; + if (imcontext == focused_imcontext && focused_widget != NULL) { + const char *signal_name = NULL; + if (scim_bridge_key_event_is_pressed (key_event)) { +@@ -762,7 +764,7 @@ + + ScimBridgeClientIMContext *imcontext = SCIM_BRIDGE_CLIENT_IMCONTEXT (context); + +- if (!event->send_event && scim_bridge_client_is_messenger_opened () && imcontext != NULL && !key_snooper_used) { ++ if (!(event->send_event & SEND_EVENT_MASK) && scim_bridge_client_is_messenger_opened () && imcontext != NULL && !key_snooper_used) { + + if (imcontext->client_window != NULL) { + int new_window_x; +@@ -875,7 +877,7 @@ + scim_bridge_client_open_messenger (); + } + +- if (is_key_snooper_enabled ()) { ++ if (!key_snooper_used && is_key_snooper_enabled ()) { + key_snooper_id = gtk_key_snooper_install ((GtkKeySnoopFunc) &key_snooper, NULL); + key_snooper_used = TRUE; + } diff --git a/source/x/scim-bridge/patches/scim-bridge-0.4.16-scim-bridge-client-imcontext-qt.cpp.patch b/source/x/scim-bridge/patches/scim-bridge-0.4.16-scim-bridge-client-imcontext-qt.cpp.patch new file mode 100644 index 000000000..74a3252ef --- /dev/null +++ b/source/x/scim-bridge/patches/scim-bridge-0.4.16-scim-bridge-client-imcontext-qt.cpp.patch @@ -0,0 +1,31 @@ +--- scim-bridge-0.4.16/client-qt/scim-bridge-client-imcontext-qt.cpp.bak 2008-11-02 14:44:46.000000000 +0800 ++++ scim-bridge-0.4.16/client-qt/scim-bridge-client-imcontext-qt.cpp 2010-09-11 22:46:10.396979441 +0800 +@@ -220,7 +220,12 @@ + { + scim_bridge_pdebugln (4, "ScimBridgeClientIMContextImpl::setFocusWidget ()"); + QInputContext::setFocusWidget (widget); +- focus_in (); ++ if (widget == NULL) { ++ focus_out (); ++ } ++ else { ++ focus_in (); ++ } + update (); + } + +@@ -442,9 +447,11 @@ + } + } + +- set_preedit_shown (false); +- update_preedit (); +- ++ if (preedit_shown) { ++ set_preedit_shown (false); ++ update_preedit (); ++ } ++ + focused_imcontext = NULL; + } + diff --git a/source/x/scim-bridge/scim-bridge.SlackBuild b/source/x/scim-bridge/scim-bridge.SlackBuild index 90354fd75..c3494c8b4 100755 --- a/source/x/scim-bridge/scim-bridge.SlackBuild +++ b/source/x/scim-bridge/scim-bridge.SlackBuild @@ -1,7 +1,7 @@ #!/bin/sh # Copyright 2008, 2009 Eric Hameleers, Eindhoven, NL -# Copyright 2008, 2009 Patrick J. Volkerding, Sebeka, MN USA +# Copyright 2008, 2009, 2011 Patrick J. Volkerding, Sebeka, MN USA # All rights reserved. # # Permission to use, copy, modify, and distribute this software for @@ -35,8 +35,17 @@ PRGNAM=scim-bridge VERSION=${VERSION:-0.4.16} -ARCH=${ARCH:-x86_64} -BUILD=${BUILD:-4} +BUILD=${BUILD:-5} + +# Automatically determine the architecture we're building on: +if [ -z "$ARCH" ]; then + case "$( uname -m )" in + i?86) export ARCH=i486 ;; + arm*) export ARCH=arm ;; + # Unless $ARCH is already set, use uname -m for all other archs: + *) export ARCH=$( uname -m ) ;; + esac +fi NUMJOBS=${NUMJOBS:-" -j7 "} @@ -68,6 +77,14 @@ rm -rf ${PRGNAM}-${VERSION} tar -xvf $CWD/${PRGNAM}-${VERSION}.tar.gz || exit 1 cd ${PRGNAM}-${VERSION} || exit 1 #sed -i -e "s/ -doxygen / doxygen /" $( grep -lr ' -doxygen ' * ) + +zcat $CWD/patches/scim-bridge-0.4.16-scim-bridge-agent-application.cpp.patch.gz | patch -p1 --verbose || exit 1 +zcat $CWD/patches/scim-bridge-0.4.16-scim-bridge-agent-imcontext.cpp.patch.gz | patch -p1 --verbose || exit 1 +zcat $CWD/patches/scim-bridge-0.4.16-scim-bridge-agent-imcontext.h.patch.gz | patch -p1 --verbose || exit 1 +zcat $CWD/patches/scim-bridge-0.4.16-scim-bridge-agent.cpp.patch.gz | patch -p1 --verbose || exit 1 +zcat $CWD/patches/scim-bridge-0.4.16-scim-bridge-client-imcontext-gtk.c.patch.gz | patch -p1 --verbose || exit 1 +zcat $CWD/patches/scim-bridge-0.4.16-scim-bridge-client-imcontext-qt.cpp.patch.gz | patch -p1 --verbose || exit 1 + chown -R root:root . find . \ \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \ @@ -114,7 +131,7 @@ EOINS # Add documentation: mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION cp -a \ - AUTHORS COPYING ChangeLog INSTALL NEWS README doc/LICENSE.* \ + AUTHORS COPYING* ChangeLog INSTALL NEWS README* doc/LICENSE.* \ $PKG/usr/doc/$PRGNAM-$VERSION find $PKG/usr/doc -type f -exec chmod 644 {} \; |