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. Qt designer
Forum Update on Monday, May 27th 2025

Qt designer

Scheduled Pinned Locked Moved General and Desktop
5 Posts 2 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
    acmezger
    wrote on last edited by
    #1

    Hello,

    Is there a way to input double values with scientific notation, i.e. 1.e-7 when using my own customwidget with QProperty double ? Perhaps I am missing something but I never succeeded to introduce small or big numbers in scientific notation

    Thanks

    1 Reply Last reply
    0
    • A Offline
      A Offline
      andre
      wrote on last edited by
      #2

      Let me see if I understand you correctly. You have a custom widget plugin for Qt Designer for your own widget, which has a property of type double. You'd like to enter the property value in the Qt property editor for this widget in scientific notation. Right?

      1 Reply Last reply
      0
      • A Offline
        A Offline
        acmezger
        wrote on last edited by
        #3

        Yes that is exactly the case. I want to introduce limits for a logarithmic plot for vacuum measurements, I.e. from 1.e-10 to 1.e-6.

        1 Reply Last reply
        0
        • A Offline
          A Offline
          andre
          wrote on last edited by
          #4

          I don't think it will be easy to do. Creator allows for a lot, but there are some blank areas on the map of what can be inserted. AFAIK, you can't provide non-standard editors for the property editor, especially not on a property-by-property basis for your plugin.

          I think I'd either go for a special type where you separate the factor and the exponent into two fields (a double and an integer), or use a QString that you'd just verify on setting it.

          1 Reply Last reply
          0
          • A Offline
            A Offline
            acmezger
            wrote on last edited by
            #5

            Yes,

            I think the way could be to have two fields. However It is a pity that the designer does not support scientific notation.

            anyhow many thanks

            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