Community
Participate
Working Groups
Consider moving "preview" button into the section bar, perhaps next to "reply". I am not sure if this is specific to Trac only or part of the common Task Editor UI. BTW, it seems like widget used to show preview there is either have an extra border or isn't using flat form look.
Created attachment 85361 [details] present look of the Trac editor
Steffen, you could assign this task to me
Created attachment 105360 [details] moving the preview button into the section bar a nice hack: marking the tab text invisible, saving resource, but still using the multitab function. detail in screen shot and comment
Created attachment 105361 [details] screenshot of moving the preview button to the section bar
Steffen & Mik (I cced you because you seem to be the "icon" authoring all the icons - the CommonImages class), will it be possible that this patch is applied and you guys also get a new icon for the editing/preview button on the top right as shown in the screen shot?
Yes, don't worry about the icons. We'll create one when applying the patch. Reusing an existing icon is perfectly okay.
Nice work on the patch Owen! Is there a reason why you've created a new class ExtensibleRichTextAttributeEditor2 instead of modifying ExtensibleRichTextAttributeEditor?
(In reply to comment #7) > Nice work on the patch Owen! Is there a reason why you've created a new class > ExtensibleRichTextAttributeEditor2 instead of modifying > ExtensibleRichTextAttributeEditor? the reason is that I am not sure whats the status of Mylyn right now, I have to watch out before modifying every class...instead of wiping everything, I created another one. It would be great if the patch is applied, but we can also get the initial version back only by changing the class name. Also for the purpose of future reference of the initial version. As commented in ExtensibleRichTextAttributeEditor2, it is a totally replacement for ExtensibleRichTextAttributeEditor. I am not sure whether its a good idea to create a patch like this. Please comment.
(In reply to comment #8) > > I am not sure whether its a good idea to create a patch like this. Please > comment. > It's much better to create patches that modify existing classes instead of creating a new class every time you want to change something. That way we can see which source code changed, and it's easier to keep track of what's what.
Created attachment 105369 [details] recut the patch changing ExtensibleRichTextAttributeEditor2 to ExtensibleRichTextAttributeEditor, others the same
Created attachment 105371 [details] re-recut the patch forgot to add David's name back to @author after the refactoring. This patch should be no typos...Sorry David...
Patch looks great! I noticed that the button is toggled by default when editing. Could you change it so it stays pressed in preview mode? I also notice a light blue background in the line that is edited. I don't remember seeing that before. Is that caused by a change in Textile-J or Mylyn?
(In reply to comment #12) > I also notice a light blue background in the line that is edited. I don't > remember seeing that before. Is that caused by a change in Textile-J or Mylyn? (In reply to comment #12) > I also notice a light blue background in the line that is edited. I don't > remember seeing that before. Is that caused by a change in Textile-J or Mylyn? The light blue background is setup by MarkupTaskEditorExtension (Textile-J) with the following code: bc. support.setCursorLinePainterPreferenceKeys(AbstractDecoratedTextEditorPreferenceConstants.EDITOR_CURRENT_LINE, AbstractDecoratedTextEditorPreferenceConstants.EDITOR_CURRENT_LINE_COLOR); the cursor line is highlighted according to a user preference.
(In reply to comment #12) > Patch looks great! I noticed that the button is toggled by default when editing. > Could you change it so it stays pressed in preview mode? > I am sorry Steffen, could you explain why would it saty pressed in preview mode? Lost you... Right now when the task editor is first open, its in editing mode, and when clicking the button, it enters preview mode to preview the editing. Its a toggle button switching between the two modes.
> Right now when the task editor is first open, its in editing mode, and when > clicking the button, it enters preview mode to preview the editing. When I opened the editor the button was checked by default. Could reverse the meaning of the button: unchecked (default) = edit, checked = preview?
Created attachment 105547 [details] all-in-one patch fixing: not checked (default) - edit mode; checked - preview mode
Patch applied. Great work Owen! I'll bug Mik to create a new icon for the preview.
Created attachment 106185 [details] try this
Created attachment 106206 [details] a patch applying the new icon thanks Mik :)
Created attachment 106207 [details] mylyn/context/zip
Created attachment 106643 [details] fixing the tooltips of the preview button a patch that fixes the following: before clicking the preview button, it displays "Click to preview", after clicking, it becomes "Preview".
Created attachment 106644 [details] mylyn/context/zip
I have changed the tooltip to "Preview" in compliance with the Eclipse User Guide Lines [http://wiki.eclipse.org/User_Interface_Guidelines#Appearance]: "The tool tips for a command should describe the behavior which occursif the command is invoked, independent of the current state. For push buttons, the label should decribe the result of users pushing the button. For toggle buttons, it should describe its effect when the item is toggled on, and the label should not change depending on the state of the button."
(In reply to comment #23) > I have changed the tooltip to "Preview" in compliance with the Eclipse User > Guide Lines [http://wiki.eclipse.org/User_Interface_Guidelines#Appearance]: > > "The tool tips for a command should describe the behavior which occursif the > command is invoked, independent of the current state. For push buttons, the > label should decribe the result of users pushing the button. For toggle buttons, > it should describe its effect when the item is toggled on, and the label should > not change depending on the state of the button." thanks for the info, Steffen, I will apply the guidelines on all my future patches
No worries. I wasn't sure about the right way to handle the tooltip so I looked it up. The guide lines are a great reference that we try to follow as close as possible in Mylyn.
Created attachment 107680 [details] reimplement ExtensibleRichTextAttributeEditor to supports sitching between RepositoryTextViewer and MarkViewer(WikiText) this reimplementation is related to bug 219939
Created attachment 107681 [details] mylyn/context/zip
the new implementation use StackLayout since it provides more flexible way of switching controls, while keeping the original features (switching between editing and previewing). The reimplementation is to provide method to disable/enable WikiText (bug 219939).
That sounds like a good idea. Owen, please file a new bug for this and attach the patch there. One thing you could consider as well is to construct the controls lazily, i.e. create the preview widget when a preview is requested for the first time.