mirror of
				https://github.com/qgis/QGIS.git
				synced 2025-10-31 00:06:02 -04:00 
			
		
		
		
	Instead of just setting the whole widget as disabled, implement proper read-only state for these widgets. This fixes an annoying UI issue where the list / key value widgets can't be scrolled when opening read-only attribute forms, preventing users from viewing all the entries in the widget.
		
			
				
	
	
		
			55 lines
		
	
	
		
			1.6 KiB
		
	
	
	
		
			Plaintext
		
	
	
	
	
	
			
		
		
	
	
			55 lines
		
	
	
		
			1.6 KiB
		
	
	
	
		
			Plaintext
		
	
	
	
	
	
| /************************************************************************
 | |
|  * This file has been generated automatically from                      *
 | |
|  *                                                                      *
 | |
|  * src/gui/qgskeyvaluewidget.h                                          *
 | |
|  *                                                                      *
 | |
|  * Do not edit manually ! Edit header and run scripts/sipify.pl again   *
 | |
|  ************************************************************************/
 | |
| 
 | |
| 
 | |
| 
 | |
| 
 | |
| 
 | |
| class QgsKeyValueWidget: QgsTableWidgetBase
 | |
| {
 | |
| %Docstring(signature="appended")
 | |
| Widget allowing to edit a QVariantMap, using a table.
 | |
| %End
 | |
| 
 | |
| %TypeHeaderCode
 | |
| #include "qgskeyvaluewidget.h"
 | |
| %End
 | |
|   public:
 | |
| 
 | |
|     explicit QgsKeyValueWidget( QWidget *parent /TransferThis/ = 0 );
 | |
| %Docstring
 | |
| Constructor.
 | |
| %End
 | |
| 
 | |
|     void setMap( const QVariantMap &map );
 | |
| %Docstring
 | |
| Set the initial value of the widget.
 | |
| %End
 | |
| 
 | |
|     QVariantMap map() const;
 | |
| %Docstring
 | |
| Gets the edit value.
 | |
| 
 | |
| :return: the QVariantMap
 | |
| %End
 | |
| 
 | |
|   public slots:
 | |
| 
 | |
|     virtual void setReadOnly( bool readOnly );
 | |
| 
 | |
| };
 | |
| 
 | |
| 
 | |
| /************************************************************************
 | |
|  * This file has been generated automatically from                      *
 | |
|  *                                                                      *
 | |
|  * src/gui/qgskeyvaluewidget.h                                          *
 | |
|  *                                                                      *
 | |
|  * Do not edit manually ! Edit header and run scripts/sipify.pl again   *
 | |
|  ************************************************************************/
 |