-
-
Notifications
You must be signed in to change notification settings - Fork 3.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[FEATURE] Merge of legend refactoring work
This replaces the existing tree widget implementation with more modular approach. In summary: - tree hierarchy in CORE library: QgsLayerTreeNode, QgsLayerTreeLayer, QgsLayerTreeGroup - model/view based tree view: QgsLayerTreeModel, QgsLayerTreeView - tree synchronization with map layer registry: QgsLayerTreeRegistryBridge - controlling of map canvas: QgsLayerTreeCanvasBridge Conflicts: src/ui/qgisapp.ui
- Loading branch information
Showing
75 changed files
with
5,093 additions
and
6,085 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
class QgsScaleVisibilityDialog : QObject | ||
{ | ||
%TypeHeaderCode | ||
#include <qgsscalevisibilitydialog.h> | ||
%End | ||
|
||
public: | ||
explicit QgsScaleVisibilityDialog( QWidget *parent = 0, QString title = QString(), QgsMapCanvas* mapCanvas = 0 ); | ||
|
||
//! return if scale visibilty is enabled | ||
bool hasScaleVisibility(); | ||
|
||
//! return minimum scale (true scale, not scale denominator) | ||
double minimumScale(); | ||
|
||
//! return maximum scale (true scale, not scale denominator) | ||
double maximumScale(); | ||
|
||
|
||
public slots: | ||
//! set if scale visibility is enabled | ||
void setScaleVisiblity( bool hasScaleVisibility ); | ||
|
||
//! set minimum scale (true scale, not scale denominator) | ||
void setMinimumScale( double minScale ); | ||
|
||
//! set maximum scale (true scale, not scale denominator) | ||
void setMaximumScale( double maxScale ); | ||
|
||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
b2a4c76
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @wonder-sk, thanks for this new awesome stuff!
Just tested but I get a crash when loading some project:
b2a4c76
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
another crash happens when using the Zoom to Layer action:
b2a4c76
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@slarosa thanks for reporting that - both crashes are fixed now.
b2a4c76
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @wonder-sk for the quick fix. Some other thin difference with the old interface which I summarize in the next picture:
Also the message box when removing some entry from legend is gone, although I would like see an undo action for that! :-)
b2a4c76
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
...and sometime dragging an entry over a group element I get segfault:
b2a4c76
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @wonder-sk I have one more issue here:
b2a4c76
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Both crashes are fixed now.
Project saved with master version will not keep the grouping because the project format has changed.