This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 110849 - Nested div project has refresh and imaging problem
Summary: Nested div project has refresh and imaging problem
Status: VERIFIED FIXED
Alias: None
Product: obsolete
Classification: Unclassified
Component: visualweb (show other bugs)
Version: 6.x
Hardware: All All
: P2 blocker (vote)
Assignee: Peter Zavadsky
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-07-25 00:43 UTC by _ krystyna
Modified: 2007-08-09 00:41 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
HMS zip (5.87 MB, application/octet-stream)
2007-07-25 00:44 UTC, _ krystyna
Details
linebreaks (188.57 KB, application/octet-stream)
2007-07-25 00:45 UTC, _ krystyna
Details
HMSswitchjsp (194.69 KB, application/octet-stream)
2007-07-25 00:46 UTC, _ krystyna
Details
HMSswitchmMenu (238.67 KB, application/octet-stream)
2007-07-25 00:47 UTC, _ krystyna
Details

Note You need to log in before you can comment on or make changes to this bug.
Description _ krystyna 2007-07-25 00:43:32 UTC
NB trunk build 07240000
XP
JDK1.6.0_02

This is 1.4 project from bugster 6431206, nested floated divs. (attaching the .zip)
Project sometimes requires a refresh after switch to .jsp; sometimes refreshes incorrectly.

#1
1) unzip and open welcome.jsp page and take note of design view; ok to refresh here to ascertain view. The lines 
break (from the mainMenu.jsp include). Resize designer width view and refresh. Still the lines break. problem one.
See HMSlinebreaks.jpg attachment.

2) switch to .jsp view and then return to designer
>design view has changed. Refresh returns the "correct" view but the view shouldn't have changed. See HMSswitchjsp.jpg
I have seen the design view switch after deployment.

#2
3) open the mainMenu.jspf in designer. return to welcome.jsp pageto see the line breaks problem gone! 
See HMSswitchmMenu.jpg file.


So switch to welcome.jsp jsp view, then welcome.jsp design view and bad line breaks happen again.
We never get the full correct view as in runtime.
Comment 1 _ krystyna 2007-07-25 00:44:20 UTC
Created attachment 45627 [details]
HMS zip
Comment 2 _ krystyna 2007-07-25 00:45:13 UTC
Created attachment 45628 [details]
linebreaks
Comment 3 _ krystyna 2007-07-25 00:46:09 UTC
Created attachment 45629 [details]
HMSswitchjsp
Comment 4 _ krystyna 2007-07-25 00:47:00 UTC
Created attachment 45630 [details]
HMSswitchmMenu
Comment 5 Peter Zavadsky 2007-07-25 08:00:34 UTC
This issue is now blocked by issue #110872. I can't get the designer loaded due to the issue.
Comment 6 Peter Zavadsky 2007-07-26 08:16:19 UTC
Yes it is there, basically after switching from to jsp and back the fields are shifted. Refreshing fixes the issue.
Investigating.
Comment 7 Peter Zavadsky 2007-07-26 08:29:59 UTC
It seems that page relayout kicks in (it is triggered if the page is fragment or contains fragments, which is this
case), and it leads to different result (which is incorrect) than when it is laid out for the first time.
It seems there is some issue with the layout architecture.
Comment 8 Peter Zavadsky 2007-07-26 11:46:25 UTC
Fixed. Now the widths won't get changed.

Checking in visualweb/designer/src/org/netbeans/modules/visualweb/css2/PageBox.java;
/cvs/visualweb/designer/src/org/netbeans/modules/visualweb/css2/PageBox.java,v  <--  PageBox.java
new revision: 1.16; previous revision: 1.15
done


Note: Sometimes I've run into strange 'livelock' when switching into JSP tab. I am not sure it was caused by
intermediate state (when fixing), afterwards it seems OK. If you run into it too, file a bug against JSP editor.
Comment 9 _ krystyna 2007-07-26 22:17:18 UTC
In 07026 (deadlock zip build 2059 - your fix was in build 2054) I see  #1 issue is still there: on initial open, the 
linebreaks are still there after resizing the width amply followed by a refresh, i.e. "Clinical" should not be on 
separate line from "View" and so on and that means that #3 is still there: if I open mainMenu.jsp and then
switch to Welcome.jsp the line breaks don't happen as previously mentioned, also e.g "Outreach Scheduling".
Comment 10 Peter Zavadsky 2007-07-27 08:20:24 UTC
Whether the lines break or not depends on the size of the viewport. You can play with the width of browser too to see
the effect.
Here in designer the correct breakage is after the refresh. Incorrect is after the switch to other window and back (the
width exceeds the containing block). That needs to be fixed, to have the same effect.
That is one issue, other is that even after making the designer width large enough, it still breaks (after the refresh).
It might be another serious layout issue.
Comment 11 Peter Zavadsky 2007-07-27 12:15:10 UTC
Fixed. This fixes the relayout part (except the fragments in the page).  It might also cause some performance issue. The
problem is that it seems that the layout depends on computing of the css values, which seems to be incorrect.

Checking in visualweb/designer/src/org/netbeans/modules/visualweb/css2/DocumentBox.java;
/cvs/visualweb/designer/src/org/netbeans/modules/visualweb/css2/DocumentBox.java,v  <--  DocumentBox.java
new revision: 1.9; previous revision: 1.8
done
Checking in visualweb/designer/src/org/netbeans/modules/visualweb/css2/PageBox.java;
/cvs/visualweb/designer/src/org/netbeans/modules/visualweb/css2/PageBox.java,v  <--  PageBox.java
new revision: 1.17; previous revision: 1.16
done
Comment 12 Peter Zavadsky 2007-08-02 11:38:38 UTC
It seems the problem is the layout depends on the computing of css values, and they can't be divided to two or more
usages at the same time. Investigating more.
Comment 13 Peter Zavadsky 2007-08-03 13:15:46 UTC
To the other part of issue (breaking the lines):
There seems to be some computing problem (in layout).
Look in CssBox#computeHorizNonInlineNormalFlow method. There yields for contentWidth of some ContainerBox -13, which
doesn't seem to be correct.
Comment 14 Peter Zavadsky 2007-08-07 01:28:06 UTC
It seems the problem is in resolving the width css value for the UL element. Continuing to investigate.
Comment 15 Peter Zavadsky 2007-08-08 00:49:55 UTC
Fixed.
It was issue with relayout (layout) of included fragments. There are still internal issues with the architecture, but
the supported (basic) scenario should work now.

Checking in visualweb/designer/cssengine/src/org/netbeans/modules/visualweb/designer/cssengine/CssEngineServiceImpl.java;
/cvs/visualweb/designer/cssengine/src/org/netbeans/modules/visualweb/designer/cssengine/CssEngineServiceImpl.java,v  <--
 CssEngineServiceImpl.java
new revision: 1.17; previous revision: 1.16
done
Checking in visualweb/designer/cssengine/src/org/netbeans/modules/visualweb/designer/cssengine/DesignerContext.java;
/cvs/visualweb/designer/cssengine/src/org/netbeans/modules/visualweb/designer/cssengine/DesignerContext.java,v  <-- 
DesignerContext.java
new revision: 1.2; previous revision: 1.1
done
Checking in visualweb/designer/cssengine/src/org/netbeans/modules/visualweb/spi/designer/cssengine/CssUserAgentInfo.java;
/cvs/visualweb/designer/cssengine/src/org/netbeans/modules/visualweb/spi/designer/cssengine/CssUserAgentInfo.java,v  <--
 CssUserAgentInfo.java
new revision: 1.2; previous revision: 1.1
done
Checking in visualweb/designer/jsf/src/org/netbeans/modules/visualweb/designer/jsf/CssUserAgentInfoImpl.java;
/cvs/visualweb/designer/jsf/src/org/netbeans/modules/visualweb/designer/jsf/CssUserAgentInfoImpl.java,v  <-- 
CssUserAgentInfoImpl.java
new revision: 1.2; previous revision: 1.1
done
Checking in visualweb/designer/jsf/src/org/netbeans/modules/visualweb/designer/jsf/JsfForm.java;
/cvs/visualweb/designer/jsf/src/org/netbeans/modules/visualweb/designer/jsf/JsfForm.java,v  <--  JsfForm.java
new revision: 1.95; previous revision: 1.94
done
Checking in visualweb/designer/src/org/netbeans/modules/visualweb/css2/JspIncludeBox.java;
/cvs/visualweb/designer/src/org/netbeans/modules/visualweb/css2/JspIncludeBox.java,v  <--  JspIncludeBox.java
new revision: 1.7; previous revision: 1.6
done
Comment 16 _ krystyna 2007-08-09 00:41:53 UTC
Verified fixed in IDE Dev (Build 200708081200) 
Java: 1.6.0_02-ea; Java HotSpot(TM) Client VM 1.6.0_02-ea-b02 
Java: 1.5.0_12; Java HotSpot(TM) Client VM 1.5.0_12-b04
System: Windows XP version 5.1 running on x86; Cp1252; en_US (nb).

Looks good on IntelMac (jdk1.5.0_07) too.