Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. 3rd Party Software
  4. How can I configure Enterprise Architect to show me signals and slots
QtWS25 Last Chance

How can I configure Enterprise Architect to show me signals and slots

Scheduled Pinned Locked Moved Unsolved 3rd Party Software
5 Posts 3 Posters 1.2k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • A Offline
    A Offline
    andr1312e
    wrote on 8 Nov 2021, 09:55 last edited by andr1312e 11 Aug 2021, 09:56
    #1

    I am new with EA but have some experience in Qt. I want to make reverse engineering and make UML diagrams based on my Qt project.
    I set Qt keyword signal and get no error when EA parsing my file.
    But I don't see on my diagram that it is a signal. How I can fix it?

    bee269c4-de52-4dab-a9fd-db673794130a-image.png

    J 1 Reply Last reply 8 Nov 2021, 13:35
    0
    • A andr1312e
      8 Nov 2021, 09:55

      I am new with EA but have some experience in Qt. I want to make reverse engineering and make UML diagrams based on my Qt project.
      I set Qt keyword signal and get no error when EA parsing my file.
      But I don't see on my diagram that it is a signal. How I can fix it?

      bee269c4-de52-4dab-a9fd-db673794130a-image.png

      J Offline
      J Offline
      JKSH
      Moderators
      wrote on 8 Nov 2021, 13:35 last edited by
      #2

      @andr1312e said in How can I configure Enterprise Architect to show me signals and slots:

      But I don't see on my diagram that it is a signal. How I can fix it?

      From a C++ compiler's point of view, a Qt signal is just a public method.

      You'll need to talk to the authors/maintainers of Enterprise Architect if you want them to add support for signals/Q_SIGNALS.

      Qt Doc Search for browsers: forum.qt.io/topic/35616/web-browser-extension-for-improved-doc-searches

      A 1 Reply Last reply 9 Nov 2021, 08:24
      1
      • J JKSH
        8 Nov 2021, 13:35

        @andr1312e said in How can I configure Enterprise Architect to show me signals and slots:

        But I don't see on my diagram that it is a signal. How I can fix it?

        From a C++ compiler's point of view, a Qt signal is just a public method.

        You'll need to talk to the authors/maintainers of Enterprise Architect if you want them to add support for signals/Q_SIGNALS.

        A Offline
        A Offline
        andr1312e
        wrote on 9 Nov 2021, 08:24 last edited by
        #3

        @JKSH I mean this:
        My code before edit:

        public:
            FirmwarePresenter(const int &blockSize, const QMap<QString, quint8> *commands, TcpSocket *socket);
            ~FirmwarePresenter();
        
        private:
            void CreateObjects();
            void InitObjects();
            void CreateConnections();
            
        signals:
            void SetButtonsEnabled(int state);
            void ConsoleLog(QString errorMessage);
            void PageUpdated(quint32 pageNum);
        

        Okay, lets view what it generate:

        55217c8a-d9df-4c86-8483-79a3d92a3d58-image.png
        And moving my signals in the header file, above private section:

        public:
            FirmwarePresenter(const int &blockSize, const QMap<QString, quint8> *commands, TcpSocket *socket);
            ~FirmwarePresenter();
        signals:
            void SetButtonsEnabled(int state);
            void ConsoleLog(QString errorMessage);
            void PageUpdated(quint32 pageNum);
        private:
            void CreateObjects();
            void InitObjects();
            void CreateConnections();
        

        Gives me:

        0f2db091-a849-4bae-a4c8-5fce21c7e1bd-image.png

        I mean that this program ignores these macros, and I don't understand how can I say it to mark these macros.

        J J 2 Replies Last reply 9 Nov 2021, 13:16
        0
        • A andr1312e
          9 Nov 2021, 08:24

          @JKSH I mean this:
          My code before edit:

          public:
              FirmwarePresenter(const int &blockSize, const QMap<QString, quint8> *commands, TcpSocket *socket);
              ~FirmwarePresenter();
          
          private:
              void CreateObjects();
              void InitObjects();
              void CreateConnections();
              
          signals:
              void SetButtonsEnabled(int state);
              void ConsoleLog(QString errorMessage);
              void PageUpdated(quint32 pageNum);
          

          Okay, lets view what it generate:

          55217c8a-d9df-4c86-8483-79a3d92a3d58-image.png
          And moving my signals in the header file, above private section:

          public:
              FirmwarePresenter(const int &blockSize, const QMap<QString, quint8> *commands, TcpSocket *socket);
              ~FirmwarePresenter();
          signals:
              void SetButtonsEnabled(int state);
              void ConsoleLog(QString errorMessage);
              void PageUpdated(quint32 pageNum);
          private:
              void CreateObjects();
              void InitObjects();
              void CreateConnections();
          

          Gives me:

          0f2db091-a849-4bae-a4c8-5fce21c7e1bd-image.png

          I mean that this program ignores these macros, and I don't understand how can I say it to mark these macros.

          J Offline
          J Offline
          JonB
          wrote on 9 Nov 2021, 13:16 last edited by
          #4

          @andr1312e
          I don't know whether you can do anything with this information, but....

          The definition of the signals (and slots) macros is just as follows:

          #define signals public
          #define slots /* nothing */
          

          As you can see, signals: simply expands to public:. I guess your EA just does not recognise this? Maybe you could pre-process the files to do this expansion to keep your EA happy?

          1 Reply Last reply
          0
          • A andr1312e
            9 Nov 2021, 08:24

            @JKSH I mean this:
            My code before edit:

            public:
                FirmwarePresenter(const int &blockSize, const QMap<QString, quint8> *commands, TcpSocket *socket);
                ~FirmwarePresenter();
            
            private:
                void CreateObjects();
                void InitObjects();
                void CreateConnections();
                
            signals:
                void SetButtonsEnabled(int state);
                void ConsoleLog(QString errorMessage);
                void PageUpdated(quint32 pageNum);
            

            Okay, lets view what it generate:

            55217c8a-d9df-4c86-8483-79a3d92a3d58-image.png
            And moving my signals in the header file, above private section:

            public:
                FirmwarePresenter(const int &blockSize, const QMap<QString, quint8> *commands, TcpSocket *socket);
                ~FirmwarePresenter();
            signals:
                void SetButtonsEnabled(int state);
                void ConsoleLog(QString errorMessage);
                void PageUpdated(quint32 pageNum);
            private:
                void CreateObjects();
                void InitObjects();
                void CreateConnections();
            

            Gives me:

            0f2db091-a849-4bae-a4c8-5fce21c7e1bd-image.png

            I mean that this program ignores these macros, and I don't understand how can I say it to mark these macros.

            J Offline
            J Offline
            JKSH
            Moderators
            wrote on 9 Nov 2021, 13:54 last edited by
            #5

            @andr1312e said in How can I configure Enterprise Architect to show me signals and slots:

            I mean that this program ignores these macro

            That means Enterprise Architect is not processing macros correctly. You should ask Sparx Systems to help you with this issue (because we don't use it)

            Qt Doc Search for browsers: forum.qt.io/topic/35616/web-browser-extension-for-improved-doc-searches

            1 Reply Last reply
            0

            2/5

            8 Nov 2021, 13:35

            • Login

            • Login or register to search.
            2 out of 5
            • First post
              2/5
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • Users
            • Groups
            • Search
            • Get Qt Extensions
            • Unsolved