Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. QtCharts and QDialog
Forum Updated to NodeBB v4.3 + New Features

QtCharts and QDialog

Scheduled Pinned Locked Moved Solved General and Desktop
qchartsqdialog
2 Posts 2 Posters 465 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.
  • D Offline
    D Offline
    Davide00
    wrote on last edited by
    #1

    Hi, I have a MainWindow with a pushbutton, and when i click the pushbutton, it shows a Dialog.
    Now, I would like to show in that dialog a pie chart, but I've seen that, for most of the examples, the code to build and display a chart is written in main.cpp.
    So, my question is, can I show a chart in a QDialog? And if yes, how can i do it?

    jsulmJ 1 Reply Last reply
    0
    • D Davide00

      Hi, I have a MainWindow with a pushbutton, and when i click the pushbutton, it shows a Dialog.
      Now, I would like to show in that dialog a pie chart, but I've seen that, for most of the examples, the code to build and display a chart is written in main.cpp.
      So, my question is, can I show a chart in a QDialog? And if yes, how can i do it?

      jsulmJ Offline
      jsulmJ Offline
      jsulm
      Lifetime Qt Champion
      wrote on last edited by
      #2

      @Davide00 said in QtCharts and QDialog:

      can I show a chart in a QDialog?

      Yes

      "And if yes, how can i do it?" - what exactly is the problem? Simply add your chart as child widget in your dialog.

      https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      0

      • Login

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