Ticket #6768 (closed defect: fixed)

Opened 7 months ago

Last modified 5 months ago

BorderContainer: style gap between panes for splitter=false

Reported by: bill Owned by: bill
Priority: normal Milestone: 1.2
Component: Dijit - LnF Version: 1.1.0
Severity: normal Keywords:
Cc: nonken

Description (last modified by bill) (diff)

When splitter=true

<div dojoType="dijit.layout.ContentPane" region="top" .. splitter="true">

...BorderContainer leaves a gap between the panes which can be grabbed and dragged in order to resize the pane:

For styling reasons (see #6438 and #6764), need to support (an optional) similar gap even when pane's size is not adjustable (ie, when splitter="false"). Actually, a gap should be the default, to match the padding that nonken will be adding to BorderContainer.

But of course don't display the thumb icon if pane isn't resizable.

As usual w/dijit everything needs to be controlled via CSS rules but not sure exactly what the best way to do this is... could have a .dijitNonMovableSplitter class or perhaps just leverage the padding setting from the BorderContainer's DOM node.

Attachments

gap.png (17.3 kB) - added by bill 7 months ago.
thumb.png (4.4 kB) - added by bill 7 months ago.

Change History

Changed 7 months ago by bill

Changed 7 months ago by bill

Changed 7 months ago by bill

  • description modified (diff)

Changed 7 months ago by peller

So I take issue with making a 'gap' the default in bc. Also, it sounds more like you want a non-movable splitter (w/o a 'thumb') than a gap; there's a difference. If we want the latter, we could have a property on BC like showAllSplitters="true" (I think it should default to 'false' to preserve the current behavior, it's simpler, and because it makes more sense when splitters aren't used) This would make the splitters appear -- an extra themed DIV element -- without their 'thumbs', using CSS rules, which is more than just producing a gap in the layout.

Changed 7 months ago by dante

showSplitters=true works for me +1

so splitter=false && showSplitters=true would create a _Splitter, but not "activate" it?

Changed 5 months ago by bill

  • owner changed from peller to bill
  • status changed from new to assigned

Changed 5 months ago by bill

  • status changed from assigned to closed
  • resolution set to fixed

(In [14340]) Add gutters=true/false parameter so BorderContainer? can be used like old LayoutContainer? where it doesn't add margin around panes or borders around ContainerPane? and TabContainer?.

When gutters=true (default), adds "margin" around all panes, even non-resizable panes, separating them from other panes and from the edge of the BorderContainer? itself.

Also removed padding from tests and instead added it to themes, in order to test that the themes are working correctly. Plus, changed themeTester.html to have single BorderContainer? instead of nested ones.

Fixes #6768 !strict

Changed 5 months ago by bill

(In [14341]) A few lines I meant to remove before previous checkin. Refs #6768 !strict

Changed 5 months ago by bill

(In [14342]) Fix and simplify calculations (adding 0 is harmless), fixing problem where right splitter was obscured on IE. Refs #6768 !strict

Changed 5 months ago by bill

(In [14343]) Fix calculations again... rightSplitterWidth should be 0 if there is no right pane. Refs #6768 !strict

Changed 5 months ago by bill

(In [14347]) Refactor code to stick in a dummy div as a gutter (for when BorderContainer?.gutters=true but ContentPane?.splitter=false). This is needed to make nested BorderContainers? look right, because they have padding:0px but they still need gutters... thus the gutter width cannot be equal to the padding. Refs #6768 !strict

Note: See TracTickets for help on using tickets.