[Libreoffice-commits] core.git: cui/AllLangResTarget_cui.mk cui/Library_cui.mk cui/source cui/uiconfig cui/UIConfig_cui.mk extras/source

Rachit Gupta rachitgupta1792 at gmail.com
Tue Jul 29 04:59:33 PDT 2014


 cui/AllLangResTarget_cui.mk                    |    2 
 cui/Library_cui.mk                             |    1 
 cui/UIConfig_cui.mk                            |    1 
 cui/source/dialogs/commonlingui.cxx            |  232 ----------
 cui/source/dialogs/commonlingui.hxx            |  153 ------
 cui/source/dialogs/commonlingui.src            |  130 -----
 cui/source/dialogs/hangulhanjadlg.cxx          |  372 +++++++---------
 cui/source/dialogs/hangulhanjadlg.hrc          |   80 ---
 cui/source/dialogs/hangulhanjadlg.src          |  182 --------
 cui/source/inc/hangulhanjadlg.hxx              |   54 +-
 cui/uiconfig/ui/hangulhanjaconversiondialog.ui |  558 +++++++++++++++++++++++++
 extras/source/glade/libreoffice-catalog.xml.in |    6 
 12 files changed, 767 insertions(+), 1004 deletions(-)

New commits:
commit e6caeefce4cf1f814bc342324490892ca80356ab
Author: Rachit Gupta <rachitgupta1792 at gmail.com>
Date:   Tue Jul 22 22:06:48 2014 +0530

    Converted RID_SVX_MDLG_HANGULHANJA to Widget Layout.
    
    Also, removed the unused hrc/src files.
    
    Change-Id: Ice45dde1af7492e40e0847ead06bb26f4e58ed9c
    Reviewed-on: https://gerrit.libreoffice.org/10595
    Reviewed-by: David Tardon <dtardon at redhat.com>
    Tested-by: David Tardon <dtardon at redhat.com>

diff --git a/cui/AllLangResTarget_cui.mk b/cui/AllLangResTarget_cui.mk
index cc4dffa..931fd1f 100644
--- a/cui/AllLangResTarget_cui.mk
+++ b/cui/AllLangResTarget_cui.mk
@@ -26,11 +26,9 @@ $(eval $(call gb_SrsTarget_add_files,cui/res,\
     cui/source/customize/acccfg.src \
     cui/source/customize/cfg.src \
     cui/source/customize/macropg.src \
-    cui/source/dialogs/commonlingui.src \
     cui/source/dialogs/cuires.src \
     cui/source/dialogs/fmsearch.src \
     cui/source/dialogs/gallery.src \
-    cui/source/dialogs/hangulhanjadlg.src \
     cui/source/dialogs/hyperdlg.src \
     cui/source/dialogs/iconcdlg.src \
     cui/source/dialogs/multipat.src \
diff --git a/cui/Library_cui.mk b/cui/Library_cui.mk
index 1ac0ed7..d1e98e6 100644
--- a/cui/Library_cui.mk
+++ b/cui/Library_cui.mk
@@ -84,7 +84,6 @@ $(eval $(call gb_Library_add_exception_objects,cui,\
     cui/source/customize/selector \
     cui/source/dialogs/about \
     cui/source/dialogs/colorpicker \
-    cui/source/dialogs/commonlingui \
     cui/source/dialogs/cuicharmap \
     cui/source/dialogs/cuifmsearch \
     cui/source/dialogs/cuigaldlg \
diff --git a/cui/UIConfig_cui.mk b/cui/UIConfig_cui.mk
index e605ff3..dbd98d0 100644
--- a/cui/UIConfig_cui.mk
+++ b/cui/UIConfig_cui.mk
@@ -71,6 +71,7 @@ $(eval $(call gb_UIConfig_add_uifiles,cui,\
 	cui/uiconfig/ui/galleryupdateprogress \
 	cui/uiconfig/ui/hangulhanjaadddialog \
 	cui/uiconfig/ui/hangulhanjaeditdictdialog \
+	cui/uiconfig/ui/hangulhanjaconversiondialog \
 	cui/uiconfig/ui/hangulhanjaoptdialog \
 	cui/uiconfig/ui/hatchpage \
 	cui/uiconfig/ui/hyperlinkdialog \
diff --git a/cui/source/dialogs/commonlingui.cxx b/cui/source/dialogs/commonlingui.cxx
deleted file mode 100644
index 48aae68..0000000
--- a/cui/source/dialogs/commonlingui.cxx
+++ /dev/null
@@ -1,232 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements. See the NOTICE file distributed
- *   with this work for additional information regarding copyright
- *   ownership. The ASF licenses this file to you under the Apache
- *   License, Version 2.0 (the "License"); you may not use this file
- *   except in compliance with the License. You may obtain a copy of
- *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-
-#include "commonlingui.hxx"
-
-#include <cuires.hrc>
-#include <dialmgr.hxx>
-#include <vcl/decoview.hxx>
-#include <sal/macros.h>
-
-#include "hangulhanjadlg.hrc"
-
-
-// SvxClickInfoCtr
-
-
-
-SvxClickInfoCtr::SvxClickInfoCtr( Window* pParent, const ResId& rResId ) :
-        Control( pParent, rResId ),
-        aFixedInfo( this)
-{
-    aFixedInfo.SetSizePixel(GetOutputSizePixel());
-    aFixedInfo.Show();
-}
-
-
-void SvxClickInfoCtr::MouseButtonDown( const MouseEvent& )
-{
-    aActivateLink.Call(this);
-}
-
-
-bool SvxClickInfoCtr::PreNotify( NotifyEvent& rNEvt )
-{
-    if(rNEvt.GetType()==EVENT_GETFOCUS || rNEvt.GetType()==EVENT_MOUSEBUTTONDOWN)
-    {
-        aActivateLink.Call(this);
-    }
-
-    return Control::PreNotify(rNEvt);
-}
-
-
-void SvxClickInfoCtr::SetText( const OUString& rStr )
-{
-    aFixedInfo.SetText(rStr );
-}
-
-
-OUString SvxClickInfoCtr::GetText() const
-{
-    return aFixedInfo.GetText();
-}
-
-
-SvxClickInfoCtr::~SvxClickInfoCtr()
-{
-}
-
-
-// SvxCommonLinguisticControl
-
-
-SvxCommonLinguisticControl::SvxCommonLinguisticControl( ModalDialog* _pParent )
-    :Window( _pParent, CUI_RES( RID_SVX_WND_COMMON_LINGU ) )
-    ,aWordText      ( this, CUI_RES( FT_WORD ) )
-    ,aAktWord       ( this, CUI_RES( FT_AKTWORD ) )
-    ,aNewWord       ( this, CUI_RES( FT_NEWWORD ) )
-    ,aNewWordED     ( this, CUI_RES( ED_NEWWORD ) )
-    ,aSuggestionFT  ( this, CUI_RES( FT_SUGGESTION ) )
-    ,aIgnoreBtn     ( this, CUI_RES( BTN_IGNORE ) )
-    ,aIgnoreAllBtn  ( this, CUI_RES( BTN_IGNOREALL ) )
-    ,aChangeBtn     ( this, CUI_RES( BTN_CHANGE ) )
-    ,aChangeAllBtn  ( this, CUI_RES( BTN_CHANGEALL ) )
-    ,aOptionsBtn    ( this, CUI_RES( BTN_OPTIONS ) )
-    ,aStatusText    ( this, CUI_RES( FT_STATUS ) )
-    ,aHelpBtn       ( this, CUI_RES( BTN_SPL_HELP ) )
-    ,aCancelBtn     ( this, CUI_RES( BTN_SPL_CANCEL ) )
-    ,aAuditBox      ( this, CUI_RES( GB_AUDIT ) )
-{
-    FreeResource();
-    aAktWord.SetAccessibleName(aWordText.GetText());
-    SetPosSizePixel( Point( 0, 0 ), _pParent->GetOutputSizePixel() );
-    Show();
-}
-
-
-PushButton* SvxCommonLinguisticControl::implGetButton( ButtonType _eType  ) const
-{
-    const PushButton* pButton = NULL;
-    switch ( _eType )
-    {
-        case eClose: pButton = &aCancelBtn; break;
-        case eIgnore: pButton = &aIgnoreBtn; break;
-        case eIgnoreAll: pButton = &aIgnoreAllBtn; break;
-        case eChange: pButton = &aChangeBtn; break;
-        case eChangeAll: pButton = &aChangeAllBtn; break;
-        case eOptions: pButton = &aOptionsBtn; break;
-    }
-    return const_cast< PushButton* >( pButton );
-}
-
-
-void SvxCommonLinguisticControl::SetButtonHandler( ButtonType _eType, const Link& _rHandler )
-{
-    Button* pButton = GetButton( _eType );
-    if ( pButton )
-        pButton->SetClickHdl( _rHandler );
-}
-
-
-void SvxCommonLinguisticControl::EnableButton( ButtonType _eType, bool _bEnable )
-{
-    Button* pButton = GetButton( _eType );
-    if ( pButton )
-        pButton->Enable( _bEnable );
-}
-
-
-void SvxCommonLinguisticControl::InsertControlGroup( Window& _rFirstGroupWindow, Window& _rLastGroupWindow, ControlGroup _eInsertAfter )
-{
-    Window* pInsertAfter = NULL;    // will be the last window of our own "undividable" group, after which we insert the foreign group
-    switch ( _eInsertAfter )
-    {
-        case eLeftRightWords    : pInsertAfter = &aNewWordED; break;
-        case eSuggestionLabel   : pInsertAfter = &aSuggestionFT; break;
-        case eActionButtons     : pInsertAfter = &aChangeAllBtn; break;
-        case eDialogButtons     : pInsertAfter = &aCancelBtn; break;
-    }
-
-    // now loop through the remaining windows of the foreign group
-    Window* pInsertBehind = pInsertAfter;
-    Window* pInsert = &_rFirstGroupWindow;
-
-    // some strange thing below: asking a window for WINDOW_NEXT or WINDOW_PREV does not take into
-    // account the border window, _but_ SetZOrder _does_!. Thus, when advancing through a chain
-    // of windows, we need to work with the border windows (WINDOW_BORDER), instead of simply
-    // asking for WINDOW_NEXT.
-
-    Window* pLoopEnd = _rLastGroupWindow.GetWindow( WINDOW_BORDER );
-    while ( pInsert && ( pInsertBehind != pLoopEnd ) )
-    {
-        // we'll destroy the NEXT relation immediately, so remember the next window
-        DBG_ASSERT( pInsert->GetWindow( WINDOW_BORDER ), "SvxCommonLinguisticControl::InsertControlGroup: border window is expected to be non NULL!" );
-        Window* pNextInsert = pInsert->GetWindow( WINDOW_BORDER )->GetWindow( WINDOW_NEXT );
-        // knit
-        pInsert->SetZOrder( pInsertBehind, WINDOW_ZORDER_BEHIND );
-        // advance
-        pInsertBehind = pInsert;
-        pInsert = pNextInsert;
-    }
-    DBG_ASSERT( pInsertBehind == pLoopEnd, "SvxCommonLinguisticControl::InsertControlGroup: controls do not form a group!" );
-        // if we did not reach pLoopEnd, then we did not reach _rLastGroupWindow in the loop, then
-        // (FirstWindow, LastWindow) was no valid control group
-}
-
-
-void SvxCommonLinguisticControl::Paint( const Rectangle& rRect )
-{
-    Window::Paint(rRect );
-
-    DecorationView aDecoView( this );
-
-    Rectangle aRect( aAuditBox.GetPosPixel(), aAuditBox.GetSizePixel() );
-    aDecoView.DrawButton( aRect, BUTTON_DRAW_NOFILL );
-}
-
-
-void SvxCommonLinguisticControl::Enlarge( sal_Int32 _nX, sal_Int32 _nY )
-{
-    Size aSize;
-    Point aPos;
-
-    // the controls which need to be resized
-    {
-        Window* pResize[] =
-        {
-            this, &aAuditBox, &aStatusText
-        };
-        for ( sal_uInt32 i = 0; i < SAL_N_ELEMENTS( pResize ); ++i )
-        {
-            aSize = pResize[i]->GetSizePixel( );
-            pResize[i]->SetSizePixel( Size( aSize.Width() + _nX, aSize.Height() + _nY ) );
-        }
-    }
-
-    // the controls which stick to the bottom of the window
-    {
-        Window* pMoveDown[] =
-        {
-            &aStatusText, &aHelpBtn, &aCancelBtn
-        };
-        for ( sal_uInt32 i = 0; i < SAL_N_ELEMENTS( pMoveDown ); ++i )
-        {
-            aPos = pMoveDown[i]->GetPosPixel();
-            aPos.Y() += _nY;
-            pMoveDown[i]->SetPosPixel( aPos );
-        }
-    }
-
-    // the controls which stick to the right
-    {
-        Window* pMoveRight[] =
-        {
-            &aIgnoreBtn, &aIgnoreAllBtn, &aChangeBtn, &aChangeAllBtn, &aOptionsBtn, &aHelpBtn, &aCancelBtn
-        };
-        for ( sal_uInt32 i = 0; i < SAL_N_ELEMENTS( pMoveRight ); ++i )
-        {
-            aPos = pMoveRight[i]->GetPosPixel();
-            aPos.X() += _nX;
-            pMoveRight[i]->SetPosPixel( aPos );
-        }
-    }
-}
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/cui/source/dialogs/commonlingui.hxx b/cui/source/dialogs/commonlingui.hxx
deleted file mode 100644
index b5598b7..0000000
--- a/cui/source/dialogs/commonlingui.hxx
+++ /dev/null
@@ -1,153 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements. See the NOTICE file distributed
- *   with this work for additional information regarding copyright
- *   ownership. The ASF licenses this file to you under the Apache
- *   License, Version 2.0 (the "License"); you may not use this file
- *   except in compliance with the License. You may obtain a copy of
- *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-
-#ifndef INCLUDED_CUI_SOURCE_DIALOGS_COMMONLINGUI_HXX
-#define INCLUDED_CUI_SOURCE_DIALOGS_COMMONLINGUI_HXX
-
-#include <vcl/ctrl.hxx>
-#include <svtools/stdctrl.hxx>
-#include <vcl/edit.hxx>
-#include <vcl/button.hxx>
-#include <vcl/group.hxx>
-#include <vcl/dialog.hxx>
-
-
-// SvxClickInfoCtr
-
-
-class SvxClickInfoCtr: public Control
-{
-private:
-    FixedInfo                   aFixedInfo;
-    Link                        aActivateLink;
-
-public:
-    SvxClickInfoCtr( Window* pParent, const ResId& rResId );
-    virtual ~SvxClickInfoCtr();
-
-    virtual void        SetText( const OUString& rStr ) SAL_OVERRIDE;
-    virtual OUString    GetText() const SAL_OVERRIDE;
-
-    void                SetActivateHdl( const Link& rLink ) { aActivateLink = rLink; }
-    const Link&         GetActivateHdl() const { return aActivateLink; }
-
-protected:
-    virtual void        MouseButtonDown( const MouseEvent& rMEvt ) SAL_OVERRIDE;
-    virtual bool        PreNotify( NotifyEvent& rNEvt ) SAL_OVERRIDE;
-
-};
-
-
-// SvxCommonLinguisticControl
-
-class SvxCommonLinguisticControl : public Window
-{
-public:
-    enum ButtonType
-    {
-        eClose,
-        eIgnore,
-        eIgnoreAll,
-        eChange,
-        eChangeAll,
-        eOptions
-    };
-
-protected:
-    FixedText       aWordText;
-    SvxClickInfoCtr aAktWord;
-
-    FixedText       aNewWord;
-    Edit            aNewWordED;
-
-    FixedText       aSuggestionFT;
-
-    PushButton      aIgnoreBtn;
-    PushButton      aIgnoreAllBtn;
-    PushButton      aChangeBtn;
-    PushButton      aChangeAllBtn;
-    PushButton      aOptionsBtn;
-
-    FixedInfo       aStatusText;
-    HelpButton      aHelpBtn;
-    CancelButton    aCancelBtn;
-
-    GroupBox        aAuditBox;
-
-protected:
-    virtual void    Paint( const Rectangle& rRect ) SAL_OVERRIDE;
-
-private:
-    PushButton* implGetButton( ButtonType _eType  ) const;
-
-public:
-    SvxCommonLinguisticControl( ModalDialog* _pParent );
-
-    // handlers
-    inline void         SetResetWordHdl( const Link& _rLink )   { aAktWord.SetActivateHdl( _rLink ); }
-    inline const Link&  GetResetWordHdl() const                 { return aAktWord.GetActivateHdl(); }
-
-    void    SetButtonHandler( ButtonType _eType, const Link& _rHandler );
-    void    EnableButton( ButtonType _eType, bool _bEnable );
-
-    inline  PushButton*         GetButton( ButtonType _eType )          { return implGetButton( _eType  ); }
-    inline  const PushButton*   GetButton( ButtonType _eType ) const    { return implGetButton( _eType  ); }
-
-    /// control groups in this window which cannot be devided (e.g. are adjacent in the Z order)
-    enum ControlGroup
-    {
-        eLeftRightWords,    ///< the controls for the two words (original and suggestion), including the labels
-        eSuggestionLabel,   ///< the label for the suggestion
-        eActionButtons,     ///< the group of "ignore(all)" / "change(all)" buttons
-        eDialogButtons      ///< the group of dialog control buttons (help and close)
-    };
-
-    /** Users of this class may want to insert own controls in some places,
-        where the ordinary Z-Order determined by construction time is not
-        sufficient. Use the following methods for this.
-     */
-    void    InsertControlGroup( Window& _rFirstGroupWindow, Window& _rLastGroupWindow, ControlGroup _eInsertAfter );
-
-    /** enlarges the window
-
-        Some controls "stick" to the borders: The group of change/ignore buttons, for instance, sticks
-        to the right, the dictionary list as well as the close/help buttons stick to the bottom of the
-        window.
-    */
-    void    Enlarge( sal_Int32 _nX, sal_Int32 _nY );
-
-    // control access methods
-    inline void     SetCurrentText( const OUString& _rText )  { aAktWord.SetText( _rText ); }
-    inline OUString GetCurrentText( ) const                 { return aAktWord.GetText(); }
-
-    inline void     SetStatusText( const OUString& _rText )   { aStatusText.SetText( _rText ); }
-    inline OUString GetStatusText( ) const                  { return aStatusText.GetText(); }
-
-    inline Edit&        GetWordInputControl()           { return aNewWordED; }
-    inline const Edit&  GetWordInputControl() const { return aNewWordED; }
-
-    /// @return the location (upper-left corner) of the group of action buttons
-    inline Point    GetActionButtonsLocation( ) const { return aIgnoreBtn.GetPosPixel(); }
-};
-
-
-
-#endif // INCLUDED_CUI_SOURCE_DIALOGS_COMMONLINGUI_HXX
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/cui/source/dialogs/commonlingui.src b/cui/source/dialogs/commonlingui.src
deleted file mode 100644
index 3d66cfa..0000000
--- a/cui/source/dialogs/commonlingui.src
+++ /dev/null
@@ -1,130 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements. See the NOTICE file distributed
- *   with this work for additional information regarding copyright
- *   ownership. The ASF licenses this file to you under the Apache
- *   License, Version 2.0 (the "License"); you may not use this file
- *   except in compliance with the License. You may obtain a copy of
- *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-
-#include <cuires.hrc>
-#include "helpid.hrc"
-#include "hangulhanjadlg.hrc"
-
-Window RID_SVX_WND_COMMON_LINGU
-{
-    DialogControl = TRUE;   // we want to tab out of this
-    Hide = TRUE;
-
-    FixedText FT_WORD
-    {
-        Pos = MAP_APPFONT( 6,  9 );
-        Size = MAP_APPFONT( 42, 10 );
-        Text [ en-US ] = "Origi~nal";
-    };
-    Control FT_AKTWORD
-    {
-        HelpId=HID_SPELLDLG_SETWORD;
-        Pos = MAP_APPFONT( 51, 9 );
-        Size = MAP_APPFONT( 164, 10 );
-        Border =FALSE;
-        TabStop = TRUE;
-    };
-
-    FixedText FT_NEWWORD
-    {
-        Pos = MAP_APPFONT(  6, 25 );
-        Size = MAP_APPFONT( 42, 10 );
-        Text [ en-US ] = "~Word" ;
-    };
-
-    Edit ED_NEWWORD
-    {
-        Pos = MAP_APPFONT( 51, 24 );
-        Size = MAP_APPFONT( 137, 12 );
-        Border = TRUE;
-    };
-
-    FixedText FT_SUGGESTION
-    {
-        Pos = MAP_APPFONT( 6, 48 );
-        Size = MAP_APPFONT( 42, 10 );
-        Text [ en-US ] = "~Suggestions" ;
-    };
-
-    PushButton BTN_IGNORE
-    {
-        Pos = MAP_APPFONT( 224, 6 );
-        Size = MAP_APPFONT( 55, 14 );
-        Text [ en-US ] = "~Ignore" ;
-    };
-
-    PushButton BTN_IGNOREALL
-    {
-        Pos = MAP_APPFONT( 224, 22 );
-        Size = MAP_APPFONT( 55, 14 );
-        Text [ en-US ] = "Always I~gnore" ;
-    };
-
-    PushButton BTN_CHANGE
-    {
-        Pos = MAP_APPFONT( 224, 40 );
-        Size = MAP_APPFONT( 55, 14 );
-        Text [ en-US ] = "~Replace" ;
-        DefButton = TRUE ;
-    };
-
-    PushButton BTN_CHANGEALL
-    {
-        Pos = MAP_APPFONT( 224, 56 );
-        Size = MAP_APPFONT( 55, 14 );
-        Text [ en-US ] = "Always R~eplace" ;
-    };
-
-    PushButton BTN_OPTIONS
-    {
-        Pos = MAP_APPFONT( 224, 129 );
-        Size = MAP_APPFONT( 55, 14 );
-        Hide = TRUE ;
-        Text [ en-US ] = "Options..." ;
-    };
-
-    FixedText FT_STATUS
-    {
-        Pos = MAP_APPFONT(  6, 155 );
-        Size = MAP_APPFONT( 130, 10 );
-    };
-
-    GroupBox GB_AUDIT
-    {
-        Pos = MAP_APPFONT( 1, 1 );
-        Size = MAP_APPFONT( 283, 148 );
-        Hide=TRUE;
-    };
-
-    HelpButton BTN_SPL_HELP
-    {
-        Pos = MAP_APPFONT( 160, 153 );
-        Size = MAP_APPFONT( 55, 14 );
-    };
-
-    CancelButton BTN_SPL_CANCEL
-    {
-        Pos = MAP_APPFONT ( 224 , 153 ) ;
-        Size = MAP_APPFONT ( 55 , 14 ) ;
-        TabStop = TRUE ;
-        Text [ en-US ] = "~Close" ;
-    };
-};
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/cui/source/dialogs/hangulhanjadlg.cxx b/cui/source/dialogs/hangulhanjadlg.cxx
index cbc4942..7a99681 100644
--- a/cui/source/dialogs/hangulhanjadlg.cxx
+++ b/cui/source/dialogs/hangulhanjadlg.cxx
@@ -18,8 +18,6 @@
  */
 
 #include "hangulhanjadlg.hxx"
-#include "hangulhanjadlg.hrc"
-#include "commonlingui.hxx"
 #include <dialmgr.hxx>
 
 #include <cuires.hrc>
@@ -42,6 +40,7 @@
 
 #define HHC editeng::HangulHanjaConversion
 #define LINE_CNT        static_cast< sal_uInt16 >(2)
+#define MAXNUM_SUGGESTIONS 50
 
 
 namespace svx
@@ -75,7 +74,6 @@ namespace svx
         };
     }
 
-
     //= PseudoRubyText
 
     /** a class which allows to draw two texts in a pseudo-ruby way (which basically
@@ -90,12 +88,16 @@ namespace svx
         };
 
     protected:
-        const OUString      m_sPrimaryText;
-        const OUString      m_sSecondaryText;
-        const RubyPosition  m_ePosition;
+        OUString      m_sPrimaryText;
+        OUString      m_sSecondaryText;
+        RubyPosition  m_ePosition;
 
     public:
         PseudoRubyText( const OUString& _rPrimary, const OUString& _rSecondary, const RubyPosition _ePosition );
+        PseudoRubyText();
+        void init( const OUString& rPrimaryText, const OUString& rSecondaryText, const RubyPosition& rPosition );
+        const OUString& getPrimaryText() const { return m_sPrimaryText; }
+        const OUString& getSecondaryText() const { return m_sSecondaryText; }
 
     public:
         void Paint( OutputDevice& _rDevice, const Rectangle& _rRect, sal_uInt16 _nTextStyle,
@@ -103,7 +105,6 @@ namespace svx
             ::vcl::ControlLayoutData* _pLayoutData = NULL );
     };
 
-
     PseudoRubyText::PseudoRubyText( const OUString& _rPrimary, const OUString& _rSecondary, const RubyPosition _ePosition )
         :m_sPrimaryText( _rPrimary )
         ,m_sSecondaryText( _rSecondary )
@@ -111,6 +112,17 @@ namespace svx
     {
     }
 
+    PseudoRubyText::PseudoRubyText()
+    {
+    }
+
+    void PseudoRubyText::init( const OUString& rPrimaryText, const OUString& rSecondaryText, const RubyPosition& rPosition )
+    {
+        m_sPrimaryText = rPrimaryText;
+        m_sSecondaryText = rSecondaryText;
+        m_ePosition = rPosition;
+    }
+
 
     void PseudoRubyText::Paint( OutputDevice& _rDevice, const Rectangle& _rRect, sal_uInt16 _nTextStyle,
         Rectangle* _pPrimaryLocation, Rectangle* _pSecondaryLocation, ::vcl::ControlLayoutData* _pLayoutData )
@@ -201,31 +213,31 @@ namespace svx
             *_pSecondaryLocation = aSecondaryRect;
     }
 
-
     //= RubyRadioButton
 
     class RubyRadioButton   :public RadioButton
-                            ,protected PseudoRubyText
     {
-        using svx::PseudoRubyText::Paint;
 
     public:
-        RubyRadioButton(
-            Window* _pParent,
-            const ResId& _rId,          // the text in the resource will be taken as primary text
-            const OUString& _rSecondary,  // this will be the secondary text which will be printed somewhat smaller
-            const PseudoRubyText::RubyPosition _ePosition );
+        RubyRadioButton( Window* _pParent, WinBits nBits );
+        void init( const OUString& rPrimaryText, const OUString& rSecondaryText, const PseudoRubyText::RubyPosition& rPosition );
+        virtual Size    GetOptimalSize() const SAL_OVERRIDE;
 
     protected:
         virtual void    Paint( const Rectangle& _rRect ) SAL_OVERRIDE;
+
+    private:
+        PseudoRubyText m_aRubyText;
     };
 
+    RubyRadioButton::RubyRadioButton( Window* _pParent, WinBits nBits )
+        :RadioButton( _pParent, nBits )
+    {
+    }
 
-    RubyRadioButton::RubyRadioButton( Window* _pParent, const ResId& _rId,
-        const OUString& _rSecondary, const PseudoRubyText::RubyPosition _ePosition )
-        :RadioButton( _pParent, _rId )
-        ,PseudoRubyText( RadioButton::GetText(), _rSecondary, _ePosition )
+    void RubyRadioButton::init( const OUString& rPrimaryText, const OUString& rSecondaryText, const PseudoRubyText::RubyPosition& rPosition )
     {
+        m_aRubyText.init( rPrimaryText, rSecondaryText, rPosition );
     }
 
 
@@ -236,8 +248,8 @@ namespace svx
         // calculate the size of the radio image - we're to paint our text _after_ this image
         DBG_ASSERT( !GetModeRadioImage(), "RubyRadioButton::Paint: images not supported!" );
         Size aImageSize = GetRadioImage( GetSettings(), 0 ).GetSizePixel();
-        aImageSize.Width()  = CalcZoom( aImageSize.Width() );
-        aImageSize.Height()  = CalcZoom( aImageSize.Height() );
+        aImageSize.Width()  = CalcZoom( aImageSize.Width() ) + 2;   // + 2 because otherwise the radiobuttons
+        aImageSize.Height()  = CalcZoom( aImageSize.Height() ) + 2; // appear a bit cut from right and top.
 
         Rectangle aOverallRect( Point( 0, 0 ), GetOutputSizePixel() );
         aOverallRect.Left() += aImageSize.Width() + 4;  // 4 is the separator between the image and the text
@@ -270,7 +282,7 @@ namespace svx
 
         // paint the ruby text
         Rectangle aPrimaryTextLocation, aSecondaryTextLocation;
-        PseudoRubyText::Paint( *this, aTextRect, nTextStyle, &aPrimaryTextLocation, &aSecondaryTextLocation );
+        m_aRubyText.Paint( *this, aTextRect, nTextStyle, &aPrimaryTextLocation, &aSecondaryTextLocation );
 
         // the focus rectangle is to be painted around both texts
         Rectangle aCombinedRect( aPrimaryTextLocation );
@@ -297,10 +309,33 @@ namespace svx
             ShowFocus( aTextRect );
     }
 
+    Size RubyRadioButton::GetOptimalSize() const
+    {
+        Font aSmallerFont( GetFont() );
+        aSmallerFont.SetHeight( static_cast<long>( 0.8 * aSmallerFont.GetHeight() ) );
+        Rectangle rect( Point(), Size( SAL_MAX_INT32, SAL_MAX_INT32 ) );
+        sal_uInt16 style = GetStyle();
 
-    //= SuggestionSet
+        Size aPrimarySize = GetTextRect( rect, m_aRubyText.getPrimaryText(), style ).GetSize();
+        Size aSecondarySize;
+        {
+            FontSwitch aFontRestore( const_cast<RubyRadioButton&>(*this), aSmallerFont );
+            aSecondarySize = GetTextRect( rect, m_aRubyText.getSecondaryText(), style ).GetSize();
+        }
+
+        Size minimumSize =  CalcMinimumSize();
+        minimumSize.Height() = aPrimarySize.Height() + aSecondarySize.Height() + 5;
+        minimumSize.Width() = aPrimarySize.Width() + aSecondarySize.Width() + 5;
+        return minimumSize;
+    }
+
+    extern "C" SAL_DLLPUBLIC_EXPORT Window* SAL_CALL makeRubyRadioButton( Window *pParent, VclBuilder::stringmap & )
+    {
+        return new RubyRadioButton( pParent, WB_LEFT|WB_VCENTER );
+    }
 
 
+    //= SuggestionSet
 
     SuggestionSet::SuggestionSet( Window* pParent )
                     : ValueSet( pParent, pParent->GetStyle() | WB_BORDER )
@@ -335,13 +370,12 @@ namespace svx
     //= SuggestionDisplay
 
 
-
-    SuggestionDisplay::SuggestionDisplay( Window* pParent, const ResId& rResId )
-        : Control( pParent, rResId )
-        , m_bDisplayListBox(true)
-        , m_aValueSet(this)
-        , m_aListBox(this,GetStyle() | WB_BORDER )
-        , m_bInSelectionUpdate(false)
+    SuggestionDisplay::SuggestionDisplay( Window* pParent, WinBits nBits )
+        : Control( pParent, nBits )
+        , m_bDisplayListBox( true )
+        , m_aValueSet( this )
+        , m_aListBox( this,GetStyle() | WB_BORDER )
+        , m_bInSelectionUpdate( false )
     {
         m_aValueSet.SetSelectHdl( LINK( this, SuggestionDisplay, SelectSuggestionHdl ) );
         m_aListBox.SetSelectHdl( LINK( this, SuggestionDisplay, SelectSuggestionHdl ) );
@@ -353,9 +387,9 @@ namespace svx
         long nItemWidth = 2*GetTextWidth( aOneCharacter );
         m_aValueSet.SetItemWidth( nItemWidth );
 
-        Size aSize(GetSizePixel());
-        m_aValueSet.SetSizePixel(aSize);
-        m_aListBox.SetSizePixel(aSize);
+        Size aSize( approximate_char_width() * 48, GetTextHeight() * 5 );
+        m_aValueSet.SetSizePixel( aSize );
+        m_aListBox.SetSizePixel( aSize );
 
         implUpdateDisplay();
     }
@@ -369,8 +403,8 @@ namespace svx
         bool bShowBox = IsVisible() && m_bDisplayListBox;
         bool bShowSet = IsVisible() && !m_bDisplayListBox;
 
-        m_aListBox.Show(bShowBox);
-        m_aValueSet.Show(bShowSet);
+        m_aListBox.Show( bShowBox );
+        m_aValueSet.Show( bShowSet );
     }
 
     void SuggestionDisplay::StateChanged( StateChangedType nStateChange )
@@ -440,7 +474,7 @@ namespace svx
             return 0L;
 
         m_bInSelectionUpdate = true;
-        if(pControl==&m_aListBox)
+        if( pControl == &m_aListBox )
         {
             sal_uInt16 nPos = m_aListBox.GetSelectEntryPos();
             m_aValueSet.SelectItem( nPos+1 ); //itemid == pos+1 (id 0 has special meaning)
@@ -451,7 +485,7 @@ namespace svx
             m_aListBox.SelectEntryPos( nPos );
         }
         m_bInSelectionUpdate = false;
-        m_aSelectLink.Call(this);
+        m_aSelectLink.Call( this );
         return 0L;
     }
 
@@ -468,7 +502,7 @@ namespace svx
     {
         sal_uInt16 nItemId = m_aListBox.InsertEntry( rStr ) + 1; //itemid == pos+1 (id 0 has special meaning)
         m_aValueSet.InsertItem( nItemId );
-        OUString* pItemData = new OUString(rStr);
+        OUString* pItemData = new OUString( rStr );
         m_aValueSet.SetItemData( nItemId, pItemData );
     }
     void SuggestionDisplay::SelectEntryPos( sal_uInt16 nPos )
@@ -495,116 +529,73 @@ namespace svx
         m_aListBox.SetHelpId( HID_HANGULDLG_SUGGESTIONS_LIST );
     }
 
+    extern "C" SAL_DLLPUBLIC_EXPORT Window* SAL_CALL makeSuggestionDisplay( Window *pParent, VclBuilder::stringmap & )
+    {
+        return new SuggestionDisplay( pParent, WB_ITEMBORDER | WB_FLATVALUESET | WB_VSCROLL );
+    }
+
 
     //= HangulHanjaConversionDialog
 
-
     HangulHanjaConversionDialog::HangulHanjaConversionDialog( Window* _pParent, HHC::ConversionDirection _ePrimaryDirection )
-        :ModalDialog( _pParent, CUI_RES( RID_SVX_MDLG_HANGULHANJA ) )
-        ,m_pPlayground( new SvxCommonLinguisticControl( this ) )
-        ,m_aFind            ( m_pPlayground.get(), CUI_RES( PB_FIND ) )
-        ,m_aSuggestions     ( m_pPlayground.get(), CUI_RES( CTL_SUGGESTIONS ) )
-        ,m_aFormat          ( m_pPlayground.get(), CUI_RES( FT_FORMAT ) )
-        ,m_aSimpleConversion( m_pPlayground.get(), CUI_RES( RB_SIMPLE_CONVERSION ) )
-        ,m_aHangulBracketed ( m_pPlayground.get(), CUI_RES( RB_HANJA_HANGUL_BRACKETED ) )
-        ,m_aHanjaBracketed  ( m_pPlayground.get(), CUI_RES( RB_HANGUL_HANJA_BRACKETED ) )
-        ,m_aConversion      ( m_pPlayground.get(), CUI_RES( FT_CONVERSION ) )
-        ,m_aHangulOnly      ( m_pPlayground.get(), CUI_RES( CB_HANGUL_ONLY ) )
-        ,m_aHanjaOnly       ( m_pPlayground.get(), CUI_RES( CB_HANJA_ONLY ) )
-        ,m_aReplaceByChar   ( m_pPlayground.get(), CUI_RES( CB_REPLACE_BY_CHARACTER ) )
+        :ModalDialog( _pParent, "HangulHanjaConversionDialog", "cui/ui/hangulhanjaconversiondialog.ui" )
         ,m_pIgnoreNonPrimary( NULL )
         ,m_bDocumentMode( true )
     {
-        // special creation of the 4 pseudo-ruby radio buttons
-        OUString sSecondaryHangul( CUI_RES( STR_HANGUL ) );
-        OUString sSecondaryHanja( CUI_RES( STR_HANJA ) );
-        m_pHanjaAbove.reset( new RubyRadioButton( m_pPlayground.get(), CUI_RES( RB_HANGUL_HANJA_ABOVE ), sSecondaryHanja, PseudoRubyText::eAbove ) );
-        m_pHanjaBelow.reset( new RubyRadioButton( m_pPlayground.get(), CUI_RES( RB_HANGUL_HANJA_BELOW ), sSecondaryHanja, PseudoRubyText::eBelow ) );
-        m_pHangulAbove.reset( new RubyRadioButton( m_pPlayground.get(), CUI_RES( RB_HANJA_HANGUL_ABOVE ), sSecondaryHangul, PseudoRubyText::eAbove ) );
-        m_pHangulBelow.reset( new RubyRadioButton( m_pPlayground.get(), CUI_RES( RB_HANJA_HANGUL_BELOW ), sSecondaryHangul, PseudoRubyText::eBelow ) );
-
-        // since these 4 buttons are not created within the other members, they have a wrong initial Z-Order
-        // correct this
-        m_pHanjaAbove->SetZOrder( &m_aHanjaBracketed, WINDOW_ZORDER_BEHIND );
-        m_pHanjaBelow->SetZOrder( m_pHanjaAbove.get(), WINDOW_ZORDER_BEHIND );
-        m_pHangulAbove->SetZOrder( m_pHanjaBelow.get(), WINDOW_ZORDER_BEHIND );
-        m_pHangulBelow->SetZOrder( m_pHangulAbove.get(), WINDOW_ZORDER_BEHIND );
-
-        // VCL automatically sets the WB_GROUP bit, if the previous sibling (at the moment of creation)
-        // is no radion button
-        m_pHanjaAbove->SetStyle( m_pHanjaAbove->GetStyle() & ~WB_GROUP );
-
-        // the "Find" button and the word input control may not have the proper distance/extensions
-        // -> correct this
-        Point aDistance = LogicToPixel( Point( 3, 0 ), MAP_APPFONT );
-        sal_Int32 nTooLargeByPixels =
-            // right margin of the word input control
-            (   m_pPlayground->GetWordInputControl().GetPosPixel().X()
-            +   m_pPlayground->GetWordInputControl().GetSizePixel().Width()
-            )
-            // minus left margin of the find button
-            -   m_aFind.GetPosPixel().X()
-            // plus desired distance between the both
-            +   aDistance.X();
-        // make the word input control smaller
-        Size aSize = m_pPlayground->GetWordInputControl().GetSizePixel();
-        aSize.Width() -= nTooLargeByPixels;
-        m_pPlayground->GetWordInputControl().SetSizePixel( aSize );
-
-        // additionall, the playground is not wide enough (in it's default size)
-        sal_Int32 nEnlargeWidth = 0;
-        {
-            FixedText aBottomAnchor( m_pPlayground.get(), CUI_RES( FT_RESIZE_ANCHOR ) );
-            Point aAnchorPos = aBottomAnchor.GetPosPixel();
-
-            nEnlargeWidth = aAnchorPos.X() - m_pPlayground->GetActionButtonsLocation().X();
-        }
-        m_pPlayground->Enlarge( nEnlargeWidth, 0 );
-
-        // insert our controls into the z-order of the playground
-        m_pPlayground->InsertControlGroup( m_aFind, m_aFind, SvxCommonLinguisticControl::eLeftRightWords );
-        m_pPlayground->InsertControlGroup( m_aSuggestions, m_aHanjaOnly, SvxCommonLinguisticControl::eSuggestionLabel );
-        m_pPlayground->InsertControlGroup( m_aReplaceByChar, m_aReplaceByChar, SvxCommonLinguisticControl::eActionButtons );
-
-        m_pPlayground->SetButtonHandler( SvxCommonLinguisticControl::eClose, LINK( this, HangulHanjaConversionDialog, OnClose ) );
-        m_pPlayground->GetWordInputControl().SetModifyHdl( LINK( this,  HangulHanjaConversionDialog, OnSuggestionModified ) );
-        m_aSuggestions.SetSelectHdl( LINK( this,  HangulHanjaConversionDialog, OnSuggestionSelected ) );
-
-        m_aReplaceByChar.SetClickHdl( LINK( this, HangulHanjaConversionDialog, ClickByCharacterHdl ) );
-
-        m_aHangulOnly.SetClickHdl( LINK( this,  HangulHanjaConversionDialog, OnConversionDirectionClicked ) );
-        m_aHanjaOnly.SetClickHdl(  LINK( this,  HangulHanjaConversionDialog, OnConversionDirectionClicked ) );
-
-        m_pPlayground->SetButtonHandler( SvxCommonLinguisticControl::eOptions,
-                                        LINK( this, HangulHanjaConversionDialog, OnOption ) );
-        m_pPlayground->GetButton( SvxCommonLinguisticControl::eOptions )->Show();
+        get( m_pFind, "find" );
+        get( m_pIgnore, "ignore" );
+        get( m_pSuggestions, "suggestions" );
+        get( m_pSimpleConversion, "simpleconversion" );
+        get( m_pHangulBracketed, "hangulbracket" );
+        get( m_pHanjaBracketed, "hanjabracket" );
+        get( m_pHangulOnly, "hangulonly" );
+        get( m_pHanjaOnly, "hanjaonly" );
+        get( m_pReplaceByChar, "replacebychar" );
+        get( m_pOptions, "options" );
+        get( m_pIgnore, "ignore" );
+        get( m_pIgnoreAll, "ignoreall" );
+        get( m_pReplace, "replace" );
+        get( m_pReplaceAll, "replaceall" );
+        get( m_pWordInput, "wordinput" );
+        get( m_pOriginalWord, "originalword" );
+        get( m_pHanjaAbove, "hanja_above" );
+        get( m_pHanjaBelow, "hanja_below" );
+        get( m_pHangulAbove, "hangul_above" );
+        get( m_pHangulBelow, "hangul_below" );
+
+        m_pSuggestions->set_height_request( m_pSuggestions->GetTextHeight() * 5 );
+        m_pSuggestions->set_width_request( m_pSuggestions->approximate_char_width() * 48 );
+
+        const OUString sHangul = "Hangul";
+        const OUString sHanja = "Hanja";
+        m_pHanjaAbove->init( sHangul, sHanja, PseudoRubyText::eAbove );
+        m_pHanjaBelow->init( sHangul, sHanja, PseudoRubyText::eBelow );
+        m_pHangulAbove->init( sHanja, sHangul, PseudoRubyText::eAbove );
+        m_pHangulBelow->init( sHanja, sHangul, PseudoRubyText::eBelow );
+
+        m_pWordInput->SetModifyHdl( LINK( this,  HangulHanjaConversionDialog, OnSuggestionModified ) );
+        m_pSuggestions->SetSelectHdl( LINK( this,  HangulHanjaConversionDialog, OnSuggestionSelected ) );
+        m_pReplaceByChar->SetClickHdl( LINK( this, HangulHanjaConversionDialog, ClickByCharacterHdl ) );
+        m_pHangulOnly->SetClickHdl( LINK( this,  HangulHanjaConversionDialog, OnConversionDirectionClicked ) );
+        m_pHanjaOnly->SetClickHdl(  LINK( this,  HangulHanjaConversionDialog, OnConversionDirectionClicked ) );
+        m_pOptions->SetClickHdl( LINK( this, HangulHanjaConversionDialog, OnOption ) );
 
         if ( editeng::HangulHanjaConversion::eHangulToHanja == _ePrimaryDirection )
         {
-            m_pIgnoreNonPrimary = &m_aHangulOnly;
+            m_pIgnoreNonPrimary = m_pHangulOnly;
         }
         else
         {
-            m_pIgnoreNonPrimary = &m_aHanjaOnly;
+            m_pIgnoreNonPrimary = m_pHanjaOnly;
         }
 
         // initial focus
         FocusSuggestion( );
 
         // initial control values
-        m_aSimpleConversion.Check();
+        m_pSimpleConversion->Check();
 
-        m_pPlayground->GetButton(SvxCommonLinguisticControl::eClose     )->SetHelpId(HID_HANGULDLG_BUTTON_CLOSE    );
-        m_pPlayground->GetButton(SvxCommonLinguisticControl::eIgnore    )->SetHelpId(HID_HANGULDLG_BUTTON_IGNORE   );
-        m_pPlayground->GetButton(SvxCommonLinguisticControl::eIgnoreAll )->SetHelpId(HID_HANGULDLG_BUTTON_IGNOREALL);
-        m_pPlayground->GetButton(SvxCommonLinguisticControl::eChange    )->SetHelpId(HID_HANGULDLG_BUTTON_CHANGE   );
-        m_pPlayground->GetButton(SvxCommonLinguisticControl::eChangeAll )->SetHelpId(HID_HANGULDLG_BUTTON_CHANGEALL);
-        m_pPlayground->GetButton(SvxCommonLinguisticControl::eOptions   )->SetHelpId(HID_HANGULDLG_BUTTON_OPTIONS  );
-        m_pPlayground->GetWordInputControl().SetHelpId(HID_HANGULDLG_EDIT_NEWWORD);
-
-        FreeResource();
-
-        m_aSuggestions.SetHelpIds();
+        m_pSuggestions->SetHelpIds();
     }
 
 
@@ -615,23 +606,22 @@ namespace svx
 
     void HangulHanjaConversionDialog::FillSuggestions( const ::com::sun::star::uno::Sequence< OUString >& _rSuggestions )
     {
-        m_aSuggestions.Clear();
-
+        m_pSuggestions->Clear();
         const OUString* pSuggestions = _rSuggestions.getConstArray();
         const OUString* pSuggestionsEnd = _rSuggestions.getConstArray() + _rSuggestions.getLength();
         while ( pSuggestions != pSuggestionsEnd )
-            m_aSuggestions.InsertEntry( *pSuggestions++ );
+            m_pSuggestions->InsertEntry( *pSuggestions++ );
 
         // select the first suggestion, and fill in the suggestion edit field
         OUString sFirstSuggestion;
-        if ( m_aSuggestions.GetEntryCount() )
+        if ( m_pSuggestions->GetEntryCount() )
         {
-            sFirstSuggestion = m_aSuggestions.GetEntry( 0 );
-            m_aSuggestions.SelectEntryPos( 0 );
+            sFirstSuggestion = m_pSuggestions->GetEntry( 0 );
+            m_pSuggestions->SelectEntryPos( 0 );
         }
-        m_pPlayground->GetWordInputControl().SetText( sFirstSuggestion );
-        m_pPlayground->GetWordInputControl().SaveValue();
-        OnSuggestionModified( &m_pPlayground->GetWordInputControl() );
+        m_pWordInput->SetText( sFirstSuggestion );
+        m_pWordInput->SaveValue();
+        OnSuggestionModified( m_pWordInput );
     }
 
 
@@ -643,39 +633,39 @@ namespace svx
 
     void HangulHanjaConversionDialog::SetIgnoreHdl( const Link& _rHdl )
     {
-        m_pPlayground->SetButtonHandler( SvxCommonLinguisticControl::eIgnore, _rHdl );
+        m_pIgnore->SetClickHdl( _rHdl );
     }
 
 
     void HangulHanjaConversionDialog::SetIgnoreAllHdl( const Link& _rHdl )
     {
-        m_pPlayground->SetButtonHandler( SvxCommonLinguisticControl::eIgnoreAll, _rHdl );
+        m_pIgnoreAll->SetClickHdl( _rHdl );
     }
 
 
     void HangulHanjaConversionDialog::SetChangeHdl( const Link& _rHdl )
     {
-        m_pPlayground->SetButtonHandler( SvxCommonLinguisticControl::eChange, _rHdl );
+        m_pReplace->SetClickHdl( _rHdl );
     }
 
 
     void HangulHanjaConversionDialog::SetChangeAllHdl( const Link& _rHdl )
     {
-        m_pPlayground->SetButtonHandler( SvxCommonLinguisticControl::eChangeAll, _rHdl );
+        m_pReplaceAll->SetClickHdl( _rHdl );
     }
 
 
     void HangulHanjaConversionDialog::SetFindHdl( const Link& _rHdl )
     {
-        m_aFind.SetClickHdl( _rHdl );
+        m_pFind->SetClickHdl( _rHdl );
     }
 
 
     void HangulHanjaConversionDialog::SetConversionFormatChangedHdl( const Link& _rHdl )
     {
-        m_aSimpleConversion.SetClickHdl( _rHdl );
-        m_aHangulBracketed.SetClickHdl( _rHdl );
-        m_aHanjaBracketed.SetClickHdl( _rHdl );
+        m_pSimpleConversion->SetClickHdl( _rHdl );
+        m_pHangulBracketed->SetClickHdl( _rHdl );
+        m_pHanjaBracketed->SetClickHdl( _rHdl );
         m_pHanjaAbove->SetClickHdl( _rHdl );
         m_pHanjaBelow->SetClickHdl( _rHdl );
         m_pHangulAbove->SetClickHdl( _rHdl );
@@ -689,21 +679,21 @@ namespace svx
     }
 
 
-    IMPL_LINK_NOARG(HangulHanjaConversionDialog, OnSuggestionSelected)
+    IMPL_LINK_NOARG( HangulHanjaConversionDialog, OnSuggestionSelected )
     {
-        m_pPlayground->GetWordInputControl().SetText( m_aSuggestions.GetSelectEntry() );
+        m_pWordInput->SetText( m_pSuggestions->GetSelectEntry() );
         OnSuggestionModified( NULL );
         return 0L;
     }
 
 
-    IMPL_LINK_NOARG(HangulHanjaConversionDialog, OnSuggestionModified)
+    IMPL_LINK_NOARG( HangulHanjaConversionDialog, OnSuggestionModified )
     {
-        m_aFind.Enable( m_pPlayground->GetWordInputControl().IsValueChangedFromSaved() );
+        m_pFind->Enable( m_pWordInput->IsValueChangedFromSaved() );
 
-        bool bSameLen = m_pPlayground->GetWordInputControl().GetText().getLength() == m_pPlayground->GetCurrentText().getLength();
-        m_pPlayground->EnableButton( SvxCommonLinguisticControl::eChange, m_bDocumentMode && bSameLen );
-        m_pPlayground->EnableButton( SvxCommonLinguisticControl::eChangeAll, m_bDocumentMode && bSameLen );
+        bool bSameLen = m_pWordInput->GetText().getLength() == m_pOriginalWord->GetText().getLength();
+        m_pReplace->Enable( m_bDocumentMode && bSameLen );
+        m_pReplaceAll->Enable( m_bDocumentMode && bSameLen );
 
         return 0L;
     }
@@ -711,10 +701,10 @@ namespace svx
 
     IMPL_LINK( HangulHanjaConversionDialog, ClickByCharacterHdl, CheckBox *, pBox )
     {
-        m_aClickByCharacterLink.Call(pBox);
+        m_aClickByCharacterLink.Call( pBox );
 
         bool bByCharacter = pBox->IsChecked();
-        m_aSuggestions.DisplayListBox( !bByCharacter );
+        m_pSuggestions->DisplayListBox( !bByCharacter );
 
         return 0L;
     }
@@ -723,14 +713,14 @@ namespace svx
     IMPL_LINK( HangulHanjaConversionDialog, OnConversionDirectionClicked, CheckBox *, pBox )
     {
         CheckBox *pOtherBox = 0;
-        if (pBox == &m_aHangulOnly)
-            pOtherBox = &m_aHanjaOnly;
-        else if (pBox == &m_aHanjaOnly)
-            pOtherBox = &m_aHangulOnly;
-        if (pBox && pOtherBox)
+        if ( pBox == m_pHangulOnly )
+            pOtherBox = m_pHanjaOnly;
+        else if ( pBox == m_pHanjaOnly )
+            pOtherBox = m_pHangulOnly;
+        if ( pBox && pOtherBox )
         {
             bool bBoxChecked = pBox->IsChecked();
-            if (bBoxChecked)
+            if ( bBoxChecked )
                 pOtherBox->Check( false );
             pOtherBox->Enable( !bBoxChecked );
         }
@@ -738,31 +728,24 @@ namespace svx
         return 0L;
     }
 
-
-    IMPL_LINK_NOARG(HangulHanjaConversionDialog, OnClose)
-    {
-        Close();
-        return 0L;
-    }
-
-    IMPL_LINK_NOARG(HangulHanjaConversionDialog, OnOption)
+    IMPL_LINK_NOARG( HangulHanjaConversionDialog, OnOption )
     {
         HangulHanjaOptionsDialog        aOptDlg( this );
         aOptDlg.Execute();
-        m_aOptionsChangedLink.Call(this);
+        m_aOptionsChangedLink.Call( this );
         return 0L;
     }
 
 
     OUString HangulHanjaConversionDialog::GetCurrentString( ) const
     {
-        return m_pPlayground->GetCurrentText( );
+        return m_pOriginalWord->GetText( );
     }
 
 
     void HangulHanjaConversionDialog::FocusSuggestion( )
     {
-        m_pPlayground->GetWordInputControl().GrabFocus();
+        m_pWordInput->GrabFocus();
     }
 
 
@@ -780,14 +763,13 @@ namespace svx
     void HangulHanjaConversionDialog::SetCurrentString( const OUString& _rNewString,
         const Sequence< OUString >& _rSuggestions, bool _bOriginatesFromDocument )
     {
-        m_pPlayground->SetCurrentText( _rNewString );
+        m_pOriginalWord->SetText( _rNewString );
 
         bool bOldDocumentMode = m_bDocumentMode;
         m_bDocumentMode = _bOriginatesFromDocument; // before FillSuggestions!
         FillSuggestions( _rSuggestions );
 
-        m_pPlayground->EnableButton( SvxCommonLinguisticControl::eIgnoreAll, m_bDocumentMode );
-            // all other buttons have been implicitly enabled or disabled during filling in the suggestions
+        m_pIgnoreAll->Enable( m_bDocumentMode );
 
         // switch the def button depending if we're working for document text
         if ( bOldDocumentMode != m_bDocumentMode )
@@ -796,13 +778,13 @@ namespace svx
             Window* pNewDefButton = NULL;
             if ( m_bDocumentMode )
             {
-                pOldDefButton = &m_aFind;
-                pNewDefButton = m_pPlayground->GetButton( SvxCommonLinguisticControl::eChange );
+                pOldDefButton = m_pFind;
+                pNewDefButton = m_pReplace;
             }
             else
             {
-                pOldDefButton = m_pPlayground->GetButton( SvxCommonLinguisticControl::eChange );
-                pNewDefButton = &m_aFind;
+                pOldDefButton = m_pReplace;
+                pNewDefButton = m_pFind;
             }
 
             DBG_ASSERT( WB_DEFBUTTON == ( pOldDefButton->GetStyle( ) & WB_DEFBUTTON ),
@@ -824,14 +806,14 @@ namespace svx
 
     OUString HangulHanjaConversionDialog::GetCurrentSuggestion( ) const
     {
-        return m_pPlayground->GetWordInputControl().GetText();
+        return m_pWordInput->GetText();
     }
 
 
     void HangulHanjaConversionDialog::SetByCharacter( bool _bByCharacter )
     {
-        m_aReplaceByChar.Check( _bByCharacter );
-        m_aSuggestions.DisplayListBox( !_bByCharacter );
+        m_pReplaceByChar->Check( _bByCharacter );
+        m_pSuggestions->DisplayListBox( !_bByCharacter );
     }
 
 
@@ -840,15 +822,15 @@ namespace svx
             HHC::ConversionDirection _ePrimaryConversionDirection )
     {
         // default state: try both direction
-        m_aHangulOnly.Check( false );
-        m_aHangulOnly.Enable( true );
-        m_aHanjaOnly.Check( false );
-        m_aHanjaOnly.Enable( true );
+        m_pHangulOnly->Check( false );
+        m_pHangulOnly->Enable( true );
+        m_pHanjaOnly->Check( false );
+        m_pHanjaOnly->Enable( true );
 
         if (!_bTryBothDirections)
         {
             CheckBox *pBox = _ePrimaryConversionDirection == HHC::eHangulToHanja?
-                                    &m_aHangulOnly : &m_aHanjaOnly;
+                                    m_pHangulOnly : m_pHanjaOnly;
             pBox->Check( true );
             OnConversionDirectionClicked( pBox );
         }
@@ -857,7 +839,7 @@ namespace svx
 
     bool HangulHanjaConversionDialog::GetUseBothDirections( ) const
     {
-        return !m_aHangulOnly.IsChecked() && !m_aHanjaOnly.IsChecked();
+        return !m_pHangulOnly->IsChecked() && !m_pHanjaOnly->IsChecked();
     }
 
 
@@ -865,9 +847,9 @@ namespace svx
             HHC::ConversionDirection eDefaultDirection ) const
     {
         HHC::ConversionDirection eDirection = eDefaultDirection;
-        if (m_aHangulOnly.IsChecked() && !m_aHanjaOnly.IsChecked())
+        if ( m_pHangulOnly->IsChecked() && !m_pHanjaOnly->IsChecked() )
             eDirection = HHC::eHangulToHanja;
-        else if (!m_aHangulOnly.IsChecked() && m_aHanjaOnly.IsChecked())
+        else if ( !m_pHangulOnly->IsChecked() && m_pHanjaOnly->IsChecked() )
             eDirection = HHC::eHanjaToHangul;
         return eDirection;
     }
@@ -877,9 +859,9 @@ namespace svx
     {
         switch ( _eType )
         {
-            case HHC::eSimpleConversion: m_aSimpleConversion.Check(); break;
-            case HHC::eHangulBracketed: m_aHangulBracketed.Check(); break;
-            case HHC::eHanjaBracketed:  m_aHanjaBracketed.Check(); break;
+            case HHC::eSimpleConversion: m_pSimpleConversion->Check(); break;
+            case HHC::eHangulBracketed: m_pHangulBracketed->Check(); break;
+            case HHC::eHanjaBracketed:  m_pHanjaBracketed->Check(); break;
             case HHC::eRubyHanjaAbove:  m_pHanjaAbove->Check(); break;
             case HHC::eRubyHanjaBelow:  m_pHanjaBelow->Check(); break;
             case HHC::eRubyHangulAbove: m_pHangulAbove->Check(); break;
@@ -892,11 +874,11 @@ namespace svx
 
     HHC::ConversionFormat HangulHanjaConversionDialog::GetConversionFormat( ) const
     {
-        if ( m_aSimpleConversion.IsChecked() )
+        if ( m_pSimpleConversion->IsChecked() )
             return HHC::eSimpleConversion;
-        if ( m_aHangulBracketed.IsChecked() )
+        if ( m_pHangulBracketed->IsChecked() )
             return HHC::eHangulBracketed;
-        if ( m_aHanjaBracketed.IsChecked() )
+        if ( m_pHanjaBracketed->IsChecked() )
             return HHC::eHanjaBracketed;
         if ( m_pHanjaAbove->IsChecked() )
             return HHC::eRubyHanjaAbove;
diff --git a/cui/source/dialogs/hangulhanjadlg.hrc b/cui/source/dialogs/hangulhanjadlg.hrc
deleted file mode 100644
index c06a2ed..0000000
--- a/cui/source/dialogs/hangulhanjadlg.hrc
+++ /dev/null
@@ -1,80 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements. See the NOTICE file distributed
- *   with this work for additional information regarding copyright
- *   ownership. The ASF licenses this file to you under the Apache
- *   License, Version 2.0 (the "License"); you may not use this file
- *   except in compliance with the License. You may obtain a copy of
- *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-#ifndef SVX_HANGUL_HANJA_DLG_HRC
-#define SVX_HANGUL_HANJA_DLG_HRC
-
-#include <svtools/controldims.hrc>
-
-// PushButton
-#define PB_FIND         1
-
-// Control
-#define CTL_SUGGESTIONS 1
-
-// FixedText
-#define FT_FORMAT           1
-#define FT_RESIZE_ANCHOR    2
-#define FT_CONVERSION       3
-
-// RadioButton
-#define RB_SIMPLE_CONVERSION        1
-#define RB_HANJA_HANGUL_BRACKETED   2
-#define RB_HANGUL_HANJA_BRACKETED   3
-#define RB_HANGUL_HANJA_ABOVE       4
-#define RB_HANGUL_HANJA_BELOW       5
-#define RB_HANJA_HANGUL_ABOVE       6
-#define RB_HANJA_HANGUL_BELOW       7
-
-// CheckBox
-#define CB_REPLACE_BY_CHARACTER     1
-#define CB_HANGUL_ONLY              2
-#define CB_HANJA_ONLY               3
-
-// String
-#define STR_HANGUL                  1
-#define STR_HANJA                   2
-
-#define FT_WORD                     10
-#define FT_AKTWORD                  11
-#define FT_NEWWORD                  12
-#define GB_AUDIT                    13
-#define BTN_IGNORE                  14
-#define BTN_IGNOREALL               15
-#define BTN_CHANGE                  16
-#define BTN_CHANGEALL               17
-#define FT_STATUS                   18
-#define BTN_SPL_CANCEL              19
-#define BTN_SPL_HELP                20
-#define ED_NEWWORD                  21
-#define FT_SUGGESTION               22
-
-// Hangul / Hanja Options Dialog
-
-#define BTN_OPTIONS                 10
-
-// metrics
-
-#define HHO_DLGWIDTH                287
-
-// Hangul Hanja Edit Custom Dictionary Dialog
-#define MAXNUM_SUGGESTIONS          50
-
-#endif // SVX_HANGUL_HANJA_DLG_HRC
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/cui/source/dialogs/hangulhanjadlg.src b/cui/source/dialogs/hangulhanjadlg.src
deleted file mode 100644
index 516b251..0000000
--- a/cui/source/dialogs/hangulhanjadlg.src
+++ /dev/null
@@ -1,182 +0,0 @@
-/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
-/*
- * This file is part of the LibreOffice project.
- *
- * This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/.
- *
- * This file incorporates work covered by the following license notice:
- *
- *   Licensed to the Apache Software Foundation (ASF) under one or more
- *   contributor license agreements. See the NOTICE file distributed
- *   with this work for additional information regarding copyright
- *   ownership. The ASF licenses this file to you under the Apache
- *   License, Version 2.0 (the "License"); you may not use this file
- *   except in compliance with the License. You may obtain a copy of
- *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
- */
-#include <cuires.hrc>
-#include "helpid.hrc"
-
-#include "hangulhanjadlg.hrc"
-
-ModalDialog RID_SVX_MDLG_HANGULHANJA
-{
-    HelpId = HID_DIALOG_HANGULHANJA;
-    Size = MAP_APPFONT( 302, 175 );
-    OutputSize = TRUE;
-    Closeable = TRUE ;
-    Moveable = TRUE ;
-    SVLook = TRUE;
-
-    Text [ en-US ] = "Hangul/Hanja Conversion";
-
-    PushButton PB_FIND
-    {
-        HelpID = "cui:PushButton:RID_SVX_MDLG_HANGULHANJA:PB_FIND";
-        Pos = MAP_APPFONT( 207, 23 );
-        Size = MAP_APPFONT( 30, 14 );
-
-        Text [ en-US ] = "~Find";
-    };
-
-    Control CTL_SUGGESTIONS
-    {
-        Pos = MAP_APPFONT( 51, 46 );
-        Size = MAP_APPFONT( 186, 30 );
-        TabStop = TRUE ;
-    };
-
-    FixedText FT_FORMAT
-    {
-        Pos = MAP_APPFONT( 6, 81 );
-        Size = MAP_APPFONT( 42, 8 );
-
-        Text [ en-US ] = "Format";
-    };
-
-    RadioButton RB_SIMPLE_CONVERSION
-    {
-        HelpID = "cui:RadioButton:RID_SVX_MDLG_HANGULHANJA:RB_SIMPLE_CONVERSION";
-        Pos = MAP_APPFONT( 51, 81 );
-        Size = MAP_APPFONT( 60, 8 );
-
-        Group = TRUE;
-
-        Text [ en-US ] = "~Hangul/Hanja";
-    };
-
-    RadioButton RB_HANJA_HANGUL_BRACKETED
-    {
-        HelpID = "cui:RadioButton:RID_SVX_MDLG_HANGULHANJA:RB_HANJA_HANGUL_BRACKETED";
-        Pos = MAP_APPFONT( 114, 81 );
-        Size = MAP_APPFONT( 60, 8 );
-
-        Text [ en-US ] = "Hanja (Han~gul)";
-    };
-
-    RadioButton RB_HANGUL_HANJA_BRACKETED
-    {
-        HelpID = "cui:RadioButton:RID_SVX_MDLG_HANGULHANJA:RB_HANGUL_HANJA_BRACKETED";
-        Pos = MAP_APPFONT( 177, 81 );
-        Size = MAP_APPFONT( 60, 8 );
-
-        Text [ en-US ] = "Hang~ul (Hanja)";
-    };
-
-    RadioButton RB_HANGUL_HANJA_ABOVE
-    {
-        HelpID = "cui:RadioButton:RID_SVX_MDLG_HANGULHANJA:RB_HANGUL_HANJA_ABOVE";
-        Pos = MAP_APPFONT( 51, 95 );
-        Size = MAP_APPFONT( 60, 16 );
-
-        // this is the _primary_ text
-        Text [ en-US ] = "Hangu~l";
-    };
-
-    RadioButton RB_HANGUL_HANJA_BELOW
-    {
-        HelpID = "cui:RadioButton:RID_SVX_MDLG_HANGULHANJA:RB_HANGUL_HANJA_BELOW";
-        Pos = MAP_APPFONT( 114, 95 );
-        Size = MAP_APPFONT( 60, 16 );
-
-        // this is the _primary_ text
-        Text [ en-US ] = "Hang~ul";
-    };
-
-    RadioButton RB_HANJA_HANGUL_ABOVE
-    {
-        HelpID = "cui:RadioButton:RID_SVX_MDLG_HANGULHANJA:RB_HANJA_HANGUL_ABOVE";
-        Pos = MAP_APPFONT( 56, 114 );
-        Size = MAP_APPFONT( 60, 16 );
-
-        // this is the _primary_ text
-        Text [ en-US ] = "Han~ja";
-    };
-
-    RadioButton RB_HANJA_HANGUL_BELOW
-    {
-        HelpID = "cui:RadioButton:RID_SVX_MDLG_HANGULHANJA:RB_HANJA_HANGUL_BELOW";
-        Pos = MAP_APPFONT( 114, 114 );
-        Size = MAP_APPFONT( 60, 16 );
-
-        // this is the _primary_ text
-        Text [ en-US ] = "Ha~nja";
-    };
-
-    FixedText FT_CONVERSION
-    {
-        Pos = MAP_APPFONT( 6, 134 );
-        Size = MAP_APPFONT( 42, 8 );
-
-        Text [ en-US ] = "Conversion";
-    };
-
-    CheckBox CB_HANGUL_ONLY
-    {
-        HelpID = "cui:CheckBox:RID_SVX_MDLG_HANGULHANJA:CB_HANGUL_ONLY";
-        Pos = MAP_APPFONT( 51, 134 );
-        Size = MAP_APPFONT( 60, 8 );
-
-        Text [ en-US ] = "Hangul ~only";
-    };
-
-    CheckBox CB_HANJA_ONLY
-    {
-        HelpID = "cui:CheckBox:RID_SVX_MDLG_HANGULHANJA:CB_HANJA_ONLY";
-        Pos = MAP_APPFONT( 114, 134 );
-        Size = MAP_APPFONT( 55, 8 );
-
-        Text [ en-US ] = "Hanja onl~y";
-    };
-
-    // this element is only for determining where our radio button group ends (in both directions)
-    FixedText FT_RESIZE_ANCHOR
-    {
-        Pos = MAP_APPFONT( 241, 133 );
-    };
-
-    CheckBox CB_REPLACE_BY_CHARACTER
-    {
-        HelpID = "cui:CheckBox:RID_SVX_MDLG_HANGULHANJA:CB_REPLACE_BY_CHARACTER";
-        Pos = MAP_APPFONT( 241, 81 );
-        Size = MAP_APPFONT( 55, 24 );
-
-        WordBreak = TRUE;
-
-        Text [ en-US ] = "Replace b~y character";
-    };
-
-    String STR_HANGUL
-    {
-        Text [ en-US ] = "Hangul";
-    };
-
-    String STR_HANJA
-    {
-        Text [ en-US ] = "Hanja";
-    };
-};
-
-/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/cui/source/inc/hangulhanjadlg.hxx b/cui/source/inc/hangulhanjadlg.hxx
index 6b1828a..cbee8ef 100644
--- a/cui/source/inc/hangulhanjadlg.hxx
+++ b/cui/source/inc/hangulhanjadlg.hxx
@@ -35,16 +35,9 @@
 #include <vector>
 #include <memory>
 
-class SvxCommonLinguisticControl;
-
 namespace svx
 {
 
-
-
-    //= HangulHanjaConversionDialog
-
-
     class SuggestionSet : public ValueSet
     {
     public:
@@ -58,7 +51,7 @@ namespace svx
     class SuggestionDisplay : public Control
     {
     public:
-        SuggestionDisplay( Window* pParent, const ResId& rResId );
+        SuggestionDisplay( Window* pParent, WinBits nBits );
         virtual ~SuggestionDisplay();
 
         void DisplayListBox( bool bDisplayListBox );
@@ -101,30 +94,33 @@ namespace svx
         bool          m_bInSelectionUpdate;
     };
 
+    class RubyRadioButton;
+
+    //= HangulHanjaConversionDialog
+
     class HangulHanjaConversionDialog : public  ModalDialog
     {
     private:
-        SAL_WNODEPRECATED_DECLARATIONS_PUSH
-        ::std::auto_ptr< SvxCommonLinguisticControl >
-                    m_pPlayground;                  // order matters: before all other controls!
-        SAL_WNODEPRECATED_DECLARATIONS_POP
-
-        PushButton      m_aFind;
-        SuggestionDisplay   m_aSuggestions;
-        FixedText       m_aFormat;
-        RadioButton     m_aSimpleConversion;
-        RadioButton     m_aHangulBracketed;
-        RadioButton     m_aHanjaBracketed;
-        SAL_WNODEPRECATED_DECLARATIONS_PUSH
-        ::std::auto_ptr< RadioButton >  m_pHanjaAbove;
-        ::std::auto_ptr< RadioButton >  m_pHanjaBelow;
-        ::std::auto_ptr< RadioButton >  m_pHangulAbove;
-        ::std::auto_ptr< RadioButton >  m_pHangulBelow;
-        SAL_WNODEPRECATED_DECLARATIONS_POP
-        FixedText       m_aConversion;
-        CheckBox        m_aHangulOnly;
-        CheckBox        m_aHanjaOnly;
-        CheckBox        m_aReplaceByChar;
+
+        PushButton*         m_pFind;
+        PushButton*         m_pIgnore;
+        PushButton*         m_pIgnoreAll;
+        PushButton*         m_pReplace;
+        PushButton*         m_pReplaceAll;
+        PushButton*         m_pOptions;
+        SuggestionDisplay*  m_pSuggestions;
+        RadioButton*        m_pSimpleConversion;
+        RadioButton*        m_pHangulBracketed;
+        RadioButton*        m_pHanjaBracketed;
+        Edit*               m_pWordInput;
+        FixedText*          m_pOriginalWord;
+        RubyRadioButton*    m_pHanjaAbove;
+        RubyRadioButton*    m_pHanjaBelow;
+        RubyRadioButton*    m_pHangulAbove;
+        RubyRadioButton*    m_pHangulBelow;
+        CheckBox*           m_pHangulOnly;
+        CheckBox*           m_pHanjaOnly;
+        CheckBox*           m_pReplaceByChar;
 
         CheckBox*       m_pIgnoreNonPrimary;
         /** are we working for a document? This is normally true, but in case
diff --git a/cui/uiconfig/ui/hangulhanjaconversiondialog.ui b/cui/uiconfig/ui/hangulhanjaconversiondialog.ui
new file mode 100644
index 0000000..e9b0ddb
--- /dev/null
+++ b/cui/uiconfig/ui/hangulhanjaconversiondialog.ui
@@ -0,0 +1,558 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- Generated with glade 3.16.1 -->
+<interface>
+  <requires lib="gtk+" version="3.10"/>
+  <requires lib="LibreOffice" version="1.0"/>
+  <object class="GtkDialog" id="HangulHanjaConversionDialog">
+    <property name="can_focus">False</property>
+    <property name="title" translatable="yes">Hangul/Hanja Conversion</property>
+    <property name="type_hint">normal</property>
+    <child internal-child="vbox">
+      <object class="GtkBox" id="dialog-vbox1">
+        <property name="can_focus">False</property>
+        <property name="orientation">vertical</property>
+        <property name="spacing">2</property>
+        <child internal-child="action_area">
+          <object class="GtkButtonBox" id="dialog-action_area1">
+            <property name="can_focus">False</property>
+            <property name="layout_style">end</property>
+            <child>
+              <object class="GtkButton" id="ok">
+                <property name="label">gtk-ok</property>
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="can_default">True</property>
+                <property name="has_default">True</property>
+                <property name="receives_default">True</property>
+                <property name="use_stock">True</property>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">0</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkButton" id="cancel">
+                <property name="label">gtk-cancel</property>
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="receives_default">True</property>
+                <property name="use_stock">True</property>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">1</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkButton" id="help">
+                <property name="label">gtk-help</property>
+                <property name="visible">True</property>
+                <property name="can_focus">True</property>
+                <property name="receives_default">True</property>
+                <property name="use_stock">True</property>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">2</property>
+              </packing>
+            </child>
+          </object>
+          <packing>
+            <property name="expand">False</property>
+            <property name="fill">True</property>
+            <property name="pack_type">end</property>
+            <property name="position">0</property>
+          </packing>
+        </child>
+        <child>
+          <object class="GtkBox" id="box1">
+            <property name="visible">True</property>
+            <property name="can_focus">False</property>
+            <property name="margin_left">6</property>
+            <property name="margin_right">6</property>
+            <property name="margin_top">6</property>
+            <property name="margin_bottom">6</property>
+            <property name="spacing">12</property>
+            <child>
+              <object class="GtkBox" id="box3">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="orientation">vertical</property>
+                <property name="spacing">6</property>
+                <child>
+                  <object class="GtkBox" id="box4">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="spacing">6</property>
+                    <child>
+                      <object class="GtkLabel" id="label1">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="margin_right">28</property>
+                        <property name="label" translatable="yes">Original</property>
+                      </object>
+                      <packing>
+                        <property name="expand">False</property>
+                        <property name="fill">True</property>
+                        <property name="position">0</property>
+                      </packing>
+                    </child>
+                    <child>
+                      <object class="GtkLabel" id="originalword">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                      </object>
+                      <packing>
+                        <property name="expand">False</property>
+                        <property name="fill">True</property>
+                        <property name="position">1</property>
+                      </packing>
+                    </child>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">0</property>
+                  </packing>
+                </child>
+                <child>
+                  <object class="GtkBox" id="box5">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="spacing">6</property>
+                    <child>
+                      <object class="GtkLabel" id="label3">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="margin_right">42</property>
+                        <property name="label" translatable="yes">Word</property>
+                      </object>
+                      <packing>
+                        <property name="expand">False</property>
+                        <property name="fill">True</property>
+                        <property name="position">0</property>
+                      </packing>
+                    </child>
+                    <child>
+                      <object class="GtkEntry" id="wordinput">
+                        <property name="visible">True</property>
+                        <property name="can_focus">True</property>
+                      </object>
+                      <packing>
+                        <property name="expand">True</property>
+                        <property name="fill">True</property>
+                        <property name="position">1</property>
+                      </packing>
+                    </child>
+                    <child>
+                      <object class="GtkButton" id="find">
+                        <property name="label" translatable="yes">_Find</property>
+                        <property name="visible">True</property>
+                        <property name="can_focus">True</property>
+                        <property name="receives_default">True</property>
+                        <property name="use_underline">True</property>
+                      </object>
+                      <packing>
+                        <property name="expand">False</property>
+                        <property name="fill">True</property>
+                        <property name="position">2</property>
+                      </packing>
+                    </child>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">1</property>
+                  </packing>
+                </child>
+                <child>
+                  <object class="GtkBox" id="box6">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="spacing">6</property>
+                    <child>
+                      <object class="GtkLabel" id="label4">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="label" translatable="yes">Suggestions</property>
+                      </object>
+                      <packing>
+                        <property name="expand">True</property>
+                        <property name="fill">True</property>
+                        <property name="position">0</property>
+                      </packing>
+                    </child>
+                    <child>
+                      <object class="cuilo-SuggestionDisplay" id="suggestions:border">
+                        <property name="visible">True</property>
+                        <property name="can_focus">True</property>
+                      </object>
+                      <packing>
+                        <property name="expand">False</property>
+                        <property name="fill">True</property>
+                        <property name="position">1</property>
+                      </packing>
+                    </child>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">2</property>
+                  </packing>
+                </child>
+                <child>
+                  <object class="GtkBox" id="box7">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="halign">baseline</property>
+                    <property name="hexpand">True</property>
+                    <property name="spacing">6</property>
+                    <child>
+                      <object class="GtkLabel" id="label5">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="margin_right">28</property>
+                        <property name="label" translatable="yes">Format</property>
+                      </object>
+                      <packing>
+                        <property name="expand">False</property>
+                        <property name="fill">True</property>
+                        <property name="position">0</property>
+                      </packing>
+                    </child>
+                    <child>
+                      <object class="GtkRadioButton" id="simpleconversion">
+                        <property name="label" translatable="yes">_Hangul/Hanja</property>
+                        <property name="visible">True</property>
+                        <property name="can_focus">True</property>
+                        <property name="receives_default">False</property>
+                        <property name="use_underline">True</property>
+                        <property name="xalign">0</property>
+                        <property name="active">True</property>
+                        <property name="draw_indicator">True</property>
+                        <property name="group">hangulbracket</property>
+                      </object>
+                      <packing>
+                        <property name="expand">False</property>
+                        <property name="fill">True</property>
+                        <property name="position">1</property>
+                      </packing>
+                    </child>
+                    <child>
+                      <object class="GtkRadioButton" id="hangulbracket">
+                        <property name="label" translatable="yes">Hanja(Han_gul)</property>
+                        <property name="visible">True</property>
+                        <property name="can_focus">True</property>
+                        <property name="receives_default">False</property>
+                        <property name="use_underline">True</property>
+                        <property name="xalign">0</property>
+                        <property name="active">True</property>
+                        <property name="draw_indicator">True</property>
+                      </object>
+                      <packing>
+                        <property name="expand">False</property>
+                        <property name="fill">True</property>
+                        <property name="position">2</property>
+                      </packing>
+                    </child>
+                    <child>
+                      <object class="GtkRadioButton" id="hanjabracket">
+                        <property name="label" translatable="yes">Hang_ul(Hanja)</property>
+                        <property name="visible">True</property>
+                        <property name="can_focus">True</property>
+                        <property name="receives_default">False</property>
+                        <property name="use_underline">True</property>
+                        <property name="xalign">0</property>
+                        <property name="active">True</property>
+                        <property name="draw_indicator">True</property>
+                        <property name="group">simpleconversion</property>
+                      </object>
+                      <packing>
+                        <property name="expand">False</property>
+                        <property name="fill">True</property>
+                        <property name="position">3</property>
+                      </packing>
+                    </child>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">3</property>
+                  </packing>
+                </child>
+                <child>
+                  <object class="GtkGrid" id="grid1">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="row_spacing">12</property>
+                    <property name="column_spacing">12</property>
+                    <child>
+                      <object class="cuilo-RubyRadioButton" id="hanja_above:border">
+                        <property name="label" translatable="yes">Hanja</property>
+                        <property name="visible">True</property>
+                        <property name="can_focus">True</property>
+                        <property name="receives_default">False</property>
+                        <property name="margin_left">88</property>
+                        <property name="xalign">0.2</property>
+                        <property name="active">True</property>
+                        <property name="draw_indicator">True</property>
+                        <property name="group">hanja_below</property>
+                      </object>
+                      <packing>
+                        <property name="left_attach">0</property>
+                        <property name="top_attach">0</property>
+                        <property name="width">1</property>
+                        <property name="height">1</property>
+                      </packing>
+                    </child>
+                    <child>
+                      <object class="cuilo-RubyRadioButton" id="hanja_below:border">
+                        <property name="label" translatable="yes">Hanja</property>
+                        <property name="visible">True</property>
+                        <property name="can_focus">True</property>
+                        <property name="receives_default">False</property>
+                        <property name="margin_left">12</property>
+                        <property name="xalign">0.2</property>
+                        <property name="draw_indicator">True</property>
+                        <property name="group">hangul_above</property>
+                      </object>
+                      <packing>
+                        <property name="left_attach">1</property>
+                        <property name="top_attach">0</property>
+                        <property name="width">1</property>
+                        <property name="height">1</property>
+                      </packing>
+                    </child>
+                    <child>
+                      <object class="cuilo-RubyRadioButton" id="hangul_above:border">
+                        <property name="label" translatable="yes">Hangul</property>
+                        <property name="visible">True</property>
+                        <property name="can_focus">True</property>
+                        <property name="receives_default">False</property>
+                        <property name="margin_left">88</property>
+                        <property name="xalign">0.2</property>
+                        <property name="draw_indicator">True</property>
+                        <property name="group">hangul_below</property>
+                      </object>
+                      <packing>
+                        <property name="left_attach">0</property>
+                        <property name="top_attach">1</property>
+                        <property name="width">1</property>
+                        <property name="height">1</property>
+                      </packing>
+                    </child>
+                    <child>
+                      <object class="cuilo-RubyRadioButton" id="hangul_below:border">
+                        <property name="label" translatable="yes">Hangul</property>
+                        <property name="visible">True</property>
+                        <property name="can_focus">True</property>
+                        <property name="receives_default">False</property>
+                        <property name="margin_left">12</property>
+                        <property name="xalign">0.2</property>
+                        <property name="draw_indicator">True</property>
+                        <property name="group">hanja_above</property>
+                      </object>
+                      <packing>
+                        <property name="left_attach">1</property>
+                        <property name="top_attach">1</property>
+                        <property name="width">1</property>
+                        <property name="height">1</property>
+                      </packing>
+                    </child>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">4</property>
+                  </packing>
+                </child>
+                <child>
+                  <object class="GtkBox" id="box8">
+                    <property name="visible">True</property>
+                    <property name="can_focus">False</property>
+                    <property name="spacing">6</property>
+                    <property name="vexpand">True</property>
+                    <child>
+                      <object class="GtkLabel" id="label6">
+                        <property name="visible">True</property>
+                        <property name="can_focus">False</property>
+                        <property name="label" translatable="yes">Conversion</property>
+                      </object>
+                      <packing>
+                        <property name="expand">False</property>
+                        <property name="fill">True</property>
+                        <property name="position">0</property>
+                      </packing>
+                    </child>
+                    <child>
+                      <object class="GtkCheckButton" id="hangulonly">
+                        <property name="label" translatable="yes">Hangul _only</property>
+                        <property name="visible">True</property>
+                        <property name="can_focus">True</property>
+                        <property name="receives_default">False</property>
+                        <property name="margin_left">6</property>
+                        <property name="use_underline">True</property>
+                        <property name="xalign">0</property>
+                        <property name="draw_indicator">True</property>
+                      </object>
+                      <packing>
+                        <property name="expand">False</property>
+                        <property name="fill">True</property>
+                        <property name="position">1</property>
+                      </packing>
+                    </child>
+                    <child>
+                      <object class="GtkCheckButton" id="hanjaonly">
+                        <property name="label" translatable="yes">Hanja onl_y</property>
+                        <property name="visible">True</property>
+                        <property name="can_focus">True</property>
+                        <property name="receives_default">False</property>
+                        <property name="margin_left">6</property>
+                        <property name="use_underline">True</property>
+                        <property name="xalign">0</property>
+                        <property name="draw_indicator">True</property>
+                      </object>
+                      <packing>
+                        <property name="expand">False</property>
+                        <property name="fill">True</property>
+                        <property name="position">2</property>
+                      </packing>
+                    </child>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">6</property>
+                  </packing>
+                </child>
+              </object>
+              <packing>
+                <property name="expand">False</property>
+                <property name="fill">True</property>
+                <property name="position">0</property>
+              </packing>
+            </child>
+            <child>
+              <object class="GtkBox" id="box2">
+                <property name="visible">True</property>
+                <property name="can_focus">False</property>
+                <property name="orientation">vertical</property>
+                <property name="spacing">6</property>
+                <property name="homogeneous">True</property>
+                <child>
+                  <object class="GtkButton" id="ignore">
+                    <property name="label" translatable="yes">_Ignore</property>
+                    <property name="visible">True</property>
+                    <property name="can_focus">True</property>
+                    <property name="receives_default">True</property>
+                    <property name="hexpand">True</property>
+                    <property name="vexpand">True</property>
+                    <property name="use_underline">True</property>
+                  </object>
+                  <packing>
+                    <property name="expand">True</property>
+                    <property name="fill">True</property>
+                    <property name="position">0</property>
+                  </packing>
+                </child>
+                <child>
+                  <object class="GtkButton" id="ignoreall">
+                    <property name="label" translatable="yes">Always I_gnore</property>
+                    <property name="visible">True</property>
+                    <property name="can_focus">True</property>
+                    <property name="receives_default">True</property>
+                    <property name="use_underline">True</property>
+                  </object>
+                  <packing>
+                    <property name="expand">True</property>
+                    <property name="fill">True</property>
+                    <property name="position">1</property>
+                  </packing>
+                </child>
+                <child>
+                  <object class="GtkButton" id="replace">
+                    <property name="label" translatable="yes">_Replace</property>
+                    <property name="visible">True</property>
+                    <property name="can_focus">True</property>
+                    <property name="receives_default">True</property>
+                    <property name="use_underline">True</property>
+                  </object>
+                  <packing>
+                    <property name="expand">True</property>
+                    <property name="fill">True</property>
+                    <property name="position">2</property>
+                  </packing>
+                </child>
+                <child>
+                  <object class="GtkButton" id="replaceall">
+                    <property name="label" translatable="yes">Always R_eplace</property>
+                    <property name="visible">True</property>
+                    <property name="can_focus">True</property>
+                    <property name="receives_default">True</property>
+                    <property name="use_underline">True</property>
+                  </object>
+                  <packing>
+                    <property name="expand">True</property>
+                    <property name="fill">True</property>
+                    <property name="position">3</property>
+                  </packing>
+                </child>
+                <child>
+                  <placeholder/>
+                </child>
+                <child>
+                  <object class="GtkCheckButton" id="replacebychar">
+                    <property name="label" translatable="yes">Replace b_y character</property>
+                    <property name="visible">True</property>
+                    <property name="can_focus">True</property>
+                    <property name="receives_default">False</property>
+                    <property name="use_underline">True</property>
+                    <property name="xalign">0</property>
+                    <property name="draw_indicator">True</property>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">False</property>
+                    <property name="position">5</property>
+                  </packing>
+                </child>
+                <child>
+                  <object class="GtkButton" id="options">
+                    <property name="label" translatable="yes">Options</property>
+                    <property name="visible">True</property>
+                    <property name="can_focus">True</property>
+                    <property name="receives_default">True</property>
+                  </object>
+                  <packing>
+                    <property name="expand">False</property>
+                    <property name="fill">True</property>
+                    <property name="position">6</property>
+                  </packing>
+                </child>
+              </object>
+              <packing>
+                <property name="expand">True</property>
+                <property name="fill">True</property>
+                <property name="position">1</property>
+              </packing>
+            </child>
+          </object>
+          <packing>
+            <property name="expand">False</property>
+            <property name="fill">True</property>
+            <property name="position">1</property>
+          </packing>
+        </child>
+      </object>
+    </child>
+    <action-widgets>
+      <action-widget response="0">ok</action-widget>
+      <action-widget response="0">cancel</action-widget>
+      <action-widget response="0">help</action-widget>
+    </action-widgets>
+  </object>
+</interface>
diff --git a/extras/source/glade/libreoffice-catalog.xml.in b/extras/source/glade/libreoffice-catalog.xml.in
index f296d6c..6f3eaf0 100644
--- a/extras/source/glade/libreoffice-catalog.xml.in
+++ b/extras/source/glade/libreoffice-catalog.xml.in
@@ -780,5 +780,11 @@
     <glade-widget-class title="Suggestion Edit" name="cuilo-SuggestionEdit"
                         generic-name="SuggestionEdit" parent="GtkEntry"
                         icon-name="widget-gtk-textentry"/>
+    <glade-widget-class title="Suggestion Display" name="cuilo-SuggestionDisplay"
+                        generic-name="SuggestionDisplay" parent="GtkTextView"
+                        icon-name="widget-gtk-textview"/>
+    <glade-widget-class title="Ruby RadioButton" name="cuilo-RubyRadioButton"
+                        generic-name="RubyRadioButton" parent="GtkRadioButton"
+                        icon-name="widget-gtk-radiobutton"/>
   </glade-widget-classes>
 </glade-catalog>


More information about the Libreoffice-commits mailing list