| Summary: | [Improve Report Layout Capabilities] Support diagonal line | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Product: | z_Archived | Reporter: | Sissi Zhu <szhu> | ||||||
| Component: | BIRT | Assignee: | Gang Liu <hustlg> | ||||||
| Status: | CLOSED FIXED | QA Contact: | Tianli Zhang <tzhang> | ||||||
| Severity: | enhancement | ||||||||
| Priority: | P3 | CC: | bluesoldier, jasonweathersby, jingwen.shen, rkanguri, rlu, wenfeng.fwd, whe, wyan, yliang, zqian | ||||||
| Version: | unspecified | Keywords: | plan | ||||||
| Target Milestone: | 2.5.0 RC1 | ||||||||
| Hardware: | PC | ||||||||
| OS: | Windows XP | ||||||||
| Whiteboard: | Autoed | ||||||||
| Attachments: |
|
||||||||
|
Description
Sissi Zhu
Add CC members for the cross-team discussion. there are two solutions for this issue: 1. MS office style. In MS office, the CELL has two extra border styles: tl2br (Top left to bottom right) and tr2bl (Top right to bottom left). To use such solution, we need add 6 more property to BIRT: tl2br-border-style tl2br-border-width tl2br-border-color tr2bl-border-style tr2bl-border-width tr2bl-border-color 2. Open office style. In Open office, the user can draw lines in the cells. Then the lines are convert to graphics. Personally I prefer the open office style as it is more extensible. To do so, we need: 1. Free-layout-container. The free-layout-container must have width/height defined. It can be placed into another free layout container or normal container. 2. Free-layout-component. Any items with x, y are free-layout components. They must be placed into a free-layout-container. The x, y is the offset from the free-layout-container. 3. Add a set of graphics components. All the graphics components are free-layout-component, so they must have x, y and are placed into the free-layout-container. To resolve this issue, the user need place a free layout container into the table header, draw a line in the container and place two text item in that container. A sample HTML example attached. Created attachment 109267 [details]
HTML sample
I prefer the second free-layout-container solution too. This is more flexible. By this means, we can achieve many more report styles that cannot done by flow layout. I prefer the second free-layout-container solution too. This is more flexible. By this means, we can achieve many more report styles that cannot done by flow layout. Currently in ROM, we already have the FreeForm element, we can revisit it see if already meet the free-layout-container requirement. +1 to the open office solution. Can use ROM defined freeform, line report items for such feature. Has a question also. X and Y are relative position to the free-layout-container. That means these values can be overlapped. For example, a text item can overlap with another text item. So, need to introduce zIndex for report items, right? BTW, in html, to render a line, Engine will always output the line as a picture, right? Not sure whether the picture backgroud color will be transparent or not. > Has a question also. X and Y are relative position to the > free-layout-container. That means these values can be overlapped. For example, > a text item can overlap with another text item. So, need to introduce zIndex > for report items, right? Yes, we need use the zIndex to control the order of overlapped of elements. > > BTW, in html, to render a line, Engine will always output the line as a > picture, right? Not sure whether the picture backgroud color will be > transparent or not. > In HTML, ENGINE will convert the graphic objects to image. The image's background MUST be transparent otherwise it may overlap other items. I suggest we defer adding freeform-layout-container report item and freelayout-drawing-object report item in 2.5.0 release. For these two report items, we shall not ignore data binding property, since user might want to use result set to draw objects in the freeform container, or write scripts that access the result set. For this feature, can we use a 3rd solution: 1. create a new report item that is similar to grid, except that it will always split the grid by diagnoal lines. 2. properties on this diagonal grid are: N number of diagnoal lines, diagnoal corner (upperleft, upperright, lowerleft, lowerright), line widht, line color, line style. 3. engine will draw N diagonal lines starting from the diagnoal corner by spliting the straight angle into 90/(N+1) degree each. 4. the diagnoal grid will have (N+1) cells, where user can put other report items into it. Question: How will engine draw lines in various output format? Will it depends on emitters? I think using image in PDF or postscript will not be precise enough to have high quality print output. Does Excel support diagnoal line natively? This is a cross-team issue. Defer to 2.5.0 for implementation. 1.added diagonalNumber,antidiagonalLineNumber,diagonalThickness,antidiagonalThickness,diagonalStyle and antidiagonalStyle properties in cell element. 2. provided api to handle these properties in CellHandle 3.provided simple api of these properties in model and engine. Also need to supports on Engine and UI. Reassign to Engine first. need more time to resolve those issues. Checked in the first version codes of the Engine part. There are still some works needs to do, like solving the conflict between diagonal line image and cell background, implementation of the diagonal style and width,etc. Reassign this bug to UI. Please reassign this bug back to me when the UI's work is done. I will continue work on the Engine's part. Thanks. Need the UI mockup first. Implemented the diagonal width in HTML. Implemented part of the diagonal styles in HTML: solid, dashed, dotted. In current BIRT HTML the double diagonal will be treated as solid diagonal. Created attachment 127452 [details]
A design file for testing.
Outputted diagonal line in word emitter. Supported diagonal line style:dotted, dashed, solid. Supported diagonal line width and color. The test report does not appear to work if the /preview mapping is used in the viewer. It works with the /frameset mapping. I have just fix a problem in HTML emitter. In previous codes I have used diagonalStyle for the antidiagonal line. It's not correct. The antidiagonal line should use the antidiagonalStyle. In current BIRT, every cell has six properties: Diagonal number Diagonal style Diagonal thickness Antidiagonal number Antidiagonal style Antidiagonal thickness The number that Engine supports is 0-3. If the number is less than 0, Engine will treat it as 0. If the number is bigger than 3, Engine will treat it as 3. The cell will be divided by surface area. The styles that Engine supports are ¡°solid¡±, ¡°dashed¡± and ¡°dotted¡±. Any other styles will be treated as ¡°solid¡±. The diagonal cell must have an absolute height and width. The cell¡¯s ¡°color¡± property will be used for diagonal line and antidiagonal line too. In HTML there is till a problem not solved: if the cell has a background color, the background color will cover the diagonal line in Firefox. It works well for IE6, IE7 and IE8. Now only the HTML and DOC have implemented the function. Other emitter will implement it later. So after other team finishes the work, please reassign the bug back to Engine for implementation on other emitters. Thanks. (In reply to comment #18) > The test report does not appear to work if the /preview mapping is used in the > viewer. It works with the /frameset mapping. > I have tested it with Firefox 3.0.8, IE6, IE7 and IE8 in run, preview, frameset model. They all work well. Can you provide more information to help us to reproduce the problem? Like which date building BIRT are you using? Or provide the HTML source when the err shows. Thanks. For the UI changes i have logged a separate bugzilla entry https://bugs.eclipse.org/bugs/show_bug.cgi?id=273109 Please use this bugzilla to complete all the engine changes and open issues For testing, currently user can use the advanced properties view to set the properties. HTML, Word output has support the diagonal line, PDF/PS/PPT need also support it. supported in ps/postscript/ppt Verified in 2.5.0 v20090512-0630 build, diagonal line is supported in html/pdf/doc/postscript/ppt. Other issues please refer to new entries. Mark this bug as verified first. close. |