Warning, file /utilities/okteta/kasten/controllers/view/selectrange/selectrangeview.hpp was not indexed or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).
0001 /* 0002 This file is part of the Okteta Kasten module, made within the KDE community. 0003 0004 SPDX-FileCopyrightText: 2009 Friedrich W. H. Kossebau <kossebau@kde.org> 0005 0006 SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL 0007 */ 0008 0009 #ifndef KASTEN_SELECTRANGEVIEW_HPP 0010 #define KASTEN_SELECTRANGEVIEW_HPP 0011 0012 // Okteta Kasten gui 0013 #include <Kasten/Okteta/AddressComboBox> 0014 // Kasten gui 0015 #include <Kasten/AbstractToolWidget> 0016 0017 0018 class QPushButton; 0019 0020 class QCheckBox; 0021 0022 namespace Kasten { 0023 0024 class SelectRangeTool; 0025 0026 class SelectRangeView : public AbstractToolWidget 0027 { 0028 Q_OBJECT 0029 0030 public: 0031 enum SelectDirection 0032 { 0033 SelectForward = 0, 0034 SelectBackward = 1, 0035 }; 0036 0037 private: 0038 static inline constexpr Okteta::AddressComboBox::Coding DefaultStartOffsetCoding = Okteta::AddressComboBox::HexadecimalCoding; 0039 static inline constexpr Okteta::AddressComboBox::Coding DefaultEndOffsetCoding = Okteta::AddressComboBox::HexadecimalCoding; 0040 static inline constexpr bool DefaultRelativeToEnd = false; 0041 static inline constexpr SelectDirection DefaultDirection = SelectForward; 0042 0043 static inline constexpr char ConfigGroupId[] = "SelectRangeTool"; 0044 0045 static inline constexpr char StartOffsetCodingConfigKey[] = "StartOffsetCoding"; 0046 static inline constexpr char EndOffsetCodingConfigKey[] = "EndOffsetCoding"; 0047 static inline constexpr char RelativeToEndConfigKey[] = "RelativeToEnd"; 0048 static inline constexpr char DirectionConfigKey[] = "Direction"; 0049 0050 public: 0051 explicit SelectRangeView(SelectRangeTool* tool, QWidget* parent = nullptr); 0052 ~SelectRangeView() override; 0053 0054 public: 0055 SelectRangeTool* tool() const; 0056 0057 private Q_SLOTS: // gui 0058 void onSelectButtonClicked(); 0059 0060 private Q_SLOTS: // tool 0061 void onApplyableChanged(bool isApplyable); 0062 0063 private: 0064 SelectRangeTool* mTool; 0065 0066 Okteta::AddressComboBox* mStartEdit; 0067 Okteta::AddressComboBox* mEndEdit; 0068 QCheckBox* mRelativeCheckBox; 0069 QCheckBox* mBackwardsCheckBox; 0070 QPushButton* mSelectButton; 0071 }; 0072 0073 inline SelectRangeTool* SelectRangeView::tool() const { return mTool; } 0074 0075 } 0076 0077 #endif