/usr/include/libdtk-2.0.7/DWidget/dflowlayout.h is in libdtkwidget-dev 2.0.7.2-2build1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 | /*
* Copyright (C) 2015 ~ 2017 Deepin Technology Co., Ltd.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef DFLOWLAYOUT_H
#define DFLOWLAYOUT_H
#include "dtkwidget_global.h"
#include <dobject.h>
#include <QLayout>
#include <QWidget>
#include <QListView>
DWIDGET_BEGIN_NAMESPACE
class DFlowLayoutPrivate;
class DFlowLayout : public QLayout, public DTK_CORE_NAMESPACE::DObject
{
Q_OBJECT
Q_PROPERTY(int horizontalSpacing READ horizontalSpacing WRITE setHorizontalSpacing NOTIFY horizontalSpacingChanged)
Q_PROPERTY(int verticalSpacing READ verticalSpacing WRITE setVerticalSpacing NOTIFY verticalSpacingChanged)
Q_PROPERTY(int count READ count NOTIFY countChanged)
Q_PROPERTY(Flow flow READ flow WRITE setFlow NOTIFY flowChanged)
Q_PROPERTY(QSize sizeHint READ sizeHint NOTIFY sizeHintChanged)
public:
typedef QListView::Flow Flow;
Q_ENUMS(Flow)
explicit DFlowLayout(QWidget *parent);
DFlowLayout();
~DFlowLayout();
void insertItem(int index, QLayoutItem *item);
void insertWidget(int index, QWidget *widget);
void insertLayout(int index, QLayout *layout);
void insertSpacing(int index, int size);
void insertStretch(int index, int stretch = 0);
void insertSpacerItem(int index, QSpacerItem *spacerItem);
void addSpacing(int size);
void addStretch(int stretch = 0);
void addSpacerItem(QSpacerItem *spacerItem);
void addItem(QLayoutItem *item) Q_DECL_OVERRIDE;
bool hasHeightForWidth() const Q_DECL_OVERRIDE;
int heightForWidth(int) const Q_DECL_OVERRIDE;
int count() const Q_DECL_OVERRIDE;
QLayoutItem *itemAt(int index) const Q_DECL_OVERRIDE;
QSize minimumSize() const Q_DECL_OVERRIDE;
void setGeometry(const QRect &rect) Q_DECL_OVERRIDE;
QSize sizeHint() const Q_DECL_OVERRIDE;
QLayoutItem *takeAt(int index) Q_DECL_OVERRIDE;
Qt::Orientations expandingDirections() const Q_DECL_OVERRIDE;
int horizontalSpacing() const;
int verticalSpacing() const;
Flow flow() const;
public Q_SLOTS:
void setHorizontalSpacing(int horizontalSpacing);
void setVerticalSpacing(int verticalSpacing);
void setSpacing(int spacing);
void setFlow(Flow flow);
Q_SIGNALS:
void horizontalSpacingChanged(int horizontalSpacing);
void verticalSpacingChanged(int verticalSpacing);
void countChanged(int count);
void flowChanged(Flow flow);
void sizeHintChanged(QSize sizeHint) const;
private:
D_DECLARE_PRIVATE(DFlowLayout)
};
DWIDGET_END_NAMESPACE
#endif // DFLOWLAYOUT_H
|