I like how DataFrame
displays with PrettyTables.pretty_table
by default. If I want the same behavior for StructArray
, can I make that happen without bad consequences?
you could overload Base.show(io::IO,::MIME"text/plain",x::StructArray)
to use the PrettyTables
show
method.
I believe that this is considered type piracy.
yes it is, but in if you are only using it in personal settings i think is fine.
Is it possible to change the display of this type only for my repl, not for any libraries that happen to use show
for their own internal purposes?
Maybe you could try to submit a PR to StructArrays.jl that uses Preferences.jl to customize the show
methods?
1 Like