Community
Participate
Working Groups
While trying to improve the Copy functionality I found some problem - the alignment for the columns is hardcoded - the first column is left justified, and all the rest right justified. This works fine with all "standard" views in MAT, but if I use OQL to select the address of an object and its value (say for Strings) then the strings are right justified. This however would need a bit more thinking and therefore I opened a separate message for it. How to reproduce: 1) open the OQL view 2) execute SELECT s.@objectAddress, toString(s) FROM java.lang.String s 3) copy some lines from the result content and paste to a text file The functionality is implemented in org.eclipse.mat.ui.util.Copy
I've got some code to fix this, and to follow reordering of columns in the GUI, and to get the dashed line the right length if the alignment of columns is not the default. I'll add it shortly.
I'll commit my changes. Should the line separator be CR/LF or line.separator ? Should export as CSV or HTML follow the reordering of table/tree columns? At the moment they do not. Krum, please try this and see if it does what you want.
Before: s.@objectAddress| toString(s) ---------------------------------------------------------------------------- 649,759,280 | returnOpenType 649,759,128 | javax.management.openmbean.OpenMBeanOperationInfoSupport 649,757,024 | javax.management.openmbean.OpenMBeanParameterInfoSupport 649,712,528 | Non-heap memory 649,712,472 | NON_HEAP 649,712,408 | Heap memory 649,712,360 | HEAP ---------------------------------------------------------------------------- With the fix: s.@objectAddress |toString(s) --------------------------------------------------------------------------- 649,759,280 |returnOpenType 649,759,128 |javax.management.openmbean.OpenMBeanOperationInfoSupport 649,757,024 |javax.management.openmbean.OpenMBeanParameterInfoSupport 649,712,528 |Non-heap memory 649,712,472 |NON_HEAP 649,712,408 |Heap memory ---------------------------------------------------------------------------