Community
Participate
Working Groups
Drop 20020502, WinXP traditional Chinese When printing the source code, the highlight also gets printed resulting in a gray line on the final print.
Is there some context information we can consult in StyledText rendering canvas that allows us to distinguish whether the rendering is done for printing or for the display.
Related issue: the background colour is printed as well, which is not always desireable. Eg. I set my background to a light blue, which I find better for readign on a display, but on paper I only want the code coloured.
StyledText printing support should avoid any extra "decorating" of the text, in much the same way that web browsers print simplified representations of web pages. Agree that there would need to be a way to communicate the context under which the rendering is occurring. I have no suggestions as to how to do this.
There may be cases where one wishes the line bg colors to be printed (e.g., if one is using line bg colors to indicate tabulation, groups of lines), so we shouldn't just not print the line bg colors. The application could set line bg colors to null, call print, and then reset the line bg colors if the colors are not desired. However, whoever calls print would need to know to set line bg colors to null, call print, reset line bg colors. Doesn't make sense to add some hacky isPrinting flag. Alternatively, we could provide some print API that allows you to specify whether or not to print line bg colors. This is related to [Bug 14956], which would also require API for specifying print options. This is probably what we should do. Investigate further.
Use StyledTextPrintOptions to turn off line background colors and other undesirable decorations. See bug 14956. Moving back to JDT UI.
Changing owner
*** Bug 17573 has been marked as a duplicate of this bug. ***
*** This bug has been marked as a duplicate of 14954 *** *** This bug has been marked as a duplicate of 14954 ***