Questions tagged [qt-designer]

Qt Designer is a tool for designing and building graphical user interfaces (GUIs) from Qt components.

Filter by
Sorted by
Tagged with
11
votes
1answer
11k views

How do Qt Designer and QGIS work together?

I am just trying understand how qgis and designer work together. From Nathan W's excellent posts I know how to create a user form and how to hook it to a qgis layer and also how to add validation ...
8
votes
2answers
3k views

How to compile QtDesigner user interface (.ui) and resource (.qrc) files with QGIS 3 on Windows?

I tried to transpose the QGIS 2 process with no success. I first had to edit C:\Program Files\QGIS 2.99\etc\ini\python-core.bat which contains references to Python27 instead of Python36. I run C:\...
8
votes
2answers
3k views

How can I add a second Toolbar Button and Dialog to a QGIS plugin built with Plugin Builder?

I want to create a toolbar with 2 buttons, each button opening a different form. The steps I followed are: Created a plugin using Plugin builder Created a toolbar with 2 buttons by doing the ...
8
votes
2answers
206 views

Colouring attribute/field on QGIS data form based on value?

Using QGIS (2.14) is it possible on the data form for an attribute to have a colour (or other formatting) based on its value? For example if my data has a field 'quality' which has a value 'good' or ...
7
votes
1answer
469 views

Do I have to publish own QGIS plugins?

If I develop QGIS plugins for my company do I have to make them available to others? I use QT-Designer and think that it also depends on the question how you develop your plugins, right? For example: ...
7
votes
1answer
297 views

Fixing headings for QGIS custom widgets in Qt Designer

I use custom Qt widgets like QgsMapLayerComboBox for my QGIS plugin, laying the whole thing out in Qt Designer. Using those requires fixing headings in .ui file as described here. Unfortunately I have ...
6
votes
2answers
3k views

How to display a picture in QGIS custom form?

I'd like to integrate an UI file as a form in QGIS 2.8. The UI file is created in QT Designer. One of the attributes in the attribute table is a filepath to an image. I'd like to display the picture ...
6
votes
2answers
1k views

Binding between QGIS custom form (Qt Designer) and date/time field in SpatiaLite database table?

For my attribute table I created a custom form in Qt Designer. The table has a date field and a time field. In Qt Designer there are widgets for entering date and time but what data type is expected ...
5
votes
2answers
1k views

How to populate QTableWidget via plugin?

I am attempting to populate a QTableWidget by adding rows, this is done by the user clicking on the add button: I have the following code to try and insert rows but nothing is happening: def ...
5
votes
1answer
11k views

How to reference to my in QT designer created buttons in python?

I have created an own QDialog (using QT Designer) with three push buttons. The names are pButton1, pButton2 and pButton3. After saving the file I created the ui file by using: pyuic4 ui_xy.ui > ...
5
votes
2answers
714 views

No custom widgets in Qt Designer for QGIS 3

There are no custom widgets in my "Qt Designer with QGIS 3.0.3 custom widgets". Is it a bug or I should somehow manually enable them?
4
votes
1answer
854 views

How to add loading bar in QGIS Plugin development?

Every time i use tool or plugin in QGIS, i saw a kind of bar like this for indicating loading progress : The different between that bar and Progress Bar is that progress bar will increase until our ...
4
votes
1answer
218 views

QGIS 3.6 picture in ui form (Qt5 Designer)

I'm facing trouble with display a picture in a ui form based on a field (path). With the autogenerate form it works but when I try with a personalized form I cannot see the picture. I tried with a ...
3
votes
3answers
188 views

Manipulating value with toolbar

In my project, I use 3 layers with a line geometry. Every line in the layer is a contour with the same depth "valdco". For operational ease, I color these lines blue, red en orange (as seen in the ...
3
votes
1answer
73 views

Making Upload button for shapefile in QGIS plugin?

I am new to Plugin Builder and creating my first plugin called NearestNeighbour. The below is GUI of my plugin made using Qt Creator I read in this link that it is important to rename Dialog Box, ...
3
votes
1answer
345 views

How to use Qt3 Support widgets in QGIS plugin?

Similar to this post: My plugins crashes with “No module named qgsprojectionselectionwidget” in Windows. Except I would like to also use Qt3 Support widgets (in particular, a Q3ButtonGroup). However, ...
3
votes
1answer
368 views

QGIS 2.18 : Choosing path of file for Python init function

I'm using a custom feature form for QGIS 2.18 (custom .ui file + custom Form.py file containing the Python init function used by the form). I would like to be able to put the .ui file and the Form.py ...
3
votes
1answer
502 views

How to connect QgsMapLayerComboBox to QgsDataDefinedButton

in Qt Designer there is the possibility to use directly QGIS custom widgets. In the UI I added a QgsMapLayerComboBox (to get the layers added in the legend) and a QgsDataDefinedButton. What I would ...
3
votes
1answer
128 views

Can't open Qt Designer with qgis-designer.bat

I'm trying to open Qt Designer using the qgis-designer.bat file, but I'm receiving the following error message Windows cannot find 'designer.exe'. Make sure you've typed the name correctly, then ...
3
votes
1answer
621 views

Autosize custom form window to its content

I've created several custom forms using Qt Designer. My problem is that when I open a form, its window size remains the same as the size of the window of the last form I opened. For example, let's say ...
3
votes
2answers
203 views

PyQGIS/QGIS2.18 : Store checkbox state as boolean in database (PostGreSQL 9.3)

I would like to store the information about whether a checkbox is checked or not in a boolean column in my database (running on PostGreSQL 9.3). I'm using a custom form, and the corresponding checkbox ...
3
votes
0answers
46 views

Plugins that works with high resolution screens

I've written a plugin for QGIS (GeoDataFarm) and I've been using QT creator for all ui files of the plugin, which have worked fine for me. However, I just got an email from someone that tested my ...
2
votes
2answers
663 views

Python GUI for QGIS plugin ; 'ModuleNotFoundError: No module named…'

I am overhauling my QGIS plugin to work with QGIS 3.0. I have hit a problem relating to the importing of custom forms created using the Qt Designer. In the old version (which worked, with QGIS 2.x) I ...
2
votes
1answer
2k views

QT Designer form - Combobox stores value but doesn't display it

I have a custom form created with QT Designer on which I have several comboboxes among other stuff. All the fields have the correct names corresponding to the database. One of these comboboxes has a ...
2
votes
1answer
2k views

QtDesigner add map canvas widget

I am getting very difficulties to add a map canvas widget through QtDesigner. I want a window with some buttons and a space to open the map canvas. How do I specify that? What widget did I choose? ...
2
votes
1answer
250 views

from qgis.gui import QgsMapCanvas - ModuleNotFoundError: No module named 'qgis'

I created a form with QT Designer, then converted it to a .py file. An error occurs with the line import : from qgis.gui import QgsMapCanvas. It's not recognized. How can I resolved this error in ...
2
votes
2answers
461 views

PyQt - merge selected features function

VERSION QGIS 2.1x i realize plugins to do this actions without use toolbar: copy features / paste to layer / merge selected features => define attribute to use in merge. So, all is okay but i don't ...
2
votes
1answer
390 views

How do I make a file dialog for a custom forms that does the same thing as the autogenerated URL selector?

I used QT Designer to build a custom form for attribute entry. One of the attributes is for storing a file path of a permit document as a string. With the auto-generated forms, there was a URL ...
2
votes
1answer
539 views

How to filter out layers with QgsMapLayerComboBox?

I am using Qt Designer 4.8.5 to develop a plugin (with QGIS 2.14.3-Essen). I recently started to use QgsMapLayerComboBox widgets instead of the conventional Combo Box widget. However, I want to ...
2
votes
1answer
145 views

Dependent Comboboxes in QGIS 2.8.2 [closed]

I´m setting up an database for an archaeological project with PSQL. There I have a field "material" connected with a table "materials" containing things like metal, stone, etc. In a third table I have ...
2
votes
2answers
2k views

Using Qt Designer to Create a Form in QGIS that can search for a specific point in a layer

I would like to ask if you can create a form in Qt Designer to create a form that can search for a point on the map using data that the user will provide such as the Name. I am currently creating a ...
2
votes
1answer
18 views

Saving QGIS form design basic functionality in .ui to modify it with QTDesigner

It is possible to save a classic Qgis form (a drag and drop form) in order to modify it with QtDesigner afterwards ? I have created a form and I just want to change a list value into a toggle button ...
2
votes
1answer
41 views

Select layer by attribute using expression qtcreator/pyqgis

I'm trying to make a function like ArcGIS's select using Python 3.6 , QGIS 2.8.6 and QtDesigner, so this is my code: def execute(self): layers = self.iface.legendInterface().layers() ...
2
votes
1answer
66 views

How do I call the objects created with QtDesigner (or QtCreator) in my code in python? Where is this information in python? PyQt4 please

Where can I find a good documentation on how to refer (to call) to the Dialog created with QtDesigner? For example, a buttomBox (or any other) just created. I’m trying to make a plugin, but the ...
2
votes
1answer
310 views

Python traceback at QGIS startup with QgsMapLayerComboBox in Plugin

I created a QGIS (2.14.8 LTR) plugin gui with QtDesigner and I would like to use a QgsMapLayerComboBox, cp. screenshot below (selected widget, settings at the right). At QGIS startup, when loading ...
2
votes
1answer
811 views

import Map from QGIS into QT Designer

I am looking for a way to get a map from QGIS into QT Designer. I have the QT Designer version that comes with QGIS, meaning i have all the standard QGIS Widget. I don´t see a map widget, but many ...
2
votes
1answer
327 views

Qt Designer and QGIS, using relation references

I have made my own form in Qt Designer and connected it to QGIS. One of my fields is a relation reference. But the text doesn't fit in the combo box. You can see it in the picture. I tried to ...
2
votes
1answer
370 views

QGIS plugin problem, can't reach objects in a Qt-based Stacked Widget

I am creating a plugin for QGIS but am having trouble with the Qt components. I have used Plugin Builder and Qt designer to create all necessary files for the plugin. I want to use a QStackedWidget ...
2
votes
0answers
33 views

QGIS map tile not printing some given extent in one time why?

I made a plugin in QGIS using pyqgis and qt designer to plot OSM tile in which I have one button which connects me to function in which I wrote a program to plot raster layer using param and I am ...
2
votes
1answer
55 views

Create tabs for the QGIS plugin interface using Qt Creator

Is it possible to create tabs for QGIS plugin using Qt Creator? (Something like the image I attached) I am trying to group the functionalities I developed for QGIS plugin and I think using multiple ...
2
votes
0answers
82 views

QGIS not binding value from field to widget in my custom form (Qt Designer)

I have created a custom form in QT Designer with a QSpinBox and a QLineEdit. I named the objects the same as the column names so that qgis can bind the values. Added the .ui to a layer. The widgets ...
2
votes
0answers
452 views

This extension is corrupted : No module named qgscollapsiblegroupbox

I'm building a QGIS plugin, and I am making the GUI using Qt Designer. Whenever I am using one of the "QGIS custom widgets" (in the present case, a QgsCollapsibleGroupBox) in my plugin window, it ...
2
votes
1answer
398 views

How to connect QtDesigner with python console on QGIS

I've created a script with python console on QGIS and an interface for my plugin with Qt Designer with QGIS 2.14.0 custom widgets. I would like to connect my sript with the interface but I can't find ...
2
votes
1answer
63 views

Return several layers from listwidget

I am new to python and I am writing my first plugin that add selected layers from a listwidget to QGIS. So good so far, but it does not allow me to select several layers at once. Am I missing ...
2
votes
0answers
1k views

Combining custom QWidgets with ui file generated from QGIS plugin builder?

I am having a hard time figuring out how I can include several QWidgets (created in individual scripts) into the QT Designer ui file generated from a QGIS plugin builder. These are custom widgets I ...
2
votes
0answers
440 views

How to best get Qt Designer for QGIS plugin development on Mac?

I'm using QGIS 2.6.1 on Mac OSX 10.9.4, trying to create a plugin as described in the PyQGIS Programmer's Guide. I have the plugin 'skeleton' (main widget with header and ok/cancel buttons) running in ...
1
vote
2answers
238 views

Debugging Global name ''QgsMapLayerComboBox' is not defined?

I try to develop little plugin for Qgis. I used custom widgets in QT that comes with QGIS 2.18 and loaded QgisMapLayerComboBox. But when I reload my plugin in QGis it gives me an error: 2018-01-...
1
vote
1answer
257 views

Python GUI for QGIS plugin ; how to reference form controls in code? [closed]

I've been going around in circles with this for a few hours so hopefully someone can help. I am familiar with VB, C# but not Python - and struggling to do something fairly simple. I have created a ...
1
vote
2answers
742 views

Advanced forms with QT designer

I have a QGIS project where a SHP-layer contains the IDs of plots besides vector data. I want to create a form with QTDesigner which enables me to enter the contact information of the landowner(s) ...
1
vote
1answer
2k views

How to change the values of the push buttons in QT designer [closed]

I am using the standard dialog box with ok and cancel options.i Have also added one more button exit. self.dlg.show() result=self.dlg.exec_() print 'The result is',result it is ...