1
$\begingroup$

I would like to display a table using TableView. My table already has headers, so I remove them using AppearanceElements -> {"CollapsedRowHeaders", "CollapsedColumnHeaders"}. When I do so though, the little triangle at the bottom right of TableView disappears and I can't resize it manually. I like to have this option so I can adjust the displayed table in TableView to the current size of the Notebook window.

As an example, compare:

data = Table[RandomReal[{1, 100}], 10, 20];
TableView[data,  ImageSize -> 700]

and

data = Table[RandomReal[{1, 100}], 10, 20];
TableView[data, AppearanceElements -> {"CollapsedRowHeaders","CollapsedColumnHeaders"}, ImageSize -> 700]

The question is: Am I naïve in thinking this should be an option all the time, or is something going wrong with the manual resizing tool when collapsing headers?

$\endgroup$
4
  • 1
    $\begingroup$ You'll need to add "ResizeArea" to the AppearanceElements (when you overwrite the default option value, you effectively removed that part) $\endgroup$
    – Lukas Lang
    Commented Sep 14, 2022 at 11:56
  • 1
    $\begingroup$ That being said, you could also just set your headers via the Headers option, then there might not even be a need to collapse them $\endgroup$
    – Lukas Lang
    Commented Sep 14, 2022 at 12:02
  • $\begingroup$ ah wow, I can't believe it's that simple and I missed it. Thanks! $\endgroup$
    – Emy
    Commented Sep 14, 2022 at 12:03
  • $\begingroup$ And thanks for the headers tip. $\endgroup$
    – Emy
    Commented Sep 14, 2022 at 12:04

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.