tools
読み取り中…
検索中…
一致する文字列を見つけられません
DoubleSlider クラス

下限・上限の2値を同時に表示・操作できるスライダーウィジェット [詳解]

#include <doubleSlider.h>

DoubleSlider の継承関係図
[凡例]
DoubleSlider 連携図
[凡例]

公開メンバ関数

 DoubleSlider (Qt::Orientation orientation, QWidget *parent=nullptr)
 コンストラクタ

公開変数類

int lowerValue
 下限ハンドルの値
int upperValue
 上限ハンドルの値

限定公開メンバ関数

void paintEvent (QPaintEvent *event) override
 ペイントイベント。2つのハンドルをスロット上に描画する

詳解

下限・上限の2値を同時に表示・操作できるスライダーウィジェット

lowerValue と upperValue の2つのパブリックメンバを持ち、 paintEvent でそれぞれの位置に青いハンドルを描画します。

覚え書き
現バージョンではマウス操作によるハンドルの移動は未実装です
auto* slider = new DoubleSlider(Qt::Horizontal, this);
slider->lowerValue = 20;
slider->upperValue = 80;
DoubleSlider(Qt::Orientation orientation, QWidget *parent=nullptr)
コンストラクタ

doubleSlider.h30 行目に定義があります。

構築子と解体子

◆ DoubleSlider()

DoubleSlider::DoubleSlider ( Qt::Orientation orientation,
QWidget * parent = nullptr )
inline

コンストラクタ

引数
orientationスライダーの向き(Qt::Horizontal / Qt::Vertical)
parent親ウィジェット(デフォルト: nullptr)

doubleSlider.h39 行目に定義があります。

関数詳解

◆ paintEvent()

void DoubleSlider::paintEvent ( QPaintEvent * event)
inlineoverrideprotected

ペイントイベント。2つのハンドルをスロット上に描画する

引数
eventペイントイベント(基底クラスに転送される)

doubleSlider.h50 行目に定義があります。

メンバ詳解

◆ lowerValue

int DoubleSlider::lowerValue

下限ハンドルの値

doubleSlider.h42 行目に定義があります。

◆ upperValue

int DoubleSlider::upperValue

上限ハンドルの値

doubleSlider.h43 行目に定義があります。


このクラス詳解は次のファイルから抽出されました: