tdf#130857 qt weld: Implement QtInstanceWidget::strip_mnemonic
[LibreOffice.git] / sc / source / ui / inc / scuiautofmt.hxx
bloba89d508a20e527864280960a0ab7d72060624501
1 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2 /*
3 * This file is part of the LibreOffice project.
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
9 * This file incorporates work covered by the following license notice:
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
19 #pragma once
21 #include <vcl/customweld.hxx>
22 #include <autoform.hxx>
23 #include "autofmt.hxx"
25 class ScAutoFormatDlg : public weld::GenericDialogController
27 public:
28 ScAutoFormatDlg(weld::Window* pParent,
29 ScAutoFormat* pAutoFormat,
30 const ScAutoFormatData* pSelFormatData,
31 const ScViewData& rViewData);
32 virtual ~ScAutoFormatDlg() override;
34 sal_uInt16 GetIndex() const { return nIndex; }
35 OUString GetCurrFormatName();
37 private:
38 OUString aStrTitle;
39 OUString aStrLabel;
40 OUString aStrClose;
41 OUString aStrDelMsg;
42 OUString aStrRename;
44 ScAutoFormat* pFormat;
45 const ScAutoFormatData* pSelFmtData;
46 sal_uInt16 nIndex;
47 bool bCoreDataChanged;
48 bool bFmtInserted;
50 ScAutoFmtPreview m_aWndPreview;
51 std::unique_ptr<weld::TreeView> m_xLbFormat;
52 std::unique_ptr<weld::Button> m_xBtnOk;
53 std::unique_ptr<weld::Button> m_xBtnCancel;
54 std::unique_ptr<weld::Button> m_xBtnAdd;
55 std::unique_ptr<weld::Button> m_xBtnRemove;
56 std::unique_ptr<weld::Button> m_xBtnRename;
57 std::unique_ptr<weld::CheckButton> m_xBtnNumFormat;
58 std::unique_ptr<weld::CheckButton> m_xBtnBorder;
59 std::unique_ptr<weld::CheckButton> m_xBtnFont;
60 std::unique_ptr<weld::CheckButton> m_xBtnPattern;
61 std::unique_ptr<weld::CheckButton> m_xBtnAlignment;
62 std::unique_ptr<weld::CheckButton> m_xBtnAdjust;
63 std::unique_ptr<weld::CustomWeld> m_xWndPreview;
65 void Init ();
66 void UpdateChecks ();
68 DECL_LINK( CheckHdl, weld::Toggleable&, void );
69 DECL_LINK( AddHdl, weld::Button&, void );
70 DECL_LINK( RemoveHdl, weld::Button&, void );
71 DECL_LINK( SelFmtHdl, weld::TreeView&, void );
72 DECL_LINK( CloseHdl, weld::Button&, void );
73 DECL_LINK( DblClkHdl, weld::TreeView&, bool );
74 DECL_LINK( RenameHdl, weld::Button&, void );
78 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */