Often, when test elements are renamed, their label in the test tree does not resize: When the name is longer than before, it is displayed with "...", if the name is shorter than before, it the blue selection box is too large. This can be fixed by expanding or collapsing the element, in case it has children.
Or by disabling and re-enabling the element...
The method JMeterTreeNode.nameChanged() is never called but fixes this. It needs to be called on the right moment, probably on the node that just is left when changing the focus. The only events that I found are raised too late: They are applied on the node that is switched to, but if you switch back to the node with short label "..." then it helps: JMeterTreeListener.mouseclicked: getCurrentNode().nameChanged(); So this only solves it halfway. It can't be that difficult?
Thanks for that insight - I have found the place in GuiPackage where the GUI fields are saved when changing node. Adding a call to nameChanged() seems to fix the issue: URL: http://svn.apache.org/viewvc?rev=1066517&view=rev Log: Bug 50221 - Renaming elements in the tree does not resize label Modified: jakarta/jmeter/trunk/src/core/org/apache/jmeter/gui/GuiPackage.java jakarta/jmeter/trunk/xdocs/changes.xml
I get null pointer exceptions sometimes when opening large test plans at the start of JMeter. This solved the problem: JMeterTreeNode.java: /** {@inheritDoc} */ public void nameChanged() { + if (treeModel != null) { treeModel.nodeChanged(this); + } }
Thanks for your comment. Sebb have correct this since few month. http://svn.apache.org/viewvc/jakarta/jmeter/trunk/src/core/org/apache/jmeter/gui/tree/JMeterTreeNode.java?r1=1066798&r2=1066797&pathrev=1066798 http://svn.apache.org/viewvc?view=revision&revision=1066798
This issue has been migrated to GitHub: https://github.com/apache/jmeter/issues/2424