Raido Valgeväli
Top achievements
Rank 2
Raido Valgeväli
asked on 07 Jun 2013, 07:11 AM
I've prepared a little demo here:
http://70.43.83.4/test/split.html
On clicking the "turn" button it almost does what is needed but not quite..
Is there something I do wrong or is it a bug or not implemented?
(I call the "size" after change because by documentation it redraws the splitter)
Thanks.
Raido
http://70.43.83.4/test/split.html
On clicking the "turn" button it almost does what is needed but not quite..
Is there something I do wrong or is it a bug or not implemented?
(I call the "size" after change because by documentation it redraws the splitter)
Thanks.
Raido
5 Answers, 1 is accepted
0
Hello Raido,
Regards,
Dimo
Telerik
The Splitter's orientation can be changed on the fly like this:
var
splitter = $(
"#splitter"
).data(
"kendoSplitter"
);
// set the desired new orientation value:
splitter.orientation = splitter.options.orientation = (splitter.orientation ==
"vertical"
?
"horizontal"
:
"vertical"
);
splitter.element
.children(
".k-splitbar"
).remove()
.end()
.children(
".k-pane"
).css({width:
""
, height:
""
, top:
""
, left:
""
});
splitter.trigger(
"resize"
);
Regards,
Dimo
Telerik
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
Raido Valgeväli
Top achievements
Rank 2
answered on 11 Jun 2013, 08:56 PM
Hi, Dino
I understand this is a non-standard case and therefore really appreciate that you found the information for me. Still it ALLMOST works, having issue of second pane being non-resizeable when the orientation turns.
Please see the sample here (press the Turn button):
http://70.43.83.4/test/kendo.htm
Additionally if you move the separator between left and right before hitting Turn, the second pane gets 0 size and hiding below bottom window edge.
Anyways, thank you very much for the information!
Raido
I understand this is a non-standard case and therefore really appreciate that you found the information for me. Still it ALLMOST works, having issue of second pane being non-resizeable when the orientation turns.
Please see the sample here (press the Turn button):
http://70.43.83.4/test/kendo.htm
Additionally if you move the separator between left and right before hitting Turn, the second pane gets 0 size and hiding below bottom window edge.
Anyways, thank you very much for the information!
Raido
0
Hi Raido,
+ initialize a new Splitter instance with the desired settings
Regards,
Dimo
Telerik
Yes, indeed, splitbars don't work as expected. However, please note that the discussed scenario is not officially supported and is practically a hack. I did not mention this in my previous reply, as it seemed that there were no side effects.
In order to achieve proper behavior, I suggest you to do the following:
+ remove all splitbars
+ remove all Splitter-specific classes and CSS styles from the panes (.k-pane, width, height, top, left)
+ destroy the Splitter object
$(
"#horisontal"
).data(
"kendoSplitter"
).destroy();
+ initialize a new Splitter instance with the desired settings
Regards,
Dimo
Telerik
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
Thomas
Top achievements
Rank 1
answered on 10 Dec 2015, 12:46 PM
Hello,
Two years have passed since your reply.
Isn't there a new, more appropriate way of changing the orientation?
Thank you in advance.
0
Hello Thomas,
The demand for the discussed feature has not been high enough for us to implement built-in orientation change. Please use the approach described above.
Regards,
Dimo
Telerik
The demand for the discussed feature has not been high enough for us to implement built-in orientation change. Please use the approach described above.
Regards,
Dimo
Telerik
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!