Uploaded image for project: 'Qt Creator'
  1. Qt Creator
  2. QTCREATORBUG-28305

Allow showing variables in full binary form during debugging in Qt Creator

    XMLWordPrintable

Details

    • Suggestion
    • Resolution: Unresolved
    • Not Evaluated
    • None
    • Qt Creator 4.13.0
    • Debugger
    • None
    • Ubuntu 18.04

      Qt Creator 4.13.0

      Qt 5.15.0 (GCC 5.3.1 20160406 (Red Hat 5.3.1-6), 64 bit)

    • Linux/X11

    Description

      I am debugging a C++ program using Qt creator and I want that there should be an option to see the variables in the `Locals` section  in full binary form instead of the four or so digits that are currently shown. I mean, as we can see in the screenshot below, the variables `i` and `j` are shown as `1100` and `0` respectively but I want them to be shown in their full 16 bit or 32 bit form(depending on what size short has on the system/compiler).

      So I want to show `i` and `j` to be in their full 16/32 bit binary representation instead of this trimmed down version that is currently shown.

      There should be a way to toggle between the full binary form(like `00000000000000000000000000001100` if `int` is 32 bit) and the trimmed down version(like `1100`) maybe by double or tripple clicking on that value in the local section.

       

       

      Screenshot

       

       

      Basically, `i` should be shown as `0000000000001100` if `int` is 16 bits and as `00000000000000000000000000001100` if `int` is 32 bits.

       

       Use Case 1

      While debugging when I've many variables, the binary representation of these variables don't align up correctly to each other because they are of different length. So it is hard to and them or or them etc manually bit by bit. So this feature request will make it easier for the user to manually and or or them. Also it would look aesthetically pleasing to have all int variables to be of same full binary length.

       

      Use Case 2

       

      Also, I use the Qt Creator's debugger when explaining some basic concepts to students. For example, like different types can have different sizes and the minimum size is fixed(as `short` must be at least 16 bits etc). Then during the explanation I've to explicitly say to the students that "just imagine there are 14 or so leading 0's). And this number of leading 0's vary depending on what value the variable has. So sometimes the students are not able easily grasp these thing and i want that there should be toggle option between full binary form and trimmed version so that the user can toggle between these two forms by double or tripple clicking on the value.

       

      Use Case 3

       

      Additionally I am also used to seeing long/complete binary form in Visual Studio and always like to be explicit wherever possible. So I think that there should at least be an option to toggle between the two form.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            hjk hjk
            ronhald Ronald Verma
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes