Files
libreoffice/sd/source/ui/inc/futext.hxx

102 lines
3.5 KiB
C++
Raw Normal View History

2010-10-27 12:53:26 +01:00
/* -*- 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 .
*/
2000-09-18 16:07:07 +00:00
#ifndef INCLUDED_SD_SOURCE_UI_INC_FUTEXT_HXX
#define INCLUDED_SD_SOURCE_UI_INC_FUTEXT_HXX
2000-09-18 16:07:07 +00:00
#include <editeng/editdata.hxx>
2000-09-18 16:07:07 +00:00
#include "fuconstr.hxx"
#include <svx/svdotext.hxx>
2000-09-18 16:07:07 +00:00
struct StyleRequestData;
class SdrTextObj;
CWS-TOOLING: integrate CWS impressfontsize 2008-12-11 14:15:16 +0100 wg r265298 : i97125 2008-12-11 12:54:53 +0100 wg r265288 : i97125 2008-12-11 12:53:03 +0100 wg r265287 : i97125 2008-12-11 11:25:42 +0100 wg r265270 : i97125 2008-12-11 10:22:13 +0100 wg r265253 : i97125 2008-12-11 09:22:47 +0100 wg r265247 : i97125 2008-12-09 15:28:51 +0100 cl r265097 : added missing toolbar buttons for inc/dec font size 2008-12-08 17:39:46 +0100 cl r265012 : #i80257# added autolayout text only 2008-12-08 17:32:07 +0100 cl r265011 : #i80257# added autolayout text only 2008-12-08 16:42:19 +0100 cl r265008 : #i94459# fixed a bug in insertByName and replaceByName 2008-12-08 16:25:26 +0100 cl r265007 : #i80257# new image for text only auto layout in impress 2008-12-08 16:24:01 +0100 cl r265006 : #i80257# new image for text only auto layout in impress 2008-12-08 16:01:46 +0100 cl r265003 : #i88855# changed wording from Monitor to Display 2008-12-08 15:57:24 +0100 cl r265002 : #i91904# applied patch to fix a wrong index access 2008-12-05 12:51:47 +0100 cl r264900 : #i8824# allow setting of text properties at shape without reformating text 2008-12-05 11:09:21 +0100 cl r264895 : fixed build problem 2008-12-04 12:04:09 +0100 cl r264829 : fixed build issue 2008-12-04 11:03:58 +0100 cl r264823 : #i8824# set new fontsize at shape 2008-12-02 22:39:22 +0100 cl r264732 : fixed build problem 2008-12-02 22:38:42 +0100 cl r264731 : fixed build problem 2008-12-01 17:44:29 +0100 cl r264623 : CWS-TOOLING: rebase CWS impressfontsize to trunk@264325 (milestone: DEV300:m36) 2008-11-07 11:38:13 +0100 cl r263418 : #i95920# fixed an OpenSolaris build breaker 2008-11-06 14:56:04 +0100 cl r263386 : #i40730# added support to supress export of hidden slides to html 2008-11-06 14:55:41 +0100 cl r263385 : #i40730# added support to supress export of hidden slides to html 2008-11-06 14:03:59 +0100 cl r263384 : #158530# allow editing of interaction links with hyperlink editor 2008-10-20 15:34:13 +0200 cl r262322 : #i8824# migrate cws impressfontsize to subversion.
2008-12-11 15:25:59 +00:00
class FontList;
class OutlinerView;
2000-09-18 16:07:07 +00:00
namespace sd {
/**
* Base class for text functions
*/
class FuText
: public FuConstruct
{
public:
TYPEINFO_OVERRIDE();
2000-09-18 16:07:07 +00:00
static rtl::Reference<FuPoor> Create( ViewShell* pViewSh, ::sd::Window* pWin, ::sd::View* pView, SdDrawDocument* pDoc, SfxRequest& rReq );
virtual void DoExecute( SfxRequest& rReq ) SAL_OVERRIDE;
2000-09-18 16:07:07 +00:00
virtual sal_Bool KeyInput(const KeyEvent& rKEvt) SAL_OVERRIDE;
virtual sal_Bool MouseMove(const MouseEvent& rMEvt) SAL_OVERRIDE;
virtual sal_Bool MouseButtonUp(const MouseEvent& rMEvt) SAL_OVERRIDE;
virtual sal_Bool MouseButtonDown(const MouseEvent& rMEvt) SAL_OVERRIDE;
virtual sal_Bool Command(const CommandEvent& rCEvt) SAL_OVERRIDE;
virtual sal_Bool RequestHelp(const HelpEvent& rHEvt) SAL_OVERRIDE;
virtual void ReceiveRequest(SfxRequest& rReq) SAL_OVERRIDE;
virtual void DoubleClick(const MouseEvent& rMEvt) SAL_OVERRIDE;
2000-09-18 16:07:07 +00:00
virtual void Activate() SAL_OVERRIDE; ///< activates the function
virtual void Deactivate() SAL_OVERRIDE; ///< deactivates the function
2000-09-18 16:07:07 +00:00
void SetInEditMode(const MouseEvent& rMEvt, sal_Bool bQuickDrag);
sal_Bool DeleteDefaultText();
SdrTextObj* GetTextObj() { return static_cast< SdrTextObj* >( mxTextObj.get() ); }
2000-09-18 16:07:07 +00:00
virtual SdrObject* CreateDefaultObject(const sal_uInt16 nID, const Rectangle& rRectangle) SAL_OVERRIDE;
2014-04-10 10:54:35 +02:00
/** is called when the current function should be aborted. <p>
This is used when a function gets a KEY_ESCAPE but can also
be called directly.
@returns true if a active function was aborted
*/
virtual bool cancel() SAL_OVERRIDE;
CWS-TOOLING: integrate CWS impressfontsize 2008-12-11 14:15:16 +0100 wg r265298 : i97125 2008-12-11 12:54:53 +0100 wg r265288 : i97125 2008-12-11 12:53:03 +0100 wg r265287 : i97125 2008-12-11 11:25:42 +0100 wg r265270 : i97125 2008-12-11 10:22:13 +0100 wg r265253 : i97125 2008-12-11 09:22:47 +0100 wg r265247 : i97125 2008-12-09 15:28:51 +0100 cl r265097 : added missing toolbar buttons for inc/dec font size 2008-12-08 17:39:46 +0100 cl r265012 : #i80257# added autolayout text only 2008-12-08 17:32:07 +0100 cl r265011 : #i80257# added autolayout text only 2008-12-08 16:42:19 +0100 cl r265008 : #i94459# fixed a bug in insertByName and replaceByName 2008-12-08 16:25:26 +0100 cl r265007 : #i80257# new image for text only auto layout in impress 2008-12-08 16:24:01 +0100 cl r265006 : #i80257# new image for text only auto layout in impress 2008-12-08 16:01:46 +0100 cl r265003 : #i88855# changed wording from Monitor to Display 2008-12-08 15:57:24 +0100 cl r265002 : #i91904# applied patch to fix a wrong index access 2008-12-05 12:51:47 +0100 cl r264900 : #i8824# allow setting of text properties at shape without reformating text 2008-12-05 11:09:21 +0100 cl r264895 : fixed build problem 2008-12-04 12:04:09 +0100 cl r264829 : fixed build issue 2008-12-04 11:03:58 +0100 cl r264823 : #i8824# set new fontsize at shape 2008-12-02 22:39:22 +0100 cl r264732 : fixed build problem 2008-12-02 22:38:42 +0100 cl r264731 : fixed build problem 2008-12-01 17:44:29 +0100 cl r264623 : CWS-TOOLING: rebase CWS impressfontsize to trunk@264325 (milestone: DEV300:m36) 2008-11-07 11:38:13 +0100 cl r263418 : #i95920# fixed an OpenSolaris build breaker 2008-11-06 14:56:04 +0100 cl r263386 : #i40730# added support to supress export of hidden slides to html 2008-11-06 14:55:41 +0100 cl r263385 : #i40730# added support to supress export of hidden slides to html 2008-11-06 14:03:59 +0100 cl r263384 : #158530# allow editing of interaction links with hyperlink editor 2008-10-20 15:34:13 +0200 cl r262322 : #i8824# migrate cws impressfontsize to subversion.
2008-12-11 15:25:59 +00:00
static void ChangeFontSize( bool, OutlinerView*, const FontList*, ::sd::View* );
protected:
FuText (ViewShell* pViewSh,
::sd::Window* pWin,
::sd::View* pView,
SdDrawDocument* pDoc,
SfxRequest& rReq);
virtual void disposing() SAL_OVERRIDE;
SdrObjectWeakRef mxTextObj;
Link aOldLink;
sal_Bool bFirstObjCreated;
bool bJustEndedEdit;
SfxRequest& rRequest;
private:
void ImpSetAttributesForNewTextObject(SdrTextObj* pTxtObj);
void ImpSetAttributesFitToSize(SdrTextObj* pTxtObj);
void ImpSetAttributesFitToSizeVertical(SdrTextObj* pTxtObj);
void ImpSetAttributesFitCommon(SdrTextObj* pTxtObj);
};
2000-09-18 16:07:07 +00:00
} // end of namespace sd
2000-09-18 16:07:07 +00:00
#endif
2010-10-27 12:53:26 +01:00
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */