With that variable set, I restarted QTCreator and now you can see how the sizes of the preview form in QTCreator and the actual app running fully match as you would expect. Here is an image of someone posted in this Answer that shows them having created the variable: The value of the variable should be: PassThrough The environment variable should be named: QT_SCALE_FACTOR_ROUNDING_POLICY In order to fix this you need to set an environment variable in windows so that the true scale gets passed through to QTCreator. Right click on the QGraphicsView and select Promote to. This monitor is where I do my QT work, so of course I would be running into this problem. I have a multi monitor system and one of my monitors is a 4k resolution where it recommends 150% scaling. If you have it set to 1.5 (150% scaling in windows display options) this makes it round to 2 (200%) making the displayed form in QTCreator much bigger. It turns out QTCreator will round your windows scaling to 1 or 2. The other major issue I was having involved the sizes of the UI form shown in QTCreator not matching the actual application running. Adding the following in my main.cpp forced my application to use the same style: QApplication::setStyle(QStyleFactory::create("Fusion")) As noted in my edit above, the following line matches up the "Style" being used for rendering. I figured out the problem and posted an answer below detailing the solution. Is it possible that QT designer has a "magnification" or some sort that I am not realizing exists? I would like for the size of the elements and the spacing to be 1:1 when looking at designer and the actual application running. 30.8k 17 17 gold badges 85 85 silver badges 139 139 bronze badges. The problem I still see is the obvious size difference between the designer window and the app. Is there any way I can make the group box initially invisible in Qt Creator Designer without having to do it in code qt qt-creator qt-designer Share. This makes the slider match the preview better, and this is not that big of a deal to me though. I was able to use the following code to change the style to match the preview in QT Creator better: QApplication::setStyle(QStyleFactory::create("Fusion")) Adding the slider to a layout did appear to help that. Its not very WYSIWYG, which is odd.Īlso adding another layout did not fix the sizing being so far off. You can see how the spacing and the size does not match. In the background is the Designer interface, the window above it is the actual application being ran using the green play button. Im getting weird clipping and the sliders are very different looking when rendered. Simple Button, two labels and a spacer put in a horizontal layout, and a horizontal slider. Weird.QT Designer is giving me one view of the app, and when I run the app it shows up differently. Re-ran it from desktop menu, and now all the menues functioned normally. Well, running qtcreator from the command line resulted in qt-creator opening with ALL menues available and functioning. then select Qt from "Files and Classes", and then "Qt Designer Form Class"Īs to why your File menu isn't working - try running qtcreator from the command line so you can see any log messages it emits when you try to use the file menu. Well, assuming the File menu is working - File | New File or Project. Qt framework, Qt Creator IDE with tools for desktop and embedded development, Qt Design Studio, plus other enterprise add-ons like Qt Digital Advertising platform and Qt Insight for usage intelligence of embedded devices. I can Alt-F to get 'File' highlighted and cursor up/down blindly, then hit return to Ok, this works, but what if you're starting from scratch and haven't created a *.ui file yet? ui file in the Projects tree to open it, then Design becomes active (because Designer is?) I already was using that when I installed qt-creator and it's still installed, so it must be something else.Ĭlick on a. I've had no problem getting qt-creator to install and run, but the 'Design' button in the left-side menu is disabled (greyed out). Posted: Sat 10:14 pm Post subject: QT Creator - no 'Design' functionality Gentoo Forums Forum Index Portage & Programming Gentoo Forums :: View topic - QT Creator - no 'Design' functionality
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |