[meego-commits] 24590: Changes to Trunk:Testing/maliit-framework

Luis Araujo no_reply at build.meego.com
Tue Nov 29 19:22:08 UTC 2011


Hi,
I have made the following changes to maliit-framework in project Trunk:Testing. Please review and accept ASAP.

Thank You,
Luis Araujo

[This message was auto-generated]

---

Request #24590:

  submit:   devel:input-methods/maliit-framework(r16) -> Trunk:Testing/maliit-framework


Message:
    Version update to 0.81.0.1 (BMC#24328)

State:   new          2011-11-29T11:04:54 araujo
Comment: None



changes files:
--------------
--- maliit-framework.changes
+++ maliit-framework.changes
@@ -0,0 +1,5 @@
+* Tue Nov 29 2011 Luis Araujo <luis.araujo at collabora.co.uk> - 0.81.0.1
+- Update to new release tag 0.81.0.1 (BMC#24328)
+- Add Maliit SDK (maliit-sdk) package
+- Add maliit-sdk-examples.patch to work around a packaging bug
+

old:
----
  maliit-framework-0.80.8.tar.bz2

new:
----
  maliit-framework-0.81.0.1.tar.bz2
  maliit-sdk-examples.patch

spec files:
-----------
--- maliit-framework.spec
+++ maliit-framework.spec
@@ -7,7 +7,7 @@
 
 Name:       maliit-framework
 Summary:    Core libraries of Maliit and server
-Version:    0.80.8
+Version:    0.81.0.1
 Release:    1
 Group:      System/Libraries
 License:    LGPLv2.1
@@ -16,6 +16,7 @@
 Source1:    maliit-server.desktop
 Source2:    maliit-server.sh
 Source100:  maliit-framework.yaml
+Patch0:     maliit-sdk-examples.patch
 Requires(pre): GConf2
 Requires(preun): GConf2
 Requires(post): GConf2
@@ -58,6 +59,19 @@
 %description doc
 Documentation for the Maliit Input Method Framework
 
+%package sdk
+Summary:    Maliit Framework SDK
+Group:      Development/Libraries
+Requires:   %{name} = %{version}-%{release}
+Requires:   maliit-framework-doc
+BuildRequires:  pkgconfig(maliit-framework-0.80)
+BuildRequires:  pkgconfig(maliit-1.0)
+BuildRequires:  pkgconfig(maliit-plugins-0.80)
+BuildRequires:  pkgconfig(maliit-plugins-quick-0.80)
+
+%description sdk
+SDK environment for Maliit
+
 %package tests
 Summary:    Maliit Framework Input Method Tests Package
 Group:      Development/Libraries
@@ -112,6 +126,8 @@
 %prep
 %setup -q -n %{name}-%{version}
 
+# maliit-sdk-examples.patch
+%patch0 -p1
 # >> setup
 # << setup
 
@@ -177,6 +193,9 @@
 
 
 
+
+
+
 %post -n libmaliit -p /sbin/ldconfig
 
 %postun -n libmaliit -p /sbin/ldconfig
@@ -197,6 +216,7 @@
 %{_bindir}/maliit-server
 %{_libdir}/libmaliit-plugins-0.80.so.*
 %{_libdir}/qt4/plugins/inputmethods/libmaliit.so
+%{_datadir}/dbus-1/services/org.maliit.server.service
 %config %{_sysconfdir}/xdg/autostart/*.desktop
 %config %{_sysconfdir}/profile.d/maliit-server.sh
 %config %{_sysconfdir}/gconf/schemas/maliit-framework.schemas
@@ -216,10 +236,17 @@
 
 %files doc
 %defattr(-,root,root,-)
-%{_docdir}/maliit-framework
+%{_docdir}/maliit-framework/html
 # >> files doc
 # << files doc
 
+%files sdk
+%defattr(-,root,root,-)
+%{_bindir}/maliit-sdk
+%{_docdir}/maliit-framework/maliit-sdk
+# >> files sdk
+# << files sdk
+
 %files tests
 %defattr(-,root,root,-)
 %{_bindir}/maliit-exampleapp-plainqt
@@ -253,6 +280,7 @@
 %files -n libmaliit-quick-devel
 %defattr(-,root,root,-)
 %{_libdir}/libmaliit-plugins-quick-0.80.so
+%{_libdir}/maliit/plugins-0.80/factories/libmaliit-plugins-quick-factory-0.80.so
 %{_includedir}/maliit/plugins-quick-0.80/
 %{_libdir}/pkgconfig/maliit-plugins-quick-0.80.pc
 # >> files libmaliit-quick-devel

other changes:
--------------

++++++ maliit-framework-0.80.8.tar.bz2 -> maliit-framework-0.81.0.1.tar.bz2
--- NEWS
+++ NEWS
@@ -1,3 +1,26 @@
+0.81.0
+======
+
+CHANGES SINCE 0.80.8
+* D-Bus activation for maliit-server
+  - An application can launch a maliit-server instance via D-Bus activation;
+    use MALIIT_SERVER_ARGUMENTS when building maliit-server to specify
+    additional arguments. Check src/org.maliit.server.service for currently
+    configured arguments.
+  - Each user session can run its own maliit-server now.
+* Plain QML file loading support for QML-based input methods
+  - Install main QML file into plugins directory and set the GConf keys in
+    /maliit/onscreen/[active,enabled] to that file.
+* Improved documentation
+  - Stand-alone application and plugins examples are installed by default
+  - A maliit-sdk executable can be used to extract examples and to view
+    documentation.
+
+BUG FIXES
+* Fixes: Building example applications stand-alone
+* Fixes: NB#291062 - Regression: QML Components Gallery, Text Input, Sip
+  Attributes Example failed.
+
 0.80.8
 ======
 
--- README
+++ README
@@ -1,24 +1,54 @@
-= How to run in i386 =
+Maliit
 
-0.
-Make sure you have a composite manager running. You're mostly OK if you're running Compiz.
-If you use Metacity make sure the composite management feature is ON:
+Maliit provides a flexible and cross-platform input method framework. It has a
+plugin-based client-server architecture where applications act as clients and
+communicate with the Maliit server via input context plugins. The communication
+link currently uses D-Bus. Maliit is an open source framework (LGPL 2) with
+open source plugins (BSD).
 
-gconftool-2 -s -t bool /apps/metacity/general/compositing_manager true
+This is the Maliit framework. For plugins, such as virtual keyboards, see
+http://wiki.maliit.org/Plugins
 
-1.
-Make sure your dbus session daemon is running. If you're on Scratchbox2,
-make sure your session is using the correct DBUS_SESSION_BUS_ADDRESS environment
-variable.
 
-2.
-If you're not using duicompositor call meego-im-uiserver with -bypass-wm-hint
-You may need to modify the service file as well.
+Installing
 
-3.
-Run your application
-Make sure there's no error messages complaining about DBUS service/connection
+Qt 4.7 must be installed to build the Maliit framework. At a terminal, run:
 
-meego-im-uiserver window is not movable, and if you're using dual screen, it's
-always on display 0.0.  You can use Xephyr if you want to move it around.
+qmake
+make
+make install
 
+Run qmake HELP=1 to get more information about build options.
+
+
+Running
+
+Set Maliit as the Qt and GTK+ input context:
+
+export QT_IM_MODULE=Maliit
+export GTK_IM_MODULE=Maliit
+
+Start the server:
+
+maliit-server -software -bypass-wm-hint
+
+Note that a compositing window manager and a D-Bus session bus are required to
+use Maliit.
+
+Test with the provided example applications:
+
+maliit-exampleapp-plainqt # for Qt
+maliit-exampleapp-gtk2 # for Gtk2
+maliit-exampleapp-gtk3 # for Gtk3
+
+Double-tap on the input field, and an input method (usually a virtual keyboard)
+should be shown. Note that an input method plugin, such as the Maliit keyboard
+from the maliit-plugins package, must be installed for the example applications
+to work.
+
+Resources
+
+Wiki: http://wiki.maliit.org/
+IRC: #maliit on chat.freenode.net
+Announcement mailing list: maliit-announce at lists.maliit.org
+Discussion mailing list: maliit-discuss at lists.maliit.org
--- common/maliit/namespace.h
+++ common/maliit/namespace.h
@@ -20,9 +20,10 @@
 #include <QMetaType>
 #include <QSharedPointer>
 
+//! \ingroup common
 namespace Maliit {
     /*!
-     * This enum contains values of the orientation angle of windows in the application.
+     * \brief Orientation angle of windows in the application.
      *
      * \sa Orientation
      */
@@ -34,16 +35,23 @@
     };
 
     /*!
-     * This enum contains possible values for orientation of windows in the application.
+     * \brief Possible orientations of windows in the application.
      *
      * \sa OrientationAngle
      */
     enum Orientation {
-        Portrait, //!< equal to either M::Angle90 or M::Angle270 orientation angles
-        Landscape //!< equal to either M::Angle0 or M::Angle180 orientation angles
+        Portrait, //!< equal to either Maliit::Angle90 or Maliit::Angle270 orientation angles
+        Landscape //!< equal to either Maliit::Angle0 or Maliit::Angle180 orientation angles
     };
 
-    //! Content type for text entries. Used at least with MTextEdit
+    /*!
+     * \brief Content type for text entries.
+     *
+     * Content type of the text in the text edit widget, which can be used by
+     * input method plugins to offer more specific input methods, such as a
+     * numeric keypad for a number content type. Plugins may also adjust their
+     * word prediction and error correction accordingly.
+     */
     enum TextContentType {
         //! all characters allowed
         FreeTextContentType,
@@ -64,7 +72,7 @@
         CustomContentType
     };
 
-    //! Type of toolbar widget
+    //! \brief Type of toolbar widget
     enum ItemType {
         //! Undefined item type
         ItemUndefined,
@@ -76,7 +84,7 @@
         ItemLabel
     };
 
-    //! Type of visible premiss for toolbar button
+    //! \brief Type of visible premiss for toolbar button
     enum VisibleType {
         //! Item's visibility will not be changed automatically
         VisibleUndefined,
@@ -88,7 +96,7 @@
         VisibleAlways
     };
 
-    //! Type of action
+    //! \brief Type of action
     enum ActionType {
         //! Do nothing
         ActionUndefined,
@@ -136,7 +144,7 @@
     };
 
     /*!
-     * This enum defines direction of plugin switching
+     * \brief Direction of plugin switching
      */
     enum SwitchDirection {
         SwitchUndefined, //!< Special value for uninitialized variables
@@ -156,7 +164,7 @@
         Accessory
     };
 
-    /// \brief Key event request type for \a MInputContext::keyEvent().
+    //! \brief Key event request type for \a MInputContext::keyEvent().
     enum EventRequestType {
         EventRequestBoth,         //!< Both a Qt::KeyEvent and a signal
         EventRequestSignalOnly,   //!< Only a signal
@@ -164,8 +172,8 @@
     };
 
      /*!
-      * This enum contains possible values for all the modes that are shown in the
-      * Input mode indicator.
+      * \brief Possible values for all the modes that are shown in the Input
+      * mode indicator.
       */
     enum InputModeIndicator {
         NoIndicator,                 //!< No indicator should be shown
@@ -201,8 +209,8 @@
     };
 
     /*!
-     * PreeditTextFormat defines the text format for part of the preedit string
-     * specified by start and length.
+     * \brief The text format for part of the preedit string, specified by
+     * start and length.
      *
      * \sa PreeditFace.
      */
@@ -220,7 +228,9 @@
         {};
     };
 
-    //! extensions for Qt::inputMethodQuery
+    /*! \brief Extensions for Qt::inputMethodQuery
+     * \note the inputMethodQuery interface may change or be removed in Qt 5!
+     */
     enum InputMethodQueryExtensions {
         VisualizationPriorityQuery = 10001, //!< Tells if input method widget wants to have high
         //!< priority for visualization. Input method should
@@ -236,19 +246,22 @@
     namespace InputMethodQuery
     {
         //! Name of property which tells whether correction is enabled.
-        //! See Maliit::ImCorrectionEnabledQuery.
+        //! \sa Maliit::ImCorrectionEnabledQuery.
         const char* const correctionEnabledQuery = "maliit-correction-enabled";
         //! Name of property which holds ID of attribute extension.
-        //! See Maliit::InputMethodAttributeExtensionIdQuery.
+        //! \sa Maliit::InputMethodAttributeExtensionIdQuery.
         const char* const attributeExtensionId = "maliit-attribute-extension-id";
         //! Name of property which holds attribute extension.
-        //! See Maliit::InputMethodAttributeExtensionQuery.
+        //! \sa Maliit::InputMethodAttributeExtensionQuery.
         const char* const attributeExtension = "maliit-attribute-extension";
         //! Name of the property which overrides localized numeric input with western numeric input.
-        //! See Maliit::WesternNumericInputEnforcedQuery.
+        //! \sa Maliit::WesternNumericInputEnforcedQuery.
         const char* const westernNumericInputEnforced = "maliit-western-numeric-input-enforced";
         //! Name of the property which controls translucent VKB mode.
-        const char* const translucentInputMethod = "maliit-translucent-inputmethod";
+        const char* const translucentInputMethod = "maliit-translucent-input-method";
+        //! Name of the property which can suppress VKB even if focused.
+        //! \sa Maliit::VisualizationPriorityQuery
+        const char* const suppressInputMethod = "maliit-suppress-input-method";
     }
 }
 
--- common/maliit/namespaceinternal.h
+++ common/maliit/namespaceinternal.h
@@ -17,6 +17,7 @@
 #ifndef NAMESPACEINTERNAL_H
 #define NAMESPACEINTERNAL_H
 
+//! \internal
 namespace Maliit { namespace Internal {
 
     //! Name of the input method hints stored in our update map.
--- config.pri
+++ config.pri
@@ -1,4 +1,4 @@
-MALIIT_VERSION = 0.80.8
+MALIIT_VERSION = 0.81.0.1
 MALIIT_INTERFACE_VERSION = 1.0
 MALIIT_PLUGINS_INTERFACE_VERSION = 0.80
 MALIIT_PLUGINS_QUICK_INTERFACE_VERSION = 0.80
@@ -67,7 +67,7 @@
     M_IM_DEFAULT_PLUGIN = libmeego-keyboard.so
     M_IM_DEFAULT_SUBVIEW = en_gb.xml
 } else {
-    M_IM_DEFAULT_PLUGIN = libmeego-keyboard-quick.so
+    M_IM_DEFAULT_PLUGIN = libmaliit-keyboard.so
     M_IM_DEFAULT_SUBVIEW = 
 }
 
@@ -119,6 +119,7 @@
                 M_IM_INSTALL_BIN \
                 M_IM_INSTALL_HEADERS \
                 M_IM_INSTALL_LIBS \
+                M_IM_INSTALL_DOCS \
                 M_IM_PLUGINS_DIR \
                 M_IM_FACTORY_PLUGINS_DIR \
                 M_IM_VERSION \
@@ -132,14 +133,17 @@
                 MALIIT_HEADER \
                 MALIIT_PLUGINS_QUICK_LIB \
                 MALIIT_PLUGINS_QUICK_HEADER \
+                MALIIT_PLUGINS_QUICK_FACTORY \
                 MALIIT_TEST_SUITE \
                 MALIIT_TEST_DATADIR \
                 MALIIT_TEST_LIBDIR \
                 MALIIT_TEST_TMPDIR \
                 MALIIT_IN_DIR \
                 MALIIT_OUT_DIR \
+                MALIIT_PACKAGENAME \
                 MALIIT_PACKAGE_BRIEF \
                 MALIIT_FRAMEWORK_HEADER \
+                MALIIT_SERVER_ARGUMENTS \
 
     command = "sed"
     for(var, variables) {
--- defines-legacy.pri
+++ defines-legacy.pri
@@ -4,6 +4,7 @@
 MALIIT_PLUGINS_HEADER = meegoimframework
 MALIIT_PLUGINS_QUICK_LIB = meegoimquick
 MALIIT_PLUGINS_QUICK_HEADER = meegoimquick
+MALIIT_PLUGINS_QUICK_FACTORY = meegoimquickfactory-$${MALIIT_PLUGINS_QUICK_INTERFACE_VERSION}
 MALIIT_TEST_SUITE = meego-im-framework-tests
 MALIIT_PACKAGENAME = meego-im-framework
 MALIIT_PACKAGE_BRIEF = Meego Touch Input Method Framework
--- defines.pri
+++ defines.pri
@@ -4,6 +4,7 @@
 MALIIT_PLUGINS_QUICK_LIB = maliit-plugins-quick-$${MALIIT_PLUGINS_QUICK_INTERFACE_VERSION}
 MALIIT_PLUGINS_HEADER = maliit/plugins-$${MALIIT_PLUGINS_INTERFACE_VERSION}
 MALIIT_PLUGINS_QUICK_HEADER = maliit/plugins-quick-$${MALIIT_PLUGINS_QUICK_INTERFACE_VERSION}
+MALIIT_PLUGINS_QUICK_FACTORY = maliit-plugins-quick-factory-$${MALIIT_PLUGINS_QUICK_INTERFACE_VERSION}
 MALIIT_TEST_SUITE = maliit-framework-tests
 MALIIT_PACKAGENAME = maliit-framework
 MALIIT_PACKAGE_BRIEF = Maliit Framework
--- doc/doc.pro
+++ doc/doc.pro
@@ -18,9 +18,9 @@
     doc.commands += ( $${IN_PWD}/xmlize.pl );
 
     # Install rules
-    htmldocs.files = $${OUT_PWD}/html/*
+    htmldocs.files = $${OUT_PWD}/html/
     htmldocs.path = $$M_IM_INSTALL_DOCS/$$MALIIT_PACKAGENAME
-    htmldocs.CONFIG += no_check_exist
+    htmldocs.CONFIG += no_check_exist directory
     INSTALLS += htmldocs
 }
 
--- doc/images
+++ doc/images
+(directory)
--- doc/images/architecture-overview.png
+++ doc/images/architecture-overview.png
+‰PNG
+
+
IHDRUŠÙ`sBIT|dˆ	pHYs''¢·">tEXtSoftwarewww.inkscape.org›î< IDATxœíÝw|uúÀñÏlßd7›J„Б’ ""‚"*bå¬g9Ïò³g9۝íÔólçyz"Þ©§§ž½a¯ˆ %ô€”„HBHo»Én¶Î!
›Àó~½x9ÌÎÌ>YɳÏ|ç[UUBšp „‡IªBB’T
"„$©
+!DIRBˆ’¤*„!$IU!BH’ªB„$U!„!IªBB’T
"„$©
+!DIRBˆÒ
;qhdfeÇ7ÇÚ0‡#ÄáÄ,þ™»*§Q’ê‘ãàwáBˆÃÔÉïü‘Ûÿ#GV¸â0—Ò¦*„!%IU!BH’ªB„$U!„!yú/D5!c<3OœÑú÷@ ÀÓÿœ¾€zá¼sÏæü¹çrÙU×àñxÃ
Î!!•ª}TúàÁœ9g6	ññèõzôC»×
=f3QV+‘‘‘]^G§Óa4ÐjµôúNǘL¦^ÅØÝyŠ¢`‹ŠÂb±˜8Ž E›¥R¢ûþ‡Eì(*ÂãñËo½ÁÊÕ«™‘Áþû:ãÆŽeü¸1
ŠŠ‹yøÑÇÙUZÆûo½N}ƒÄ„ŒF#ÿ{û
Ο{ª
+ýí)–.ÏaâÑGsÕ—1$=¼üm<7ÿšÝ
ÞxåEîýóCüåÏ÷sõu7rô„L®½úJΘ{GOÈà7—^ÂÈáÃØ’—Ç˯¾ÆÚu¹¼4ÿ9EÁd2QU]ÍúÜ
èôz
¸÷OŒ>”Ûîü»JKÃù‘
TR©
+ÑÇÝs÷
¼4ÿ9
~àžÖ}1Ñ1Üpóm|óÝBþþìsÜxó­<ö·0dÈN5«õ8«%’n¾
W³‹_{67ÞòìfŸz*×\uv»ƒënº£ÑÀ¥¿¾ˆ]¥¥TVU‘™1žÌŒ
ŽF&df™‘Áæ-y477síU¿¥¾¾s/¼¿/À•—_Úúžiƒòçžç‰§žnÝ÷à½dpZ7ÝvÇaPA*U!ú¼Ûîú#ùÛ
+	øý˜#‚·û?,^BAávž~â1
JeåªÕø}~FÞzîæ-[(Ùµ‹ÊÊ*ššœ—PQYA||
&“‰‘ÇQ]SÃÝ·ß
+ at tt4kÖ­gBFï}ô1GO˜@Ƹ±|ðñ,iƒ±hñO444·mgŸ1}K³ÂÖ¼|V­^ÓîgÈÌÈà«o¾¥¢¢òà~X}€TªBôqMM.qº\­ûš››0Œ
s+W­fÙŠ
L&c»s}>?€Š?àk÷Zss3+V®¢¶®žgæ½À‹¯¼Ê’¥ËX».—aC‡Ï‚O>cò¤c°Z-¬Y·žÆÆFÖån`ÚÔã˜>íx¦dOfÅÊ•x½Þv±µõð£súi§ðWý6tL%•ª}TuM5ë7lÄÕ&™ú|~ÖoØHUU5n·›yÿú7sN;
—«™~\Byy9›6o¡¨¸€ü‚\N'Û·oÇd
+V¼ÏÎ{9³Oåö[nÂçóòý¢%@°RÝðó&¶lÍ£Ángá¢ÅÄÇDzek
O?;3çÌæ×žÇK~âÓÏ¿ /?GcSk¼å¬ß°‘+Wñ—Ǟ䜳Π;+‹œU«æGVŠª
AåŽ`™YÙ+€ìpÇ!ÄalAsº­T3³²­ÀØCPQ—»*'/ÜA!ú¦.“jfVöàC`È¡
§_P3³²ŸÌ]•sW¸Bô=Ý=¨ú’P»£wffeË­´¢“NI53+{,0=±ô77†;!DßÓU¥ú›C
EÿtAfV¶9ÜA!ú–®’ê¤C
EÿdD
ä	!:è*©N8äQô_™á@Ñ·´Kª™YÙé@LxBé—$©
+!ÚéX©ŽKýרp „è[:&U[X¢è¿¢Ã
€¢oé˜T£ÂEÿ%_BBˆv:&UkX¢è¿$©
+!Ú‘¤z`$©
+!Úé˜T{·PÍ‘K:ÿ!Úé˜T•°D!„‡	™¤ú¦UTbLþNûÝ~
Ͼ/
+1%¥	ƒVåÇK»í¶N
â ¢IÇúÊž‹ûH}³.@ƒG‹×üžOŠô‘ÜÄâ]êšµû
Û/NLsàôjÉ)‹Øïs
Ø’T`£cݼyÖÎNû¿ÝiåöR÷ù:¿WKŒÉǏ%–vÛm]1®†•呬¯4ó䉥h•Ûìt­Û'W2wd=.ŸBÎnwÿ˜Âè8M+ãòÏS×¼ÿ­.Ž®§Â©—¤*:IªG°üz#³ßF”1À;gíàÓϯ‹ÇãW86ÅÉ”Ô&ÖU˜XZjÁëWÐ(*““]öwç´!vEyyss_í°Rl70)ÉÉøøf4•돮æ›
V
+덝Î=åáLImäÁãË9sx•Î=Õé°h7§qðÞÖhì
-WeÔ°´4’
•f’->ÎUG^‰“»G×ۣø¡ØŠ½¥ú¾pt=¯ƒ&À@«—ò£)mÔ‡þG$Yøï´*Ì‹¾žù¶·Ã
K—æGÅ<Û«¼3£«—½~
ݍzÊ›‚ß­^
»õ\1¾–¿Ÿ´“6ÀýS+øë´ÝÜ–UÕåþ®\6¶–‡§•QPg É«áŠquÌHk¨UÑj@X
tÝü4ê˜õÁ¥~<
Z(†E{¸nB5ñ~ô•ë&T“™à Uùàœíœ0°‘ƒ
Üul³‡Ú¸ð¨:No³ýÐÔ2¦lâìvîŸZ¶¯Ÿ¨{%•j/LMmâ¢Ñud$º@QŸGe=ÏGß
î¸:SL(üŠ@àÒ..ð^`åí­±ìrt_•i•9Cí|»3ŠGW$ÒàÖòÛñ5Dý]®14ÚÃí“+¹má@~(nß°´4’‡
F剜ÝÆñ鯶ÓàÖòya_nbJjS—Ç)m
+åÉÉN"õþ¶2‘œ²¦¦lëöúÛíîø!•»³+˜;ª¡Ûã„Ø_’T÷ÓÝÇV0+ÝA¼¹Ýr¿@íÓ³{Åš|Ú_©gê@'.MêöQ at U¨wk±‚å¡ÅÀéÓÐäÓPïÖb5øÚíoîâö¿Æ¥Ã§ÂåãjX¾;§·}9êõƒYÛó‚“Ó߁ݭ! v¾¾Ó¼žEïglÜž2¶¢)ØD0 ÒK´ÉO¤¾sÂo=¶åvßPÐidñK:’T÷Óc+™¿.ž+3j96¥‘Ñ1Í.PÖ¢jî
wlèIøÕÿ (uë+Í‘/oˆ³-îð©+olŠå®c+øðÜ
²zxqC<^¿ÒiÿKâºlSmpk¸uá@þ;§˜ž¼‹¿
Ôîõœ2¿?¦’ÏÏ+äÖ
ɯíܦêè&¡¬)&꿝XŠÃ³§­u[‰
EV
:¾ŒÒF=NŸ@z	ŠC«ÝÕ™Yُû¼ Y§2}o@Ã÷E{ÿeíÎôAœ<ØÁÃË“˜’ÒÔºíéá!HG­J¼ÙGK‹Û¯!-ÊÃ55¼±9–¼.~i÷ÅÈX7.¯†’
n—s¯Ú<ž€ö
+n¨¿½Wor0ͳž€F3
³ýåÌy“ÑÍÕ:Ê„.*:Ší صé˜D'«ÌÔ»÷$®®öŒu£Ó¨l®6µÛ
á%-ÊËN»/õn-;‚×OµxI¶xÙRc¢©M%;8ÊCB„5´]==ÚègxŒ»õø(£Ÿ£¸È­43<ÆM‰Ý@
SÇ@«¢b3úymN,Oâý¼hÆÆ7ãö+ÔÛm²záeM
ô
+¬ç%ª÷Å)év
šlä¿ð“!l­é]òëæ¬
üuER¯cÉHpñòìbnøfKK#{}¶îȪàï«=<¾Îñ3Ð÷*ÀŽÅÀbæu¿N¡/ °º¼}RiòjX²«óeWûÛVšm·+z*ÁÏ®ÚÙþŸZi£¾Ë'îEvE-‰½­z·¶]Œv·¶µÛVÛýO/eP”øn§•σ#‰7Uï,Øv»Ä¡ïñKSˆýu at Iõ¬
l®61(ÊÃYÃØZ|ððòìbr+Í
׌ۯaþÚxòêŒÜ>¹’(£¯_axŒ›ÿnŒeaqûé¬?)V/
+*F­Ê9#ìÌL·cô󷕉T8u<p\9q>¶ÕY°ÍÆâwfWpkV§³óŸ
±¤X½­
ÉOâàô¡vŒÚ_ï°²  š¡67šRÁ²ÒHNLk¤ÈnàÉ•¨oÖb3ãØR##wû“K?O'Î䣶YÛmó£6€/ àWZüª‚^«¢ªÁ/øþ®×]ªR-^&&:ù´ÐÆ÷EQÌÚÐÚà?)ÉÉ™Ãí,ØfcÕÃ=SË
ÛÌÙÃØRc¢²IÇ3vwz˜bñ1)ɉFQ˜3ÌΟ¦”³¼4’gÖ Ñ£¡Ù§á_¹ñÜñC*<0µ
¢òíÎà¬
‹,|²Í†Õ`R’›ÑOºÍÓ3J)²ÈÙ
ÁƒÇ—“•ìl=æ¤4åGsưf¥;8aP#ûÒþ(úU
j—NêAô©%¼<»˜¬d'
™÷ܬ]¼<»˜	\ÝžgЪ¬¼<Ÿß
SÀ¢‹·qÿÔ`1ôѹÛyú¤R 8úíʌڃüS
<½Nªgh at Q@ƒJ£WC´ÉÏ	ƒ[__²+‚¯vDñ]‘•ŒxWkò,qèy?/š··Ä ×ªLLrvû
§¤;(¶xec
?íŠdS	“.ÀâùSJ8&ÑE¼ÙÇðë*‚O³s+͝FÍÌ

L”¯nŒåµMqxü
+3Ó
­¯¿¹%–òm4ûFÄ4pÒàÆNU´&&:™”ääò±ÁÄ73½‘i™”ä$Æì
bÖ©±yºìr÷‹û—$ó^^pž÷ÇsyåçXôZ•YC
\QÕÀ¨í|¾F	¶½ÇG´ëƒ¢@lû^9Dê˜t*Fm€‹«!ì_Þr|Û¿Cðü¶ÝôŒÚ––ŸaPK{ýÞôêö_QàÌá
8<Î

Rèök8k¸
EÁD4.¾™øã\”8­#’#}¤Û<Ljù–˯51:ÖÝåû¬­Œ`rJ5ãšÙVkÀfôsöðzFÅ63íÍ‘Ü<±’_©C«¨8Z
š¤EyØXÝþ–=·¥ûÐÄD'•.
­Ú®KQcËHKucÔçbMyJo>
!{ùµFŽØDŠÅË
£ëȯ52²å÷Ø UYvi

n-}€
Õf®ýzP§k<4­ŒowFñsUweW°£Þȏ%æ´Òøé’|ÞÜ
Ãã9‰­ç
èdÞ¬]xý
+Vc€®‰ç•q\2¦–ËÇÕb3úÙPeæ/Ë’(¶øú‚Š
Ò¬
~®2·`&îX”ÊÔÔ&æÍ*áê¯Òhôh¸#»’1q.êšuÌ_Ï'ÛlÜ<©šKÆÔ²|w$SRš8é­áÔ4÷œ6{U©NLt’jñòôªDÎþp(g8”òmLØØ:AG³_Ã's·sT¬›ùëã[Ï­têxfæ.®Î¨áµŸc[GótåÃ<ßï´ðÒiEä\–OV²‹K¬4y5,¼hÃbö$ãüz#KvYøCV%Oo?ÒgMEïlæ¾ãÊ™?«„Ï
+m,ì¡·Âq©M¬Ü
)·"ä’-ÞCzk{Ñè:FuS´
ˆí
FÖV˜¹cr%Ç$:y/oÏz¡¾€ÂéïçÒÏÒyre"LIézðFGŸDñÕŽ(š¼f¾=œçÖ&´{}FZ†ë¾ÄñÿÁ
Á¦¾›'UóY¡_}4”a6Œªo=g¨ÍͽK’ùëŠD>)ˆbzZú§m`—CÏêò®Ì¨!Æèç܏†±¬4’[&Uµ«J·×9ïãt
Þ½OæÓ«Juuy™¯´_#ðщ<ºbÏ7Êš23W~‘†F¡]רZ—–K?OǬ´v
+ÿwn
ÿ΍ë´íòé¸cQ*Fm£NÅÞRžüÎpthöµOz¿û¶ý
mcüëò$
_‘ˆV³'žõ•ævÇ
÷ÆHþ/³†/vÈÊ2"4Ì:•sFÔsî¨zY¼üÔÒ;%+ÙI¬ÉÏ×;‚ww	^f¤5ñíkkwµ3‡7Pb7´ÞYOp‘nóðiA°WC´ÑϬ!–”XZ”YéêÝZV•E00ÊËmÙE”9t|²ÍÆùÑíºÈ
ˆw¶Äð䉥,Ùe¡´M
+‹ÁÏ«§ïDQ ¨>Ø“cL\3+vï½WŽÛ|nÁ¶ñŽ>-ˆb\¼‹7ÏÜIm³ŽÇW$âò+µ.UÏ9#‚£ãÆ·iÛÍÙmaQKSÞÇÛl\•QÃì!f¤5òêÏq¨jp4žY§òÆ;`Ûüè¸=_Fó×ÅïóÌm¥ó^­‘*—¾Ó“¼b‡
“.ø”¯ã(›ž¸ýÜmÆû
+¾î›jºåWügºëä—¤.D(Ü3¥œIIN’-^Š[úêž5¬Œ®Ö¤:8Ê˽SÊÙP¹§ð­YU|µ=ª5©ž”æàì‘öÖ¤šéãÞ)åÜàÔšT¯™PM^µ‰Ue”Ø
5Òm
.
WKÆ€fî\”ŒÛàÓ~,,¶ðõ+ïnÁئ]ò„$Eú¸ú«4Dø˜œÒýs“®Ô»µµ*cã›)¶Ú%3•[¦PÞ8c's†Ù¹ûÇœ^
n‹æÙÕñÄ™}‹ö´žcwï9¿Øn`my·LªÄ¬ðɶà縸ØÂ„D—}6—Oaú &¶Ô˜8cX°)b¦Â<(Iõ‚CºÜÿÐÒäƒñvBôi÷.IƤS™;²žì'Ç$«¨—%µ{(²¶"‚ɯÄØó|Ú»Ãð·) ž[›Àüõ{n‰óëŒL~m$Þ6ç\òizëÀ‰ì”FVìŽ`uy$ïn‰¦Áš*‚Å͝‹‚SDNm37Ãò–ù
þ}jq—}÷æ›íV¦¦6ñæ™;ydyïnݳhñ)é®É¬ÁP¨sëx?φ˧ðxÎ.SÇ¥—›V^ÞÇòn*㏷ÙxhZËK#[¿ˆ^ù9–›Õ|sa!zM€‡o‹z÷ ú€FT	È]•Ó/^3³²WÐ͈*qhÙŒ~Bt¾7QFk³Ù¡f1Z‡R„>€I ¶‹æh“§W³_£1;^[«ì_eÚFïGT
ŽòpT\s§ý[jL]ކéÎ}Ç•³¶"‚Ï£Úmÿ"Îìã–IU|”ocmEÉ/M

ö~Û
+q¨
ª„
+„-¡%¡B°é°»æÃú^¬
+ÑñÚªWIõèD×M¨Æ¨kòS߬ÅåÓðÂúøýJªg³ã
(|^Õn»;_œWÈk?Çòôêî§ŒBˆpêURýx›·Ù81­‘ÌÜÅ£+ùjGc㛹ï¸rFƺYTláƒ¼à“Æ±ñÍÌ
YßiWâÌ>
˜ZNA‘w¶Æbñ©pûäJ4
+œ6ÔÁ¸„fþðCê+	!D¨
¬>W€§N,%ÕêåM1\1¾–ߌ«mÝ?°eÿoÆ÷w%Îìã¥ÓJ0éT^̍è
#3ûùn§•€
+›kLüoS®”éBj!ËLcâ›I¶xùd›¯wD‘[iffº£uÿ‚–ýª‚û»rJºƒ‹—?þ˜ŒË×>´_º”7èYXlÅ݈hÑ^Z”‡Ó†Ø[ÿœÒÍÿ›_Ä›}
'è>`YÉN
>¾Œhã>ôwëA¼ÙÇÃÇ—qt¢³Ûm!¶%Õ‚:#

ZÆãµ¹YWaîrÿúŠ®gÿv§•*—–Ì,írÖv»GK²%ô¿Ôd~ì4æÅœî0ºô|ÔÝüË6¢§C¦¦6ñøŒÝÜ1¹’[&UñûI•=^ò©“JùۉݯMNC€³F4fõîÓ~!†õSuûžZ5€ßŒ«å¼‘õ¬,‹àõM±]îmSl—רvéø¿¯Òøïœ"ž›µ‹G—'¶{ýÍÍ1\6¶Ž¯/(dâG
*ôý–lñruF
ã\€ÿ;à	žÙ¶€º¥LÃǽ<oÛøÇ)1Ÿ]ÐnBè¶nú~ ›ÛÌ™p÷±˜u*^šÄ-“ªˆ3ùXWÁˆ7ªœÞñùµñ”6øÕ¨:¦¤8Y¾;‚w¶ÄPíÒñд2\^Mp*G‹sãXZIVrp"Ž´(•M:îZœB¤>8Í¢VQÑkUÎ
ÑÀ)évêÜZ>)°±¤ÄÂŒ4—­ã§]‘œ:ÄÁšŠžZ9€@7ó[è4bõ¡S©kÙ76ÁÅÜQõÙ
Ì_OY£ž§N*¥¸AOªÕK­KGn•™ËÇÖbÔ©¬«0óƦXv4¸ñ˜*R­^ªœzÆÄº(oÒSîÔ1omC£ÝÜ3¥‚gÖ$°¡›ejđ〒êÅ–vÃ<?̏æÃüèNÇu·?ûõ‘]nÏzgxëvÛëÿk}<ÿj3À¡köñÄôÝŒŒucûåVUŀ½è{Ë©@°±޽ht
3ÓÉ)‹àžÅa¼|Z1
+Œ\þÙ`ÞÝÍ[gî$ÆäãøM\ùEv†J§UUøßæŠ
znŸ\IªÅË+p÷±$˜ýüyiãã›dõðøÊDÒ£ë¹ibKK#ùÝ1U4y5üá‡T†E{ðDø™”äÄ ƒ“¹gJ9/K⨸fž™Yʬ·‡‘ÐrL½[Ëâ×N¨æ›íVr«ºNb&]°=þ“m¶Öɰ'pñÊÆ8îÈVã÷/I&3¡™éyqC
›«M4x´üeY]€‡Ž/ǤS¹gq2ã=œ4ØÁù6؈7û¸á˜^ßËéC팈q³UæÞÈUû¥Ö¥ã‹“9oTs†5éC«Q¨¼jQ¸ãëDQN&ÎüZSà­Ñ–OZ†7v4}<»
z[&ŒØ^oäõM±\“YÇùÑ­mÚ
n-ªª°°ÈŠN£rbZ#þÁ&Ÿ!Q

Z¼ÃØXe潭ѤÛ<\4:X/~µ=Š›&VñêéE,ÞeaY‡UfvPíÔñ~^4C£Ýœ7ªži{Fëük}<.¯†k'T3"ÖÝmRíÊg
6¾Ü
ÅŒ´FŽm3ÁÇꊈÖ/ëÓ‡Ù¹6³£6@”1À±É{Žkpkù˲dj°SýõGWsÆ0;§qðEaT¯;œ‹Ã‹$ÕýTåÔ3]<ó×Å3.¡™ÿ¹óY¥’ë

wl<o{ø
+ƒÿŸç/H_@#ªœ^MkGq­¢göqþ¨z¶Õ™˜=´×7Ű½ÞˆÃ­e`”‡¤HUN-«Lxü
+·ÿ
®˜1ÀÕ:»—£¥©AmÓ<¾bw$æÛÈJv1oV	‹;,a½¾ÒÌ)év†Ø<
“èjÙgj
Úéðhèmê:&ÑÅÛ}ŒŒq“צª¬i32çŠñ5”5éùýwyóÌ"âÍ{Úaëšµ­Í
v·–Ï
+m\›YM´ÉÏíù©½ŒJ
n¤_Òø¹Ê×7ÜÊõõ}/¡ÜÐp74ÜËՍ{;ô¾ãÊyyv1/Ï.ÆfòóØŒ2*œ:.ù4•fž˜Q†Qàãm6̺__PÀ¨87óÖÅcÔ©|sA‹.ÞÆ£ë{|Ÿ;²+XtqO/¥ ÎȲ㳿(NlþÖY;¸~B5ÿÙKa}ïÖ>ë(RççëóÑkü÷ç®Ûõ?+°11ÑÉ‚¹Ûñw×`ÛâÍÍ1D›ül©1‘WšE{珪GÓÏndìÿ’±ÿAVCpí!—oïÇ/=;º{hÁ‰Â½M·¢zˤSñøéq®Ü}€fŸÒã1z­ÊÈ7¯œ^Ì#ËYÐM³Š80oŸµ“—6ÄñÝÎ~±
+Ç‚ÜU9çH¥*BÂáÑìSB
`2í)¡BpºÇP'T`¯É‚M!{;f¨ÍÃcÓwóa¾O
+%¡
“’œŒŠmæâÑu{?¸‘6U!z!¯ÖÈ™
w‡µ“Ó
h8*¾«1€ÃÝ?jÀŽQ
„Ú@!öFìd'ª
+þ€ÂÅGõŸjµcRÝ·
dÄ/÷~ˆbi•»¥à	hx{K4_nï?ËuLª=ü
5„;!G¾€B^‘@˃ô»~/gô
’TŒ$U!¢€ª´[r¦?¤z`$©
+qÔà`”þ¤cR=t’
jÂ
€‡3¿ª ô³RµcRÝ–(ú¯Má@ˆÃY  ôïJ5wUN%Ð7'Ëì›rÃ
€‡³€J¿oSXwÈ£è¿$©
+qèç•j‹¥‡<Šþ©ÈwB
Îüõ°¨T_úÐz%}Ö+¹«rlQ%!D‹J5wUNðqbéOTà
p!ÄáÎPúÝÔÝÍPpðÝ¡¤±—æ®Ê)w B
îTèwIµËYªrW唳2³²eѝÎ|¹«r¤yDˆC ?Vª=Ný—»*§ùP"„
TÐô³ÉóúÇ
Bˆ#’Ðô³,ÕÏÂB
IÔ€Tª¢ï’!µ¢ßñ£ô§JuÈr*G’Zþ;І1!ö™’LÚ€¨
+w,=ðßOA‡ÕT
¢OyÞ¶E-ãzûyáe_õŸÂZq$
+ jú՝•$U!D¦øQÕ~•§úU°Bˆ#Œð£ô¯g’T
}—¢øégyª_+„8Â(èg½U$©
+!ú.©T
"„ü J¥*„ì
èëQ”HP¬<}w¸ÃÙW2¢JÑ7Ã@™(Øîpö•$U!D;™YÙFàTÂ|'{þ¨”’{¦”)Š‚æý­ÑUgeŸÎxÚð_æ®Ê	tõ¢$U!DGw„;ˆ÷òlœ;ªŽh£ŸGV$ßîx:øð÷®^¤*„+ÕB8¥IDATè(*Üüâ‹Â(Z¼úÞ%Ý~F’T
}Öy1$Fö¯Õ‹äé¿¢Ïrùv6èÃ
Æ~‘¤*„!$IU!BH’ªB„$U!„!IªBB’T
‡LR¤h£¿ÇíÞ0éTR,^ôÚÞuhMˆðkM×-IªBˆý2g¨s·óÌÌÒÖ}7O¬dÁÜíÜ2©çEOß={¿ŸTÙãö5™5\•QÓåù¿ŸXÅ‚¹ÛY0w;/œRÂ%cjQ˜šÚÄ—ç22ÆÝ«ŸéÅÓJ¸ÿ¸Š^Û‘tþBì—(£Ÿt›‡ÁQ
Æ'¸ØÙ`ä×cê0jUDx
åaDŒw at amyMÞÎõÛ_—'RÞ¤o·jñrÚ;*
+¹•f
+êÔ7ï™ù/Î
|ﻥplŠ“;³+)¶Ú]7Öìc¨Íæj3
?
è¢Ø®§Ò©G£@vJÅ
bÌ~\^
Âz#Ï®I Ñ|Ÿ±ñ͸ý
+Ì~V•Gì׈.IªBˆ^Y¾;’_UÇæ»
lÆ=ó‹Ü41X±Æ™ü<3³”Ë>̦jS»óÿ4¥‚ïŠ,¬¯4·no«5‘jõpç±<•“HNYD§÷þzgN
玬gh´›]cëkǦ8yô„Ýœ÷q:•N=/Ï.汜DÞÞÃÛgï Íê¡Ôa Ùâ%§,’[¿Oå÷«ØÙ`dåî
9a7VC_a@„/
+£¸ï§ä}þ\äö_Ñ+on‰á”!.
[Ë[[bh[Ì=»&»#Ù\kBUaÎ0û>]ó­-1äÕšØZc悏‡t™P¾<¯ÿÌ.¡¬QÇ‚‚è}ºvf‚‹Q1nþøc
+šŽ®‡ìçö+Ìy(ŸÚ˜6¨qŸ®ÿ©T
½’WcdC¥™á1n>+´qí„`;¨N£òÒìbŠê
|\_UHŒô†ô½ŸX9€R‡¼Zc§×|ƒ’"ö<|2ë‚•t“O‹?¾.'îʯ5Pš¼"õ=
ØIªBˆ^»ï§d¬?Í>¥uŸ^‘º~ÆÇ»Ðiöï‰ü–猨çÁãËya}<eÓÔÅVÔn.»¾"ØÌpˤJl¦==
+V–EPíÔñÐÔÝ”7z¬TÑ›¾’T
ûecµ™ÖÇÓäÕRéÔÁ‡M¯mŠ¡Ô®ÇåS¸ñÛAœœî`UY¥z*Z
H½²1–íõÆ
·_XÏÖ#ÉÞEâ¢âHÊ›têŽ=/¬§Ò©¥Ê©ç†o1%¥‰ïЬLImbc•¿ªpöGC9mˆR‡žgN.eKM0¿½%¦õXÛí¥»"ihÞ¿%²µ»t/„8"efe¿\î8†WfSçÖpTœƒVåÂOÒ©vöª¶|0wUΟ»zA*U!Ä㑉vób®­-ÑBM’ªâˆQPg¤ ®óíP’.UBB’T
"„$©
+!DIRBˆ’¤*„!$IU!BH’ªB„$U!„!IªBˆŽz7}þ‘¥ÛÏHFT	!:ºØ„]Ýñot÷¢L¨"„!$ßDBBÿ¿õe8îßIEND®B`‚--- doc/mdoxy.cfg.in
+++ doc/mdoxy.cfg.in
@@ -7,9 +7,10 @@
 HIDE_UNDOC_MEMBERS    = NO
 HIDE_UNDOC_CLASSES    = NO
 HIDE_UNDOC_RELATIONS  = YES
-BRIEF_MEMBER_DESC     = YES
+BRIEF_MEMBER_DESC     = NO
 REPEAT_BRIEF          = YES
 ALWAYS_DETAILED_SEC   = NO
+ENUM_VALUES_PER_LINE  = 0
 FULL_PATH_NAMES       = NO
 STRIP_FROM_PATH       = 
 INTERNAL_DOCS         = NO
@@ -46,6 +47,8 @@
 
 FILE_VERSION_FILTER   = "echo @M_IM_VERSION@"
 INPUT                 = @MALIIT_IN_DIR@/../src/ \
+                        @MALIIT_IN_DIR@/../maliit/ \
+                        @MALIIT_IN_DIR@/../common/maliit/ \
                         @MALIIT_IN_DIR@/src/
 FILE_PATTERNS         = *.cpp *.h *.dox
 RECURSIVE             = YES
@@ -53,6 +56,7 @@
 EXCLUDE_PATTERNS      = moc_*.cpp *_p.h *_p.cpp */demo/*
 IMAGE_PATH            = @MALIIT_IN_DIR@/images
 INPUT_FILTER          = "sed -f @MALIIT_IN_DIR@/aliases.sed <"
+EXAMPLE_PATH          = @MALIIT_IN_DIR@/../examples/apps/
 
 #---------------------------------------------------------------------------
 # configuration options related to the alphabetical class index
--- doc/src/common.dox
+++ doc/src/common.dox
+/*! @defgroup common Common
+
+\brief Shared API between @ref libmaliit and @ref pluginapi.
+
+This API consists of enums and other constants that are generally useful to
+consumers of %Maliit APIs.
+
+*/
--- doc/src/footer.html
+++ doc/src/footer.html
@@ -1,8 +1,8 @@
 <hr>
 <table width="100%" cellspacing="0" border="0"><tr class="address">
-<td width="30%" align="left">Copyright © 2010 Nokia Corporation</td>
+<td width="30%" align="left">Copyright © 2011 Nokia Corporation</td>
 <td width="40%" align="center" class="generator"><!-- Generated on $datetime<br>Doxygen $doxygenversion --></td>
-<td width="30%" align="right"><div align="right">MeeGo Touch</div></td>
+<td width="30%" align="right"><div align="right">Maliit</div></td>
 </tr></table>
 </body>
 </html>
--- doc/src/header.html
+++ doc/src/header.html
@@ -11,6 +11,8 @@
 <a href="$relpath$index.html">Home</a>
 ·
 <a href="$relpath$classes.html">API Reference</a>
+·
+<a href="$relpath$modules.html">Modules</a>
 </td>
 </tr>
 </table>
--- doc/src/internals.dox
+++ doc/src/internals.dox
@@ -96,7 +96,7 @@
 If current input method mode is M::InputMethodModeDirect, then the input method sends key event instead of sending pre-edit or commit string.
 
 \subsection Pre_edit_injection Pre-edit injection
-MTextEdit widget requires that if a word is clicked then it needs to be turned into a pre-edit, so it can be changed into another word with error correction feature. When this happens, the clicked word is removed, then the widget construct a MPreeditInjection event and sends it to input context. If the event is accepted, e.g. if the error correction is enabled, then the incoming word enclosed in the event then treated as pre-edit. In MInputContext side, upon receiving this event, will construct a QInputMethodEvent with the word as a new pre-edit string.
+MTextEdit widget requires that if a word is clicked then it needs to be turned into a pre-edit, so it can be changed into another word with error correction feature. When this happens, the clicked word is removed and the widget constructs a MPreeditInjection event and sends it to input context. If the event is accepted, e.g. if the error correction is enabled, then the incoming word enclosed in the event is treated as pre-edit. In MInputContext side, upon receiving this event, a QInputMethodEvent will be constructed with the word as a new pre-edit string and sent to the widget. MInputContext will then call im::setPreedit() RPC function to inform the input method about the new pre-edit string. Upon receiving the new pre-edit string, the input method will decide appropriate styling for the pre-edit and call app::sendPreeditString() RPC function. Please note that pre-edit becomes truly active only after input method has called app::sendPreeditString() RPC function. This means that update() will be called only after app::sendPreeditString() RPC function has been called and therefore input method will not know the true state of the widget (e.g. cursor position and surrounding text) before.
 
 \subsection Copy_and_paste Copy and paste
 
--- doc/src/libmaliit.dox
+++ doc/src/libmaliit.dox
+/*! @defgroup libmaliit Libmaliit
+
+\brief Input method extension library for Qt.
+
+Libmaliit is an input method extension library for Qt — use it to add
+application support for screen rotation and attribute extensions.
+
+ at section basiclibmaliitusage Basic usage
+
+Include the header for the class that you wish to use. For example, if you want
+to use @ref Maliit::InputMethod "InputMethod":
+ at code
+#include <maliit/inputmethod.h>
+ at endcode
+
+Add the libmaliit pkg-config checks to your project's qmake .pro %file:
+ at code
+CONFIG += link_pkgconfig
+PKGCONFIG += maliit-1.0
+ at endcode
+
+Finally, run qmake and build your application in the usual way:
+ at code
+qmake
+make
+ at endcode
+
+*/
--- doc/src/mainpage.dox
+++ doc/src/mainpage.dox
@@ -1,51 +1,71 @@
-/*! @mainpage MeeGo Touch Input Method Framework Documentation
+/*! @mainpage %Maliit Framework Documentation
 
 @section intro Introduction
 
-MeeGo Touch Input Method Framework provides the necessary framework to input text into text entry fields of applications. To achieve this, MeeGo Touch Input Method Framework indirectly interacts with the applications through the MeeGo Touch Framework, using the supplied MInputContext. MInputContext is an implementation of the QInputContext defined by Qt. This input context enables input services for both native MeeGo Touch and plain Qt applications. The input context is created automatically by the application process and acts a messenger between server and the applications.
+%Maliit provides a flexible and cross-platform input method framework. It has a
+plugin-based client-server architecture where applications act as clients and
+communicate with the %Maliit server via input context plugins. The communication
+link currently uses D-Bus. %Maliit is an open source framework (LGPL 2) with
+open source plugins (BSD).
+
+The framework provides two distinct plugin interfaces:
+- @ref pluginapi "Maliit plugin", for writing input methods such as virtual keyboards or handwriting
+- %Maliit engine plugin, for writing input method engines used for word prediction and error correction.
+
+ at if false
+[ATTENTION: engine interface is not Maliit-fied yet].
+* Writing Maliit plugins [LINK]
+* Writing Maliit engine plugins [LINK]
+ at endif
+
+ at image html architecture-overview.png
+
+The %Maliit @ref architecture provides an abstraction that enables application
+developers to concentrate on application logic, with the option to extend input
+method interaction with @ref libmaliitintro, while plugin developers are
+insulated from applications. Neither plugins nor applications know directly of
+each other, nor do they have to use the same toolkits. For example, plugins
+written for Qt or MeeGo Touch applications will work just as well for GTK+
+applications, without any modifications.
+
+The framework is responsible for switching to specific plugins, depending on
+the application and device state. For example, when opening a hardware
+keyboard, %Maliit will automatically search for a HWKB-capable plugin and
+activate it. Additionally, plugins can trigger a plugin or language layout
+change. Plugins announce their services via a plugin description interface, the
+list of languages they support, whether they are on-screen or
+HWKB plugins (or both).
 
-Non-Qt input contexts need to implement the D-Bus interface to be able to use the framework.
+ at subsection maliit-fwbasicusage Basic Usage
 
-MeeGo Touch Input Method Framework consists of two frameworks:
-
-- MeeGo Touch Input Method UI Framework
-- MeeGo Touch Input Method Engine Framework
-
-These frameworks are built in such a way that both the input method engines and UIs are individual plugin components separate from the frameworks. Therefore, developers can create alternate or additional Input Method engine and UI plugins, or customise the existing ones.
-
-The UI framework has a client-server type architecture, where the application acts as the client, and the Input Method main application (UI Server) as the server. The server presents the user an input UI whenever the user taps a text entry field. The input UI and any active input method engines are provided by the plugins present in the system at a given time.
-
-These input method plugins can range from simple virtual or hardware keyboards to handwriting recognition or even speech-to-text type of input.
-
- at section inputmethoduifw MeeGo Touch Input Method UI Framework
-
-MeeGo Touch Input Method UI Framework is an integration framework that provides interfaces to be implemented by input method UI plugins created by developers. Such plugins offer a custom UI to be used in inputting text to text fields in applications. They also buffer and allow on-the-fly modification of text prior to delivery to the application. The included MeeGo Keyboard is an implementation of such a plugin.
-
-<B>Note</B>: The Input Method UI plugins interact with Input Method Engine plugins which can provide them with, for example, modified, alternate or corrected versions of the entered input. For more information, see the libmeegoimengine library introduction.
-
- at section basicusage Basic Usage
-
-<B>Main classes:</B>
+ at subsubsection maliit-fwclasses Main classes
 
 The following base classes are needed to implement an input method UI plugin:
 
 - MAbstractInputMethod : to allow input method server to update input method plugin state
-
 - MAbstractInputMethodSettings : to provide settings in control panel
-
 - MInputMethodPlugin : to enable the plugin to be loaded by the input method server
 
- at section general General documentation
+ at subsection general General documentation
 - <a href="architecture.html">Architecture</a>
 - <a href="extensions.html">Extensions to Qt</a>
 - <a href="pluginsystem.html">Plugin System</a>
 - <a href="internals.html">Feature Internals</a>
 - <a href="toolbarxml.html">Toolbar Widget XML Specification</a>
 
-
- at section tutorial Tutorial
+ at subsection tutorial Tutorial
 - <a href="plugintutorial.html">How to implement a plugin</a>
 
+ at section libmaliitintro Libmaliit
+
+ at ref libmaliit "Libmaliit" is an input method extension library for Qt — use it to add application support for screen rotation and attribute extensions.
+
+ at subsection libmaliitclasses Useful classes
+
+- @ref Maliit::AttributeExtension "AttributeExtension" : Register extensions such as key overrides.
+- @ref Maliit::InputMethod "InputMethod" : Listen to device orientation, language and raw key events.
+- @ref Maliit::PreeditInjectionEvent "PreeditInjectionEvent" : Extension for preedit text inside text edits.
+
 @section api API reference
 <a href="classes.html">All Classes</a>
 
--- doc/src/maliitserver.dox
+++ doc/src/maliitserver.dox
+/*! @defgroup maliitserver Maliit server
+
+%Maliit Server is an integration framework that provides interfaces to be implemented by input method UI plugins created by developers. If you are an application developer, you likely want to read the @ref pluginapi documentation instead. Such plugins offer a custom UI to be used in inputting text to text fields in applications. They also buffer and allow on-the-fly modification of text prior to delivery to the application. The included MeeGo Keyboard is an implementation of such a plugin.
+
+ at note Input method plugins interact with word engine plugins, which can provide them with, for example, modified, alternate or corrected versions of the entered input. For more information, see the libmeegoimengine library introduction.
+
+*/
--- doc/src/meego-im.css
+++ doc/src/meego-im.css
@@ -1,28 +1,29 @@
-BODY,H1,H2,H3,H4,H5,H6,P,CENTER,TD,TH,UL,DL,DIV {
+body,h1,h2,h3,h4,h5,h6,p,center,td,th,ul,dl,div {
   font-family: Arial, Geneva, Helvetica, sans-serif;
 }
 
-H1 {
+h1, div.title {
 	text-align: center;
         font-size: 160%;
+	font-weight: bold;
 }
-H2 {
+h2 {
 	font-size: 120%;
 }
-H3 {
+h3 {
 	font-size: 100%;
 }
-CAPTION { 
+caption {
 	font-weight: bold 
 }
-DIV.qindex {
+div.qindex {
 	width: 100%;
 	text-align: center;
 	margin: 2px;
 	padding: 2px;
 	line-height: 140%;
 }
-DIV.navpath {
+div.navpath {
 	width: 100%;
 	background-color: #e8eef2;
 	border: 1px solid #84b0c7;
@@ -31,7 +32,7 @@
 	padding: 2px;
 	line-height: 140%;
 }
-DIV.navtab {
+div.navtab {
        background-color: #e8eef2;
        border: 1px solid #84b0c7;
        text-align: center;
@@ -39,85 +40,85 @@
        margin-right: 15px;
        padding: 2px;
 }
-TD.navtab {
+td.navtab {
        font-size: 70%;
 }
 
 div.qindex {
        display: none;
 }
-A.qindex {
+a.qindex {
        text-decoration: none;
        font-weight: bold;
        color: #1A419D;
 }
-A.qindex:visited {
+a.qindex:visited {
        text-decoration: none;
        font-weight: bold;
        color: #1A419D
 }
-A.qindex:hover {
+a.qindex:hover {
 	text-decoration: none;
 	background-color: #ddddff;
 }
-A.qindexHL {
+a.qindexHL {
 	text-decoration: none;
 	font-weight: bold;
 	background-color: #6666cc;
 	color: #ffffff;
 	border: 1px double #9295C2;
 }
-A.qindexHL:hover {
+a.qindexHL:hover {
 	text-decoration: none;
 	background-color: #6666cc;
 	color: #ffffff;
 }
-A.qindexHL:visited { 
+a.qindexHL:visited {
 	text-decoration: none; 
 	background-color: #6666cc; 
 	color: #ffffff 
 }
 
-A {
+a {
 	text-decoration: none;
 }
 
-A.el { 
+a.el {
 	text-decoration: none; 
 }
-A.elRef { 
+a.elRef {
 	font-weight: bold 
 }
-A.code:link { 
+a.code:link {
 	text-decoration: none; 
 	font-weight: normal; 
 	color: #0000FF
 }
-A.code:visited { 
+a.code:visited {
 	text-decoration: none; 
 	font-weight: normal; 
 	color: #0000FF
 }
-A.codeRef:link { 
+a.codeRef:link {
 	font-weight: normal; 
 	color: #0000FF
 }
-A.codeRef:visited { 
+a.codeRef:visited {
 	font-weight: normal; 
 	color: #0000FF
 }
-A:hover { 
+a:hover {
 	text-decoration: none; 	
 	background-color: #f2f2ff 
 }
-DL.el { 
+dl.el {
 	margin-left: -1cm 
 }
 .fragment {
        font-family: monospace, fixed;
        font-size: 95%;
 }
-PRE.fragment {
+pre.fragment {
 	border: 1px solid #CCCCCC;
 	background-color: #f5f5f5;
 	margin-top: 4px;
@@ -129,65 +130,65 @@
 	padding-top: 4px;
 	padding-bottom: 4px;
 }
-DIV.ah { 
+div.ah {
 	font-weight: bold; 
 	margin-bottom: 5px; 
 	margin-top: 5px 
 }
 
-DIV.groupHeader {
+div.groupHeader {
        margin-left: 16px;
        margin-top: 12px;
        margin-bottom: 6px;
        font-weight: bold;
 }
-DIV.groupText { 
+div.groupText {
 	margin-left: 16px; 
 	font-style: italic; 
 	font-size: 90% 
 }
-BODY {
+body {
 	background: white;
 	color: black;
 	margin-right: 20px;
 	margin-left: 20px;
 }
-TD.indexkey {
+td.indexkey {
 -moz-background-clip:border;
 -moz-background-inline-policy:continuous;
 -moz-background-origin:padding;
 background:#F0F0F0 none repeat scroll 0 0;
 color:black;
 }
-TD.indexvalue {
+td.indexvalue {
 -moz-background-clip:border;
 -moz-background-inline-policy:continuous;
 -moz-background-origin:padding;
 background:#E4E4E4 none repeat scroll 0 0;
 color:black;
 }
-TR.memlist {
+tr.memlist {
 	background-color: #f0f0f0; 
 }
-P.formulaDsp { 
+p.formulaDsp {
 	text-align: center; 
 }
-IMG.formulaDsp {
+img.formulaDsp {
 }
-IMG.formulaInl { 
+img.formulaInl {
 	vertical-align: middle; 
 }
-SPAN.keyword       { color: #008000 }
-SPAN.keywordtype   { color: #604020 }
-SPAN.keywordflow   { color: #e08000 }
-SPAN.comment       { color: #800000 }
-SPAN.preprocessor  { color: #806020 }
-SPAN.stringliteral { color: #002080 }
-SPAN.charliteral   { color: #008080 }
-SPAN.vhdldigit     { color: #ff00ff }
-SPAN.vhdlchar      { color: #000000 }
-SPAN.vhdlkeyword   { color: #700070 }
-SPAN.vhdllogic     { color: #ff0000 }
+span.keyword       { color: #008000 }
+span.keywordtype   { color: #604020 }
+span.keywordflow   { color: #e08000 }
+span.comment       { color: #800000 }
+span.preprocessor  { color: #806020 }
+span.stringliteral { color: #002080 }
+span.charliteral   { color: #008080 }
+span.vhdldigit     { color: #ff00ff }
+span.vhdlchar      { color: #000000 }
+span.vhdlkeyword   { color: #700070 }
+span.vhdllogic     { color: #ff0000 }
 
 .mdescLeft {
  border:1px none #E0E0E0;
@@ -276,17 +277,17 @@
 	color: #003399;
 	font-weight: bold;
 }
-FORM.search {
+form.search {
 	margin-bottom: 0px;
 	margin-top: 0px;
 }
-INPUT.search { 
+input.search {
 	font-size: 75%;
 	color: #000080;
 	font-weight: normal;
 	background-color: #e8eef2;
 }
-TD.tiny { 
+td.tiny {
 	font-size: 75%;
 }
 a {
@@ -295,16 +296,16 @@
 a:visited {
 	color: #2A3798;
 }
-.dirtab { 
+.dirtab {
 	padding: 4px;
 	border-collapse: collapse;
 	border: 1px solid #84b0c7;
 }
-TH.dirtab { 
+th.dirtab {
 	background: #e8eef2;
 	font-weight: bold;
 }
-HR { 
+hr {
 border: 0;
 color: #a0a0a0;
 background-color: #ccc;
@@ -407,7 +408,7 @@
    border-color: #E0E0E0;
 }
 
-table.mainIndex TH {
+table.mainIndex th {
    width: 33%;
    border-width: 1px 0px 1px 0px;
    padding: 2px;
@@ -420,7 +421,7 @@
    font-size: 100%;
 }
 
-table.mainIndex TD {
+table.mainIndex td {
    border-style: none;
    vertical-align: top;
    padding-top: 1em;
--- doc/src/pluginapi.dox
+++ doc/src/pluginapi.dox
+/*! @defgroup pluginapi Plugin API
+
+\brief Input method plugin API.
+
+*/
--- examples/README
+++ examples/README
@@ -2,3 +2,11 @@
 and have simple sanity tests found under tests/
 All newly added examples must contain such a test.
 This is done to prevent bitrot.
+
+To make the examples buildable both as a part of the normal
+framework build, and as a stand-alone examples package, the BUILD_TYPE
+is used.
+The value "unittest" means normal framework build, and "skeleton" means
+stand-alone. The value "skeleton-legacy" should be used for examples
+that need to build differently as examples for framework in legacy mode.
+When not in unittest mode, the build cannot refer to directories below examples/
--- examples/apps/apps.pro
+++ examples/apps/apps.pro
@@ -1,2 +1,10 @@
 TEMPLATE = subdirs
 SUBDIRS = plainqt twofields widgetproperties
+
+system(pkg-config gtk+-2.0) {
+    SUBDIRS += gtk2
+}
+
+system(pkg-config gtk+-3.0) {
+    SUBDIRS += gtk3
+}
--- examples/apps/gtk2
+++ examples/apps/gtk2
+(directory)
--- examples/apps/gtk2/exampleapp-gtk.c
+++ examples/apps/gtk2/exampleapp-gtk.c
+/* * This file is part of meego-im-framework *
+ *
+ * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+ * All rights reserved.
+ * Contact: Nokia Corporation (directui at nokia.com)
+ *
+ * If you have questions regarding the use of this file, please contact
+ * Nokia at directui at nokia.com.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1 as published by the Free Software Foundation
+ * and appearing in the file LICENSE.LGPL included in the packaging
+ * of this file.
+ */
+
+#include <gtk/gtk.h>
+
+gint
+main(gint    argc,
+     gchar **argv)
+{
+    GtkWidget *window, *vbox;
+    GtkWidget *button, *entry, *text_view;
+
+    gtk_init(&argc, &argv);
+
+    window = gtk_window_new(GTK_WINDOW_TOPLEVEL);
+    gtk_window_set_title(GTK_WINDOW(window), "Maliit GTK+ example");
+
+    // Clicking the button will steal focus from the text entry, thus hiding
+    // the virtual keyboard:
+    button = gtk_button_new_with_label("Hide keyboard");
+    entry = gtk_entry_new();
+    text_view = gtk_text_view_new();
+    gtk_widget_set_size_request(text_view, 150, 200);
+    vbox = gtk_vbox_new(FALSE, 10);
+
+    gtk_box_pack_start(GTK_BOX(vbox), button, FALSE, FALSE, 0);
+    gtk_box_pack_start(GTK_BOX(vbox), entry, FALSE, FALSE, 0);
+    gtk_box_pack_start(GTK_BOX(vbox), text_view, TRUE, TRUE, 0); /* Expands */
+    gtk_container_add(GTK_CONTAINER(window), vbox);
+
+    g_signal_connect(G_OBJECT(window), "delete-event",
+                     G_CALLBACK(gtk_main_quit), window);
+    gtk_widget_show_all(window);
+
+    gtk_main();
+    return 0;
+}
--- examples/apps/gtk2/gtk2.pro
+++ examples/apps/gtk2/gtk2.pro
+TEMPLATE = app
+TARGET = maliit-exampleapp-gtk2
+
+BUILD_TYPE = unittest
+
+contains(BUILD_TYPE, unittest) {
+    include(../../../config.pri)
+    target.path = $$M_IM_INSTALL_BIN
+    INSTALLS += target
+}
+
+CONFIG -= qt
+CONFIG += link_pkgconfig
+PKGCONFIG += gtk+-2.0
+
+SOURCES = exampleapp-gtk.c
+
+QMAKE_CLEAN += target
--- examples/apps/gtk3
+++ examples/apps/gtk3
+(directory)
--- examples/apps/gtk3/gtk3.pro
+++ examples/apps/gtk3/gtk3.pro
+TEMPLATE = app
+TARGET = maliit-exampleapp-gtk3
+
+BUILD_TYPE = unittest
+
+contains(BUILD_TYPE, unittest) {
+    include(../../../config.pri)
+    target.path = $$M_IM_INSTALL_BIN
+    INSTALLS += target
+}
+
+CONFIG -= qt
+CONFIG += link_pkgconfig
+PKGCONFIG += gtk+-3.0
+
+SOURCES = ../gtk2/exampleapp-gtk.c
+
+QMAKE_CLEAN += target
--- examples/apps/plainqt/mainwindow.cpp
+++ examples/apps/plainqt/mainwindow.cpp
@@ -186,5 +186,7 @@
     }
     const Maliit::OrientationAngle angle = orientations[orientationIndex];
 
+    //! [Get singleton InputMethod instance]
     Maliit::InputMethod::instance()->setOrientationAngle(angle);
+    //! [Get singleton InputMethod instance]
 }
--- examples/apps/plainqt/plainqt.pro
+++ examples/apps/plainqt/plainqt.pro
@@ -1,8 +1,5 @@
-include(../../../config.pri)
-
 TEMPLATE = app
 TARGET = maliit-exampleapp-plainqt
-target.path = $$M_IM_INSTALL_BIN
 DEPENDPATH += .
 
 BUILD_TYPE = unittest
@@ -14,6 +11,9 @@
 }
 
 contains(BUILD_TYPE, unittest) {
+    include(../../../config.pri)
+    target.path = $$M_IM_INSTALL_BIN
+    INSTALLS += target
 
     # Used for testing purposes, can be deleted when used as a project skeleton
     # Build against in-tree libs
@@ -36,5 +36,5 @@
 
 QT += core gui
 
-INSTALLS += target
+
 QMAKE_CLEAN += maliit-exampleapp-plainqt
--- examples/apps/twofields/twofields.pro
+++ examples/apps/twofields/twofields.pro
@@ -1,8 +1,6 @@
-include(../../../config.pri)
 
 TEMPLATE = app
 TARGET = maliit-exampleapp-twofields
-target.path = $$M_IM_INSTALL_BIN
 DEPENDPATH += .
 
 BUILD_TYPE = unittest
@@ -14,6 +12,9 @@
 }
 
 contains(BUILD_TYPE, unittest) {
+    include(../../../config.pri)
+    target.path = $$M_IM_INSTALL_BIN
+    INSTALLS += target
 
     # Used for testing purposes, can be deleted when used as a project skeleton
     # Build against in-tree libs
@@ -40,5 +41,4 @@
 
 QT += core gui
 
-INSTALLS += target
 QMAKE_CLEAN += maliit-exampleapp-twofields
--- examples/apps/widgetproperties/mainwindow.cpp
+++ examples/apps/widgetproperties/mainwindow.cpp
@@ -58,6 +58,9 @@
     QCheckBox *preferNumbersCheckBox(new QCheckBox("Prefer numbers (show symview first)"));
     preferNumbersCheckBox->setFocusProxy(entryWithProperties);
 
+    QCheckBox *suppressionCheckBox(new QCheckBox("Suppress virtual keyboard while retaining focus"));
+    suppressionCheckBox->setFocusProxy(entryWithProperties);
+
     QTextEdit *hiddenText(new QTextEdit);
     hiddenText->setTextColor(Qt::gray);
     hiddenText->setFontPointSize(16);
@@ -70,6 +73,7 @@
     vbox->addWidget(entryWithProperties);
     vbox->addWidget(translucencyCheckBox);
     vbox->addWidget(preferNumbersCheckBox);
+    vbox->addWidget(suppressionCheckBox);
     vbox->addStretch();
     vbox->addWidget(hiddenText);
 
@@ -79,6 +83,9 @@
     connect(preferNumbersCheckBox, SIGNAL(toggled(bool)),
             this,                  SLOT(onPreferNumbersToggled(bool)));
 
+    connect(suppressionCheckBox, SIGNAL(toggled(bool)),
+            this,                SLOT(onSuppressionToggled(bool)));
+
     QPushButton *closeApp = new QPushButton("Close application");
     vbox->addWidget(closeApp);
     connect(closeApp, SIGNAL(clicked()),
@@ -109,4 +116,12 @@
     if (QInputContext *ic = qApp->inputContext()) {
         ic->update();
     }
+}
+
+void MainWindow::onSuppressionToggled(bool value)
+{
+    entryWithProperties->setProperty(Maliit::InputMethodQuery::suppressInputMethod, QVariant(value));
+    if (QInputContext *ic = qApp->inputContext()) {
+        ic->update();
+    }
 }
--- examples/apps/widgetproperties/mainwindow.h
+++ examples/apps/widgetproperties/mainwindow.h
@@ -18,6 +18,7 @@
     MainWindow();
     Q_SLOT void onTranslucencyToggled(bool value);
     Q_SLOT void onPreferNumbersToggled(bool value);
+    Q_SLOT void onSuppressionToggled(bool value);
 };
 
 #endif // MAINWINDOW_H
--- examples/apps/widgetproperties/widgetproperties.pro
+++ examples/apps/widgetproperties/widgetproperties.pro
@@ -1,8 +1,5 @@
-include(../../../config.pri)
-
 TEMPLATE = app
 TARGET = maliit-exampleapp-widgetproperties
-target.path = $$M_IM_INSTALL_BIN
 DEPENDPATH += .
 
 BUILD_TYPE = unittest
@@ -14,6 +11,9 @@
 }
 
 contains(BUILD_TYPE, unittest) {
+    include(../../../config.pri)
+    target.path = $$M_IM_INSTALL_BIN
+    INSTALLS += target
 
     # Used for testing purposes, can be deleted when used as a project skeleton
     # Build against in-tree libs
@@ -36,5 +36,4 @@
 
 QT += core gui
 
-INSTALLS += target
 QMAKE_CLEAN += target
--- examples/plugins/qml/cyclekeys/cyclekeys.pro
+++ examples/plugins/qml/cyclekeys/cyclekeys.pro
@@ -42,7 +42,7 @@
 
     INCLUDEPATH += $$TOP_DIR
 
-    QUICK_DIR = $$TOP_DIR/input-method-quick
+    QUICK_DIR = $$TOP_DIR/maliit-plugins-quick/input-method
     LIBS += $$QUICK_DIR/lib$${MALIIT_PLUGINS_QUICK_LIB}.so
     INCLUDEPATH += $$QUICK_DIR
 
--- examples/plugins/qml/helloworld/helloworld.pro
+++ examples/plugins/qml/helloworld/helloworld.pro
@@ -1,19 +1,5 @@
-TEMPLATE = lib
-TARGET = qmlhelloworldplugin
-
-OBJECTS_DIR = .obj
-MOC_DIR = .moc
-
-CONFIG += debug plugin
-QT = core gui declarative
-
-SOURCES += helloworldplugin.cpp
-HEADERS += helloworldplugin.h
-RESOURCES = helloworld.qrc
-target.depends = $$IN_PWD/helloworld.qml
-
-OTHER_FILES += \
-    helloworld.qml \
+TEMPLATE = app
+TARGET = helloworld.qml
 
 BUILD_TYPE = unittest
 
@@ -21,12 +7,11 @@
     CONFIG += link_pkgconfig
     PKGCONFIG += maliit-plugins-quick-0.80
     target.path += $$system(pkg-config --variable pluginsdir maliit-plugins-0.80)
-    INCLUDEPATH += $$system(pkg-config --cflags maliit-plugins-quick-0.80 | tr \' \' \'\\n\' | grep ^-I | cut -d I -f 2-)
     INSTALLS += target
 }
 
 contains(BUILD_TYPE, skeleton-legacy) {
-    CONFIG += meegoimframework meegoimquick
+    CONFIG += meegoimframework
     target.path += $$system(pkg-config --variable pluginsdir MeegoImFramework)
     INSTALLS += target
 }
@@ -38,18 +23,6 @@
 
     include($$TOP_DIR/config.pri)
 
-    INCLUDEPATH += $$TOP_DIR
-
-    QUICK_DIR = $$TOP_DIR/input-method-quick
-    LIBS += $$QUICK_DIR/lib$${MALIIT_PLUGINS_QUICK_LIB}.so
-    INCLUDEPATH += $$QUICK_DIR
-
-    SRC_DIR = $$TOP_DIR/src
-    LIBS += $$SRC_DIR/lib$${MALIIT_PLUGINS_LIB}.so
-    INCLUDEPATH += $$SRC_DIR $$TOP_DIR/common
-
     target.path += $$MALIIT_TEST_PLUGINS_DIR/examples/qml/helloworld
     INSTALLS += target
 }
-
-QMAKE_CLEAN += libqmlhelloworldplugin.so
--- examples/plugins/qml/helloworld/helloworld.qrc
+++ examples/plugins/qml/helloworld/helloworld.qrc
-<RCC>
-  <qresource prefix="/">
-    <file>helloworld.qml</file>
-  </qresource>
-</RCC>
--- examples/plugins/qml/helloworld/helloworldplugin.cpp
+++ examples/plugins/qml/helloworld/helloworldplugin.cpp
-/* * This file is part of meego-im-framework *
- *
- * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
- * All rights reserved.
- * Contact: Nokia Corporation (directui at nokia.com)
- *
- * If you have questions regarding the use of this file, please contact
- * Nokia at directui at nokia.com.
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License version 2.1 as published by the Free Software Foundation
- * and appearing in the file LICENSE.LGPL included in the packaging
- * of this file.
- */
-
-#include "helloworldplugin.h"
-
-#include <minputmethodquickplugin.h>
-
-#include <QString>
-#include <QDebug>
-
-namespace
-{
-    const char * const filePath = "qrc:/helloworld.qml";
-    const char * const pluginName = "HelloWorldPlugin";
-}
-
-HelloWorldPlugin::HelloWorldPlugin()
-{
-    Q_INIT_RESOURCE(helloworld);
-}
-
-QString HelloWorldPlugin::name() const
-{
-    return pluginName;
-}
-
-QString HelloWorldPlugin::qmlFileName() const
-{
-    return filePath;
-}
-
-Q_EXPORT_PLUGIN2(qmlhelloworldplugin, HelloWorldPlugin)
--- examples/plugins/qml/helloworld/helloworldplugin.h
+++ examples/plugins/qml/helloworld/helloworldplugin.h
-/* * This file is part of meego-im-framework *
- *
- * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
- * All rights reserved.
- * Contact: Nokia Corporation (directui at nokia.com)
- *
- * If you have questions regarding the use of this file, please contact
- * Nokia at directui at nokia.com.
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License version 2.1 as published by the Free Software Foundation
- * and appearing in the file LICENSE.LGPL included in the packaging
- * of this file.
- */
-
-#ifndef HELLO_WORLD_PLUGIN_H
-#define HELLO_WORLD_PLUGIN_H
-
-#include <minputmethodquickplugin.h>
-#include <QObject>
-
-class HelloWorldPlugin
-     : public QObject, public MInputMethodQuickPlugin
-{
-    Q_OBJECT
-    Q_INTERFACES(MInputMethodQuickPlugin MInputMethodPlugin)
-public:
-    HelloWorldPlugin();
-    //! \reimpl
-    virtual QString name() const;
-    virtual QString qmlFileName() const;
-    //! \reimpl_end
-};
-
-#endif // HELLO_WORLD_PLUGIN_H
--- examples/plugins/qml/override/override.pro
+++ examples/plugins/qml/override/override.pro
@@ -40,7 +40,7 @@
 
     INCLUDEPATH += $$TOP_DIR
 
-    QUICK_DIR = $$TOP_DIR/input-method-quick
+    QUICK_DIR = $$TOP_DIR/maliit-plugins-quick/input-method
     LIBS += $$QUICK_DIR/lib$${MALIIT_PLUGINS_QUICK_LIB}.so
     INCLUDEPATH += $$QUICK_DIR
 
--- gtk-input-context/client-gtk/client-gtk.pro
+++ gtk-input-context/client-gtk/client-gtk.pro
@@ -4,7 +4,7 @@
 TARGET = im-maliit
 
 CONFIG += link_pkgconfig
-PKGCONFIG += gtk+-2.0
+PKGCONFIG += gtk+-2.0 gio-2.0
 PKGCONFIG += glib-2.0 gthread-2.0 dbus-glib-1 # FIXME: should not be needed
 
 debug{
@@ -38,6 +38,7 @@
     isEqual(DISTRO, Ubuntu) {
         update-im-cache.path = $$GTK2_DIR/
         update-im-cache.extra = gtk-query-immodules-2.0 > $$GTK2_DIR/gtk.immodules
+        update-im-cache.uninstall = gtk-query-immodules-2.0 > $$GTK2_DIR/gtk.immodules
 
         INSTALLS *= update-im-cache
     }
@@ -46,6 +47,7 @@
     system(test -e /etc/fedora-release) {
         update-im-cache.path = $$GTK3_DIR/
         update-im-cache.extra = update-gtk-immodules $$HOST
+        update-im-cache.uninstall = update-gtk-immodules $$HOST
 
         INSTALLS *= update-im-cache
     }
--- gtk-input-context/client-gtk3/client-gtk3.pro
+++ gtk-input-context/client-gtk3/client-gtk3.pro
@@ -4,7 +4,7 @@
 TARGET = im-maliit
 
 CONFIG += link_pkgconfig
-PKGCONFIG += gtk+-3.0
+PKGCONFIG += gtk+-3.0 gio-2.0
 PKGCONFIG += glib-2.0 gthread-2.0 dbus-glib-1 # FIXME: should not be needed
 
 debug{
@@ -38,16 +38,20 @@
     isEqual(DISTRO, Ubuntu) {
         update-im-cache.path = $$GTK3_DIR/
         update-im-cache.extra = gtk-query-immodules-3.0 > $$GTK3_DIR/immodules.cache
+        update-im-cache.uninstall = gtk-query-immodules-3.0 > $$GTK3_DIR/immodules.cache
 
         INSTALLS *= update-im-cache
     }
 
     system(test -e /etc/fedora-release) {
         update-im-cache.path = $$GTK3_DIR/
-        contains(GTK3_IM_LIBDIR, lib64) {
+        64bit = $$find(GTK3_IM_LIBDIR, lib64)
+        !isEmpty(64bit) {
             update-im-cache.extra = gtk-query-immodules-3.0-64 > $$GTK3_DIR/immodules.cache
+            update-im-cache.uninstall = gtk-query-immodules-3.0-64 > $$GTK3_DIR/immodules.cache
         } else {
             update-im-cache.extra = gtk-query-immodules-3.0-32 > $$GTK3_DIR/immodules.cache
+            update-im-cache.uninstall = gtk-query-immodules-3.0-32 > $$GTK3_DIR/immodules.cache
         }
 
         INSTALLS *= update-im-cache
--- gtk-input-context/gtk-input-context.pro
+++ gtk-input-context/gtk-input-context.pro
@@ -1,6 +1,7 @@
 include(../config.pri)
 
 TEMPLATE = subdirs
+CONFIG += ordered
 
 system(pkg-config gtk+-2.0) {
     SUBDIRS *= src
--- gtk-input-context/src/meego-im-connector.c
+++ gtk-input-context/src/meego-im-connector.c
@@ -17,8 +17,12 @@
 #include "meego-im-connector.h"
 
 #include <glib.h>
+#include <gio/gio.h>
 
-#define MEEGO_IM_SOCKET_PATH "unix:path=/tmp/meego-im-uiserver/imserver_dbus"
+#define MALIIT_SERVER_NAME "org.maliit.server"
+#define MALIIT_SERVER_OBJECT_PATH "/org/maliit/server/address"
+#define MALIIT_SERVER_INTERFACE "org.maliit.Server.Address"
+#define MALIIT_SERVER_ADDRESS_PROPERTY "address"
 
 MeegoImConnector *meego_im_connector_new();
 
@@ -39,6 +43,34 @@
     try_reconnect(connector);
 }
 
+static char *
+get_dbus_address()
+{
+    GDBusProxy *proxy = g_dbus_proxy_new_for_bus_sync(G_BUS_TYPE_SESSION,
+                                                      G_DBUS_PROXY_FLAGS_NONE,
+                                                      0,
+                                                      MALIIT_SERVER_NAME,
+                                                      MALIIT_SERVER_OBJECT_PATH,
+                                                      MALIIT_SERVER_INTERFACE,
+                                                      0, 0);
+
+    if (!proxy)
+        return 0;
+
+    GVariant *variant = g_dbus_proxy_get_cached_property(proxy, MALIIT_SERVER_ADDRESS_PROPERTY);
+
+    if (!variant) {
+        g_object_unref(proxy);
+        return 0;
+    }
+
+    char* address = g_strdup(g_variant_get_string(variant, 0));
+
+    g_variant_unref(variant);
+    g_object_unref(proxy);
+
+    return address;
+}
 
 /**
  * MeegoImConnector:
@@ -94,7 +126,16 @@
 
     g_return_if_fail(self != NULL);
 
-    connection = dbus_g_connection_open(MEEGO_IM_SOCKET_PATH, &error);
+    char *address = get_dbus_address();
+    if (!address) {
+        g_warning("Couldn't connect to Maliit server. Retrying...");
+
+        g_timeout_add_seconds(2, (GSourceFunc)try_reconnect, self);
+        return;
+    }
+
+    connection = dbus_g_connection_open(address, &error);
+    g_free(address);
 
     if (error != NULL) {
         g_warning("Couldn't connect to Maliit server. Retrying...");
--- input-context/glibdbusimserverproxy.cpp
+++ input-context/glibdbusimserverproxy.cpp
@@ -17,8 +17,6 @@
 #include "glibdbusimserverproxy.h"
 #include "mdbusglibinputcontextadaptor.h"
 
-#include "minputcontext.h"
-
 #include <QPoint>
 #include <QRect>
 #include <QString>
@@ -31,12 +29,10 @@
 #include <unistd.h>
 #include <sys/types.h>
 
-
 namespace
 {
     const char * const DBusPath("/com/meego/inputmethod/uiserver1");
     const char * const DBusInterface("com.meego.inputmethod.uiserver1");
-    const char * const SocketPath = "unix:path=/tmp/meego-im-uiserver/imserver_dbus";
     const int ConnectionRetryInterval(6*1000); // in ms
     const QString icAdaptorPath("/com/meego/inputmethod/inputcontext");
 
@@ -139,12 +135,33 @@
         }
         return result;
     }
+
+
+    static bool debugEnabled()
+    {
+        static bool enabled = false;
+        static bool initialized = false;
+
+        if (initialized) {
+            return enabled;
+        }
+
+        QByteArray debugEnvVar = qgetenv("MIC_ENABLE_DEBUG");
+        if (!debugEnvVar.isEmpty() && debugEnvVar != "false") {
+            enabled = true;
+        }
+
+        initialized = true;
+        return enabled;
+    }
+
 }
 
 GlibDBusIMServerProxy::GlibDBusIMServerProxy(QObject *parent)
     : glibObjectProxy(NULL),
       connection(),
-      active(true)
+      active(true),
+      mAddress(new Maliit::InputContext::DBus::Address)
 {
     Q_UNUSED(parent);
 
@@ -175,17 +192,23 @@
 
 void GlibDBusIMServerProxy::onDisconnectionTrampoline(DBusGProxy */*proxy*/, gpointer userData)
 {
-    if (MInputContext::debug) qDebug() << "MInputContext" << __PRETTY_FUNCTION__;
+    if (debugEnabled()) qDebug() << "MInputContext" << __PRETTY_FUNCTION__;
     static_cast<GlibDBusIMServerProxy *>(userData)->onDisconnection();
 }
 
 void GlibDBusIMServerProxy::connectToDBus()
 {
-    if (MInputContext::debug) qDebug() << "MInputContext" << __PRETTY_FUNCTION__;
+    if (debugEnabled()) qDebug() << "MInputContext" << __PRETTY_FUNCTION__;
 
     GError *error = NULL;
 
-    connection = toRef(dbus_g_connection_open(SocketPath, &error));
+    const std::string &address = mAddress->get();
+    if (address.empty()) {
+        QTimer::singleShot(ConnectionRetryInterval, this, SLOT(connectToDBus()));
+        return;
+    }
+
+    connection = toRef(dbus_g_connection_open(address.c_str(), &error));
     if (!connection) {
         if (error) {
             qWarning("MInputContext: unable to create D-Bus connection: %s", error->message);
@@ -212,7 +235,7 @@
 
 void GlibDBusIMServerProxy::onDisconnection()
 {
-    if (MInputContext::debug) qDebug() << "MInputContext" << __PRETTY_FUNCTION__;
+    if (debugEnabled()) qDebug() << "MInputContext" << __PRETTY_FUNCTION__;
 
     glibObjectProxy = 0;
     connection.reset();
@@ -231,7 +254,7 @@
 
 void GlibDBusIMServerProxy::resetNotify(DBusGProxy *proxy, DBusGProxyCall *callId)
 {
-    if (MInputContext::debug) qDebug() << "MInputContext" << __PRETTY_FUNCTION__;
+    if (debugEnabled()) qDebug() << "MInputContext" << __PRETTY_FUNCTION__;
 
     dbus_g_proxy_end_call(proxy, callId, 0, G_TYPE_INVALID);
     pendingResetCalls.remove(callId);
--- input-context/glibdbusimserverproxy.h
+++ input-context/glibdbusimserverproxy.h
@@ -27,6 +27,7 @@
 
 #include "mimserverconnection.h"
 #include "minputcontext.h"
+#include "inputcontextdbusaddress.h"
 
 namespace Maliit
 {
@@ -108,6 +109,7 @@
     GObject *inputContextAdaptor;
     bool active;
     QSet<DBusGProxyCall *> pendingResetCalls;
+    const std::tr1::shared_ptr<Maliit::InputContext::DBus::Address> mAddress;
 };
 
 #endif
--- input-context/input-context.pro
+++ input-context/input-context.pro
@@ -23,19 +23,21 @@
     mdbusglibinputcontextadaptor.h \
     glibdbusimserverproxy.h \
     mimserverconnection.h \
+    inputcontextdbusaddress.h \
 
 SOURCES += minputcontext.cpp \
     minputcontextplugin.cpp \
     mdbusglibinputcontextadaptor.cpp \
     glibdbusimserverproxy.cpp \
     mimserverconnection.cpp \
+    inputcontextdbusaddress.cpp \
 
 OTHER_FILES += minputmethodcontext1interface.xml
 
 QT = core gui
 CONFIG += plugin link_pkgconfig
 
-PKGCONFIG += dbus-glib-1
+PKGCONFIG += dbus-glib-1 gio-2.0
 
 # coverage flags are off per default, but can be turned on via qmake COV_OPTION=on
 for(OPTION,$$list($$lower($$COV_OPTION))){
--- input-context/inputcontextdbusaddress.cpp
+++ input-context/inputcontextdbusaddress.cpp
+/* * This file is part of meego-im-framework *
+ *
+ * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+ * All rights reserved.
+ * Contact: Nokia Corporation (directui at nokia.com)
+ *
+ * If you have questions regarding the use of this file, please contact
+ * Nokia at directui at nokia.com.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1 as published by the Free Software Foundation
+ * and appearing in the file LICENSE.LGPL included in the packaging
+ * of this file.
+ */
+
+#include "inputcontextdbusaddress.h"
+
+#include <gio/gio.h>
+#include <tr1/memory>
+#include <tr1/functional>
+#include <QDebug>
+
+namespace {
+    const char * const MaliitServerName = "org.maliit.server";
+    const char * const MaliitServerObjectPath = "/org/maliit/server/address";
+    const char * const MaliitServerInterface = "org.maliit.Server.Address";
+    const char * const MaliitServerAddressProperty = "address";
+
+    template<typename T>
+    class SafeUnref {
+    public:
+        explicit SafeUnref(std::tr1::function<void (T*)>unref)
+            : mUnref(unref)
+        {}
+
+        void operator()(T* t)
+        {
+            if (t)
+                mUnref(t);
+        }
+
+    private:
+        std::tr1::function<void (T*)> mUnref;
+    };
+}
+
+namespace Maliit {
+namespace InputContext {
+namespace DBus {
+
+Address::Address()
+{
+}
+
+const std::string Address::get() const
+{
+    GError *error = NULL;
+    std::tr1::shared_ptr<GDBusProxy> proxy(g_dbus_proxy_new_for_bus_sync(G_BUS_TYPE_SESSION,
+                                                                         G_DBUS_PROXY_FLAGS_NONE,
+                                                                         0,
+                                                                         MaliitServerName,
+                                                                         MaliitServerObjectPath,
+                                                                         MaliitServerInterface,
+                                                                         0, &error),
+                                           SafeUnref<GDBusProxy>(g_object_unref));
+
+    if (!proxy) {
+        qWarning() << __PRETTY_FUNCTION__ << error->message;
+        g_error_free(error);
+        return std::string();
+    }
+
+    std::tr1::shared_ptr<GVariant> address(g_dbus_proxy_get_cached_property(proxy.get(), MaliitServerAddressProperty),
+                                           SafeUnref<GVariant>(g_variant_unref));
+
+    if (!address) {
+        return std::string();
+    }
+
+    std::string result(g_variant_get_string(address.get(), 0));
+
+    return result;
+}
+
+} // namespace DBus
+} // namespace InputContext
+} // namespace Maliit
--- input-context/inputcontextdbusaddress.h
+++ input-context/inputcontextdbusaddress.h
+/* * This file is part of meego-im-framework *
+ *
+ * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+ * All rights reserved.
+ * Contact: Nokia Corporation (directui at nokia.com)
+ *
+ * If you have questions regarding the use of this file, please contact
+ * Nokia at directui at nokia.com.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1 as published by the Free Software Foundation
+ * and appearing in the file LICENSE.LGPL included in the packaging
+ * of this file.
+ */
+
+#ifndef MALIIT_INPUTCONTEXT_DBUS_INPUTCONTEXTDBUSADDRESS_H
+#define MALIIT_INPUTCONTEXT_DBUS_INPUTCONTEXTDBUSADDRESS_H
+
+#include <string>
+
+namespace Maliit {
+namespace InputContext {
+namespace DBus {
+
+class Address
+{
+public:
+    explicit Address();
+    virtual const std::string get() const;
+};
+
+} // namespace DBus
+} // namespace InputContext
+} // namespace Maliit
+
+#endif // MALIIT_INPUTCONTEXT_DBUS_INPUTCONTEXTDBUSADDRESS_H
--- input-context/mdbusglibinputcontextadaptor.cpp
+++ input-context/mdbusglibinputcontextadaptor.cpp
@@ -19,8 +19,6 @@
 
 #include <minputmethodnamespace.h>
 
-#include <QDebug>
-
 G_DEFINE_TYPE(MDBusGlibInputContextAdaptor, m_dbus_glib_input_context_adaptor, G_TYPE_OBJECT)
 
 
--- input-context/minputcontext.cpp
+++ input-context/minputcontext.cpp
@@ -52,6 +52,45 @@
     const char * const ToolbarTarget("/toolbar");
     const char * const InputContextName(MALIIT_INPUTCONTEXT_NAME);
 
+    //! Extracts a dynamic QObject property from obj, using normalization rules
+    //! for propertyName (eases mapping of QML properties to QObject
+    //! properties). Valid property names start with "maliit-"
+    QVariant extractProperty(const QObject *obj,
+                             const char * const propertyName)
+    {
+        static const QByteArray prefix("maliit-");
+        const QByteArray name(propertyName);
+
+        if (not obj || not name.startsWith(prefix)) {
+            qCritical() << __PRETTY_FUNCTION__
+                        << "Ignoring invalid object or invalid propertyName "
+                        << propertyName;
+            return QVariant();
+        }
+
+        QVariant result = obj->property(name);
+
+        if (not result.isValid()) {
+            QByteArray camelCased;
+            bool turnUp = false;
+
+            // Function guard guarantees that properyName starts with "maliit-".
+            for (int idx = prefix.length(); idx < name.length(); ++idx) {
+                const QChar curr = name.at(idx);
+                if (curr == '-') {
+                    turnUp = true;
+                } else {
+                    camelCased.append(turnUp ? curr.toUpper() : curr);
+                    turnUp = false;
+                }
+            }
+
+            result = obj->property(camelCased);
+        }
+
+        return result;
+    }
+
 #ifdef Q_WS_X11
     enum {
         XKeyPress = KeyPress,
@@ -1021,14 +1060,26 @@
 
     QVariant queryResult;
 
-    queryResult = focused->inputMethodQuery(
-        static_cast<Qt::InputMethodQuery>(MInputMethod::VisualizationPriorityQuery));
+    // Extract suppressInputMethod (formerly known as VisualizationPriorityQuery):
+    queryResult = extractProperty(focused, Maliit::InputMethodQuery::suppressInputMethod);
+
+    if (!queryResult.isValid()) {
+        if (focusedObject) {
+            queryResult = extractProperty(focusedObject, Maliit::InputMethodQuery::suppressInputMethod);
+        }
+
+        if (!queryResult.isValid()) {
+
+            queryResult = focused->inputMethodQuery(
+                        static_cast<Qt::InputMethodQuery>(MInputMethod::VisualizationPriorityQuery));
+        }
+    }
 
     if (queryResult.isValid()) {
         stateInformation["visualizationPriority"] = queryResult.toBool();
     }
 
-    queryResult = focused->property(Maliit::InputMethodQuery::attributeExtensionId);
+    queryResult = extractProperty(focused, Maliit::InputMethodQuery::attributeExtensionId);
 
     if (!queryResult.isValid()) {
         if (focusedObject) {
@@ -1037,7 +1088,7 @@
             queryResult = focusedObject->property("meego-inputmethod-attribute-extension-id");
 
             if (!queryResult.isValid()) {
-                queryResult = focusedObject->property(Maliit::InputMethodQuery::attributeExtensionId);
+                queryResult = extractProperty(focusedObject, Maliit::InputMethodQuery::attributeExtensionId);
             }
         }
 
@@ -1052,7 +1103,7 @@
     }
 
     // toolbar file
-    queryResult = focused->property(Maliit::InputMethodQuery::attributeExtension);
+    queryResult = extractProperty(focused, Maliit::InputMethodQuery::attributeExtension);
 
     if (!queryResult.isValid())
     {
@@ -1154,12 +1205,13 @@
     // 3. focusWidget()->inputMethodQuery(.),
     // Ensures that plain Qt and Qt Comoponents can readily use this override,
     // as neither of them implement a Maliit-specific IM query.
-    queryResult = focused->property(Maliit::InputMethodQuery::westernNumericInputEnforced);
+    queryResult = extractProperty(focused, Maliit::InputMethodQuery::westernNumericInputEnforced);
 
     if (!queryResult.isValid())
     {
        if (focusedObject) {
-            queryResult = focusedObject->property(Maliit::InputMethodQuery::westernNumericInputEnforced);
+            queryResult = extractProperty(focusedObject,
+                                          Maliit::InputMethodQuery::westernNumericInputEnforced);
         }
 
         if (!queryResult.isValid()) {
@@ -1170,12 +1222,12 @@
 
     stateInformation[Maliit::InputMethodQuery::westernNumericInputEnforced] = queryResult.toBool();
 
-    queryResult = focused->property(Maliit::InputMethodQuery::translucentInputMethod);
+    queryResult = extractProperty(focused, Maliit::InputMethodQuery::translucentInputMethod);
 
     if (!queryResult.isValid())
     {
        if (focusedObject) {
-            queryResult = focusedObject->property(Maliit::InputMethodQuery::translucentInputMethod);
+            queryResult = extractProperty(focusedObject, Maliit::InputMethodQuery::translucentInputMethod);
         }
     }
 
--- input-method-quick
+++ input-method-quick
-(directory)
--- input-method-quick/input-method-quick.pro
+++ input-method-quick/input-method-quick.pro
-include(../config.pri)
-
-VERSION = 0.1.0
-TEMPLATE = lib
-TARGET = $$MALIIT_PLUGINS_QUICK_LIB
-INCLUDEPATH += .. ../src ../common
-
-# Input
-HEADERSINSTALL = \
-        minputmethodquickplugin.h \
-        minputmethodquick.h \
-        maliitquick.h \
-        mkeyoverridequick.h
-
-HEADERS += $$HEADERSINSTALL \
-        mkeyoverridequick_p.h
-
-SOURCES += \
-        minputmethodquickplugin.cpp \
-        minputmethodquick.cpp \
-        mkeyoverridequick.cpp
-
-QT = core gui xml declarative
-
-# coverage flags are off per default, but can be turned on via qmake COV_OPTION=on
-for(OPTION,$$list($$lower($$COV_OPTION))){
-    isEqual(OPTION, on){
-        QMAKE_CXXFLAGS += -ftest-coverage -fprofile-arcs -fno-elide-constructors
-        LIBS += -lgcov
-    }
-}
-
-target.path += $$M_IM_INSTALL_LIBS
-
-OBJECTS_DIR = .obj
-MOC_DIR = .moc
-
-QMAKE_CLEAN += $$OBJECTS_DIR/*.gcno $$OBJECTS_DIR/*.gcda
-
-headers.path += $$M_IM_INSTALL_HEADERS/$$MALIIT_PLUGINS_QUICK_HEADER
-headers.files += $$HEADERSINSTALL
-
-!enable-legacy {
-    outputFiles(maliit-plugins-quick-$${MALIIT_PLUGINS_QUICK_INTERFACE_VERSION}.pc)
-} else {
-    outputFiles(meegoimquick.prf)
-}
-
-install_prf.path = $$[QT_INSTALL_DATA]/mkspecs/features
-install_prf.files = $$OUT_PWD/meegoimquick.prf
-
-install_pkgconfig.path = $${M_IM_INSTALL_LIBS}/pkgconfig
-install_pkgconfig.files = $$OUT_PWD/maliit-plugins-quick-$${MALIIT_PLUGINS_QUICK_INTERFACE_VERSION}.pc
-
-INSTALLS += target \
-    headers \
-    install_prf \
-    install_pkgconfig \
-
-QMAKE_EXTRA_TARGETS += check
-check.target = check
-check.depends += lib$${TARGET}.so.$${VERSION}
--- input-method-quick/maliit-plugins-quick-0.80.pc.in
+++ input-method-quick/maliit-plugins-quick-0.80.pc.in
(renamed to maliit-plugins-quick/input-method/maliit-plugins-quick-0.80.pc.in)
--- input-method-quick/maliitquick.h
+++ input-method-quick/maliitquick.h
(renamed to maliit-plugins-quick/input-method/maliitquick.h)
--- input-method-quick/meegoimquick.prf.in
+++ input-method-quick/meegoimquick.prf.in
(renamed to maliit-plugins-quick/input-method/meegoimquick.prf.in)
--- input-method-quick/minputmethodquick.cpp
+++ input-method-quick/minputmethodquick.cpp
(renamed to maliit-plugins-quick/input-method/minputmethodquick.cpp)
--- input-method-quick/minputmethodquick.h
+++ input-method-quick/minputmethodquick.h
(renamed to maliit-plugins-quick/input-method/minputmethodquick.h)
--- input-method-quick/minputmethodquickplugin.cpp
+++ input-method-quick/minputmethodquickplugin.cpp
(renamed to maliit-plugins-quick/input-method/minputmethodquickplugin.cpp)
--- input-method-quick/minputmethodquickplugin.h
+++ input-method-quick/minputmethodquickplugin.h
(renamed to maliit-plugins-quick/input-method/minputmethodquickplugin.h)
--- input-method-quick/mkeyoverridequick.cpp
+++ input-method-quick/mkeyoverridequick.cpp
(renamed to maliit-plugins-quick/input-method/mkeyoverridequick.cpp)
--- input-method-quick/mkeyoverridequick.h
+++ input-method-quick/mkeyoverridequick.h
(renamed to maliit-plugins-quick/input-method/mkeyoverridequick.h)
--- input-method-quick/mkeyoverridequick_p.h
+++ input-method-quick/mkeyoverridequick_p.h
(renamed to maliit-plugins-quick/input-method/mkeyoverridequick_p.h)
--- maliit-framework.pro
+++ maliit-framework.pro
@@ -6,12 +6,14 @@
         Important build options: \
         \\n\\t M_IM_PREFIX : Install prefix (default: /usr) \
         \\n\\t M_IM_INSTALL_{BIN,LIBS,HEADERS,SCHEMAS,DOCS} : Install prefix for specific types of files \
+        \\n\\t MALIIT_SERVER_ARGUMENTS : Arguments to use for starting maliit-server by D-Bus activation \
         \\nRecognised CONFIG flags: \
         \\n\\t enable-legacy : Build in legacy mode (for meego-im ABI/API compatability) \
         \\n\\t enable-meegotouch : Link input context to libmeegotouch for a MApplicationPage hack \
         \\n\\t enable-contextkit : Build contextkit support (for monitoring hardware keyboard status) \
         \\n\\t notests : Do not build tests \
-        \\n\\t nodoc : Do not build documentation \
+        \\n\\t nosdk : Do not build Maliit SDK \
+        \\n\\t nodoc : Do not build documentation (also disables SDK) \
         \\n\\t only-libmaliit : Only build libmaliit \
         \\n\\t external-libmaliit : Use external libmaliit (do not build libmaliit) \
         \\n\\t disable-gtk-cache-update : Do not update GTK2/3 input method caches \
@@ -44,12 +46,16 @@
 }
 
 !only-libmaliit {
-    SUBDIRS += common input-context gtk-input-context input-method-quick examples
+    SUBDIRS += common input-context gtk-input-context maliit-plugins-quick examples
 
     !nodoc {
         SUBDIRS += doc
     }
 
+    !nosdk:!nodoc {
+        SUBDIRS += sdk
+    }
+
     !notests {
         SUBDIRS += tests
     }
@@ -65,4 +71,15 @@
 check.target = check
 check.CONFIG = recursive
 
+DIST_NAME = $$MALIIT_PACKAGENAME-$$MALIIT_VERSION
+DIST_PATH = $$OUT_PWD/$$DIST_NAME
+TARBALL_SUFFIX = .tar.bz2
+TARBALL_PATH = $$DIST_PATH$$TARBALL_SUFFIX
+
+# The 'make dist' target
+# Creates a tarball
+QMAKE_EXTRA_TARGETS += dist
+dist.target = dist
+dist.commands += git archive HEAD --prefix=$$DIST_NAME/ | bzip2 > $$TARBALL_PATH
+
 OTHER_FILES += NEWS README
--- maliit-plugin-sdk-dist.sh
+++ maliit-plugin-sdk-dist.sh
-#!/bin/bash
-
-### This script creates a tarball of the Maliit Plugin SDK for distribution
-
-# TODO: 
-# - a way to track which version of the framework the sdk is for
-# - some sort of distcheck like option, that takes the resulting tarball
-# and tries to compile it against the currently installed version
-# - put into the build system?
-VERSION=0.2.0
-
-EXAMPLES_PATH=./examples
-DOC_PATH=./doc/html
-OUT_PATH=./maliit-plugin-sdk
-SDK_FILE_PATH=./maliit-plugin-sdk-$VERSION.tar.gz
-
-rm -r $OUT_PATH
-mkdir -p $OUT_PATH/{documentation,examples}
-
-# Examples
-cp -r $EXAMPLES_PATH $OUT_PATH/
-cd $OUT_PATH/examples
-sed -i -e s/"^BUILD_TYPE.*=.*"/"BUILD_TYPE = skeleton"/ `grep -r --files-with-matches BUILD_TYPE ./ | tr "\n" " "`
-make clean
-find ./ -name Makefile -exec rm {} \;
-rm README
-cd -
-
-# Documentation
-cp -r $DOC_PATH $OUT_PATH/documentation
-
-# Pack
-tar -acf $SDK_FILE_PATH $OUT_PATH
-
--- maliit-plugins-quick
+++ maliit-plugins-quick
+(directory)
--- maliit-plugins-quick/input-method
+++ maliit-plugins-quick/input-method
+(directory)
--- maliit-plugins-quick/input-method/input-method.pro
+++ maliit-plugins-quick/input-method/input-method.pro
+include(../../config.pri)
+
+VERSION = 0.1.0
+TEMPLATE = lib
+TARGET = $$MALIIT_PLUGINS_QUICK_LIB
+INCLUDEPATH_BASE = ../..
+INCLUDEPATH += \
+        $${INCLUDEPATH_BASE} \
+        $${INCLUDEPATH_BASE}/src \
+        $${INCLUDEPATH_BASE}/common \
+
+# Input
+HEADERSINSTALL = \
+        minputmethodquickplugin.h \
+        minputmethodquick.h \
+        maliitquick.h \
+        mkeyoverridequick.h
+
+HEADERS += $$HEADERSINSTALL \
+        mkeyoverridequick_p.h
+
+SOURCES += \
+        minputmethodquickplugin.cpp \
+        minputmethodquick.cpp \
+        mkeyoverridequick.cpp
+
+QT = core gui xml declarative
+
+# coverage flags are off per default, but can be turned on via qmake COV_OPTION=on
+for(OPTION,$$list($$lower($$COV_OPTION))){
+    isEqual(OPTION, on){
+        QMAKE_CXXFLAGS += -ftest-coverage -fprofile-arcs -fno-elide-constructors
+        LIBS += -lgcov
+    }
+}
+
+target.path += $$M_IM_INSTALL_LIBS
+
+OBJECTS_DIR = .obj
+MOC_DIR = .moc
+
+QMAKE_CLEAN += $$OBJECTS_DIR/*.gcno $$OBJECTS_DIR/*.gcda
+
+headers.path += $$M_IM_INSTALL_HEADERS/$$MALIIT_PLUGINS_QUICK_HEADER
+headers.files += $$HEADERSINSTALL
+
+!enable-legacy {
+    outputFiles(maliit-plugins-quick-$${MALIIT_PLUGINS_QUICK_INTERFACE_VERSION}.pc)
+} else {
+    outputFiles(meegoimquick.prf)
+}
+
+install_prf.path = $$[QT_INSTALL_DATA]/mkspecs/features
+install_prf.files = $$OUT_PWD/meegoimquick.prf
+
+install_pkgconfig.path = $${M_IM_INSTALL_LIBS}/pkgconfig
+install_pkgconfig.files = $$OUT_PWD/maliit-plugins-quick-$${MALIIT_PLUGINS_QUICK_INTERFACE_VERSION}.pc
+
+INSTALLS += target \
+    headers \
+    install_prf \
+    install_pkgconfig \
+
+QMAKE_EXTRA_TARGETS += check
+check.target = check
+check.depends += lib$${TARGET}.so.$${VERSION}
--- maliit-plugins-quick/input-method/maliit-plugins-quick-0.80.pc.in
+++ maliit-plugins-quick/input-method/maliit-plugins-quick-0.80.pc.in
(renamed from input-method-quick/maliit-plugins-quick-0.80.pc.in)
--- maliit-plugins-quick/input-method/maliitquick.h
+++ maliit-plugins-quick/input-method/maliitquick.h
(renamed from input-method-quick/maliitquick.h)
--- maliit-plugins-quick/input-method/meegoimquick.prf.in
+++ maliit-plugins-quick/input-method/meegoimquick.prf.in
(renamed from input-method-quick/meegoimquick.prf.in)
--- maliit-plugins-quick/input-method/minputmethodquick.cpp
+++ maliit-plugins-quick/input-method/minputmethodquick.cpp
(renamed from input-method-quick/minputmethodquick.cpp)
--- maliit-plugins-quick/input-method/minputmethodquick.h
+++ maliit-plugins-quick/input-method/minputmethodquick.h
(renamed from input-method-quick/minputmethodquick.h)
--- maliit-plugins-quick/input-method/minputmethodquickplugin.cpp
+++ maliit-plugins-quick/input-method/minputmethodquickplugin.cpp
(renamed from input-method-quick/minputmethodquickplugin.cpp)
--- maliit-plugins-quick/input-method/minputmethodquickplugin.h
+++ maliit-plugins-quick/input-method/minputmethodquickplugin.h
(renamed from input-method-quick/minputmethodquickplugin.h)
--- maliit-plugins-quick/input-method/mkeyoverridequick.cpp
+++ maliit-plugins-quick/input-method/mkeyoverridequick.cpp
(renamed from input-method-quick/mkeyoverridequick.cpp)
--- maliit-plugins-quick/input-method/mkeyoverridequick.h
+++ maliit-plugins-quick/input-method/mkeyoverridequick.h
(renamed from input-method-quick/mkeyoverridequick.h)
--- maliit-plugins-quick/input-method/mkeyoverridequick_p.h
+++ maliit-plugins-quick/input-method/mkeyoverridequick_p.h
(renamed from input-method-quick/mkeyoverridequick_p.h)
--- maliit-plugins-quick/maliit-plugins-quick.pro
+++ maliit-plugins-quick/maliit-plugins-quick.pro
+include(../config.pri)
+
+CONFIG += ordered
+TEMPLATE = subdirs
+SUBDIRS = input-method plugin-factory
--- maliit-plugins-quick/plugin-factory
+++ maliit-plugins-quick/plugin-factory
+(directory)
--- maliit-plugins-quick/plugin-factory/maliitquickpluginfactory.cpp
+++ maliit-plugins-quick/plugin-factory/maliitquickpluginfactory.cpp
+/* * This file is part of meego-im-framework *
+ *
+ * Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies).
+ * All rights reserved.
+ *
+ * Contact: Kimmo Surakka <kimmo.surakka at nokia.com>
+ *
+ * If you have questions regarding the use of this file, please contact
+ * Nokia at directui at nokia.com.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1 as published by the Free Software Foundation
+ * and appearing in the file LICENSE.LGPL included in the packaging
+ * of this file.
+ */
+
+#include "maliitquickpluginfactory.h"
+#include "maliit-plugins-quick/input-method/minputmethodquickplugin.h"
+
+class MyPlugin
+    : public MInputMethodQuickPlugin
+{
+    Q_DISABLE_COPY(MyPlugin)
+
+private:
+    const QString m_filename;
+
+public:
+    explicit MyPlugin(const QString &filename)
+        : MInputMethodQuickPlugin()
+        , m_filename(filename)
+    {}
+
+    virtual QString qmlFileName() const
+    {
+        return m_filename;
+    }
+
+    virtual QString name() const
+    {
+        static QFileInfo info(m_filename);
+        return info.baseName();
+    }
+};
+
+MaliitQuickPluginFactory::MaliitQuickPluginFactory(QObject *parent)
+    : QObject(parent)
+    , MImAbstractPluginFactory()
+{}
+
+MaliitQuickPluginFactory::~MaliitQuickPluginFactory()
+{}
+
+QString MaliitQuickPluginFactory::fileExtension() const
+{
+    return "qml";
+}
+
+MInputMethodPlugin * MaliitQuickPluginFactory::create(const QString &file) const
+{
+    return new MyPlugin(file);
+}
+
+Q_EXPORT_PLUGIN2(MaliitQuickPluginFactory, MaliitQuickPluginFactory)
--- maliit-plugins-quick/plugin-factory/maliitquickpluginfactory.h
+++ maliit-plugins-quick/plugin-factory/maliitquickpluginfactory.h
+/* * This file is part of meego-im-framework *
+ *
+ * Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies).
+ * All rights reserved.
+ *
+ * Contact: Kimmo Surakka <kimmo.surakka at nokia.com>
+ *
+ * If you have questions regarding the use of this file, please contact
+ * Nokia at directui at nokia.com.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1 as published by the Free Software Foundation
+ * and appearing in the file LICENSE.LGPL included in the packaging
+ * of this file.
+ */
+
+#ifndef MALIITQUICKPLUGINFACTORY_H
+#define MALIITQUICKPLUGINFACTORY_H
+
+#include "mimabstractpluginfactory.h"
+
+#include <QtCore>
+
+class MaliitQuickPluginFactory
+    : public QObject, public MImAbstractPluginFactory
+{
+    Q_OBJECT
+    Q_INTERFACES(MImAbstractPluginFactory)
+    Q_DISABLE_COPY(MaliitQuickPluginFactory)
+
+public:
+    explicit MaliitQuickPluginFactory(QObject *parent = 0);
+
+    //! \reimp
+    virtual ~MaliitQuickPluginFactory();
+    virtual QString fileExtension() const;
+    virtual MInputMethodPlugin * create(const QString &file) const;
+    //! \reimp_end
+};
+
+#endif // MALIITQUICKPLUGINFACTORY_H
--- maliit-plugins-quick/plugin-factory/plugin-factory.pro
+++ maliit-plugins-quick/plugin-factory/plugin-factory.pro
+include(../../config.pri)
+
+TEMPLATE = lib
+TARGET = $$MALIIT_PLUGINS_QUICK_FACTORY
+QUICK_DIR = $${OUT_PWD}/../input-method
+
+INCLUDEPATH_BASE = ../..
+INCLUDEPATH += \
+        $${INCLUDEPATH_BASE} \
+        $${INCLUDEPATH_BASE}/src \
+        $${INCLUDEPATH_BASE}/common \
+
+CONFIG += plugin
+
+# Input
+HEADERS += \
+        maliitquickpluginfactory.h \
+
+SOURCES += \
+        maliitquickpluginfactory.cpp \
+
+LIBS += \
+        $$QUICK_DIR/lib$${MALIIT_PLUGINS_QUICK_LIB}.so \
+
+QT = core gui declarative
+
+# coverage flags are off per default, but can be turned on via qmake COV_OPTION=on
+for(OPTION,$$list($$lower($$COV_OPTION))){
+    isEqual(OPTION, on){
+        QMAKE_CXXFLAGS += -ftest-coverage -fprofile-arcs -fno-elide-constructors
+        LIBS += -lgcov
+    }
+}
+
+target.path += $${M_IM_FACTORY_PLUGINS_DIR}
+
+OBJECTS_DIR = .obj
+MOC_DIR = .moc
+
+QMAKE_CLEAN += $$OBJECTS_DIR/*.gcno $$OBJECTS_DIR/*.gcda
+
+INSTALLS += target
--- maliit/attributeextension.h
+++ maliit/attributeextension.h
@@ -29,6 +29,9 @@
 
 class AttributeExtensionPrivate;
 
+/*! \ingroup libmaliit
+ * \brief Register extensions such as key overrides.
+ */
 class AttributeExtension : public QObject
 {
     Q_OBJECT
--- maliit/attributeextensionregistry.h
+++ maliit/attributeextensionregistry.h
@@ -31,6 +31,8 @@
 
 typedef QList<QWeakPointer<AttributeExtension> > ExtensionList;
 
+//! \ingroup libmaliit
+//! \internal
 class AttributeExtensionRegistry : public QObject
 {
     Q_OBJECT
--- maliit/inputmethod.h
+++ maliit/inputmethod.h
@@ -30,12 +30,18 @@
 
 class InputMethodPrivate;
 
+/*! \ingroup libmaliit
+ * \brief Listen to device orientation, language and raw key events.
+ */
 class InputMethod : public QObject
 {
     Q_OBJECT
 
 public:
     //! \brief Get singleton instance
+    //!
+    //! Example of using the singleton InputMethod instance:
+    //! \snippet plainqt/mainwindow.cpp Get singleton InputMethod instance
     //! \return singleton instance
     static InputMethod *instance();
 
@@ -75,14 +81,15 @@
     void setArea(const QRect &newRegion);
 
 Q_SIGNALS:
-    /*! \brief Emitted when input method area is changed
+    /*!
+     * \brief Emitted when input method area is changed
      *
-     *  If applications want to react to this signal by changing their layout (e.g. to
-     *  one that works better when a input method panel is around) they have to do their
-     *  layout changes immediately upon invocation of this signal. Therefore queued
-     *  connections (like Qt::QueuedConnection) should not be used for that purpose.
+     * \warning This signal is consumed by the input widget relocator inside
+     * libmeegotouch, and can be emitted at any time, so in order to avoid
+     * conflicts, an application that does any custom relayout must not use a
+     * queued connection (like Qt::QueuedConnection).
      *
-     *  \param region new input method area
+     * \param region new input method area
      */
     void areaChanged(const QRect &region);
 
@@ -125,16 +132,17 @@
 };
 
 /*!
- * Sends a request to the application's input context to open a software
+ * \brief Sends a request to the application's input context to open a software
  * input panel (e.g. the virtual keyboard).
- * Warning: In order to gain more screen space, window decorations may be
+ *
+ * \warning In order to gain more screen space, window decorations may be
  * temporarily hidden while the input panel is up.
  * \sa closeInputMethodPanel
  */
 void requestInputMethodPanel();
 
 /*!
- * Sends a request to the application's input context to close a software
+ * \brief Sends a request to the application's input context to close a software
  * input panel.
  * \sa requestInputMethodPanel
  */
--- maliit/preeditinjectionevent.h
+++ maliit/preeditinjectionevent.h
@@ -26,7 +26,8 @@
 class PreeditInjectionEventPrivate;
 
 /*!
- * \brief The MPreeditInjectionEvent class provides the information about preedit text.
+ * \ingroup libmaliit
+ * \brief Extension for preedit text inside text edits.
  *
  * MPreeditInjectionEvent should be sent from text edit to input context and offer the word as preedit.
  */
--- passthroughserver/main.cpp
+++ passthroughserver/main.cpp
@@ -15,27 +15,16 @@
  */
 
 
-// Input method overlay window
-
-#include "mimpluginmanager.h"
-#include "mimapplication.h"
 #include "mimdummyinputcontext.h"
 #include "minputcontextglibdbusconnection.h"
-#include "mimpluginsproxywidget.h"
+#include "mimserver.h"
 
 #if defined(Q_WS_X11)
 #include "mimxapplication.h"
-#include "mimremotewindow.h"
-#include "mimrotationanimation.h"
-#include "mpassthruwindow.h"
-#elif defined(Q_WS_QPA)
-#include "mimqpaplatform.h"
 #endif
 
 #include <QApplication>
 #include <QtDebug>
-#include <QWidget>
-#include <QGraphicsView>
 #include <QPalette>
 #include <QCommonStyle>
 #include <stdlib.h>
@@ -66,8 +55,8 @@
 
 #if defined(Q_WS_X11)
     MImXApplication app(argc, argv);
-#else
-    MIMApplication app(argc, argv);
+#elif defined(Q_WS_QPA)
+    QApplication app(argc, argv);
 #endif
 
     // Set a dummy input context so that Qt does not create a default input
@@ -75,66 +64,11 @@
     // meego-im-uiserver.
     app.setInputContext(new MIMDummyInputContext);
 
-    qDebug() << (app.selfComposited() ? "Use self composition" : "Use system compositor");
-
     // DBus Input Context Connection
     shared_ptr<MInputContextConnection> icConnection(new MInputContextGlibDBusConnection);
 
-#if defined(Q_WS_X11)
-    // For X11 the toplevel window is a MPassThruWindow (managed by MImXApplication. It
-    // contains a MImPluginsProxyWidget as container for all plugin widgets and a
-    // MImRotationAnimation, which is used to display the rotation animation. MImXApplication
-    // also manages MImRemoteWindows representing the current application window.
-
-    QObject::connect(icConnection.get(), SIGNAL(focusChanged(WId)),
-                     &app, SLOT(setTransientHint(WId)));
-
-    // Widget for showing a rotation animation inside the toplevel MPassThruWindow instead
-    // of the MImPluginsProxyWidget when the device is rotating.
-    MImRotationAnimation *rotationAnimation = new MImRotationAnimation(app.pluginsProxyWidget(),
-                                                                       app.passThruWindow(), &app);
-    QObject::connect(icConnection.get(), SIGNAL(appOrientationAboutToChange(int)),
-                     rotationAnimation, SLOT(appOrientationAboutToChange(int)));
-    QObject::connect(icConnection.get(), SIGNAL(appOrientationChanged(int)),
-                     rotationAnimation, SLOT(appOrientationChangeFinished(int)));
-
-    // Container for all plugin widgets
-    QWidget *pluginsProxyWidget = app.pluginsProxyWidget();
-
-    // Manager for loading and handling all plugins
-    MIMPluginManager *pluginManager = new MIMPluginManager(icConnection,
-                                                           pluginsProxyWidget);
-
-    // Hide active plugins when the application window is gone or iconified.
-    QObject::connect(&app, SIGNAL(remoteWindowGone()),
-                     pluginManager, SLOT(hideActivePlugins()));
-
-    // Handle changed used area by plugins
-    QObject::connect(pluginManager, SIGNAL(regionUpdated(const QRegion &)),
-                     app.passThruWindow(), SLOT(inputPassthrough(const QRegion &)));
-
-    // Configure widgets for self compositing after loading
-    QObject::connect(pluginManager, SIGNAL(pluginLoaded()),
-                     &app, SLOT(configureWidgetsForCompositing()));
-
-    // Configure widgets loaded during MIMPluginManager construction
-    app.configureWidgetsForCompositing();
-
-#elif defined(Q_WS_QPA)
-    // For QPA the toplevel window is a MImPluginsProxyWidget containing all plugin
-    // widgets. The MImQPAPlatform is used to show/hide that toplevel window when
-    // required.
-
-    std::auto_ptr<QWidget> pluginsProxyWidget(new MImPluginsProxyWidget);
-
-    std::auto_ptr<MImQPAPlatform> platform(new MImQPAPlatform(pluginsProxyWidget.get()));
-
-    MIMPluginManager *pluginManager = new MIMPluginManager(icConnection,
-                                                           pluginsProxyWidget.get());
-
-    QObject::connect(pluginManager, SIGNAL(regionUpdated(const QRegion &)),
-                     platform.get(), SLOT(inputPassthrough(const QRegion &)));
-#endif
+    MImServer imServer(icConnection);
+    Q_UNUSED(imServer);
 
     return app.exec();
 }
--- passthroughserver/mimdummyinputcontext.cpp
+++ passthroughserver/mimdummyinputcontext.cpp
(renamed to src/mimdummyinputcontext.cpp)
--- passthroughserver/mimdummyinputcontext.h
+++ passthroughserver/mimdummyinputcontext.h
(renamed to src/mimdummyinputcontext.h)
--- passthroughserver/mimqpaplatform.cpp
+++ passthroughserver/mimqpaplatform.cpp
-#include "mimqpaplatform.h"
-
-#include <QDebug>
-#include <QWidget>
-
-MImQPAPlatform::MImQPAPlatform(QWidget *proxyWidget) :
-    QObject(0),
-    mProxyWidget(proxyWidget)
-{
-}
-
-void MImQPAPlatform::inputPassthrough(const QRegion &region)
-{
-    qDebug() << __PRETTY_FUNCTION__;
-
-    if (region.isEmpty())
-        mProxyWidget.data()->hide();
-    else
-        mProxyWidget.data()->show();
-}
--- passthroughserver/mimqpaplatform.h
+++ passthroughserver/mimqpaplatform.h
-#ifndef MIMQPAPLATFORM_H
-#define MIMQPAPLATFORM_H
-
-#include <QObject>
-#include <QRegion>
-#include <QWeakPointer>
-
-class QWidget;
-
-class MImQPAPlatform : public QObject
-{
-    Q_OBJECT
-public:
-    explicit MImQPAPlatform(QWidget *proxyWidget);
-
-public Q_SLOTS:
-    //! Set window ID for given region
-    void inputPassthrough(const QRegion &region = QRegion());
-
-private:
-    QWeakPointer<QWidget> mProxyWidget;
-};
-
-#endif // MIMQPAPLATFORM_H
--- passthroughserver/mpassthruwindow.cpp
+++ passthroughserver/mpassthruwindow.cpp
(renamed to src/mpassthruwindow.cpp)
--- passthroughserver/mpassthruwindow.h
+++ passthroughserver/mpassthruwindow.h
-/* * This file is part of meego-im-framework *
- *
- * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
- * All rights reserved.
- * Contact: Nokia Corporation (directui at nokia.com)
- *
- * If you have questions regarding the use of this file, please contact
- * Nokia at directui at nokia.com.
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License version 2.1 as published by the Free Software Foundation
- * and appearing in the file LICENSE.LGPL included in the packaging
- * of this file.
- */
-#ifndef MPASSTHRUWINDOW_H
-#define MPASSTHRUWINDOW_H
-
-#include <QWidget>
-#include <QRegion>
-#include <QCloseEvent>
-
-class MImRemoteWindow;
-class MImXApplication;
-
-/*!
- * \brief MPassThruWindow uses XFixes to redirect mouse events to VKB
- */
-class MPassThruWindow: public QWidget
-{
-    Q_OBJECT
-
-public:
-    /*!
-     * \brief Constructor
-     * \param p QWidget* parent widget
-     */
-    explicit MPassThruWindow(MImXApplication *application);
-
-    //! Destructor
-    ~MPassThruWindow();
-
-    virtual bool event(QEvent *e);
-    void closeEvent(QCloseEvent *ev);
-
-    //! Return region occupied by current plugin
-    const QRegion &region();
-
-public Q_SLOTS:
-    //! Set window ID for given region
-    void inputPassthrough(const QRegion &region = QRegion());
-
-    //! Set the new remote window (application window)
-    void setRemoteWindow(MImRemoteWindow *remoteWindow = 0);
-
-    //! Schedules repainting for widget's background from remote window
-    void updateFromRemoteWindow(const QRegion &region);
-
-private:
-    Q_DISABLE_COPY(MPassThruWindow);
-
-    void updateInputRegion();
-    void updateWindowType();
-
-    MImRemoteWindow *remoteWindow;
-    QRegion mRegion;
-    MImXApplication *mApplication;
-
-#ifdef UNIT_TEST
-    friend class Ut_PassthroughServer;
-#endif
-};
-
-#endif
--- passthroughserver/passthroughserver.pro
+++ passthroughserver/passthroughserver.pro
@@ -8,28 +8,7 @@
 
 LIBS += ../src/lib$${MALIIT_PLUGINS_LIB}.so -lXfixes
 
-SOURCES += \
-           main.cpp \
-           mimdummyinputcontext.cpp \
-
-HEADERS += \
-           mimdummyinputcontext.h \
-
-x11 {
-    SOURCES += \
-           mpassthruwindow.cpp \
-
-    HEADERS += \
-           mpassthruwindow.h \
-}
-
-qpa {
-    SOURCES += \
-        mimqpaplatform.cpp \
- 
-    HEADERS += \
-        mimqpaplatform.h
-}
+SOURCES += main.cpp
 
 QT += core gui
 
--- sdk
+++ sdk
+(directory)
--- sdk/maliit-sdk-create.sh
+++ sdk/maliit-sdk-create.sh
+#!/bin/bash
+
+### This script creates the Maliit SDK for distribution
+
+EXPECTED_ARGS=4
+ERROR_BADARGS=65
+
+if [ $# -ne $EXPECTED_ARGS ]
+then
+  echo "Usage: `basename $0` SRC_DIR OUT_DIR VERSION MODE"
+  exit $ERROR_BADARGS
+fi
+
+IN=$1
+OUT=$2
+VERSION=$3
+MODE=$4
+
+case $MODE in
+    normal )
+        BUILD_TYPE=skeleton
+        ;;
+    legacy )
+        BUILD_TYPE=skeleton-legacy
+        ;;
+    * )
+        echo "Wrong MODE argument: \"$MODE\". Has to be either \"normal\" or \"legacy\""
+        exit $ERROR_BADARGS
+        ;;
+esac
+
+
+EXAMPLES_PATH=$IN/examples
+DOC_PATH=$IN/doc/html
+
+SDK_DIR=maliit-sdk
+SDK_OUT_PATH=$OUT/$SDK_DIR
+SDK_OUT_FILE_PATH=$OUT/maliit-sdk-$VERSION.tar.gz
+
+rm -r $SDK_OUT_PATH
+mkdir -p $SDK_OUT_PATH/examples
+
+# Extract examples
+cp -r $EXAMPLES_PATH $SDK_OUT_PATH/
+cd $SDK_OUT_PATH/examples
+sed -i -e s/"^BUILD_TYPE.*=.*"/"BUILD_TYPE = $BUILD_TYPE"/ `grep -r --files-with-matches BUILD_TYPE ./ | tr "\n" " "`
+make clean &> /dev/null
+find ./ -name Makefile -exec rm {} \;
+rm README
+cd -
+
+# Pack
+cd $OUT
+tar -acf $SDK_OUT_FILE_PATH $SDK_DIR
+cd -
+
--- sdk/maliit-sdk.in
+++ sdk/maliit-sdk.in
+#!/bin/bash
+
+### This script will allow user to get started using the Maliit SDK
+
+DOC_START_PATH=@M_IM_INSTALL_DOCS@/@MALIIT_PACKAGENAME@/html/index.html
+SDK_PATH=@M_IM_INSTALL_DOCS@/@MALIIT_PACKAGENAME@/maliit-sdk/
+
+MINIMUM_ARGS=1
+
+ERROR_GENERAL=1
+ERROR_BADARGS=65
+
+POSSIBLE_COMMANDS="start|extract|run"
+
+### Functions
+print_usage() {
+
+    echo "Usage: `basename $0` $POSSIBLE_COMMANDS"
+    echo -e "\n"\
+         "run: Open the Maliit SDK documentation start page\n"\
+         "extract: Extract the Maliit SDK to given directory. Default: ./maliit-sdk \n"\
+         "start: Do both of the run and extract commands\n"\
+         ""
+}
+
+do_command () {
+    COMMAND=$1
+    COMMAND_ARG=$2
+
+    case $COMMAND in
+        extract )
+            # Extract SDK to given directory, or to a default
+            OUT_PATH=./maliit-sdk
+
+            if [ "$COMMAND_ARG" ]
+            then
+                OUT_PATH=$COMMAND_ARG
+            fi
+
+            if [ -e $OUT_PATH ]
+            then
+                echo "Error: File \"$OUT_PATH\" exists already. Not overwriting."
+                exit $ERROR_GENERAL
+            fi
+
+            cp -r $SDK_PATH $OUT_PATH && echo "Maliit SDK has been extracted to $OUT_PATH"
+            ;;
+        run )
+            # Open HTML documentation
+            xdg-open $DOC_START_PATH && echo "Maliit SDK documentation should now be open in your browser"
+            ;;
+        start )
+            do_command extract $COMMAND_ARG
+            do_command run
+            ;;
+        * )
+            echo "Wrong command: \"$COMMAND\". Valid commands: $POSSIBLE_COMMANDS"
+            exit $ERROR_BADARGS
+            ;;
+    esac
+}
+
+### Main
+if [ "$#" -lt "$MINIMUM_ARGS" ]
+then
+  print_usage
+  exit $ERROR_BADARGS
+fi
+
+COMMAND=$1
+COMMAND_ARG=$2
+
+do_command $COMMAND $COMMAND_ARG
--- sdk/sdk.pro
+++ sdk/sdk.pro
+include(../config.pri)
+
+TEMPLATE = subdirs
+
+outputFiles(maliit-sdk)
+
+OTHER_FILES = \
+    maliit-sdk-create.sh \
+    maliit-sdk.in
+
+# Hack to make the sdk_tarball target run automatically
+QMAKE_EXTRA_TARGETS += first
+first.depends += sdk
+
+# Build
+enable-legacy {
+    MODE = legacy
+} else {
+    MODE = normal
+}
+QMAKE_EXTRA_TARGETS += sdk
+sdk.commands += $$IN_PWD/maliit-sdk-create.sh $$IN_PWD/.. $$OUT_PWD/build $$MALIIT_VERSION $$MODE
+
+# Install
+sdk_install.files = $$OUT_PWD/build/maliit-sdk/
+sdk_install.path = $$M_IM_INSTALL_DOCS/$$MALIIT_PACKAGENAME
+sdk_install.CONFIG += no_check_exist directory
+sdk_install.depends = sdk
+
+sdk_executable.CONFIG += no_check_exist
+sdk_executable.files = $$OUT_PWD/maliit-sdk
+sdk_executable.path = $$M_IM_INSTALL_BIN
+
+INSTALLS += sdk_install sdk_executable
+
+# TODO: Extract and build SDK as part of a distcheck
--- src/mabstractinputmethod.h
+++ src/mabstractinputmethod.h
@@ -36,13 +36,13 @@
 class MImExtensionEvent;
 
 
-/*!
- * \brief MAbstractInputMethod is a base class for input methods.
+/*! \ingroup pluginapi
+ * \brief A base class for input methods.
  *
- * It defines the interface which input method framework uses for
- * passing commands received from the applications. Communication in the other direction,
- * from the input method to the framework, is done using the MAbstractInputMethodHost
- * object returned from inputMethodHost().
+ * Defines the interface which input method framework uses for passing commands
+ * received from the applications to plugins. Communication in the other
+ * direction, from the input method plugin to the framework, is done using the
+ * MAbstractInputMethodHost object returned from inputMethodHost().
  */
 class MAbstractInputMethod: public QObject
 {
--- src/mabstractinputmethodhost.cpp
+++ src/mabstractinputmethodhost.cpp
@@ -15,9 +15,12 @@
  */
 
 #include "mabstractinputmethodhost.h"
-#include "mimapplication.h"
 #include "mimsubviewdescription.h"
 
+#if defined(Q_WS_X11)
+#include "mimxapplication.h"
+#endif
+
 class MAbstractInputMethodHostPrivate
 {
 public:
@@ -55,14 +58,18 @@
 
 QPixmap MAbstractInputMethodHost::background() const
 {
+#if defined(Q_WS_X11)
     // Check whether we are really running a MIMApplication first.
     // For instance, unit tests in other packages might use !MIMApplication,
     // as they don't have access to the MIMApplication headers.
-    if (qobject_cast<MIMApplication *>(QCoreApplication::instance())) {
-        return MIMApplication::instance()->remoteWindowPixmap();
+    if (qobject_cast<MImXApplication *>(QCoreApplication::instance())) {
+        return MImXApplication::instance()->remoteWindowPixmap();
     } else {
         return QPixmap();
     }
+#else
+    return QPixmap();
+#endif
 }
 
 QList<MImSubViewDescription>
--- src/mabstractinputmethodhost.h
+++ src/mabstractinputmethodhost.h
@@ -31,14 +31,15 @@
 class MImSubViewDescription;
 class MAbstractInputMethodHostPrivate;
 
-/*!
+/*! \ingroup maliitserver
  * \brief Provides an interface for input method instances to connect to the environment.
  *
  * MAbstractInputMethodHost provides methods MAbstractInputMethod instances can use
  * for interacting with the application that is using input method services and
  * the input method framework state itself.
- * Note: this is not meant to be derived by the input method framework users.
  *
+ * \note this is not meant to be derived by the input method framework users;
+ * the concrete implementations are provided by the framework.
  */
 class MAbstractInputMethodHost: public QObject
 {
--- src/mabstractinputmethodsettings.h
+++ src/mabstractinputmethodsettings.h
@@ -21,13 +21,12 @@
 
 class QGraphicsWidget;
 
-/*!
- * \brief MAbstractInputMethodSettings is a base class for input method settings.
- *
- * MAbstractInputMethodSettings defines the setting of a input method plugin. contentWidget()
- * holds its content.
- * Each input method plugin can implement its own setting by inheriting this class.
+/*! \ingroup pluginapi
+ * \brief A base class for input method settings.
  *
+ * MAbstractInputMethodSettings defines the setting of a input method plugin.
+ * contentWidget() holds its content. Each input method plugin can implement
+ * its own setting by inheriting this class.
  */
 
 class MAbstractInputMethodSettings
--- src/mattributeextension.h
+++ src/mattributeextension.h
@@ -30,6 +30,9 @@
 class MToolbarData;
 class MKeyOverrideData;
 
+/*! \ingroup pluginapi
+ * \brief Attribute extension.
+ */
 class MAttributeExtension : public QObject
 {
     Q_OBJECT
--- src/mattributeextensionid.h
+++ src/mattributeextensionid.h
@@ -23,8 +23,8 @@
 #include <QPointer>
 
 //! \internal
-/*!
- * \brief MAttributeExtensionId contains global unique identifier for an attribute extension.
+/*! \ingroup maliitserver
+ * \brief Contains global unique identifier for an attribute extension.
  *
  * Such identifiers are generated by MAttributeExtensionManager::generateId.
  */
--- src/mattributeextensionmanager.cpp
+++ src/mattributeextensionmanager.cpp
@@ -17,7 +17,6 @@
 
 #include "mattributeextensionmanager.h"
 #include "mattributeextension.h"
-#include "mattributeextensionid.h"
 #include "mtoolbardata.h"
 #include "mtoolbarlayout.h"
 #include "mkeyoverridedata.h"
@@ -34,9 +33,11 @@
     const char * const DomainItemName("_domain");
     const char * const KeysExtensionString("/keys");
     const char * const ToolbarExtensionString("/toolbar");
-}
 
-MAttributeExtensionManager *MAttributeExtensionManager::attributeExtensionMgrInstance = 0;
+    const char * const ToolbarIdAttribute = "toolbarId";
+    const char * const ToolbarAttribute = "toolbar";
+    const char * const FocusStateAttribute = "focusState";
+}
 
 MAttributeExtensionManager::MAttributeExtensionManager()
     : copyPasteStatus(MInputMethod::InputMethodNoCopyPaste),
@@ -50,13 +51,6 @@
 {
 }
 
-void MAttributeExtensionManager::destroyInstance()
-{
-    Q_ASSERT(attributeExtensionMgrInstance);
-    delete attributeExtensionMgrInstance;
-    attributeExtensionMgrInstance = 0;
-}
-
 QList<MAttributeExtensionId> MAttributeExtensionManager::attributeExtensionIdList() const
 {
     return attributeExtensions.keys();
@@ -333,3 +327,104 @@
         qWarning() << "Invalid or incompatible attribute extension target:" << target;
     }
 }
+
+
+void MAttributeExtensionManager::handleClientDisconnect(unsigned int clientId)
+{
+    // unregister toolbars registered by the lost connection
+    const QString service(QString::number(clientId));
+    QSet<MAttributeExtensionId>::iterator i(attributeExtensionIds.begin());
+    while (i != attributeExtensionIds.end()) {
+        if ((*i).service() == service) {
+            unregisterAttributeExtension(*i);
+            i = attributeExtensionIds.erase(i);
+        } else {
+            ++i;
+        }
+    }
+}
+
+void MAttributeExtensionManager::handleExtendedAttributeUpdate(unsigned int clientId, int id,
+                                   const QString &target, const QString &targetName,
+                                   const QString &attribute, const QVariant &value)
+{
+    MAttributeExtensionId globalId(id, QString::number(clientId));
+    if (globalId.isValid() && attributeExtensionIds.contains(globalId)) {
+        setExtendedAttribute(globalId, target, targetName, attribute, value);
+    }
+}
+
+void MAttributeExtensionManager::handleAttributeExtensionRegistered(unsigned int clientId,
+                                                                  int id, const QString &attributeExtension)
+{
+    MAttributeExtensionId globalId(id, QString::number(clientId));
+    if (globalId.isValid() && !attributeExtensionIds.contains(globalId)) {
+        registerAttributeExtension(globalId, attributeExtension);
+        attributeExtensionIds.insert(globalId);
+    }
+}
+
+void MAttributeExtensionManager::handleAttributeExtensionUnregistered(unsigned int clientId, int id)
+{
+    MAttributeExtensionId globalId(id, QString::number(clientId));
+    if (globalId.isValid() && attributeExtensionIds.contains(globalId)) {
+        unregisterAttributeExtension(globalId);
+        attributeExtensionIds.remove(globalId);
+    }
+}
+
+void MAttributeExtensionManager::handleWidgetStateChanged(unsigned int clientId,
+                                                          const QMap<QString, QVariant> &newState,
+                                                          const QMap<QString, QVariant> &oldState,
+                                                          bool focusChanged)
+
+{
+    Q_UNUSED(oldState);
+    // toolbar change
+    MAttributeExtensionId oldAttributeExtensionId;
+    MAttributeExtensionId newAttributeExtensionId;
+    oldAttributeExtensionId = attributeExtensionId;
+
+    QVariant variant = newState[ToolbarIdAttribute];
+    if (variant.isValid()) {
+        // map toolbar id from local to global
+        newAttributeExtensionId = MAttributeExtensionId(variant.toInt(), QString::number(clientId));
+    }
+    if (!newAttributeExtensionId.isValid()) {
+        newAttributeExtensionId = MAttributeExtensionId::standardAttributeExtensionId();
+    }
+
+    variant = newState[FocusStateAttribute];
+    if (not variant.isValid()) {
+        qCritical() << __PRETTY_FUNCTION__ << "Invalid focus state";
+    }
+    bool widgetFocusState = variant.toBool();
+
+    // compare the toolbar id (global)
+    if (oldAttributeExtensionId != newAttributeExtensionId) {
+        QString toolbarFile = newState[ToolbarAttribute].toString();
+        if (!contains(newAttributeExtensionId) && !toolbarFile.isEmpty()) {
+            // register toolbar if toolbar manager does not contain it but
+            // toolbar file is not empty. This can reload the toolbar data
+            // if im-uiserver crashes.
+            // XXX: should not happen, the input context is reponsible for registering
+            // and resending the toolbar information on server reconnect
+            qWarning() << "Unregistered toolbar found in widget information";
+
+            variant = newState[ToolbarIdAttribute];
+            if (variant.isValid()) {
+                const int toolbarLocalId = variant.toInt();
+                // FIXME: brittle to call the signal handler directly like this
+                handleAttributeExtensionRegistered(clientId, toolbarLocalId, toolbarFile);
+            }
+        }
+        Q_EMIT attributeExtensionIdChanged(newAttributeExtensionId);
+        // store the new used toolbar id(global).
+        attributeExtensionId = newAttributeExtensionId;
+    }
+    // this happens when we focus on a text widget with no attribute extensions.
+    else if (focusChanged && widgetFocusState)
+    {
+        Q_EMIT attributeExtensionIdChanged(newAttributeExtensionId);
+    }
+}
--- src/mattributeextensionmanager.h
+++ src/mattributeextensionmanager.h
@@ -20,18 +20,18 @@
 
 #include <QObject>
 #include <QHash>
+#include <QSet>
 #include <QPointer>
 
 #include "mkeyoverridedata.h"
 #include "mtoolbardata.h"
 #include "mattributeextension.h"
+#include "mattributeextensionid.h"
 #include "minputmethodnamespace.h"
 #include "mimsettings.h"
 
-class MAttributeExtensionId;
-
 //! \internal
-/*!
+/*! \ingroup maliitserver
  \brief The MAttributeExtensionManager class manager the virtual keyboard attribute extensions.
 
   AttributeExtensionManager loads and manages not only the toolbars which are registered
@@ -44,17 +44,15 @@
 
 public:
     /*!
+     * \brief Default constructor.
+     */
+    MAttributeExtensionManager();
+
+    /*!
      *\brief Destructor.
      */
     virtual ~MAttributeExtensionManager();
 
-    //! \brief Get singleton instance
-    //! \return singleton instance
-    static MAttributeExtensionManager &instance();
-
-    //! \brief Destroy singleton
-    static void destroyInstance();
-
     /*!
      * \brief Register an input method attribute extension which is defined in \a fileName with the unique identifier \a id.
      * AttributeExtensionManager can load a attribute extension's content according \a id and \a fileName, and cache it for the
@@ -96,13 +94,6 @@
     bool contains(const MAttributeExtensionId &id) const;
 
     /*!
-     * \brief Set copy/paste button state: hide it, show copy or show paste
-     *  \param copyAvailable True if text is selected
-     *  \param pasteAvailable True if clipboard content is not empty
-     */
-    void setCopyPasteState(bool copyAvailable, bool pasteAvailable);
-
-    /*!
      *\brief Sets the \a attribute of the \a targetItem in the attribute extension \a target which has unique\a id to \a value.
      */
     void setExtendedAttribute(const MAttributeExtensionId &id,
@@ -110,6 +101,22 @@
                               const QString &targetItem,
                               const QString &attribute,
                               const QVariant &value);
+public Q_SLOTS:
+    /*!
+     * \brief Set copy/paste button state: hide it, show copy or show paste
+     *  \param copyAvailable True if text is selected
+     *  \param pasteAvailable True if clipboard content is not empty
+     */
+    void setCopyPasteState(bool copyAvailable, bool pasteAvailable);
+
+    void handleClientDisconnect(unsigned int clientId);
+    void handleAttributeExtensionRegistered(unsigned int clientId, int id, const QString &attributeExtension);
+    void handleAttributeExtensionUnregistered(unsigned int clientId, int id);
+    void handleExtendedAttributeUpdate(unsigned int clientId, int id,
+                                       const QString &target, const QString &targetName,
+                                       const QString &attribute, const QVariant &value);
+    void handleWidgetStateChanged(unsigned int clientId, const QMap<QString, QVariant> &newState, const QMap<QString, QVariant> &oldState, bool focusChanged);
+
 private Q_SLOTS:
     //! \brief Handle preferred_domain GConf setting updates.
     void handlePreferredDomainUpdate();
@@ -118,12 +125,10 @@
     //! This signal is emited when a new key override is created.
     void keyOverrideCreated();
 
-private:
-    /*!
-     * \brief Default constructor.
-     */
-    MAttributeExtensionManager();
+    //! Emitted when attribute extension has changed
+    void attributeExtensionIdChanged(const MAttributeExtensionId &id);
 
+private:
     /*!
      * \brief Returns a list of the id for all attribute extensions' ids.
      */
@@ -150,6 +155,9 @@
     //! all registered attribute extensions
     AttributeExtensionContainer attributeExtensions;
 
+    MAttributeExtensionId attributeExtensionId; //current attribute extension id
+    QSet<MAttributeExtensionId> attributeExtensionIds; //all attribute extension ids
+
     //! Standard close button
     QSharedPointer<MToolbarItem> close;
 
@@ -165,19 +173,9 @@
     //! Preferred domain for URL and Email toolbar domain buttons.
     MImSettings preferredDomainSetting;
 
-    //! Singleton instance
-    static MAttributeExtensionManager *attributeExtensionMgrInstance;
-
     friend class Ut_MAttributeExtensionManager;
 };
 
-inline MAttributeExtensionManager &MAttributeExtensionManager::instance()
-{
-    if (!attributeExtensionMgrInstance) {
-        attributeExtensionMgrInstance = new MAttributeExtensionManager;
-    }
-    return *attributeExtensionMgrInstance;
-}
 //! \internal_end
 
 #endif
--- src/mimabstractpluginfactory.h
+++ src/mimabstractpluginfactory.h
@@ -23,11 +23,12 @@
 class MInputMethodPlugin;
 class MImAbstractPluginFactoryPrivate;
 
-/*!
- * \brief MImAbstractPluginFactory is an MInputMethodPlugin factory used for dynamic languages
+/*! \ingroup pluginapi
+ * \brief An MInputMethodPlugin factory used for dynamic languages
  *
- * To create a factory, re-implement the virtual functions this functions will be used to create
- * a new instacen of MInputMethodPlugin based on file mime-type
+ * To create a factory, re-implement the virtual functions. These functions will
+ * be used to create a new instance of MInputMethodPlugin based on file
+ * mime-type.
  */
 class MImAbstractPluginFactory
 {
--- src/mimapplication.cpp
+++ src/mimapplication.cpp
-/* * This file is part of meego-im-framework *
- *
- * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
- * All rights reserved.
- * Contact: Nokia Corporation (directui at nokia.com)
- *
- * If you have questions regarding the use of this file, please contact
- * Nokia at directui at nokia.com.
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License version 2.1 as published by the Free Software Foundation
- * and appearing in the file LICENSE.LGPL included in the packaging
- * of this file.
- */
-
-#include "mimapplication.h"
-
-#include <QDebug>
-
-MIMApplication::MIMApplication(int &argc, char **argv)
-    : QApplication(argc, argv)
-
-{
-}
-
-MIMApplication::~MIMApplication()
-{
-}
-
-MIMApplication *MIMApplication::instance()
-{
-    return static_cast<MIMApplication *>(QCoreApplication::instance());
-}
-
-bool MIMApplication::selfComposited() const
-{
-    return false;
-}
-
-const QPixmap &MIMApplication::remoteWindowPixmap()
-{
-    static const QPixmap empty;
-    return empty;
-}
--- src/mimapplication.h
+++ src/mimapplication.h
-/* * This file is part of meego-im-framework *
- *
- * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
- * All rights reserved.
- * Contact: Nokia Corporation (directui at nokia.com)
- *
- * If you have questions regarding the use of this file, please contact
- * Nokia at directui at nokia.com.
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License version 2.1 as published by the Free Software Foundation
- * and appearing in the file LICENSE.LGPL included in the packaging
- * of this file.
- */
-
-#ifndef MIM_APPLICATION_H
-#define MIM_APPLICATION_H
-
-#include <QApplication>
-#include <QPixmap>
-
-//! \internal
-/*! \brief A helper class to filter X11 events
- *
- *  This class allows the meego-im-uiserver to make itself transient to the
- *  remote application window.
- */
-class MIMApplication
-    : public QApplication
-{
-    Q_OBJECT
-
-public:
-    /*
-     * The command line arguments need to stay valid for the whole life-time of
-     * the application.
-     * That's why it is important to pass argc by reference, otherwise
-     * QApplication and QCoreApplication *will* break (e.g., when using
-     * QCoreApplication::arguments(),  in the case of filtered command line
-     * arguments).
-     */
-    explicit MIMApplication(int &argc, char** argv);
-    virtual ~MIMApplication();
-    static MIMApplication *instance();
-
-    virtual bool selfComposited() const;
-
-    virtual const QPixmap &remoteWindowPixmap();
-};
-//! \internal_end
-
-#endif // MIM_APPLICATION_H
--- src/mimdummyinputcontext.cpp
+++ src/mimdummyinputcontext.cpp
(renamed from passthroughserver/mimdummyinputcontext.cpp)
--- src/mimdummyinputcontext.h
+++ src/mimdummyinputcontext.h
(renamed from passthroughserver/mimdummyinputcontext.h)
--- src/mimextensionevent.h
+++ src/mimextensionevent.h
@@ -21,12 +21,13 @@
 
 class MImExtensionEventPrivate;
 
-/*!
- * \brief MImExtensionEvent is base class for extending signaling from input method
- * system to plugins.
+/*! \ingroup pluginapi
+ * \brief Base class for extending signaling from input method system to
+ * plugins.
  *
- * This event can be subclassed for future additions. See
- * MAbstractInputMethod::imExtensionEvent(MImExtensionEvent *event)
+ * This event can be subclassed for future additions.
+ *
+ * \sa MAbstractInputMethod::imExtensionEvent(MImExtensionEvent *event)
  */
 class MImExtensionEvent
 {
--- src/mimgraphicsview.cpp
+++ src/mimgraphicsview.cpp
@@ -16,7 +16,10 @@
 
 #include "mimgraphicsview_p.h"
 #include "mimgraphicsview.h"
-#include "mimapplication.h"
+
+#if defined(Q_WS_X11)
+#include "mimxapplication.h"
+#endif
 
 #include <QDebug>
 
@@ -79,8 +82,12 @@
         return;
     }
 
-    const QPixmap &bg(MIMApplication::instance()->remoteWindowPixmap());
+#if defined(Q_WS_X11)
+    const QPixmap &bg(MImXApplication::instance()->remoteWindowPixmap());
     if (not bg.isNull()) {
         painter->drawPixmap(rect.toRect(), bg, rect.toRect());
     }
+#else
+    return;
+#endif
 }
--- src/mimgraphicsview.h
+++ src/mimgraphicsview.h
@@ -25,10 +25,16 @@
 #include <QPainter>
 #include <QRectF>
 
-//! A QGraphicsView implementation that can be used for input methods
-//! using MAbstractInputMethod.
 class MImGraphicsViewPrivate;
 
+/*! \ingroup maliitserver
+ * \brief A QGraphicsView implementation that can be used for input methods
+ * using MAbstractInputMethod.
+ *
+ * Comes with support for self-compositing.
+ *
+ * \sa MImWidget
+ */
 class MImGraphicsView
     : public QGraphicsView
 {
--- src/mimhwkeyboardtracker.h
+++ src/mimhwkeyboardtracker.h
@@ -22,16 +22,18 @@
 #include <QObject>
 #include <QScopedPointer>
 
-//! \internal
-/*!
- * Class responsible for tracking the hardware keyboard properties and signaling events.
- * It is designed as singleton. Using isPresent() can query whether the device supports
- * hardware keyboard or not. If hardware keyboard is supported, using isOpen() to query
- * its current state. Signal stateChanged will be emitted when hardware keyboard state is changed.
- */
-
 class MImHwKeyboardTrackerPrivate;
 
+//! \internal
+/*! \ingroup maliitserver
+ * \brief Class responsible for tracking the hardware keyboard properties and
+ * signaling events.
+ *
+ * Singleton class. Using isPresent() queries whether the device supports
+ * hardware keyboard or not. If hardware keyboard is supported, using isOpen()
+ * to query its current state. Signal stateChanged will be emitted when the
+ * hardware keyboard state is changed.
+ */
 class MImHwKeyboardTracker
     : public QObject
 {
--- src/mimonscreenplugins.h
+++ src/mimonscreenplugins.h
@@ -25,6 +25,9 @@
 
 #include "mimsettings.h"
 
+/*! \ingroup maliitserver
+ * \brief Check the current status of plugins for a subview.
+ */
 class MImOnScreenPlugins: public QObject
 {
     Q_OBJECT
--- src/mimplugindescription.h
+++ src/mimplugindescription.h
@@ -24,7 +24,9 @@
 class MImPluginDescriptionPrivate;
 class MInputMethodPlugin;
 
-//! \brief MImPluginDescription provides information about loaded input method plugin
+/*! \ingroup maliitserver
+ * \brief Provides information about loaded input method plugin
+ */
 class MImPluginDescription
 {
 public:
@@ -59,4 +61,3 @@
 };
 
 #endif
-
--- src/mimpluginmanager.cpp
+++ src/mimpluginmanager.cpp
@@ -23,6 +23,8 @@
 #include "mabstractinputmethod.h"
 #include "mimsettings.h"
 #include "mimhwkeyboardtracker.h"
+#include "mimupdateevent.h"
+#include "maliit/namespaceinternal.h"
 
 #include <QDir>
 #include <QPluginLoader>
@@ -45,6 +47,9 @@
     const QString DefaultPluginLocation(M_IM_PLUGINS_DIR);
     const QString DefaultFactoryPluginLocation(M_IM_FACTORY_PLUGINS_DIR);
 
+    const char * const VisualizationAttribute = "visualizationPriority";
+    const char * const FocusStateAttribute = "focusState";
+
     const QString ConfigRoot           = MALIIT_CONFIG_ROOT;
     const QString MImPluginPaths       = ConfigRoot + "paths";
     const QString MImPluginDisabled    = ConfigRoot + "disabledpluginfiles";
@@ -78,7 +83,9 @@
       acceptRegionUpdates(false),
       indicatorService(0),
       onScreenPlugins(),
-      mProxyWidget(proxyWidget)
+      mProxyWidget(proxyWidget),
+      lastOrientation(0),
+      mAttributeExtensionManager(new MAttributeExtensionManager)
 {
     inputSourceToNameMap[MInputMethod::Hardware] = "hardware";
     inputSourceToNameMap[MInputMethod::Accessory] = "accessory";
@@ -248,9 +255,9 @@
                      q,
                      SLOT(_q_setActiveSubView(QString, MInputMethod::HandlerState)));
 
-    mICConnection->addTarget(inputMethod); // redirect incoming requests
 
-    return;
+    inputMethod->handleAppOrientationChanged(lastOrientation);
+    targets.insert(inputMethod);
 }
 
 
@@ -341,8 +348,9 @@
     plugins[plugin].state = PluginState();
     inputMethod->hide();
     inputMethod->reset();
-    QObject::disconnect(inputMethod, 0, q, 0),
-    mICConnection->removeTarget(inputMethod);
+    QObject::disconnect(inputMethod, 0, q, 0);
+
+    targets.remove(inputMethod);
 }
 
 void MIMPluginManagerPrivate::replacePlugin(MInputMethod::SwitchDirection direction,
@@ -379,11 +387,11 @@
         plugins[source].lastSwitchDirection = direction;
     }
     QSharedPointer<const MToolbarData> toolbar =
-        MAttributeExtensionManager::instance().toolbarData(toolbarId);
+        mAttributeExtensionManager->toolbarData(toolbarId);
     switchedTo->setToolbar(toolbar);
 
     QMap<QString, QSharedPointer<MKeyOverride> > keyOverrides =
-        MAttributeExtensionManager::instance().keyOverrides(toolbarId);
+        mAttributeExtensionManager->keyOverrides(toolbarId);
     switchedTo->setKeyOverrides(keyOverrides);
 
     // TODO: show/hide from IC matches SIP show/hide requests but here show is used (and
@@ -1091,16 +1099,64 @@
     Q_D(MIMPluginManager);
     d->q_ptr = this;
 
+    // Connect connection to our handlers
     connect(d->mICConnection.get(), SIGNAL(showInputMethodRequest()),
             this, SLOT(showActivePlugins()));
 
     connect(d->mICConnection.get(), SIGNAL(hideInputMethodRequest()),
             this, SLOT(hideActivePlugins()));
 
-    connect(d->mICConnection.get(), SIGNAL(toolbarIdChanged(const MAttributeExtensionId &)),
+    connect(d->mICConnection.get(), SIGNAL(resetInputMethodRequest()),
+            this, SLOT(resetInputMethods()));
+
+    connect(d->mICConnection.get(), SIGNAL(activeClientDisconnected()),
+            this, SLOT(handleClientChange()));
+
+    connect(d->mICConnection.get(), SIGNAL(clientActivated(uint)),
+            this, SLOT(handleClientChange()));
+
+    connect(d->mICConnection.get(), SIGNAL(appOrientationAboutToChangeCompleted(int)),
+            this, SLOT(handleAppOrientationAboutToChange(int)));
+
+    connect(d->mICConnection.get(), SIGNAL(appOrientationChangeCompleted(int)),
+            this, SLOT(handleAppOrientationChanged(int)));
+
+    connect(d->mICConnection.get(), SIGNAL(preeditChanged(QString,int)),
+            this, SLOT(handlePreeditChanged(QString,int)));
+
+    connect(d->mICConnection.get(), SIGNAL(mouseClickedOnPreedit(QPoint,QRect)),
+            this, SLOT(handleMouseClickOnPreedit(QPoint,QRect)));
+
+    connect(d->mICConnection.get(), SIGNAL(recievedKeyEvent(QEvent::Type,Qt::Key,Qt::KeyboardModifiers,QString,bool,int,quint32,quint32,ulong)),
+            this, SLOT(processKeyEvent(QEvent::Type,Qt::Key,Qt::KeyboardModifiers,QString,bool,int,quint32,quint32,ulong)));
+
+    connect(d->mICConnection.get(), SIGNAL(widgetStateChanged(uint,QMap<QString,QVariant>,QMap<QString,QVariant>,bool)),
+            this, SLOT(handleWidgetStateChanged(uint,QMap<QString,QVariant>,QMap<QString,QVariant>,bool)));
+
+    // Connect connection and MAttributeExtensionManager
+    connect(d->mICConnection.get(), SIGNAL(copyPasteStateChanged(bool,bool)),
+            d->mAttributeExtensionManager.data(), SLOT(setCopyPasteState(bool, bool)));
+
+    connect(d->mICConnection.get(), SIGNAL(widgetStateChanged(uint,QMap<QString,QVariant>,QMap<QString,QVariant>,bool)),
+            d->mAttributeExtensionManager.data(), SLOT(handleWidgetStateChanged(uint,QMap<QString,QVariant>,QMap<QString,QVariant>,bool)));
+
+    connect(d->mICConnection.get(), SIGNAL(attributeExtensionRegistered(uint, int, QString)),
+            d->mAttributeExtensionManager.data(), SLOT(handleAttributeExtensionRegistered(uint, int, QString)));
+
+    connect(d->mICConnection.get(), SIGNAL(attributeExtensionUnregistered(uint, int)),
+            d->mAttributeExtensionManager.data(), SLOT(handleAttributeExtensionUnregistered(uint, int)));
+
+    connect(d->mICConnection.get(), SIGNAL(extendedAttributeChanged(uint, int, QString, QString, QString, QVariant)),
+            d->mAttributeExtensionManager.data(), SLOT(handleExtendedAttributeUpdate(uint, int, QString, QString, QString, QVariant)));
+
+    connect(d->mICConnection.get(), SIGNAL(clientDisconnected(uint)),
+            d->mAttributeExtensionManager.data(), SLOT(handleClientDisconnect(uint)));
+
+    // Connect from MAttributeExtensionManager to our handlers
+    connect(d->mAttributeExtensionManager.data(), SIGNAL(attributeExtensionIdChanged(const MAttributeExtensionId &)),
             this, SLOT(setToolbar(const MAttributeExtensionId &)));
 
-    connect(d->mICConnection.get(), SIGNAL(keyOverrideCreated()),
+    connect(d->mAttributeExtensionManager.data(), SIGNAL(keyOverrideCreated()),
             this, SLOT(updateKeyOverrides()));
 
     d->paths        = MImSettings(MImPluginPaths).value(QStringList(DefaultPluginLocation)).toStringList();
@@ -1151,7 +1207,6 @@
 MIMPluginManager::~MIMPluginManager()
 {
     Q_D(MIMPluginManager);
-    MAttributeExtensionManager::destroyInstance();
     delete d;
 }
 
@@ -1273,10 +1328,10 @@
     d->toolbarId = id;
 
     QSharedPointer<const MToolbarData> toolbar =
-        MAttributeExtensionManager::instance().toolbarData(id);
+        d->mAttributeExtensionManager->toolbarData(id);
 
     QMap<QString, QSharedPointer<MKeyOverride> > keyOverrides =
-        MAttributeExtensionManager::instance().keyOverrides(id);
+        d->mAttributeExtensionManager->keyOverrides(id);
 
     bool focusStateOk(false);
     const bool focusState(d->mICConnection->focusState(focusStateOk));
@@ -1353,11 +1408,137 @@
 {
     Q_D(MIMPluginManager);
     QMap<QString, QSharedPointer<MKeyOverride> > keyOverrides =
-        MAttributeExtensionManager::instance().keyOverrides(d->toolbarId);
+        d->mAttributeExtensionManager->keyOverrides(d->toolbarId);
 
     Q_FOREACH (MInputMethodPlugin *plugin, d->activePlugins) {
         d->plugins.value(plugin).inputMethod->setKeyOverrides(keyOverrides);
     }
 }
 
+void MIMPluginManager::handleAppOrientationAboutToChange(int angle)
+{
+    Q_FOREACH (MAbstractInputMethod *target, targets()) {
+        target->handleAppOrientationAboutToChange(angle);
+    }
+}
+
+void MIMPluginManager::handleAppOrientationChanged(int angle)
+{
+    Q_D(MIMPluginManager);
+
+    d->lastOrientation = angle;
+
+    Q_FOREACH (MAbstractInputMethod *target, targets()) {
+        target->handleAppOrientationChanged(angle);
+    }
+}
+
+void MIMPluginManager::handleClientChange()
+{
+    // notify plugins
+    Q_FOREACH (MAbstractInputMethod *target, targets()) {
+        target->handleClientChange();
+    }
+}
+
+void MIMPluginManager::handleWidgetStateChanged(unsigned int clientId,
+                                                const QMap<QString, QVariant> &newState,
+                                                const QMap<QString, QVariant> &oldState,
+                                                bool focusChanged)
+{
+    Q_UNUSED(clientId);
+
+    // check visualization change
+    bool oldVisualization = false;
+    bool newVisualization = false;
+
+    QVariant variant = oldState[VisualizationAttribute];
+
+    if (variant.isValid()) {
+        oldVisualization = variant.toBool();
+    }
+
+    variant = newState[VisualizationAttribute];
+    if (variant.isValid()) {
+        newVisualization = variant.toBool();
+    }
+
+    // update state
+    QStringList changedProperties;
+    for (QMap<QString, QVariant>::const_iterator iter = newState.constBegin();
+         iter != newState.constEnd();
+         ++iter)
+    {
+        if (oldState.value(iter.key()) != iter.value()) {
+            changedProperties.append(iter.key());
+        }
+
+    }
+
+    variant = newState[FocusStateAttribute];
+    const bool widgetFocusState = variant.toBool();
+
+    if (focusChanged) {
+        Q_FOREACH (MAbstractInputMethod *target, targets()) {
+            target->handleFocusChange(widgetFocusState);
+        }
+    }
+
+    // call notification methods if needed
+    if (oldVisualization != newVisualization) {
+        Q_FOREACH (MAbstractInputMethod *target, targets()) {
+            target->handleVisualizationPriorityChange(newVisualization);
+        }
+    }
+
+    const Qt::InputMethodHints lastHints = static_cast<Qt::InputMethodHints>(newState.value(Maliit::Internal::inputMethodHints).toLongLong());
+    MImUpdateEvent ev(newState, changedProperties, lastHints);
+
+    // general notification last
+    Q_FOREACH (MAbstractInputMethod *target, targets()) {
+        if (not changedProperties.isEmpty()) {
+            (void) target->imExtensionEvent(&ev);
+        }
+        target->update();
+    }
+}
+
+void MIMPluginManager::handleMouseClickOnPreedit(const QPoint &pos, const QRect &preeditRect)
+{
+    Q_FOREACH (MAbstractInputMethod *target, targets()) {
+        target->handleMouseClickOnPreedit(pos, preeditRect);
+    }
+}
+
+void MIMPluginManager::handlePreeditChanged(const QString &text, int cursorPos)
+{
+    Q_FOREACH (MAbstractInputMethod *target, targets()) {
+        target->setPreedit(text, cursorPos);
+    }
+}
+
+void MIMPluginManager::resetInputMethods()
+{
+    Q_FOREACH (MAbstractInputMethod *target, targets()) {
+        target->reset();
+    }
+}
+
+void MIMPluginManager::processKeyEvent(QEvent::Type keyType, Qt::Key keyCode,
+                     Qt::KeyboardModifiers modifiers, const QString &text, bool autoRepeat, int count,
+                     quint32 nativeScanCode, quint32 nativeModifiers, unsigned long time)
+
+{
+    Q_FOREACH (MAbstractInputMethod *target, targets()) {
+        target->processKeyEvent(keyType, keyCode, modifiers, text, autoRepeat, count,
+                                nativeScanCode, nativeModifiers, time);
+    }
+}
+
+QSet<MAbstractInputMethod *> MIMPluginManager::targets()
+{
+    Q_D(MIMPluginManager);
+    return d->targets;
+}
+
 #include "moc_mimpluginmanager.cpp"
--- src/mimpluginmanager.h
+++ src/mimpluginmanager.h
@@ -32,8 +32,13 @@
 class MIMPluginManagerPrivate;
 class MAttributeExtensionId;
 class MAbstractInputMethod;
+class MAttributeExtensionManager;
 
-//! Note: this class is not considered stable API
+//! \internal
+/*! \ingroup maliitserver
+ * \brief Manager of MInputMethodPlugin instances.
+ * \note this class is not considered stable API
+ */
 class MIMPluginManager: public QObject
 {
     Q_OBJECT
@@ -109,6 +114,8 @@
     //! Hide active plugins.
     void hideActivePlugins();
 
+    void resetInputMethods();
+
     //! Updates the whole painting area for input method objects.
     void updateRegion(const QRegion &region);
 
@@ -122,6 +129,23 @@
     //! Update the key overrides for active plugin.
     void updateKeyOverrides();
 
+    void handleAppOrientationChanged(int angle);
+    void handleAppOrientationAboutToChange(int angle);
+
+    void handleClientChange();
+
+    void handleWidgetStateChanged(unsigned int clientId, const QMap<QString, QVariant> &newState,
+                                  const QMap<QString, QVariant> &oldState, bool focusChanged);
+    void handleMouseClickOnPreedit(const QPoint &pos, const QRect &preeditRect);
+    void handlePreeditChanged(const QString &text, int cursorPos);
+
+    void processKeyEvent(QEvent::Type keyType, Qt::Key keyCode,
+                         Qt::KeyboardModifiers modifiers, const QString &text, bool autoRepeat,
+                         int count, quint32 nativeScanCode, quint32 nativeModifiers, unsigned long time);
+
+private:
+    QSet<MAbstractInputMethod *> targets();
+
 protected:
     MIMPluginManagerPrivate *const d_ptr;
 
--- src/mimpluginmanager_p.h
+++ src/mimpluginmanager_p.h
@@ -32,6 +32,7 @@
 class MImAbstractPluginFactory;
 class MInputContextConnection;
 class MIMPluginManager;
+class MAttributeExtensionManager;
 class MImSettings;
 class MAbstractInputMethod;
 class MIMPluginManagerAdaptor;
@@ -149,6 +150,7 @@
 
     Plugins plugins;
     ActivePlugins activePlugins;
+    QSet<MAbstractInputMethod *> targets;
     PluginsFactory factories;
 
     QStringList paths;
@@ -180,6 +182,9 @@
     MImHwKeyboardTracker hwkbTracker;
 
     WeakWidget mProxyWidget;
+    int lastOrientation;
+
+    QScopedPointer<MAttributeExtensionManager> mAttributeExtensionManager;
 };
 
 #endif
--- src/mimpluginmanageradaptor.h
+++ src/mimpluginmanageradaptor.h
@@ -27,6 +27,9 @@
 class MIMPluginManager;
 
 //! \internal
+/*! \ingroup maliitserver
+ * \brief Manage available and active plugins.
+ */
 class MIMPluginManagerAdaptor: public QDBusAbstractAdaptor
 {
     Q_OBJECT
--- src/mimpluginsproxywidget.cpp
+++ src/mimpluginsproxywidget.cpp
@@ -15,7 +15,10 @@
  */
 
 #include "mimpluginsproxywidget.h"
-#include "mimapplication.h"
+
+#if defined(Q_WS_X11)
+#include "mimxapplication.h"
+#endif
 
 #include <QDesktopWidget>
 
@@ -27,13 +30,16 @@
     setAutoFillBackground(false);
     setBackgroundRole(QPalette::NoRole);
 
-    if (MIMApplication::instance() && MIMApplication::instance()->selfComposited()) {
+#if defined(Q_WS_X11)
+    if (MImXApplication::instance() && MImXApplication::instance()->selfComposited()) {
         setAttribute(Qt::WA_OpaquePaintEvent);
         setAttribute(Qt::WA_NoSystemBackground);
     } else {
         setAttribute(Qt::WA_TranslucentBackground);
     }
-
+#else
+    setAttribute(Qt::WA_TranslucentBackground);
+#endif
     setSizePolicy(QSizePolicy::Fixed, QSizePolicy::Fixed);
     QDesktopWidget* desktop = QApplication::desktop();
     setMinimumSize(desktop->screenGeometry().size());
--- src/mimpluginsproxywidget.h
+++ src/mimpluginsproxywidget.h
@@ -19,6 +19,12 @@
 
 #include <QWidget>
 
+/*! \ingroup maliitserver
+ * \brief Proxy QWidget for input method plugins.
+ *
+ * Used to manage the visibility of plugins without having to infer that from
+ * the plugin's own visibility.
+ */
 class MImPluginsProxyWidget : public QWidget
 {
     Q_OBJECT
--- src/mimqpaplatform.cpp
+++ src/mimqpaplatform.cpp
+#include "mimqpaplatform.h"
+
+#include <QDebug>
+#include <QWidget>
+
+MImQPAPlatform::MImQPAPlatform() :
+    QObject(0),
+    mProxyWidget(new MImPluginsProxyWidget)
+{
+}
+
+void MImQPAPlatform::inputPassthrough(const QRegion &region)
+{
+    qDebug() << __PRETTY_FUNCTION__;
+
+    if (region.isEmpty())
+        mProxyWidget.data()->hide();
+    else
+        mProxyWidget.data()->show();
+}
+
+QWidget *MImQPAPlatform::pluginsProxyWidget()
+{
+    return mProxyWidget.data();
+}
+
--- src/mimqpaplatform.h
+++ src/mimqpaplatform.h
+#ifndef MIMQPAPLATFORM_H
+#define MIMQPAPLATFORM_H
+
+#include <QObject>
+#include <QRegion>
+#include <QWeakPointer>
+
+class QWidget;
+
+class MImQPAPlatform : public QObject
+{
+    Q_OBJECT
+public:
+    explicit MImQPAPlatform();
+
+    QWidget *pluginsProxyWidget();
+
+public Q_SLOTS:
+    //! Set window ID for given region
+    void inputPassthrough(const QRegion &region = QRegion());
+
+private:
+    std::auto_ptr<QWidget> mProxyWidget;
+};
+
+#endif // MIMQPAPLATFORM_H
--- src/mimremotewindow.cpp
+++ src/mimremotewindow.cpp
@@ -44,8 +44,9 @@
 #else
 # define ICONIFIED_ATOM_NAME "WM_STATE"
 #endif
+    static const Atom stateAtom = XInternAtom(QX11Info::display(), ICONIFIED_ATOM_NAME, false);
 
-    return XInternAtom(QX11Info::display(), ICONIFIED_ATOM_NAME, false);
+    return stateAtom;
 }
 
 }
@@ -270,7 +271,7 @@
 
 void MImRemoteWindow::destroyPixmap()
 {
-    if (MIMApplication::instance())
+    if (MImXApplication::instance())
         pixmap = QPixmap();
 
     if (xpixmap != 0) {
--- src/mimremotewindow.h
+++ src/mimremotewindow.h
@@ -23,8 +23,8 @@
 class MImXApplication;
 
 /*! \internal
- *  \brief A helper class to handle remote application windows
- *
+ * \ingroup maliitserver
+ * \brief A helper class to handle remote application windows
  */
 class MImRemoteWindow : public QObject
 {
--- src/mimrotationanimation.h
+++ src/mimrotationanimation.h
@@ -27,9 +27,11 @@
 class MImXApplication;
 
 /*! \internal
- * \brief Custom QObject'ified PixmapItem that's placed on the scene,
- * one instance for the origin snapshot, one for the target
- * of the rotation (crossfading).
+ * \ingroup maliitserver
+ * \brief Custom QObject'ified PixmapItem that's placed on the scene, one
+ * instance for the origin snapshot, one for the target of the rotation
+ * (crossfading).
+ *
  * Inherits from QObject so that it can have animatable properties.
  */
 class SnapshotPixmapItem : public QObject, public QGraphicsPixmapItem {
--- src/mimserver.cpp
+++ src/mimserver.cpp
+/* * This file is part of meego-im-framework *
+ *
+ * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+ * All rights reserved.
+ * Contact: Nokia Corporation (directui at nokia.com)
+ *
+ * If you have questions regarding the use of this file, please contact
+ * Nokia at directui at nokia.com.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1 as published by the Free Software Foundation
+ * and appearing in the file LICENSE.LGPL included in the packaging
+ * of this file.
+ */
+
+#include "mimserver.h"
+
+#include "mimpluginmanager.h"
+
+#if defined(Q_WS_X11)
+#include "mimxapplication.h"
+#elif defined(Q_WS_QPA)
+#include "mimqpaplatform.h"
+#endif
+
+using namespace std::tr1;
+
+class MImServerPrivate
+{
+public:
+    explicit MImServerPrivate();
+
+    // Manager for loading and handling all plugins
+    MIMPluginManager *pluginManager;
+
+    // Connection to application side (input-context)
+    shared_ptr<MInputContextConnection> icConnection;
+
+#if defined(Q_WS_QPA)
+    std::auto_ptr<MImQPAPlatform> platform;
+#endif
+
+private:
+    Q_DISABLE_COPY(MImServerPrivate)
+};
+
+MImServerPrivate::MImServerPrivate()
+{}
+
+// X11:
+// For X11 the toplevel window is a MPassThruWindow (managed by MImXApplication. It
+// contains a MImPluginsProxyWidget as container for all plugin widgets and a
+// MImRotationAnimation, which is used to display the rotation animation. MImXApplication
+// also manages MImRemoteWindows representing the current application window.
+//
+// QPA:
+// For QPA the toplevel window is a MImPluginsProxyWidget containing all plugin
+// widgets. The MImQPAPlatform is used to show/hide that toplevel window when
+// required.
+MImServer::MImServer(shared_ptr<MInputContextConnection> icConnection, QObject *parent)
+  : QObject(parent)
+  , d_ptr(new MImServerPrivate)
+{
+    Q_D(MImServer);
+
+    d->icConnection = icConnection;
+
+#if defined(Q_WS_X11)
+    MImXApplication *app = MImXApplication::instance();
+    qDebug() << (app->selfComposited() ? "Use self composition" : "Use system compositor");
+#elif defined(Q_WS_QPA)
+    d->platform.reset(new MImQPAPlatform);
+#endif
+
+    d->pluginManager = new MIMPluginManager(d->icConnection, pluginsWidget());
+
+    connectComponents();
+
+#if defined(Q_WS_X11)
+    // Configure widgets loaded during MIMPluginManager construction
+    // only needed on X11 for self-compositing
+    app->configureWidgetsForCompositing();
+#endif
+}
+
+MImServer::~MImServer()
+{
+
+}
+
+void MImServer::connectComponents()
+{
+    Q_D(MImServer);
+
+#if defined(Q_WS_X11)
+    MImXApplication *app = MImXApplication::instance();
+
+    QObject::connect(d->icConnection.get(), SIGNAL(focusChanged(WId)),
+                     app, SLOT(setTransientHint(WId)));
+
+    QObject::connect(d->icConnection.get(), SIGNAL(appOrientationAboutToChange(int)),
+                     app, SLOT(appOrientationAboutToChange(int)));
+    QObject::connect(d->icConnection.get(), SIGNAL(appOrientationChanged(int)),
+                     app, SLOT(appOrientationChangeFinished(int)));
+
+    // Hide active plugins when the application window is gone or iconified.
+    QObject::connect(app, SIGNAL(remoteWindowGone()),
+                     d->pluginManager, SLOT(hideActivePlugins()));
+
+    // Handle changed used area by plugins
+    QObject::connect(d->pluginManager, SIGNAL(regionUpdated(const QRegion &)),
+                     app->passThruWindow(), SLOT(inputPassthrough(const QRegion &)));
+
+    // Configure widgets for self compositing after loading
+    QObject::connect(d->pluginManager, SIGNAL(pluginLoaded()),
+                     app, SLOT(configureWidgetsForCompositing()));
+
+#elif defined(Q_WS_QPA)
+    QObject::connect(d->pluginManager, SIGNAL(regionUpdated(const QRegion &)),
+                     d->platform.get(), SLOT(inputPassthrough(const QRegion &)));
+#endif
+}
+
+QWidget *MImServer::pluginsWidget()
+{
+    Q_D(MImServer);
+
+#if defined(Q_WS_X11)
+    Q_UNUSED(d);
+    return MImXApplication::instance()->pluginsProxyWidget();
+#elif defined(Q_WS_QPA)
+    return d->platform.get()->pluginsProxyWidget();
+#endif
+}
--- src/mimserver.h
+++ src/mimserver.h
+/* * This file is part of meego-im-framework *
+ *
+ * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+ * All rights reserved.
+ * Contact: Nokia Corporation (directui at nokia.com)
+ *
+ * If you have questions regarding the use of this file, please contact
+ * Nokia at directui at nokia.com.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1 as published by the Free Software Foundation
+ * and appearing in the file LICENSE.LGPL included in the packaging
+ * of this file.
+ */
+
+#ifndef MIMSERVER_H
+#define MIMSERVER_H
+
+#include <QObject>
+#include <tr1/memory>
+
+class MInputContextConnection;
+class MImServerPrivate;
+class QWidget;
+
+/* MImServer: The Maliit Input Method Server
+ *
+ * Consumers of MImServer are responsible for creating a QApplication (for the mainloop),
+ * and an MInputContextConnection for communication with clients, and for starting the mainloop.
+ * Everything else is handled by the server.
+ *
+ * Note: For X11, MImServer MUST be used together with MImXApplication.
+ */
+class MImServer : public QObject
+{
+    Q_OBJECT
+public:
+    explicit MImServer(std::tr1::shared_ptr<MInputContextConnection> icConnection, QObject *parent = 0);
+    ~MImServer();
+
+private:
+    void connectComponents();
+    QWidget *pluginsWidget();
+
+    Q_DISABLE_COPY(MImServer)
+    Q_DECLARE_PRIVATE(MImServer)
+    const QScopedPointer<MImServerPrivate> d_ptr;
+};
+
+#endif // MIMSERVER_H
--- src/mimsettings.h
+++ src/mimsettings.h
@@ -31,7 +31,7 @@
 //! \internal
 
 /*!
-
+  \ingroup maliitserver
   \brief MImSettings is a simple C++ wrapper for GConf.
 
   Creating a MImSettings instance gives you access to a single GConf
--- src/mimsubviewdescription.h
+++ src/mimsubviewdescription.h
@@ -21,6 +21,9 @@
 
 class MImSubViewDescriptionPrivate;
 
+/*! \ingroup maliitserver
+ * \brief Query the current subview properties.
+ */
 class MImSubViewDescription
 {
 public:
--- src/mimupdateevent.h
+++ src/mimupdateevent.h
@@ -24,6 +24,9 @@
 class MImUpdateEventPrivate;
 class MImUpdateReceiver;
 
+/*! \ingroup pluginapi
+ * \brief Monitor the input method properties sent by the application.
+ */
 class MImUpdateEvent
     : public MImExtensionEvent
 {
--- src/mimupdatereceiver.h
+++ src/mimupdatereceiver.h
@@ -22,18 +22,22 @@
 class MImUpdateReceiverPrivate;
 class MImUpdateEvent;
 
-//! An example that turns data-polling from events into data-pushing via
-//! properties and change notifications.
-//! Used in combination with MImUpdateEvents: The event is propagated down to
-//! the final component, where it is then processed by an event receiver. The
-//! receiver therefore acts as an endpoint for events, allowing the actual
-//! consumers of event data to listen to property changes. Using this approach,
-//! consumers are completely decoupled from the event propagation itself.
-//! Event receivers implemented in plugins are supposed to be more specialized
-//! than the generic MImUpdateReceiver. They can be designed to only carry the
-//! properties that is required for a given endpoint.
-//! The life time of event receivers usually exceeds the life time of events,
-//! which allows to keep signal connections alive.
+/*! \ingroup pluginapi
+ * \brief An example that turns data-polling from events into data-pushing via
+ * properties and change notifications.
+ *
+ * Used in combination with MImUpdateEvents: The event is propagated down to
+ * the final component, where it is then processed by an event receiver. The
+ * receiver therefore acts as an endpoint for events, allowing the actual
+ * consumers of input method properties to listen to property changes. Using
+ * this approach, consumers are completely decoupled from the event propagation
+ * itself. Event receivers implemented in plugins are supposed to be more
+ * specialized than the generic MImUpdateReceiver. They can be designed to only
+ * carry the properties that are required for a given endpoint. The life time
+ * of event receivers usually exceeds the life time of events, which makes it
+ * possible to keep signal connections between consumers and event receivers
+ * alive.
+ */
 class MImUpdateReceiver
     : public QObject
 {
--- src/mimwidget.cpp
+++ src/mimwidget.cpp
@@ -16,7 +16,10 @@
 
 #include "mimwidget_p.h"
 #include "mimwidget.h"
-#include "mimapplication.h"
+
+#if defined(Q_WS_X11)
+#include "mimxapplication.h"
+#endif
 
 #include <QPainter>
 #include <QDebug>
@@ -66,9 +69,13 @@
         return;
     }
 
-    const QPixmap &bg(MIMApplication::instance()->remoteWindowPixmap());
+#if defined(Q_WS_X11)
+    const QPixmap &bg(MImXApplication::instance()->remoteWindowPixmap());
     if (not bg.isNull()) {
         QPainter p(this);
         p.drawPixmap(ev->rect(), bg, ev->rect());
     }
+#else
+    return;
+#endif
 }
--- src/mimwidget.h
+++ src/mimwidget.h
@@ -25,9 +25,12 @@
 
 class MImWidgetPrivate;
 
-//! A QWidget implementation that can be used for input methods
-//! using MAbstractInputMethod.
-//! Need to call MImWidget::paintEvent when overriding paintEvent.
+/*! \ingroup maliitserver
+ * \brief A QWidget implementation that can be used for input methods using
+ * MAbstractInputMethod.
+ *
+ * Need to call MImWidget::paintEvent when overriding paintEvent.
+ */
 class MImWidget
     : public QWidget
 {
--- src/mimxapplication.cpp
+++ src/mimxapplication.cpp
@@ -1,5 +1,6 @@
 #include "mimxapplication.h"
 #include "mimpluginsproxywidget.h"
+#include "mimrotationanimation.h"
 
 #include <QDebug>
 
@@ -26,7 +27,7 @@
         // QPalette::NoRole - see QTBUG-17924.
         w->setBackgroundRole(QPalette::NoRole);
 
-        if (MIMApplication::instance() && not MIMApplication::instance()->selfComposited()) {
+        if (MImXApplication::instance() && not MImXApplication::instance()->selfComposited()) {
             // Careful: This flag can trigger a call to
             // qt_x11_recreateNativeWidgetsRecursive
             // - which will crash when it tries to get the effective WId
@@ -39,7 +40,7 @@
 }
 
 MImXApplication::MImXApplication(int &argc, char** argv) :
-    MIMApplication(argc, argv),
+    QApplication(argc, argv),
     mCompositeExtension(),
     mDamageExtension(),
     mSelfComposited(false),
@@ -54,6 +55,7 @@
 
     mPassThruWindow.reset(new MPassThruWindow(this));
     mPluginsProxyWidget.reset(new MImPluginsProxyWidget(mPassThruWindow.get()));
+    mRotationAnimation.reset(new MImRotationAnimation(pluginsProxyWidget(), passThruWindow(), this));
 
 #ifdef HAVE_MEEGOGRAPHICSSYSTEM
     QMeeGoGraphicsSystemHelper::setSwitchPolicy(QMeeGoGraphicsSystemHelper::NoSwitch);
@@ -70,6 +72,15 @@
 {
 }
 
+MImXApplication *MImXApplication::instance()
+{
+    MImXApplication *app = qobject_cast<MImXApplication *>(QCoreApplication::instance());
+    if (QCoreApplication::instance() && !app) {
+        qCritical() << "Application instance used is not MImXApplication";
+    }
+    return app;
+}
+
 void MImXApplication::finalize()
 {
     // Cannot destroy QWidgets or QPixmaps during MIMApplication destruction.
@@ -111,7 +122,7 @@
     }
 
     if (mRemoteWindow->wasIconified(ev) || mRemoteWindow->wasUnmapped(ev)) {
-        qDebug() << "MIMApplication" << __PRETTY_FUNCTION__
+        qDebug() << "MImXApplication" << __PRETTY_FUNCTION__
                  << "Remote window was destroyed or iconified - hiding.";
 
         Q_EMIT remoteWindowChanged(0);
@@ -258,9 +269,15 @@
     visitWidgetHierarchy(configureForCompositing, mPassThruWindow.get());
 }
 
-#ifdef UNIT_TEST
+void MImXApplication::appOrientationAboutToChange(int toAngle) {
+    mRotationAnimation->appOrientationAboutToChange(toAngle);
+}
+
+void MImXApplication::appOrientationChangeFinished(int toAngle) {
+    mRotationAnimation->appOrientationChangeFinished(toAngle);
+}
+
 MImRemoteWindow *MImXApplication::remoteWindow() const
 {
     return mRemoteWindow.get();
 }
-#endif
--- src/mimxapplication.h
+++ src/mimxapplication.h
@@ -1,8 +1,6 @@
 #ifndef MIMXAPPLICATION_H
 #define MIMXAPPLICATION_H
 
-#include "mimapplication.h"
-
 #include "mpassthruwindow.h"
 #include "mimremotewindow.h"
 #include "mimxextension.h"
@@ -10,7 +8,14 @@
 #include <memory>
 #include <tr1/functional>
 
-class MImXApplication : public MIMApplication
+#include <QApplication>
+
+class MImRotationAnimation;
+
+/*! \ingroup maliitserver
+ * \brief Application abstraction for X applications.
+ */
+class MImXApplication : public QApplication
 {
     Q_OBJECT
 public:
@@ -21,6 +26,7 @@
 
     MImXApplication(int &argc, char** argv);
     virtual ~MImXApplication();
+    static MImXApplication *instance();
 
     const MImXCompositeExtension& compositeExtension() { return mCompositeExtension; }
     const MImXDamageExtension& damageExtension() { return mDamageExtension; }
@@ -47,9 +53,8 @@
 
     void visitWidgetHierarchy(WidgetVisitor visitor, QWidget *widget);
 
-#ifdef UNIT_TEST
+    //! For unittesting purposes
     MImRemoteWindow *remoteWindow() const;
-#endif
 
 public Q_SLOTS:
     void setTransientHint(WId remoteWinId);
@@ -68,6 +73,9 @@
 
     void updatePassThruWindow(const QRegion &region);
 
+    void appOrientationAboutToChange(int toAngle);
+    void appOrientationChangeFinished(int toAngle);
+
 private:
     void parseArguments(int &argc, char** argv);
 
@@ -87,6 +95,7 @@
     std::auto_ptr<MPassThruWindow> mPassThruWindow;
     std::auto_ptr<QWidget> mPluginsProxyWidget;
     std::auto_ptr<MImRemoteWindow> mRemoteWindow;
+    std::auto_ptr<MImRotationAnimation> mRotationAnimation;
 
     friend class Ut_PassthroughServer;
 };
--- src/mimxerrortrap.h
+++ src/mimxerrortrap.h
@@ -22,9 +22,11 @@
 #include <X11/Xlib.h>
 
 /*! \internal
- *  \brief A helper class to enable to trap X errors.
+ * \ingroup maliitserver
+ * \brief A helper class to enable trapping of X errors.
  *
- * This class is not thread safe and must be only used in the main UI thread.
+ * \warning This class is not thread safe and must be only used in the main UI
+ * thread.
  */
 class MImXErrorTrap
 {
--- src/mimxextension.h
+++ src/mimxextension.h
@@ -19,9 +19,10 @@
 
 #include <QObject>
 
-//! \internal
-/*! \brief A helper class to check if X extensions are supported and query their event
- * and error bases.
+/*! \internal
+ * \ingroup maliitserver
+ * \brief A helper class to check if X extensions are supported, and query
+ * their event and error bases.
  */
 class MImXExtension
 {
--- src/mindicatorserviceclient.h
+++ src/mindicatorserviceclient.h
@@ -27,8 +27,8 @@
 class QDBusInterface;
 class QDBusServiceWatcher;
 
-//! \internal
-/*!
+/*! \internal
+ * \ingroup maliitserver
  * \brief Provides interface for setting the system keyboard indicator state.
  */
 class MIndicatorServiceClient: public QObject
--- src/minputcontextconnection.cpp
+++ src/minputcontextconnection.cpp
@@ -16,12 +16,6 @@
 
 #include "minputcontextconnection.h"
 
-#include "mabstractinputmethod.h"
-#include "mattributeextensionmanager.h"
-#include "mattributeextensionid.h"
-#include "mimupdateevent.h"
-#include "maliit/namespaceinternal.h"
-
 #include <QKeyEvent>
 
 namespace {
@@ -36,7 +30,6 @@
     const char * const CursorPositionAttribute = "cursorPosition";
     const char * const HasSelectionAttribute = "hasSelection";
     const char * const InputMethodModeAttribute = "inputMethodMode";
-    const char * const VisualizationAttribute = "visualizationPriority";
     const char * const ToolbarIdAttribute = "toolbarId";
     const char * const ToolbarAttribute = "toolbar";
     const char * const WinId = "winId";
@@ -50,8 +43,6 @@
 public:
     MInputContextConnectionPrivate();
     ~MInputContextConnectionPrivate();
-
-    QSet<MAbstractInputMethod *> targets; // not owned by us
 };
 
 
@@ -79,9 +70,6 @@
     , mDetectableAutoRepeat(false)
 {
     Q_UNUSED(parent);
-
-    connect(&MAttributeExtensionManager::instance(), SIGNAL(keyOverrideCreated()),
-            this,                                    SIGNAL(keyOverrideCreated()));
 }
 
 
@@ -90,29 +78,7 @@
     delete d;
 }
 
-void MInputContextConnection::addTarget(MAbstractInputMethod *target)
-{
-    d->targets.insert(target);
-    target->handleAppOrientationChanged(lastOrientation);
-}
-
-void MInputContextConnection::removeTarget(MAbstractInputMethod *target)
-{
-    d->targets.remove(target);
-}
-
-void MInputContextConnection::updateInputMethodArea(const QRegion &region)
-{
-    Q_UNUSED(region);
-}
-
-QSet<MAbstractInputMethod *> MInputContextConnection::targets()
-{
-    return d->targets;
-}
-
 /* Accessors to widgetState */
-
 bool MInputContextConnection::focusState(bool &valid)
 {
     QVariant focusStateVariant = widgetState[FocusStateAttribute];
@@ -257,9 +223,7 @@
     if (activeConnection != connectionId)
         return;
 
-    Q_FOREACH (MAbstractInputMethod *target, targets()) {
-        target->handleMouseClickOnPreedit(pos, preeditRect);
-    }
+    Q_EMIT mouseClickedOnPreedit(pos, preeditRect);
 }
 
 
@@ -271,9 +235,7 @@
 
     preedit = text;
 
-    Q_FOREACH (MAbstractInputMethod *target, targets()) {
-        target->setPreedit(text, cursorPos);
-    }
+    Q_EMIT preeditChanged(text, cursorPos);
 }
 
 
@@ -284,9 +246,7 @@
 
     preedit.clear();
 
-    Q_FOREACH (MAbstractInputMethod *target, targets()) {
-        target->reset();
-    }
+    Q_EMIT resetInputMethodRequest();
 
     if (!preedit.isEmpty()) {
         qWarning("Preedit set from InputMethod::reset()!");
@@ -299,105 +259,15 @@
     unsigned int connectionId, const QMap<QString, QVariant> &stateInfo,
     bool handleFocusChange)
 {
-    // check visualization change
-    bool oldVisualization = false;
-    bool newVisualization = false;
-
-    QVariant variant = widgetState[VisualizationAttribute];
-
-    if (variant.isValid()) {
-        oldVisualization = variant.toBool();
-    }
-
-    variant = stateInfo[VisualizationAttribute];
-    if (variant.isValid()) {
-        newVisualization = variant.toBool();
-    }
-
-    // toolbar change
-    MAttributeExtensionId oldAttributeExtensionId;
-    MAttributeExtensionId newAttributeExtensionId;
-    oldAttributeExtensionId = attributeExtensionId;
-
-    variant = stateInfo[ToolbarIdAttribute];
-    if (variant.isValid()) {
-        // map toolbar id from local to global
-        newAttributeExtensionId = MAttributeExtensionId(variant.toInt(), QString::number(connectionId));
-    }
-    if (!newAttributeExtensionId.isValid()) {
-        newAttributeExtensionId = MAttributeExtensionId::standardAttributeExtensionId();
-    }
-
-    // update state
-    QStringList changedProperties;
-    for (QMap<QString, QVariant>::const_iterator iter = stateInfo.constBegin();
-         iter != stateInfo.constEnd();
-         ++iter)
-    {
-        if (widgetState.value(iter.key()) != iter.value()) {
-            changedProperties.append(iter.key());
-        }
-
-    }
-
-    const Qt::InputMethodHints lastHints = static_cast<Qt::InputMethodHints>(stateInfo.value(Maliit::Internal::inputMethodHints).toLongLong());
+    QMap<QString, QVariant> &oldState = widgetState;
 
     widgetState = stateInfo;
-    bool focusStateOk(false);
-    const bool widgetFocusState(focusState(focusStateOk));
-
-    if (!focusStateOk)
-    {
-        qCritical() << __PRETTY_FUNCTION__ << ": focus state is invalid.";
-    }
 
     if (handleFocusChange) {
-        Q_FOREACH (MAbstractInputMethod *target, targets()) {
-            target->handleFocusChange(widgetFocusState);
-        }
-
         Q_EMIT focusChanged(winId());
     }
 
-    // call notification methods if needed
-    if (oldVisualization != newVisualization) {
-        Q_FOREACH (MAbstractInputMethod *target, targets()) {
-            target->handleVisualizationPriorityChange(newVisualization);
-        }
-    }
-
-    // compare the toolbar id (global)
-    if (oldAttributeExtensionId != newAttributeExtensionId) {
-        QString toolbarFile = stateInfo[ToolbarAttribute].toString();
-        if (!MAttributeExtensionManager::instance().contains(newAttributeExtensionId) && !toolbarFile.isEmpty()) {
-            // register toolbar if toolbar manager does not contain it but
-            // toolbar file is not empty. This can reload the toolbar data
-            // if im-uiserver crashes.
-            variant = stateInfo[ToolbarIdAttribute];
-            if (variant.isValid()) {
-                const int toolbarLocalId = variant.toInt();
-                registerAttributeExtension(connectionId, toolbarLocalId, toolbarFile);
-            }
-        }
-        Q_EMIT toolbarIdChanged(newAttributeExtensionId);
-        // store the new used toolbar id(global).
-        attributeExtensionId = newAttributeExtensionId;
-    }
-    // this happens when we focus on a text widget with no attribute extensions.
-    else if (handleFocusChange && widgetFocusState)
-    {
-        Q_EMIT toolbarIdChanged(newAttributeExtensionId);
-    }
-
-    MImUpdateEvent ev(widgetState, changedProperties, lastHints);
-
-    Q_FOREACH (MAbstractInputMethod *target, targets()) {
-        if (not changedProperties.isEmpty()) {
-            (void) target->imExtensionEvent(&ev);
-        }
-
-        target->update();
-    }
+    Q_EMIT widgetStateChanged(connectionId, widgetState, oldState, handleFocusChange);
 }
 
 void
@@ -411,9 +281,8 @@
     // to this signal first before the plugins. This ensures
     // that the rotation animation can be painted sufficiently early.
     Q_EMIT appOrientationAboutToChange(angle);
-    Q_FOREACH (MAbstractInputMethod *target, targets()) {
-        target->handleAppOrientationAboutToChange(angle);
-    }
+
+    Q_EMIT appOrientationAboutToChangeCompleted(angle);
 }
 
 
@@ -426,10 +295,8 @@
     // Handle orientation changes through MImRotationAnimation with priority.
     // That's needed for getting the correct rotated pixmap buffers.
     Q_EMIT appOrientationChanged(angle);
-    Q_FOREACH (MAbstractInputMethod *target, targets()) {
-        target->handleAppOrientationChanged(angle);
-    }
-    lastOrientation = angle;
+
+    Q_EMIT appOrientationChangeCompleted(angle);
 }
 
 
@@ -439,7 +306,7 @@
     if (activeConnection != connectionId)
         return;
 
-    MAttributeExtensionManager::instance().setCopyPasteState(copyAvailable, pasteAvailable);
+    Q_EMIT copyPasteStateChanged(copyAvailable, pasteAvailable);
 }
 
 
@@ -451,40 +318,27 @@
     if (activeConnection != connectionId)
         return;
 
-    Q_FOREACH (MAbstractInputMethod *target, targets()) {
-        target->processKeyEvent(keyType, keyCode, modifiers, text, autoRepeat, count,
-                                nativeScanCode, nativeModifiers, time);
-    }
+    Q_EMIT recievedKeyEvent(keyType, keyCode,
+                            modifiers, text, autoRepeat, count,
+                            nativeScanCode, nativeModifiers, time);
 }
 
 void MInputContextConnection::registerAttributeExtension(unsigned int connectionId, int id,
                                                          const QString &attributeExtension)
 {
-    MAttributeExtensionId globalId(id, QString::number(connectionId));
-    if (globalId.isValid() && !attributeExtensionIds.contains(globalId)) {
-        MAttributeExtensionManager::instance().registerAttributeExtension(globalId, attributeExtension);
-        attributeExtensionIds.insert(globalId);
-    }
+    Q_EMIT attributeExtensionRegistered(connectionId, id, attributeExtension);
 }
 
 void MInputContextConnection::unregisterAttributeExtension(unsigned int connectionId, int id)
 {
-    MAttributeExtensionId globalId(id, QString::number(connectionId));
-    if (globalId.isValid() && attributeExtensionIds.contains(globalId)) {
-        MAttributeExtensionManager::instance().unregisterAttributeExtension(globalId);
-        attributeExtensionIds.remove(globalId);
-    }
+    Q_EMIT attributeExtensionUnregistered(connectionId, id);
 }
 
 void MInputContextConnection::setExtendedAttribute(
     unsigned int connectionId, int id, const QString &target, const QString &targetName,
     const QString &attribute, const QVariant &value)
 {
-    qDebug() << __PRETTY_FUNCTION__;
-    MAttributeExtensionId globalId(id, QString::number(connectionId));
-    if (globalId.isValid() && attributeExtensionIds.contains(globalId)) {
-        MAttributeExtensionManager::instance().setExtendedAttribute(globalId, target, targetName, attribute, value);
-    }
+    Q_EMIT extendedAttributeChanged(connectionId, id, target, targetName, attribute, value);
 }
 /* End handlers for inbound communication */
 
@@ -568,17 +422,7 @@
 /* */
 void MInputContextConnection::handleDisconnection(unsigned int connectionId)
 {
-    // unregister toolbars registered by the lost connection
-    const QString service(QString::number(connectionId));
-    QSet<MAttributeExtensionId>::iterator i(attributeExtensionIds.begin());
-    while (i != attributeExtensionIds.end()) {
-        if ((*i).service() == service) {
-            MAttributeExtensionManager::instance().unregisterAttributeExtension(*i);
-            i = attributeExtensionIds.erase(i);
-        } else {
-            ++i;
-        }
-    }
+    Q_EMIT clientDisconnected(connectionId);
 
     if (activeConnection != connectionId) {
         return;
@@ -586,10 +430,7 @@
 
     activeConnection = 0;
 
-    // notify plugins
-    Q_FOREACH (MAbstractInputMethod *target, targets()) {
-        target->handleClientChange();
-    }
+    Q_EMIT activeClientDisconnected();
 }
 
 void MInputContextConnection::activateContext(unsigned int connectionId)
@@ -616,10 +457,8 @@
         setDetectableAutoRepeat(!mDetectableAutoRepeat);
     }
 
-    // notify plugins
-    Q_FOREACH (MAbstractInputMethod *target, targets()) {
-        target->handleClientChange();
-    }
+    Q_EMIT clientActivated(connectionId);
+
 }
 /* */
 
@@ -669,3 +508,8 @@
 
 void MInputContextConnection::sendActivationLostEvent()
 {}
+
+void MInputContextConnection::updateInputMethodArea(const QRegion &region)
+{
+    Q_UNUSED(region);
+}
--- src/minputcontextconnection.h
+++ src/minputcontextconnection.h
@@ -19,8 +19,6 @@
 
 #include "minputmethodnamespace.h"
 
-#include "mattributeextensionid.h"
-
 #include <QtCore>
 #include <QWidget> // For WId
 
@@ -30,10 +28,10 @@
 class MAbstractInputMethod;
 class MAttributeExtensionId;
 
-//! \internal
-/*!
- * \brief MInputContextConnection is a base class of the input method communication implementation
- * between the input context and the input method server.
+/*! \internal
+ * \ingroup maliitserver
+ * \brief Base class of the input method communication implementation between
+ * the input context and the input method server.
  */
 class MInputContextConnection: public QObject
 {
@@ -45,16 +43,6 @@
     virtual ~MInputContextConnection();
 
     /*!
-     * \brief Adds the target which get called on incoming requests
-     */
-    virtual void addTarget(MAbstractInputMethod *target);
-
-    /*!
-     * \brief Removes the handler of the connection
-     */
-    virtual void removeTarget(MAbstractInputMethod *target);
-
-    /*!
      * \brief Returns focus state if output parameter \a valid is \c true.
      *
      * By focus state it is meant to be focus state of an input widget
@@ -268,7 +256,7 @@
      *  \param pasteAvailable bool TRUE if clipboard content is not empty
      */
     void setCopyPasteState(unsigned int clientId,
-                                   bool copyAvailable, bool pasteAvailable);
+                           bool copyAvailable, bool pasteAvailable);
 
     /*!
      * \brief Process a key event redirected from hardware keyboard to input method plugin(s).
@@ -304,27 +292,44 @@
     virtual void updateInputMethodArea(const QRegion &region);
 
 Q_SIGNALS:
+    /* Emitted first */
     void appOrientationAboutToChange(int angle);
     void appOrientationChanged(int angle);
+    /* Emitted later */
+    void appOrientationAboutToChangeCompleted(int angle);
+    void appOrientationChangeCompleted(int angle);
 
     void focusChanged(WId id);
 
-    //! \internal
     //! Emitted when input method request to be shown.
     void showInputMethodRequest();
 
     //! Emitted when input method request to be hidden.
     void hideInputMethodRequest();
 
-    //! Emitted when set toobar to input method.
-    void toolbarIdChanged(const MAttributeExtensionId &id);
+    void resetInputMethodRequest();
 
-    //! This signal is emited when a new key override is created.
-    void keyOverrideCreated();
-    //! \internal_end.
+    void copyPasteStateChanged(bool copyAvailable, bool pasteAvailable);
+    void widgetStateChanged(unsigned int clientId, const QMap<QString, QVariant> &newState,
+                            const QMap<QString, QVariant> &oldState, bool focusChanged);
+
+    void attributeExtensionRegistered(unsigned int connectionId, int id, const QString &attributeExtension);
+    void attributeExtensionUnregistered(unsigned int connectionId, int id);
+    void extendedAttributeChanged(unsigned int connectionId, int id, const QString &target,
+                              const QString &targetName,const QString &attribute, const QVariant &value);
+
+    void clientActivated(unsigned int connectionId);
+    void clientDisconnected(unsigned int connectionId);
+    void activeClientDisconnected();
+
+    void preeditChanged(const QString &text, int cursorPos);
+    void mouseClickedOnPreedit(const QPoint &pos, const QRect &preeditRect);
+
+    void recievedKeyEvent(QEvent::Type keyType, Qt::Key keyCode,
+                         Qt::KeyboardModifiers modifiers, const QString &text, bool autoRepeat,
+                         int count, quint32 nativeScanCode, quint32 nativeModifiers, unsigned long time);
 
 protected:
-    QSet<MAbstractInputMethod *> targets();
     unsigned int activeConnection; // 0 means no active connection
 
     bool detectableAutoRepeat();
@@ -349,8 +354,6 @@
     bool mGlobalCorrectionEnabled;
     bool mRedirectionEnabled;
     bool mDetectableAutoRepeat;
-    MAttributeExtensionId attributeExtensionId; //current attribute extension id
-    QSet<MAttributeExtensionId> attributeExtensionIds; //all attribute extension ids
     QString preedit;
 };
 //! \internal_end
--- src/minputcontextglibdbusconnection.cpp
+++ src/minputcontextglibdbusconnection.cpp
@@ -17,6 +17,7 @@
 #define _BSD_SOURCE             // for mkdtemp
 
 #include "minputcontextglibdbusconnection.h"
+#include "serverdbusaddress.h"
 
 #include <QDataStream>
 #include <QDebug>
@@ -37,8 +38,6 @@
 
 namespace
 {
-    const char * const SocketDirectory = "/tmp/meego-im-uiserver";
-    const char * const SocketName = "imserver_dbus";
     const char * const DBusPath = "/com/meego/inputmethod/uiserver1";
 
     const char * const DBusClientPath = "/com/meego/inputmethod/inputcontext";
@@ -464,27 +463,13 @@
 }
 
 MInputContextGlibDBusConnection::MInputContextGlibDBusConnection()
-    : server(NULL)
+    : mAddress(new Maliit::Server::DBus::Address),
+      server(0)
 {
     dbus_g_thread_init();
     g_type_init();
 
-    if (!QDir().mkpath(SocketDirectory)) {
-        qFatal("IMServer: couldn't create directory for D-Bus socket.");
-    }
-    socketAddress = SocketDirectory;
-    socketAddress.append("/");
-    socketAddress.append(SocketName);
-    QFile::remove(socketAddress);
-    socketAddress.prepend("unix:path=");
-
-    DBusError error;
-    dbus_error_init(&error);
-
-    server = dbus_server_listen(socketAddress, &error);
-    if (!server) {
-        qFatal("Couldn't create D-Bus server: %s", error.message);
-    }
+    server = mAddress->connect();
 
     dbus_server_setup_with_g_main(server, NULL);
     dbus_server_set_new_connection_function(server, handleNewConnection, this, NULL);
--- src/minputcontextglibdbusconnection.h
+++ src/minputcontextglibdbusconnection.h
@@ -22,12 +22,16 @@
 #include <QtCore>
 #include <QtGui>
 
+#include "serverdbusaddress.h"
+#include <tr1/memory>
+
 struct MDBusGlibICConnection;
 struct MIMSDBusActivater;
 struct DBusServer;
 
-//! \internal
-/*! \brief Peer-to-peer DBus input context connection based on glib dbus bindings
+/*! \internal
+ * \ingroup maliitserver
+ * \brief Peer-to-peer DBus input context connection based on glib dbus bindings
  */
 class MInputContextGlibDBusConnection : public MInputContextConnection
 {
@@ -80,8 +84,9 @@
                      const QString &language);
 
 private:
-    QByteArray socketAddress;
+    const std::tr1::shared_ptr<Maliit::Server::DBus::Address> mAddress;
     DBusServer *server;
+
     /* Used to maintain a mapping between the connection identifiers
     and the object we actually use to handle communication for the given ID. */
     QMap<unsigned int,MDBusGlibICConnection *>mConnections;
--- src/minputmethodhost.h
+++ src/minputmethodhost.h
@@ -30,8 +30,8 @@
 
 using namespace std::tr1;
 
-//! \internal
-/*!
+/*! \internal
+ * \ingroup maliitserver
  * \brief Interface implementation for connecting input method instances to the environment.
  */
 class MInputMethodHost: public MAbstractInputMethodHost
--- src/minputmethodplugin.h
+++ src/minputmethodplugin.h
@@ -28,12 +28,13 @@
 class MAbstractInputMethodHost;
 
 
-/*!
- * \brief MInputMethodPlugin is an interface class for all input method plugins.
+/*! \ingroup pluginapi
+ * \brief An interface class for all input method plugins.
  *
- * To create a virtual keyboard / input method plugin, re-implement the virtual functions and
- * instantiate the input method implementation in the createInputMethod() method.
- * Make sure your plugin links against the m im framework library as well.
+ * To create a virtual keyboard / input method plugin, re-implement the virtual
+ * functions and instantiate the input method implementation in the
+ * createInputMethod() method. Make sure your plugin links against the m im
+ * framework library as well.
  */
 class MInputMethodPlugin
 {
--- src/mkeyoverride.h
+++ src/mkeyoverride.h
@@ -28,7 +28,7 @@
 
 class MKeyOverridePrivate;
 
-/*!
+/*! \ingroup maliitserver
  * \brief MKeyOverride is used to store key attribute overrides for virtual keyboard.
  */
 class MKeyOverride : public QObject
--- src/mkeyoverridedata.h
+++ src/mkeyoverridedata.h
@@ -27,8 +27,8 @@
 #include "mkeyoverride.h"
 
 
-/*!
-  \brief MKeyOverrideData corresponds to the key overrides.
+/*! \ingroup maliitserver
+ * \brief Corresponds to the key overrides.
  */
 class MKeyOverrideData : public QObject
 {
--- src/mpassthruwindow.cpp
+++ src/mpassthruwindow.cpp
(renamed from passthroughserver/mpassthruwindow.cpp)
--- src/mpassthruwindow.h
+++ src/mpassthruwindow.h
+/* * This file is part of meego-im-framework *
+ *
+ * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+ * All rights reserved.
+ * Contact: Nokia Corporation (directui at nokia.com)
+ *
+ * If you have questions regarding the use of this file, please contact
+ * Nokia at directui at nokia.com.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1 as published by the Free Software Foundation
+ * and appearing in the file LICENSE.LGPL included in the packaging
+ * of this file.
+ */
+#ifndef MPASSTHRUWINDOW_H
+#define MPASSTHRUWINDOW_H
+
+#include <QWidget>
+#include <QRegion>
+#include <QCloseEvent>
+
+class MImRemoteWindow;
+class MImXApplication;
+
+/*!
+ * \brief MPassThruWindow uses XFixes to redirect mouse events to VKB
+ */
+class MPassThruWindow: public QWidget
+{
+    Q_OBJECT
+
+public:
+    /*!
+     * \brief Constructor
+     * \param p QWidget* parent widget
+     */
+    explicit MPassThruWindow(MImXApplication *application);
+
+    //! Destructor
+    ~MPassThruWindow();
+
+    virtual bool event(QEvent *e);
+    void closeEvent(QCloseEvent *ev);
+
+    //! Return region occupied by current plugin
+    const QRegion &region();
+
+public Q_SLOTS:
+    //! Set window ID for given region
+    void inputPassthrough(const QRegion &region = QRegion());
+
+    //! Set the new remote window (application window)
+    void setRemoteWindow(MImRemoteWindow *remoteWindow = 0);
+
+    //! Schedules repainting for widget's background from remote window
+    void updateFromRemoteWindow(const QRegion &region);
+
+private:
+    Q_DISABLE_COPY(MPassThruWindow);
+
+    void updateInputRegion();
+    void updateWindowType();
+
+    MImRemoteWindow *remoteWindow;
+    QRegion mRegion;
+    MImXApplication *mApplication;
+
+    friend class Ut_PassthroughServer;
+};
+
+#endif
--- src/mtoolbardata.h
+++ src/mtoolbardata.h
@@ -32,8 +32,8 @@
 struct MTBParseStructure;
 class MToolbarDataPrivate;
 
-/*!
-  \brief MToolbarData corresponds to a toolbar defined in a XML file
+/*! \ingroup maliitserver
+ * \brief corresponds to a toolbar defined in a XML file.
  */
 class MToolbarData : public QObject
 {
--- src/mtoolbaritem.h
+++ src/mtoolbaritem.h
@@ -29,10 +29,10 @@
 class MToolbarItemPrivate;
 class MToolbarItemActionPrivate;
 
-/*!
- * \brief MToolbarItemAction defines action which could be performed by MToolbarItem.
+/*! \ingroup maliitserver
+ * \brief Defines action which could be performed by MToolbarItem.
  *
- * See also MInputMethod::ActionType
+ * \sa MInputMethod::ActionType
  */
 class MToolbarItemAction {
 public:
--- src/mtoolbarlayout.h
+++ src/mtoolbarlayout.h
@@ -27,8 +27,8 @@
 
 class MToolbarLayoutPrivate;
 
-/*!
- * \brief MToolbarLayout defines toolbar layout for specified orientation
+/*! \ingroup maliitserver
+ * \brief Defines toolbar layout for specified orientation.
  */
 class MToolbarLayout {
 public:
--- src/org.maliit.server.service.in
+++ src/org.maliit.server.service.in
+[D-BUS Service]
+Name=org.maliit.server
+Exec=@M_IM_INSTALL_BIN@/maliit-server @MALIIT_SERVER_ARGUMENTS@
+
--- src/serverdbusaddress.cpp
+++ src/serverdbusaddress.cpp
+/* * This file is part of meego-im-framework *
+ *
+ * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+ * All rights reserved.
+ * Contact: Nokia Corporation (directui at nokia.com)
+ *
+ * If you have questions regarding the use of this file, please contact
+ * Nokia at directui at nokia.com.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1 as published by the Free Software Foundation
+ * and appearing in the file LICENSE.LGPL included in the packaging
+ * of this file.
+ */
+
+#include "serverdbusaddress.h"
+
+#include <QDebug>
+#include <QDBusConnection>
+
+#include <dbus/dbus.h>
+
+namespace {
+    const char * const MaliitServerName = "org.maliit.server";
+    const char * const MaliitServerObjectPath = "/org/maliit/server/address";
+}
+
+namespace Maliit {
+namespace Server {
+namespace DBus {
+
+AddressPublisher::AddressPublisher(const QString &address)
+    : QObject()
+    , mAddress(address)
+{
+    QDBusConnection::sessionBus().registerObject(MaliitServerObjectPath, this, QDBusConnection::ExportAllProperties);
+    QDBusConnection::sessionBus().registerService(MaliitServerName);
+}
+
+AddressPublisher::~AddressPublisher()
+{
+    QDBusConnection::sessionBus().unregisterObject(MaliitServerObjectPath);
+}
+
+QString AddressPublisher::address() const
+{
+    return mAddress;
+}
+
+
+Address::Address()
+{}
+
+DBusServer* Address::connect()
+{
+    std::string dbusAddress("unix:tmpdir=/tmp/maliit-server");
+
+    DBusError error;
+    dbus_error_init(&error);
+
+    DBusServer *server = dbus_server_listen(dbusAddress.c_str(), &error);
+    if (!server) {
+        qFatal("Couldn't create D-Bus server: %s", error.message);
+    }
+
+    char *address = dbus_server_get_address(server);
+    publisher.reset(new AddressPublisher(QString::fromLatin1(address)));
+    dbus_free(address);
+
+    return server;
+}
+
+} // namespace DBus
+} // namespace Server
+} // namespace Maliit
--- src/serverdbusaddress.h
+++ src/serverdbusaddress.h
+/* * This file is part of meego-im-framework *
+ *
+ * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
+ * All rights reserved.
+ * Contact: Nokia Corporation (directui at nokia.com)
+ *
+ * If you have questions regarding the use of this file, please contact
+ * Nokia at directui at nokia.com.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1 as published by the Free Software Foundation
+ * and appearing in the file LICENSE.LGPL included in the packaging
+ * of this file.
+ */
+
+#ifndef MALIIT_SERVER_DBUS_SERVERDBUSADDRESS_H
+#define MALIIT_SERVER_DBUS_SERVERDBUSADDRESS_H
+
+#include <string>
+
+#include <QObject>
+
+struct DBusServer;
+
+namespace Maliit {
+namespace Server {
+namespace DBus {
+
+class AddressPublisher : public QObject
+{
+    Q_OBJECT
+    Q_CLASSINFO("D-Bus Interface", "org.maliit.Server.Address")
+
+    Q_PROPERTY(QString address READ address)
+
+public:
+    explicit AddressPublisher(const QString &address);
+    ~AddressPublisher();
+    QString address() const;
+
+private:
+    const QString mAddress;
+};
+
+class Address
+{
+public:
+    explicit Address();
+
+    virtual DBusServer* connect();
+
+private:
+    QScopedPointer<AddressPublisher> publisher;
+};
+
+} // namespace DBus
+} // namespace Server
+} // namespace Maliit
+
+#endif // MALIIT_SERVER_DBUS_SERVERDBUSADDRESS_H
--- src/src.pro
+++ src/src.pro
@@ -3,7 +3,7 @@
 VERSION = 0.1.0
 TEMPLATE = lib
 TARGET = $$MALIIT_PLUGINS_LIB
-INCLUDEPATH += .. ../passthroughserver ../common
+INCLUDEPATH += .. ../common
 
 # Input
 HEADERSINSTALL = \
@@ -34,7 +34,6 @@
         mimpluginmanager_p.h \
         mimpluginmanageradaptor.h \
         mindicatorserviceclient.h \
-        mimapplication.h \
         minputcontextconnection.h \
         minputmethodhost.h \
         mtoolbardata_p.h \
@@ -45,13 +44,15 @@
         minputcontextglibdbusconnection.h \
         mimhwkeyboardtracker.h \
         mimupdateevent_p.h \
-        mimupdatereceiver_p.h \
         mimgraphicsview_p.h \
         mimwidget_p.h \
         mimpluginsproxywidget.h \
         mimonscreenplugins.h \
         mimhwkeyboardtracker_p.h \
         mimextensionevent_p.h \
+        mimdummyinputcontext.h \
+        mimserver.h \
+        serverdbusaddress.h \
 
 SOURCES += \
         mimabstractpluginfactory.cpp \
@@ -62,7 +63,6 @@
         mabstractinputmethodhost.cpp \
         minputmethodhost.cpp \
         minputcontextconnection.cpp \
-        mimapplication.cpp \
         mtoolbaritem.cpp \
         mtoolbardata.cpp \
         mkeyoverride.cpp \
@@ -83,10 +83,13 @@
         mimpluginsproxywidget.cpp \
         mimonscreenplugins.cpp \
         mimsubviewdescription.cpp \
+        mimdummyinputcontext.cpp \
+        mimserver.cpp \
+        serverdbusaddress.cpp \
 
 x11 {
     HEADERS += \
-        ../passthroughserver/mpassthruwindow.h \
+        mpassthruwindow.h \
         mimremotewindow.h \
         mimxerrortrap.h \
         mimxextension.h \
@@ -97,11 +100,19 @@
         mimremotewindow.cpp \
         mimxerrortrap.cpp \
         mimxextension.cpp \
-        ../passthroughserver/mpassthruwindow.cpp \
+        mpassthruwindow.cpp \
         mimrotationanimation.cpp \
         mimxapplication.cpp \
 }
 
+qpa {
+    SOURCES += \
+        mimqpaplatform.cpp \
+
+    HEADERS += \
+        mimqpaplatform.h
+}
+
 CONFIG += qdbus link_pkgconfig
 QT = core gui xml
 
@@ -141,7 +152,7 @@
 }
 
 !enable-legacy {
-    outputFiles(maliit-plugins-$${MALIIT_PLUGINS_INTERFACE_VERSION}.pc, maliit-framework.schemas)
+    outputFiles(maliit-plugins-$${MALIIT_PLUGINS_INTERFACE_VERSION}.pc, maliit-framework.schemas, org.maliit.server.service)
 } else {
     outputFiles(MeegoImFramework.pc, meegoimframework.prf, meego-im-framework.schemas)
 }
@@ -159,12 +170,21 @@
 }
 install_schemas.path = $$M_IM_INSTALL_SCHEMAS
 
+!enable-legacy {
+    install_services.path = $$system(pkg-config --variable session_bus_services_dir dbus-1)
+    install_services.files = org.maliit.server.service
+}
+
 INSTALLS += target \
     headers \
     install_prf \
     install_pkgconfig \
     install_schemas \
 
+!enable-legacy {
+    INSTALLS += install_services
+}
+
 # Registering the GConf schemas in the gconf database
 gconftool = gconftool-2
 gconf_config_source = $$system(echo $GCONF_CONFIG_SOURCE)
--- tests/common_check.pri
+++ tests/common_check.pri
@@ -4,7 +4,7 @@
     TESTING_IN_SANDBOX=1 \
     TESTPLUGIN_PATH=../plugins \
     TESTDATA_PATH=$$IN_PWD \
-    LD_LIBRARY_PATH=../../input-method-quick:../../src:../../input-context/:../../passthroughserver/:../../maliit:../plugins:$(LD_LIBRARY_PATH) \
+    LD_LIBRARY_PATH=../../maliit-plugins-quick/input-method:../../maliit-plugins-quick/plugin-factory:../../src:../../input-context/:../../maliit:../plugins:$(LD_LIBRARY_PATH) \
     ./$$TARGET
 
 check.depends += $$TARGET
--- tests/common_top.pri
+++ tests/common_top.pri
@@ -16,13 +16,11 @@
 
 TOP_DIR = ../..
 SRC_DIR = $$TOP_DIR/src
-PASSTHROUGH_DIR = $$TOP_DIR/passthroughserver
 
 INCLUDEPATH += . \
                $$TOP_DIR \
                $$SRC_DIR \
                $$TOP_DIR/common \
-               $$PASSTHROUGH_DIR \
                $$UTILS_DIR \
 
 HEADERS += \
--- tests/ft_exampleplugin/ft_exampleplugin.cpp
+++ tests/ft_exampleplugin/ft_exampleplugin.cpp
@@ -16,11 +16,11 @@
 
 #include "utils.h"
 #include "ft_exampleplugin.h"
-#include "mimapplication.h"
 
 #include <minputmethodhost.h>
 #include <minputmethodplugin.h>
 #include <minputcontextconnection.h>
+
 #include <QtCore>
 #include <QtGui>
 
@@ -36,7 +36,7 @@
     // Enforcing raster GS to make test reliable:
     QApplication::setGraphicsSystem("raster");
 
-    app = new MIMApplication(argc, argv);
+    app = new QApplication(argc, argv);
 }
 
 void Ft_ExamplePlugin::cleanupTestCase()
--- tests/ft_exampleplugin/ft_exampleplugin.h
+++ tests/ft_exampleplugin/ft_exampleplugin.h
@@ -21,8 +21,6 @@
 #include <QtCore>
 #include <QtGui>
 
-class MIMApplication;
-
 class Ft_ExamplePlugin 
     : public QObject
 {
@@ -39,7 +37,7 @@
     void testFunction();
 
 private:
-    MIMApplication *app;
+    QCoreApplication *app;
 
 };
 
--- tests/ft_exampleplugin/ft_exampleplugin.pro
+++ tests/ft_exampleplugin/ft_exampleplugin.pro
@@ -5,8 +5,7 @@
 
 INCLUDEPATH += \
     $$SRC_DIR \
-    
-DEFINES += UNIT_TEST
+
 QT += core gui
 
 # Input
--- tests/ft_mimpluginmanager/ft_mimpluginmanager.cpp
+++ tests/ft_mimpluginmanager/ft_mimpluginmanager.cpp
@@ -3,18 +3,17 @@
 #include "mkeyboardstatetracker_stub.h"
 #include "dummyimplugin.h"
 #include "dummyinputmethod.h"
-#include "mimapplication.h"
-#include "minputcontextconnection.h"
-
 #include "utils.h"
 
+#include <minputcontextconnection.h>
+#include <mimpluginmanager.h>
+#include <mimpluginmanager_p.h>
+
 #include <QProcess>
 #include <QGraphicsScene>
 #include <QRegExp>
 #include <QApplication>
 #include <QPointer>
-#include <mimpluginmanager.h>
-#include <mimpluginmanager_p.h>
 
 using namespace std::tr1;
 
@@ -56,7 +55,7 @@
     static char *argv[1] = { (char *) "ut_mimpluginmanager" };
     static int argc = 1;
 
-    app = new MIMApplication(argc, argv);
+    app = new QApplication(argc, argv);
 }
 
 void Ft_MIMPluginManager::cleanupTestCase()
--- tests/ft_mimpluginmanager/ft_mimpluginmanager.h
+++ tests/ft_mimpluginmanager/ft_mimpluginmanager.h
@@ -28,7 +28,7 @@
     void testPluginDescriptions();
 
 private:
-    MIMApplication *app;
+    QApplication *app;
     MIMPluginManager *subject;
 };
 
--- tests/rt.sh
+++ tests/rt.sh
@@ -39,7 +39,7 @@
 if [ ! -f ./$BASENAME ]; then
     EXIT_CODE=255
 else
-    TESTING_IN_SANDBOX=1 TESTPLUGIN_PATH=../plugins LD_LIBRARY_PATH=../../src:../../input-context/:../../passthroughserver/:$LD_LIBRARY_PATH dui-run ./$BASENAME -xml -o ./$BASENAME.log
+    TESTING_IN_SANDBOX=1 TESTPLUGIN_PATH=../plugins LD_LIBRARY_PATH=../../src:../../input-context/:../../common:../../maliit-plugins-quick/input-method:../../maliit-plugins-quick/plugin-factory:$LD_LIBRARY_PATH dui-run ./$BASENAME -xml -o ./$BASENAME.log
     xsltproc --nonet ../qtestlib2junitxml.xsl $QTESTLOG > $JUNITLOG
     EXIT_CODE=$?
 fi
--- tests/ut_mimapplication/ut_mimapplication.pro
+++ tests/ut_mimapplication/ut_mimapplication.pro
@@ -1,6 +1,6 @@
 include(../common_top.pri)
 
-INCLUDEPATH += ../../passthroughserver \
+INCLUDEPATH += ../../src \
                ../stubs \
 
 # Input
@@ -13,17 +13,6 @@
     ut_mimapplication.cpp \
     ../stubs/fakegconf.cpp \
 
-isEqual(code_coverage_option, off) {
-    HEADERS += \
-        $$PASSTHROUGH_DIR/mpassthruwindow.h
-    SOURCES += \
-        $$PASSTHROUGH_DIR/mpassthruwindow.cpp
-} else {
-    LIBS += \
-        $$PASSTHROUGH_DIR/moc_mpassthruwindow.o \
-        $$PASSTHROUGH_DIR/mpassthruwindow.o
-}
-
 CONFIG += plugin qdbus
 
 LIBS += \
--- tests/ut_mimpluginmanager/ut_mimpluginmanager.cpp
+++ tests/ut_mimpluginmanager/ut_mimpluginmanager.cpp
@@ -1,9 +1,9 @@
 #include "ut_mimpluginmanager.h"
+
 #ifdef Q_WS_X11
 #include "mimxapplication.h"
-#else
-#include "mimapplication.h"
 #endif
+
 #include "mimsettings_stub.h"
 #include "dummyimplugin.h"
 #include "dummyimplugin3.h"
@@ -79,7 +79,7 @@
     app = new MImXApplication(argc, argv);
     proxyWidget = static_cast<MImXApplication*>(app)->pluginsProxyWidget();
 #else
-    app = new MIMApplication(argc, argv);
+    app = new QApplication(argc, argv);
     proxyWidget = new QWidget;
 #endif
 
@@ -501,13 +501,13 @@
 
     //test toolbar status when switch plugin
     MAttributeExtensionId toolbarId1(1, "toolbarIdTest1");
-    MAttributeExtensionManager::instance().registerAttributeExtension(toolbarId1, Toolbar1);
+    subject->mAttributeExtensionManager->registerAttributeExtension(toolbarId1, Toolbar1);
     QSharedPointer<const MToolbarData> toolbarData1 =
-        MAttributeExtensionManager::instance().toolbarData(toolbarId1);
+        subject->mAttributeExtensionManager->toolbarData(toolbarId1);
     MAttributeExtensionId toolbarId2(2, "toolbarIdTest2");
-    MAttributeExtensionManager::instance().registerAttributeExtension(toolbarId2, Toolbar2);
+    subject->mAttributeExtensionManager->registerAttributeExtension(toolbarId2, Toolbar2);
     QSharedPointer<const MToolbarData> toolbarData2 =
-        MAttributeExtensionManager::instance().toolbarData(toolbarId2);
+        subject->mAttributeExtensionManager->toolbarData(toolbarId2);
 
     QVERIFY(toolbarData1.data());
     QVERIFY(toolbarData2.data());
@@ -525,8 +525,8 @@
     QVERIFY(inputMethod->toolbarParam == toolbarData2);
     QVERIFY(inputMethod3->toolbarParam == toolbarData2);
 
-    MAttributeExtensionManager::instance().unregisterAttributeExtension(toolbarId1);
-    MAttributeExtensionManager::instance().unregisterAttributeExtension(toolbarId2);
+    subject->mAttributeExtensionManager->unregisterAttributeExtension(toolbarId1);
+    subject->mAttributeExtensionManager->unregisterAttributeExtension(toolbarId2);
 }
 
 void Ut_MIMPluginManager::checkHandlerMap(int handler, const QString &name)
@@ -818,13 +818,13 @@
     QVERIFY(inputMethod);
 
     MAttributeExtensionId toolbarId1(1, "toolbarIdTest1");
-    MAttributeExtensionManager::instance().registerAttributeExtension(toolbarId1, Toolbar1);
+    subject->mAttributeExtensionManager->registerAttributeExtension(toolbarId1, Toolbar1);
     QSharedPointer<const MToolbarData> toolbarData1 =
-        MAttributeExtensionManager::instance().toolbarData(toolbarId1);
+        subject->mAttributeExtensionManager->toolbarData(toolbarId1);
     MAttributeExtensionId toolbarId2(2, "toolbarIdTest2");
-    MAttributeExtensionManager::instance().registerAttributeExtension(toolbarId2, Toolbar2);
+    subject->mAttributeExtensionManager->registerAttributeExtension(toolbarId2, Toolbar2);
     QSharedPointer<const MToolbarData> toolbarData2 =
-        MAttributeExtensionManager::instance().toolbarData(toolbarId2);
+        subject->mAttributeExtensionManager->toolbarData(toolbarId2);
 
     QVERIFY(toolbarData1.data());
     QVERIFY(toolbarData2.data());
@@ -836,8 +836,8 @@
     manager->setToolbar(toolbarId2);
     QVERIFY(inputMethod->toolbarParam == toolbarData2);
 
-    MAttributeExtensionManager::instance().unregisterAttributeExtension(toolbarId1);
-    MAttributeExtensionManager::instance().unregisterAttributeExtension(toolbarId2);
+    subject->mAttributeExtensionManager->unregisterAttributeExtension(toolbarId1);
+    subject->mAttributeExtensionManager->unregisterAttributeExtension(toolbarId2);
 }
 
 void Ut_MIMPluginManager::testLoadedPluginsInfo_data()
--- tests/ut_mimpluginmanager/ut_mimpluginmanager.h
+++ tests/ut_mimpluginmanager/ut_mimpluginmanager.h
@@ -4,7 +4,6 @@
 #include <QtTest/QtTest>
 #include <QObject>
 
-class MIMApplication;
 class MIMPluginManager;
 class MIMPluginManagerPrivate;
 class QCoreApplication;
@@ -52,7 +51,7 @@
 private:
     void handleMessages();
 
-    MIMApplication *app;
+    QApplication *app;
     QWidget *proxyWidget;
     QString pluginPath;
     MIMPluginManager *manager;
--- tests/ut_minputcontext/ut_minputcontext.cpp
+++ tests/ut_minputcontext/ut_minputcontext.cpp
@@ -7,6 +7,7 @@
 #include <QGraphicsView>
 #include <QLineEdit>
 
+#include <maliit/namespace.h>
 #include <maliit/inputmethod.h>
 #include <maliit/preeditinjectionevent.h>
 
@@ -893,6 +894,50 @@
 #endif
 }
 
+void Ut_MInputContext::testPropertyNameNormalization_data()
+{
+    typedef QByteArray QBA;
+    typedef QVariant QV;
+
+    QTest::addColumn<QBA>("name");
+    QTest::addColumn<QBA>("defaultName");
+    QTest::addColumn<QVariant>("value");
+    QTest::addColumn<QVariant>("expected");
+
+    QTest::newRow("no normalization")
+     << QBA("maliit-western-numeric-input-enforced")
+     << QBA(Maliit::InputMethodQuery::westernNumericInputEnforced)
+     << QV(true) << QV(true);
+
+    QTest::newRow("Qt component normalization")
+     << QBA("westernNumericInputEnforced")
+     << QBA(Maliit::InputMethodQuery::westernNumericInputEnforced)
+     << QV(true) << QV(true);
+
+    QTest::newRow("Invalid property")
+     << QBA("invalidPropertyName")
+     << QBA("invalid-property-name")
+     << QV(42) << QV();
+}
+
+void Ut_MInputContext::testPropertyNameNormalization()
+{
+    QFETCH(QByteArray, name);
+    QFETCH(QByteArray, defaultName);
+    QFETCH(QVariant, value);
+    QFETCH(QVariant, expected);
+
+    WidgetStub widget(0);
+    gFocusedWidget = &widget;
+    m_subject->setFocusWidget(&widget);
+
+    widget.setProperty(name.data(), value);
+    m_subject->update();
+    QVariant extracted = m_subject->getStateInformation().value(QString(defaultName));
+
+    QCOMPARE(extracted, expected);
+}
+
 
 QTEST_APPLESS_MAIN(Ut_MInputContext)
 
--- tests/ut_minputcontext/ut_minputcontext.h
+++ tests/ut_minputcontext/ut_minputcontext.h
@@ -173,6 +173,9 @@
 
     void testMPreeditInjectionEventCompatibility();
 
+    void testPropertyNameNormalization_data();
+    void testPropertyNameNormalization();
+
 private:
     void waitAndProcessEvents(int waitTime);
 
--- tests/ut_minputmethodquickplugin/ut_minputmethodquickplugin.cpp
+++ tests/ut_minputmethodquickplugin/ut_minputmethodquickplugin.cpp
@@ -16,11 +16,11 @@
 
 #include "utils.h"
 #include "ut_minputmethodquickplugin.h"
-#include "mimapplication.h"
 
 #include <minputmethodquickplugin.h>
 #include <minputmethodquick.h>
 #include <minputmethodhost.h>
+#include <maliitquickpluginfactory.h>
 #include <QtCore>
 #include <QtGui>
 
@@ -36,7 +36,7 @@
     // Enforcing raster GS to make test reliable:
     QApplication::setGraphicsSystem("raster");
 
-    app = new MIMApplication(argc, argv);
+    app = new QApplication(argc, argv);
 }
 
 void Ut_MInputMethodQuickPlugin::cleanupTestCase()
@@ -54,7 +54,7 @@
 {
     QTest::addColumn<QString>("testPluginPath");
     QTest::newRow("Hello world")
-        << "helloworld/libqmlhelloworldplugin.so";
+        << "helloworld/helloworld.qml";
     QTest::newRow("Cycle keys")
         << "cyclekeys/libqmlcyclekeysplugin.so";
     QTest::newRow("Override")
@@ -76,11 +76,19 @@
     const QString pluginPath = pluginDir.absoluteFilePath(testPluginPath);
     QVERIFY(pluginDir.exists(pluginPath));
 
-    QPluginLoader loader(pluginPath);
-    QObject *pluginInstance = loader.instance();
-    QVERIFY(pluginInstance != 0);
+    QObject *pluginInstance = 0;
+    MInputMethodPlugin *plugin = 0;
+
+    if (pluginPath.endsWith(".qml")) {
+        MaliitQuickPluginFactory factory;
+        plugin = factory.create(pluginPath);
+    } else {
+        QPluginLoader loader(pluginPath);
+        pluginInstance = loader.instance();
+        QVERIFY(pluginInstance != 0);
+        plugin =  qobject_cast<MInputMethodPlugin *>(pluginInstance);
+    }
 
-    MInputMethodPlugin *plugin =  qobject_cast<MInputMethodPlugin *>(pluginInstance);
     QVERIFY(plugin != 0);
 
     MInputMethodQuick *testee = static_cast<MInputMethodQuick *>(
--- tests/ut_minputmethodquickplugin/ut_minputmethodquickplugin.h
+++ tests/ut_minputmethodquickplugin/ut_minputmethodquickplugin.h
@@ -38,7 +38,7 @@
     void testQmlSetup();
 
 private:
-    MIMApplication *app;
+    QApplication *app;
 };
 
 #endif // UT_MINPUTMETHODQUICKPLUGIN_H
--- tests/ut_minputmethodquickplugin/ut_minputmethodquickplugin.pro
+++ tests/ut_minputmethodquickplugin/ut_minputmethodquickplugin.pro
@@ -1,14 +1,16 @@
 include(../common_top.pri)
 
-QUICK_DIR = ../../input-method-quick
+QUICK_DIR = ../../maliit-plugins-quick
+QUICK_IM_DIR = $${QUICK_DIR}/input-method
+QUICK_FACTORY_DIR = $${QUICK_DIR}/plugin-factory
 INCLUDEPATH += \
     $$SRC_DIR \
-    $$QUICK_DIR \
-    
-DEFINES += UNIT_TEST
+    $$QUICK_IM_DIR \
+    $$QUICK_FACTORY_DIR \
+
 QT += core gui declarative
 
-IN_TREE_TEST_PLUGIN_DIR = $$OUT_PWD/../../examples/plugins
+IN_TREE_TEST_PLUGIN_DIR = $${OUT_PWD}/../../examples/plugins
 DEFINES += IN_TREE_TEST_PLUGIN_DIR=\\\"$${IN_TREE_TEST_PLUGIN_DIR}\\\"
 
 # Input
@@ -19,7 +21,11 @@
     ut_minputmethodquickplugin.cpp \
 
 LIBS += \
-    $$SRC_DIR/lib$${MALIIT_PLUGINS_LIB}.so \
-    $$QUICK_DIR/lib$${MALIIT_PLUGINS_QUICK_LIB}.so \
+    -L$${QUICK_IM_DIR} \
+    -L$${QUICK_FACTORY_DIR} \
+    -L$${SRC_DIR} \
+    -l$${MALIIT_PLUGINS_LIB} \
+    -l$${MALIIT_PLUGINS_QUICK_LIB} \
+    -l$${MALIIT_PLUGINS_QUICK_FACTORY} \
 
 include(../common_check.pri)
--- tests/ut_passthroughserver/ut_passthroughserver.pro
+++ tests/ut_passthroughserver/ut_passthroughserver.pro
@@ -5,22 +5,10 @@
 # Input
 HEADERS += \
     ut_passthroughserver.h \
-    $$PASSTHROUGH_DIR/mpassthruwindow.h \
 
 SOURCES += \
     ut_passthroughserver.cpp \
 
-
 QT += testlib
 
-isEqual(code_coverage_option, off) {
-    SOURCES += \
-        $$PASSTHROUGH_DIR/mpassthruwindow.cpp
-}else {
-    QMAKE_CXXFLAGS += -ftest-coverage -fprofile-arcs -fno-elide-constructors
-    # requires to run make (for $$PASSTHROUGH_DIR) before make check:
-    LIBS += $$PASSTHROUGH_DIR/mpassthruwindow.o
-}
-
-
 include(../common_check.pri)
--- tests/ut_selfcompositing/ut_selfcompositing.pro
+++ tests/ut_selfcompositing/ut_selfcompositing.pro
@@ -1,30 +1,14 @@
 include(../common_top.pri)
 
-PASSTHRU_DIR = ../../passthroughserver
 INCLUDEPATH += \
     $$SRC_DIR \
-    $$PASSTHRU_DIR \
-    
-DEFINES += UNIT_TEST
 
 # Input
 HEADERS += \
     ut_selfcompositing.h \
-    $$SRC_DIR/mimxapplication.h \
-    $$SRC_DIR/mimapplication.h \
-    $$SRC_DIR/mimremotewindow.h \
-    $$SRC_DIR/mimwidget.h \ 
-    $$SRC_DIR/mimgraphicsview.h \
-    $$PASSTHRU_DIR/mpassthruwindow.h \
 
 SOURCES += \
     ut_selfcompositing.cpp \
-    $$SRC_DIR/mimapplication.cpp \
-    $$SRC_DIR/mimxapplication.cpp \
-    $$SRC_DIR/mimremotewindow.cpp \
-    $$SRC_DIR/mimwidget.cpp \ 
-    $$SRC_DIR/mimgraphicsview.cpp \
-    $$PASSTHRU_DIR/mpassthruwindow.cpp \
 
 LIBS += \
     $$SRC_DIR/lib$${MALIIT_PLUGINS_LIB}.so -lXcomposite -lXdamage -lXfixes

++++++ maliit-framework.yaml
--- maliit-framework.yaml
+++ maliit-framework.yaml
@@ -1,6 +1,6 @@
 Name: maliit-framework
 Summary: Core libraries of Maliit and server
-Version: 0.80.8
+Version: 0.81.0.1
 Release: 1
 Group: System/Libraries
 License: LGPLv2.1
@@ -10,6 +10,8 @@
 ExtraSources:
     - maliit-server.desktop;%{_sysconfdir}/xdg/autostart
     - maliit-server.sh;%{_sysconfdir}/profile.d
+Patches:
+    - maliit-sdk-examples.patch
 Description: |
     Core libraries of Maliit and server
 PkgConfigBR:
@@ -35,6 +37,7 @@
     - "%{_bindir}/maliit-server"
     - "%{_libdir}/libmaliit-plugins-0.80.so.*"
     - "%{_libdir}/qt4/plugins/inputmethods/libmaliit.so"
+    - "%{_datadir}/dbus-1/services/org.maliit.server.service"
     - "%config %{_sysconfdir}/xdg/autostart/*.desktop"
     - "%config %{_sysconfdir}/profile.d/maliit-server.sh"
     - "%config %{_sysconfdir}/gconf/schemas/maliit-framework.schemas"
@@ -59,7 +62,22 @@
       Group: Development/Libraries
       Description: Documentation for the Maliit Input Method Framework
       Files:
-         - "%{_docdir}/maliit-framework"
+          - "%{_docdir}/maliit-framework/html"
+
+    - Name: sdk
+      Summary: Maliit Framework SDK
+      Group: Development/Libraries
+      Description: SDK environment for Maliit
+      Files:
+          - "%{_bindir}/maliit-sdk"
+          - "%{_docdir}/maliit-framework/maliit-sdk"
+      PkgConfigBR:
+          - maliit-framework-0.80
+          - maliit-1.0
+          - maliit-plugins-0.80
+          - maliit-plugins-quick-0.80
+      Requires:
+          - maliit-framework-doc
 
     - Name: tests
       Summary: Maliit Framework Input Method Tests Package
@@ -110,6 +128,7 @@
       Description: Development files for the Maliit Input Method Quick library
       Files:
           - "%{_libdir}/libmaliit-plugins-quick-0.80.so"
+          - "%{_libdir}/maliit/plugins-0.80/factories/libmaliit-plugins-quick-factory-0.80.so"
           - "%{_includedir}/maliit/plugins-quick-0.80/"
           - "%{_libdir}/pkgconfig/maliit-plugins-quick-0.80.pc"
       Requires:

++++++ maliit-sdk-examples.patch (new)
--- maliit-sdk-examples.patch
+++ maliit-sdk-examples.patch
+diff -Nurwp maliit-framework-0.81.0.1-orig/examples/apps/gtk2/gtk2.pro maliit-framework-0.81.0.1-chag/examples/apps/gtk2/gtk2.pro
+--- maliit-framework-0.81.0.1-orig/examples/apps/gtk2/gtk2.pro	2011-11-23 13:01:17.000000000 -0430
++++ maliit-framework-0.81.0.1-chag/examples/apps/gtk2/gtk2.pro	2011-11-25 12:22:54.934997195 -0430
+@@ -1,6 +1,8 @@
+ TEMPLATE = app
+ TARGET = maliit-exampleapp-gtk2
+ 
++OBJECTS_DIR = .obj
++
+ BUILD_TYPE = unittest
+ 
+ contains(BUILD_TYPE, unittest) {
+@@ -15,4 +17,4 @@ PKGCONFIG += gtk+-2.0
+ 
+ SOURCES = exampleapp-gtk.c
+ 
+-QMAKE_CLEAN += target
++QMAKE_CLEAN += maliit-exampleapp-gtk2
+diff -Nurwp maliit-framework-0.81.0.1-orig/examples/apps/plainqt/plainqt.pro maliit-framework-0.81.0.1-chag/examples/apps/plainqt/plainqt.pro
+--- maliit-framework-0.81.0.1-orig/examples/apps/plainqt/plainqt.pro	2011-11-23 13:01:17.000000000 -0430
++++ maliit-framework-0.81.0.1-chag/examples/apps/plainqt/plainqt.pro	2011-11-25 12:22:54.934997195 -0430
+@@ -1,5 +1,9 @@
+ TEMPLATE = app
+ TARGET = maliit-exampleapp-plainqt
++
++OBJECTS_DIR = .obj
++MOC_DIR = .moc
++
+ DEPENDPATH += .
+ 
+ BUILD_TYPE = unittest
+diff -Nurwp maliit-framework-0.81.0.1-orig/examples/apps/twofields/twofields.pro maliit-framework-0.81.0.1-chag/examples/apps/twofields/twofields.pro
+--- maliit-framework-0.81.0.1-orig/examples/apps/twofields/twofields.pro	2011-11-23 13:01:17.000000000 -0430
++++ maliit-framework-0.81.0.1-chag/examples/apps/twofields/twofields.pro	2011-11-25 12:22:54.934997195 -0430
+@@ -1,6 +1,9 @@
+-
+ TEMPLATE = app
+ TARGET = maliit-exampleapp-twofields
++
++OBJECTS_DIR = .obj
++MOC_DIR = .moc
++
+ DEPENDPATH += .
+ 
+ BUILD_TYPE = unittest
+diff -Nurwp maliit-framework-0.81.0.1-orig/examples/apps/widgetproperties/widgetproperties.pro maliit-framework-0.81.0.1-chag/examples/apps/widgetproperties/widgetproperties.pro
+--- maliit-framework-0.81.0.1-orig/examples/apps/widgetproperties/widgetproperties.pro	2011-11-23 13:01:17.000000000 -0430
++++ maliit-framework-0.81.0.1-chag/examples/apps/widgetproperties/widgetproperties.pro	2011-11-25 12:22:54.934997195 -0430
+@@ -1,5 +1,9 @@
+ TEMPLATE = app
+ TARGET = maliit-exampleapp-widgetproperties
++
++OBJECTS_DIR = .obj
++MOC_DIR = .moc
++
+ DEPENDPATH += .
+ 
+ BUILD_TYPE = unittest
+@@ -36,4 +40,4 @@ HEADERS += \
+ 
+ QT += core gui
+ 
+-QMAKE_CLEAN += target
++QMAKE_CLEAN += maliit-exampleapp-widgetproperties
+diff -Nurwp maliit-framework-0.81.0.1-orig/sdk/maliit-sdk-create.sh maliit-framework-0.81.0.1-chag/sdk/maliit-sdk-create.sh
+--- maliit-framework-0.81.0.1-orig/sdk/maliit-sdk-create.sh	2011-11-23 13:01:17.000000000 -0430
++++ maliit-framework-0.81.0.1-chag/sdk/maliit-sdk-create.sh	2011-11-25 12:30:58.804997073 -0430
+@@ -37,15 +37,17 @@ SDK_DIR=maliit-sdk
+ SDK_OUT_PATH=$OUT/$SDK_DIR
+ SDK_OUT_FILE_PATH=$OUT/maliit-sdk-$VERSION.tar.gz
+ 
+-rm -r $SDK_OUT_PATH
++if [ -d $SDK_OUT_PATH ] ; then rm -r $SDK_OUT_PATH ; fi
+ mkdir -p $SDK_OUT_PATH/examples
+ 
+ # Extract examples
+ cp -r $EXAMPLES_PATH $SDK_OUT_PATH/
+ cd $SDK_OUT_PATH/examples
+ sed -i -e s/"^BUILD_TYPE.*=.*"/"BUILD_TYPE = $BUILD_TYPE"/ `grep -r --files-with-matches BUILD_TYPE ./ | tr "\n" " "`
++# Clean examples
+ make clean &> /dev/null
+ find ./ -name Makefile -exec rm {} \;
++find ./ -type d \( -name ".obj" -o -name ".moc" \) -print0 | xargs -0 /bin/rmdir
+ rm README
+ cd -
+ 
+@@ -53,4 +55,3 @@ cd -
+ cd $OUT
+ tar -acf $SDK_OUT_FILE_PATH $SDK_DIR
+ cd -
+-



More information about the MeeGo-commits mailing list