2 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
4 * This file is part of the LibreOffice project.
6 * This Source Code Form is subject to the terms of the Mozilla Public
7 * License, v. 2.0. If a copy of the MPL was not distributed with this
8 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
10 * This file incorporates work covered by the following license notice:
12 * Licensed to the Apache Software Foundation (ASF) under one or more
13 * contributor license agreements. See the NOTICE file distributed
14 * with this work for additional information regarding copyright
15 * ownership. The ASF licenses this file to you under the Apache
16 * License, Version 2.0 (the "License"); you may not use this file
17 * except in compliance with the License. You may obtain a copy of
18 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
20 #ifndef INCLUDED_SW_SOURCE_UIBASE_INC_BREAK_HXX
21 #define INCLUDED_SW_SOURCE_UIBASE_INC_BREAK_HXX
23 #include <vcl/weld.hxx>
27 enum class SwLineBreakClear
;
29 class SwBreakDlg final
: public weld::GenericDialogController
31 std::unique_ptr
<weld::RadioButton
> m_xLineBtn
;
32 std::unique_ptr
<weld::Label
> m_xLineClearText
;
33 std::unique_ptr
<weld::ComboBox
> m_xLineClearBox
;
34 std::unique_ptr
<weld::RadioButton
> m_xColumnBtn
;
35 std::unique_ptr
<weld::RadioButton
> m_xPageBtn
;
36 std::unique_ptr
<weld::Label
> m_xPageCollText
;
37 std::unique_ptr
<weld::ComboBox
> m_xPageCollBox
;
38 std::unique_ptr
<weld::CheckButton
> m_xPageNumBox
;
39 std::unique_ptr
<weld::SpinButton
> m_xPageNumEdit
;
40 std::unique_ptr
<weld::Button
> m_xOkBtn
;
45 ::std::optional
<sal_uInt16
> m_oPgNum
;
46 std::optional
<SwLineBreakClear
> m_eClear
;
50 DECL_LINK(ToggleHdl
, weld::Toggleable
&, void);
51 DECL_LINK(ChangeHdl
, weld::ComboBox
&, void);
52 DECL_LINK(PageNumHdl
, weld::Toggleable
&, void);
53 DECL_LINK(PageNumModifyHdl
, weld::SpinButton
&, void);
54 DECL_LINK(OkHdl
, weld::Button
&, void);
57 void rememberResult();
60 SwBreakDlg(weld::Window
* pParent
, SwWrtShell
& rSh
);
61 const OUString
& GetTemplateName() const { return m_aTemplate
; }
62 sal_uInt16
GetKind() const { return m_nKind
; }
63 const ::std::optional
<sal_uInt16
>& GetPageNumber() const { return m_oPgNum
; }
64 const std::optional
<SwLineBreakClear
>& GetClear() const { return m_eClear
; }
69 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */