Skip to content
Snippets Groups Projects
Select Git revision
  • bf20ebc86a50d5e1c16957f3da27a00a75583e3e
  • master default protected
  • develop
  • semantic
  • auto-inflate
  • feature/aps
  • legacy protected
  • 10.0.0
  • 9.3.8
  • 9.3.7
  • 9.3.6
  • 9.3.5
  • 9.3.4
  • 9.3.3
  • 9.3.2
  • 9.3.1
  • 9.3.0
  • 9.2.0
  • 9.1.2
  • 9.1.1
  • 9.1.0
  • 9.0.1
  • 9.0.0
  • 8.2.5
  • 8.2.4
  • 8.2.3
  • 8.2.2
27 results

setup.py

Blame
  • LevelNameEdit.hpp 1.08 KiB
    /**
     * LevelNameEdit.hpp
     *
     * @date 29.01.2025
     * @author Jonathan Dueck (jonathan.dueck@informatik.hs-fulda.de)
     */
    
    #pragma once
    
    #include <QLineEdit>
    
    namespace editor
    {
    
    /**
     * The LevelNameEdit Widget is displayed on the left of the TopBar.
     * It allows the user to set a custom level name.
     */
    class LevelNameEdit : public QLineEdit
    {
        public:
            /**
             * Creates a LevelNameEdit Widget prefilling the provided level_name.
             * The parent of the LevelNameEdit Widget is set to the provided parent.
             * @param levelName The initial name of the level.
             * @param parent The Widget that should be set as the parent of this Widget.
             */
            LevelNameEdit(const std::string& levelName, QWidget* parent = nullptr);
    
        protected:
            /**
             * Receives a QKeyEvent when the user presses a key to change the content of the QLineEdit.
             * The onLevelNameUpdated event method is subsequently emitted.
             * @param event The QKeyEvent for the Key Press.
             */
            void keyPressEvent(QKeyEvent* event) override;
    };
    
    } // namespace editor