View Issue Details

IDProjectCategoryView StatusLast Update
0000199QElectroTechElement Editorpublic2020-08-07 15:34
ReporterdamianCaceres Assigned To 
PrioritynormalSeverityminorReproducibilityalways
Status resolvedResolutionfixed 
Product VersionGIT/master 
Fixed in VersionGIT/master 
Summary0000199: Text changes in the drawing area are not reflexted in the information area
DescriptionSee next
Steps To Reproduce1.- Open ElementEditor and create a text field
2.- Select the bounding box, double click and modify the text
3.- The introduced changes are not picked by the input field in the information area
Additional InformationQElectroTech V 0.80-DEV
Compilation : GCC 10.1.0
Built with Qt 5.9.5 - Date : Aug 6 2020 : 19:56:03
TagsNo tags attached.

Activities

scorpio810

2020-08-07 13:29

administrator   ~0000442

I can reproduce

scorpio810

2020-08-07 13:47

administrator   ~0000443

Last edited: 2020-08-07 13:56

View 3 revisions

A Workaround is to disable double click to modify like dynamic text

--- sources/editor/graphicspart/parttext.cpp
+++ sources/editor/graphicspart/parttext.cpp
@@ -162,7 +162,7 @@ void PartText::keyPressEvent(QKeyEvent *event) {
 void PartText::mouseDoubleClickEvent(QGraphicsSceneMouseEvent *e) {
     QGraphicsTextItem::mouseDoubleClickEvent(e);
     if (e -> button() == Qt::LeftButton) {
-		setEditable(true);
+		setEditable(false);
     }
 }
https://git.tuxfamily.org/qet/qet.git/tree/sources/editor/graphicspart/parttext.cpp#n338

scorpio810

2020-08-07 14:20

administrator   ~0000444

Last edited: 2020-08-07 14:22

View 2 revisions

This bug is very old, it does not come from the last changes, I can reproduce under 0.7 version

scorpio810

2020-08-07 15:25

administrator   ~0000445

Possible fix:
--- sources/editor/graphicspart/parttext.cpp
+++ sources/editor/graphicspart/parttext.cpp
@@ -172,12 +172,9 @@ void PartText::mouseDoubleClickEvent(QGraphicsSceneMouseEvent *e) {
     @param value Valeur numerique relative au changement
 */
 QVariant PartText::itemChange(GraphicsItemChange change, const QVariant &value) {
-	if (change == QGraphicsItem::ItemPositionHasChanged || change == QGraphicsItem::ItemSceneHasChanged) {
+	if (change == QGraphicsItem::ItemPositionHasChanged || change == QGraphicsItem::ItemSceneHasChanged || change == QGraphicsItem::ItemSelectedChange) {
         updateCurrentPartEditor();
-	} else if (change == QGraphicsItem::ItemSelectedHasChanged) {
-		if (value.toBool() == true) {
-			updateCurrentPartEditor();
-		}
+	
     }
     return(QGraphicsTextItem::itemChange(change, value));
 }

Issue History

Date Modified Username Field Change
2020-08-06 21:14 damianCaceres New Issue
2020-08-07 13:29 scorpio810 Note Added: 0000442
2020-08-07 13:47 scorpio810 Note Added: 0000443
2020-08-07 13:47 scorpio810 Note Edited: 0000443 View Revisions
2020-08-07 13:56 scorpio810 Note Edited: 0000443 View Revisions
2020-08-07 14:20 scorpio810 Note Added: 0000444
2020-08-07 14:22 scorpio810 Note Edited: 0000444 View Revisions
2020-08-07 15:25 scorpio810 Note Added: 0000445
2020-08-07 15:34 scorpio810 Status new => resolved
2020-08-07 15:34 scorpio810 Resolution open => fixed
2020-08-07 15:34 scorpio810 Product Version SVN/trunk => GIT/master
2020-08-07 15:34 scorpio810 Fixed in Version => GIT/master