##

BaseInspectorDialog.hh
Go to the documentation of this file.
/*
* Copyright (C) 2015 Open Source Robotics Foundation
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*
*/
#ifndef GAZEBO_GUI_BUILDING_BASEINSPECTORDIALOG_HH_
#define GAZEBO_GUI_BUILDING_BASEINSPECTORDIALOG_HH_
#include <memory>
#include <string>
#include <ignition/math/Color.hh>
#include "gazebo/gui/qt.h"
#include "gazebo/util/system.hh"
namespace gazebo
{
namespace gui
{
// Forward declare private data.
class BaseInspectorDialogPrivate;
class GZ_GUI_VISIBLE BaseInspectorDialog : public QDialog
{
Q_OBJECT
public: explicit BaseInspectorDialog(QWidget *_parent);
public: ~BaseInspectorDialog();
public: void InitColorComboBox();
public: void InitTextureComboBox();
public: ignition::math::Color Color() const;
public: std::string Texture() const;
public: void SetColor(const ignition::math::Color &_color);
public: void SetTexture(const std::string &_texture);
Q_SIGNALS: void Applied();
protected slots: void OnCancel();
protected slots: void OnApply();
protected slots: void OnOK();
protected: QComboBox *colorComboBox;
protected: QComboBox *textureComboBox;
private: std::unique_ptr<BaseInspectorDialogPrivate> dataPtr;
};
}
}
#endif
gazebo::gui::BaseInspectorDialog::Color
ignition::math::Color Color() const
Get the color.
gazebo
Forward declarations for the common classes.
Definition: Animation.hh:26
qt.h
gazebo::gui::BaseInspectorDialog::OnApply
void OnApply()
Qt callback when the Apply button is pressed.
gazebo::gui::BaseInspectorDialog::Texture
std::string Texture() const
Get the texture.
system.hh
gazebo::gui::BaseInspectorDialog::colorComboBox
QComboBox * colorComboBox
Combo box for selecting the color.
Definition: BaseInspectorDialog.hh:85
gazebo::gui::BaseInspectorDialog::InitColorComboBox
void InitColorComboBox()
Initiate color combo box.
gazebo::gui::BaseInspectorDialog::OnCancel
void OnCancel()
Qt callback when the Cancel button is pressed.
gazebo::gui::BaseInspectorDialog
Base Dialog for a specific inspector dialog.
Definition: BaseInspectorDialog.hh:39
gazebo::gui::BaseInspectorDialog::OnOK
void OnOK()
Qt callback when the Ok button is pressed.
gazebo::gui::BaseInspectorDialog::Applied
void Applied()
Qt signal emitted to indicate that changes should be applied.
gazebo::gui::BaseInspectorDialog::BaseInspectorDialog
BaseInspectorDialog(QWidget *_parent)
Constructor.
gazebo::gui::BaseInspectorDialog::SetTexture
void SetTexture(const std::string &_texture)
Set the texture.
gazebo::gui::BaseInspectorDialog::InitTextureComboBox
void InitTextureComboBox()
Initiate texture combo box.
gui
gui
Definition: KeyEventHandler.hh:29
gazebo::gui::BaseInspectorDialog::~BaseInspectorDialog
~BaseInspectorDialog()
Destructor.
gazebo::gui::BaseInspectorDialog::SetColor
void SetColor(const ignition::math::Color &_color)
Set the color.
gazebo::gui::BaseInspectorDialog::textureComboBox
QComboBox * textureComboBox
Combo box for selecting the texture.
Definition: BaseInspectorDialog.hh:88