/* -*- 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_INC_BACKGRND_HXX #define INCLUDED_CUI_SOURCE_INC_BACKGRND_HXX #include #include #include #include #include #include class BackgroundPreviewImpl; class SvxOpenGraphicDialog; struct SvxBackgroundTable_Impl; struct SvxBackgroundPage_Impl; class SvxBrushItem; /** class SvxBackgroundTabPage -------------------------------------------- [Description] With this TabPage a Brush (e. g. for a frame's background color) can be set. [Items] : ; */ class SvxBackgroundTabPage : public SvxTabPage { using TabPage::DeactivatePage; friend class VclPtr; static const sal_uInt16 pPageRanges[]; public: static VclPtr Create( vcl::Window* pParent, const SfxItemSet* rAttrSet ); // returns the area of the which-values static const sal_uInt16* GetRanges() { return pPageRanges; } virtual bool FillItemSet( SfxItemSet* rSet ) override; virtual void Reset( const SfxItemSet* rSet ) override; virtual void FillUserData() override; virtual void PointChanged( vcl::Window* pWindow, RectPoint eRP ) override; /// Shift-ListBox activation void ShowSelector(); /// for the Writer (cells/rows/tables) void ShowTblControl(); virtual void PageCreated(const SfxAllItemSet& aSet) override; protected: virtual DeactivateRC DeactivatePage( SfxItemSet* pSet ) override; private: SvxBackgroundTabPage( vcl::Window* pParent, const SfxItemSet& rCoreSet ); virtual ~SvxBackgroundTabPage() override; virtual void dispose() override; VclPtr m_pAsGrid; VclPtr m_pSelectTxt; VclPtr m_pLbSelect; VclPtr m_pTblDesc; VclPtr m_pTblLBox; VclPtr m_pBackGroundColorLabelFT; VclPtr m_pBackGroundColorFrame; VclPtr m_pBackgroundColorSet; VclPtr m_pPreviewWin1; VclPtr m_pBtnPreview; // Background Bitmap ---------------------------------- VclPtr m_pBitmapContainer; VclPtr m_pFileFrame; VclPtr m_pBtnBrowse; VclPtr m_pBtnLink; VclPtr m_pFtUnlinked; VclPtr m_pFtFile; VclPtr m_pTypeFrame; VclPtr m_pBtnPosition; VclPtr m_pBtnArea; VclPtr m_pBtnTile; VclPtr m_pWndPosition; VclPtr m_pPreviewWin2; // DDListBox for Writer ------------------------------- Color aBgdColor; sal_uInt16 nHtmlMode; bool bAllowShowSelector : 1; bool bIsGraphicValid : 1; bool bHighlighting : 1; bool bCharBackColor : 1; bool m_bColorSelected : 1; Graphic aBgdGraphic; OUString aBgdGraphicPath; OUString aBgdGraphicFilter; SvxBackgroundPage_Impl* pPageImpl; SvxOpenGraphicDialog* pImportDlg; SvxBackgroundTable_Impl* pTableBck_Impl;///< Items for Sw-Table must be corrected std::unique_ptr pHighlighting; void FillColorValueSets_Impl(); void ShowColorUI_Impl(); void HideColorUI_Impl(); void ShowBitmapUI_Impl(); void HideBitmapUI_Impl(); bool LoadLinkedGraphic_Impl(); void RaiseLoadError_Impl(); void SetGraphicPosition_Impl( SvxGraphicPosition ePos ); SvxGraphicPosition GetGraphicPosition_Impl(); void FillControls_Impl(const SvxBrushItem& rBgdAttr, const OUString& rUserData); DECL_LINK( LoadIdleHdl_Impl, Timer*, void ); DECL_LINK(SelectHdl_Impl, ListBox&, void ); DECL_LINK(BrowseHdl_Impl, Button*, void); DECL_LINK( RadioClickHdl_Impl, Button*, void ); DECL_LINK( FileClickHdl_Impl, Button*, void ); DECL_LINK(BackgroundColorHdl_Impl, ValueSet*, void); DECL_LINK( TblDestinationHdl_Impl, ListBox&, void ); }; #endif // INCLUDED_CUI_SOURCE_INC_BACKGRND_HXX /* vim:set shiftwidth=4 softtabstop=4 expandtab: */