Opened 10 years ago

Closed 10 years ago

#11599 closed Bug (wontfix)

Cannot decrease indent of single list item.

Reported by: Zoltan Koszegi Owned by:
Priority: Normal Milestone:
Component: General Version: 4.3.2
Keywords: Oracle Cc:

Description

I tested it with IE9 and IE11 using DEMO page.
STR:
1) Create a flat numbered list with five elements.
2) Select elements 2-4 and press 5x "INCREASE Indent" button.
3) Now select one of the indented list element and try to DECREASE indentation.
RESULT: All of the indented list items move not just the selected one.
4) INCREASE the same element indentation.
RESULT: Single list element can be indented right but left.

Change History (1)

comment:1 Changed 10 years ago by Olek Nowodziński

Resolution: wontfix
Status: newclosed

This behavior is actually a feature of CKEditor, not related to IE or any other particular web browser.

Let's consider the following HTML and selection:

<ol>
	<li>a</li>
	<li>[b</li>
	<li>c]</li>
	<li>d</li>
</ol>

Note that the very first indent level produces nested list:

<ol>
	<li>a
	<ol>
		<li>[b</li>
		<li>c]</li>
	</ol>
	</li>
	<li>d</li>
</ol>

But if you decide to increase indent more, a CSS margin-left is used (config: indentOffset, indentUnit, indentClasses) because further list nesting wouldn't make much sense:

<ol>
	<li>a
	<ol style="margin-left: 40px;">
		<li>[b</li>
		<li>c]</li>
	</ol>
	</li>
	<li>d</li>
</ol>

Knowing that, if you press the indent button 5 times, it will produce the following HTML:

<ol>
	<li>a
	<ol style="margin-left: 160px;">
		<li>[b</li>
		<li>c]</li>
	</ol>
	</li>
	<li>d</li>
</ol>

As for the opposite process, CKEditor prefers block-level behavior to list-level in such case, that is to say that it will decrease indentation (margin-left) of the entire list if possible, until it reaches the nesting level (indent once – no margin). It's a consequence of priorities and assumptions made during design process of our indentation system.

Note: See TracTickets for help on using tickets.
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy