Bug 286223 - [cheatsheet][editor] The sub-step/subitem do not allow line breaks.
Summary: [cheatsheet][editor] The sub-step/subitem do not allow line breaks.
Status: CLOSED WONTFIX
Alias: None
Product: PDE
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.5   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: PDE-UI-Inbox CLA
QA Contact:
URL:
Whiteboard: stalebug
Keywords: bugday
Depends on:
Blocks:
 
Reported: 2009-08-11 07:47 EDT by Ankur Sharma CLA
Modified: 2019-09-29 17:29 EDT (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ankur Sharma CLA 2009-08-11 07:47:16 EDT
1. Create a new Cheat Sheet.
2. Add a step and then a sub-step to it.
3. For the sub-step, go to "Body*" in the "Definition" section and specify some text with line breaks.
4. Save and preview it.
5. Following exception is thrown

null
Error
Tue Aug 11 17:17:40 IST 2009
The 'subitem' element must specify a label attribute.

org.eclipse.ui.internal.cheatsheets.data.CheatSheetParserException: The 'subitem' element must specify a label attribute.
at org.eclipse.ui.internal.cheatsheets.data.CheatSheetParser.handleSubItemAttributes(CheatSheetParser.java:840)
at org.eclipse.ui.internal.cheatsheets.data.CheatSheetParser.handleSubItem(CheatSheetParser.java:785)
at org.eclipse.ui.internal.cheatsheets.data.CheatSheetParser.handleItem(CheatSheetParser.java:587)
at org.eclipse.ui.internal.cheatsheets.data.CheatSheetParser.parseCheatSheet(CheatSheetParser.java:1003)
at org.eclipse.ui.internal.cheatsheets.data.CheatSheetParser.parse(CheatSheetParser.java:960)
at org.eclipse.ui.internal.cheatsheets.views.CheatSheetViewer.readFile(CheatSheetViewer.java:1017)
at org.eclipse.ui.internal.cheatsheets.views.CheatSheetViewer.initCheatSheetView(CheatSheetViewer.java:857)
at org.eclipse.ui.internal.cheatsheets.views.CheatSheetViewer.setContent(CheatSheetViewer.java:1136)
at org.eclipse.ui.internal.cheatsheets.views.CheatSheetViewer.setInputFromXml(CheatSheetViewer.java:1262)
at org.eclipse.ui.internal.cheatsheets.views.CheatSheetView.setInputFromXml(CheatSheetView.java:231)
at org.eclipse.ui.cheatsheets.OpenCheatSheetAction.run(OpenCheatSheetAction.java:145)
at org.eclipse.pde.internal.ua.ui.editor.cheatsheet.simple.actions.SimpleCSPreviewAction.run(SimpleCSPreviewAction.java:70)
at org.eclipse.jface.action.Action.runWithEvent(Action.java:498)
at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:584)
at org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionItem.java:501)
at org.eclipse.jface.action.ActionContributionItem$5.handleEvent(ActionContributionItem.java:411)
at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1003)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3880)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3473)
at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:2405)
at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2369)
at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:2221)
at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:500)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:493)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:113)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:194)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:368)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:179)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:79)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:618)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:559)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:514)
at org.eclipse.equinox.launcher.Main.run(Main.java:1311)
Comment 1 Ankur Sharma CLA 2009-08-11 07:50:27 EDT
When cheat sheet is saved, the line break is correctly translated to 
 in the XML, but the model does not read it back correctly.
Other escaped sequences like <  and  " work correctly.
Comment 2 Curtis Windatt CLA 2009-08-11 10:39:44 EDT
Worth looking at in 3.6
Comment 3 Ankur Sharma CLA 2009-08-11 10:59:32 EDT
I feel the sub-step/subitem should support HTML too like step/item node.
Comment 4 Eclipse Webmaster CLA 2019-09-06 16:17:00 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.
Comment 5 Julian Honnen CLA 2019-09-09 02:21:04 EDT
Please remove the stalebug flag, if this issue is still relevant and can be reproduced on the latest release.
Comment 6 Ulrich Wuensche CLA 2019-09-29 17:29:12 EDT
Cf. help item "Cheat Sheet Content File XML Format" of the cheat-sheet version 3.5.500.

subitem may have an attribute label e.g. <subitem label="unformatted"/>. In this case label cannot use formatting <b> <br/>.

Since version 3.4 a subitem without label attribute may have a description e.g. <subitem><description><b>This is bold</b></description></subitem>.

As it seems the label behaviour is not a bug but a feature.
Pleas note that the simple cheat sheet editor does not honour the <description> variant.