Hi,
More specifically, you can find this specific extension here:
SequenceableCollection>>gtInspectorItemsIn: composite
^ composite table
title: 'Items';
display: [ :aCollection | [(1 to: self size) collect: [ :index | index -> (self at: index) ]] on:Error do:[#()]];
beMultiple;
searchOn: [:text :each |
Smalltalk compiler evaluate: ' | entity each | each := self. entity := each.', text for: each value logged: false];
column: 'Index' evaluated: [ :assoc | assoc key asString ] width: 50;
column: 'Item' evaluated: [ :assoc | GTObjectPrinter new asTruncatedTextFrom: assoc value ];
send: [ :result |
result isNil
ifTrue: [ nil ]
ifFalse: [ result value size = 1
ifTrue: [result anyOne value]
ifFalse: [self species withAll: (result collect: [:each | each value])]]];
showOnly: 50;
helpMessage: 'Quick selection field. Given your INPUT, it executes: self select: [:each | INPUT ]'.
And then:
GTObjectPrinter>>asTruncatedTextFrom: anObject
^ [ Text fromString: (anObject gtDisplayString replaceAll: String cr with: String space) ]
on: Error
do: [ Text string: 'error printing' attribute: TextColor red ]
So, in the end, you want to override gtDisplayOn: in your class.
Cheers,
Doru
On Jun 16, 2016, at 2:19 PM, Torsten Bergmann <astares@gmx.de> wrote:
Hi Peter,
It's done as a GT extension: see #gtInspectorItemsIn: in class SequencableCollection
and (as nothing is carved in stone in Pharo) for sure this can be changed (or overwritten) ;)
HTH
T.
Gesendet: Donnerstag, 16. Juni 2016 um 14:10 Uhr
Von: "Peter Uhnák" <i.uhnak@gmail.com>
An: "Pharo Development List" <pharo-dev@lists.pharo.org>, "Moose-related development" <moose-dev@list.inf.unibe.ch>
Betreff: [Pharo-dev] What is GTInspector using to print UUID?
Hi,
how inspector decides what to print in the table/headings/etc?
Because for UUID it prints the bytes (I guess because it's child of ByteArray?), however that's rarely useful for UUID, as normally you want to see the #asString representation.
<Mail Attachment.png>
Can this be changed?
Thanks,
Peter
_______________________________________________
Moose-dev mailing list
Moose-dev@list.inf.unibe.ch
https://www.list.inf.unibe.ch/listinfo/moose-dev
--
www.tudorgirba.comwww.feenk.com
"Problem solving should be focused on describing
the problem in a way that makes the solution obvious."