partially updated styles
git-svn-id: http://svn.research-infrastructures.eu/public/d4science/gcube/trunk/portlets/user/reports@69207 82a268e6-3cf1-43bd-a215-b396298e98cf
|
@ -37,7 +37,9 @@ import org.gcube.portlets.user.reportgenerator.client.targets.Coords;
|
|||
import org.gcube.portlets.user.reportgenerator.client.targets.D4sRichTextarea;
|
||||
import org.gcube.portlets.user.reportgenerator.client.targets.DroppingArea;
|
||||
import org.gcube.portlets.user.reportgenerator.client.targets.GenericTable;
|
||||
import org.gcube.portlets.user.reportgenerator.client.targets.GroupingDelimiterArea;
|
||||
import org.gcube.portlets.user.reportgenerator.client.targets.ImageArea;
|
||||
import org.gcube.portlets.user.reportgenerator.client.targets.RepeatableSequence;
|
||||
import org.gcube.portlets.user.reportgenerator.client.targets.ReportTextArea;
|
||||
import org.gcube.portlets.user.reportgenerator.client.targets.TSArea;
|
||||
import org.gcube.portlets.user.reportgenerator.shared.SessionInfo;
|
||||
|
@ -934,7 +936,9 @@ public class Presenter {
|
|||
switch (component.getType()) {
|
||||
case HEADING_1:
|
||||
case HEADING_2:
|
||||
case HEADING_3:
|
||||
case HEADING_3:
|
||||
case HEADING_4:
|
||||
case HEADING_5:
|
||||
case TITLE:
|
||||
if (component.isLocked()) {
|
||||
HTML text = (HTML) component.getContent();
|
||||
|
@ -1009,6 +1013,14 @@ public class Presenter {
|
|||
HTML instr = (HTML) component.getContent();
|
||||
wp.addComponentToLayout(instr, component.isDoubleColLayout());
|
||||
break;
|
||||
case REPEAT_SEQUENCE_DELIMITER:
|
||||
GroupingDelimiterArea gpa = (GroupingDelimiterArea) component.getContent();
|
||||
wp.addComponentToLayout(gpa, component.isDoubleColLayout());
|
||||
break;
|
||||
case REPEAT_SEQUENCE:
|
||||
RepeatableSequence rps = (RepeatableSequence) component.getContent();
|
||||
wp.addComponentToLayout(rps, component.isDoubleColLayout());
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -65,11 +65,10 @@ public class WorkspacePanel extends Composite {
|
|||
presenter = c;
|
||||
|
||||
templateModel = presenter.getModel();
|
||||
|
||||
mainLayout.setSize(""+templateModel.getPageWidth(), ""+templateModel.getPageHeight());
|
||||
mainLayout.setSize(""+(templateModel.getPageWidth()), ""+templateModel.getPageHeight());
|
||||
|
||||
mainLayout.setStyleName("wpFlow");
|
||||
|
||||
//mainLayout.setStyleName("wpFlow");
|
||||
//mainLayout.addStyleName("position-relative");
|
||||
|
||||
|
||||
initWidget(mainLayout);
|
||||
|
|
|
@ -10,6 +10,7 @@ import org.gcube.portlets.d4sreporting.common.shared.Metadata;
|
|||
import org.gcube.portlets.d4sreporting.common.shared.SerializableAttribute;
|
||||
import org.gcube.portlets.d4sreporting.common.shared.SerializableAttributeArea;
|
||||
import org.gcube.portlets.d4sreporting.common.shared.SerializableComponent;
|
||||
import org.gcube.portlets.d4sreporting.common.shared.SerializableRepeatableSequence;
|
||||
import org.gcube.portlets.d4sreporting.common.shared.SerializableTable;
|
||||
import org.gcube.portlets.d4sreporting.common.shared.SerializableTimeSeries;
|
||||
import org.gcube.portlets.user.reportgenerator.client.Presenter.Presenter;
|
||||
|
@ -20,7 +21,10 @@ import org.gcube.portlets.user.reportgenerator.client.targets.DropImageListener;
|
|||
import org.gcube.portlets.user.reportgenerator.client.targets.DropTSListener;
|
||||
import org.gcube.portlets.user.reportgenerator.client.targets.DroppingArea;
|
||||
import org.gcube.portlets.user.reportgenerator.client.targets.GenericTable;
|
||||
import org.gcube.portlets.user.reportgenerator.client.targets.GroupingDelimiterArea;
|
||||
import org.gcube.portlets.user.reportgenerator.client.targets.GroupingInnerArea;
|
||||
import org.gcube.portlets.user.reportgenerator.client.targets.ImageArea;
|
||||
import org.gcube.portlets.user.reportgenerator.client.targets.RepeatableSequence;
|
||||
import org.gcube.portlets.user.reportgenerator.client.targets.ReportTextArea;
|
||||
import org.gcube.portlets.user.reportgenerator.client.targets.TSArea;
|
||||
|
||||
|
@ -195,19 +199,21 @@ public class TemplateComponent {
|
|||
break;
|
||||
case HEADING_1:
|
||||
case HEADING_2:
|
||||
case HEADING_3:
|
||||
case HEADING_3:
|
||||
case HEADING_4:
|
||||
case HEADING_5:
|
||||
case TITLE:
|
||||
if (sc.isLocked()) {
|
||||
HTML area = new HTML();
|
||||
area.setStyleName(getStyle(sc.getType()));
|
||||
area.getElement().getStyle().setMarginLeft(25, Unit.PX);
|
||||
area.getElement().getStyle().setMarginTop(15, Unit.PX);
|
||||
area.setPixelSize(width, height);
|
||||
area.setPixelSize(width, 25);
|
||||
area.setText((String) sc.getPossibleContent());
|
||||
this.content = area;
|
||||
}
|
||||
else {
|
||||
BasicTextArea bToAdd = new BasicTextArea(sc.getType(), presenter, sc.getX(), sc.getY(), width, height, getUserComments() != null);
|
||||
BasicTextArea bToAdd = new BasicTextArea(sc.getType(), presenter, sc.getX(), sc.getY(), width, 25, getUserComments() != null);
|
||||
bToAdd.setText((String) sc.getPossibleContent());
|
||||
this.content = bToAdd;
|
||||
}
|
||||
|
@ -294,6 +300,22 @@ public class TemplateComponent {
|
|||
|
||||
this.content = tsa;
|
||||
break;
|
||||
case REPEAT_SEQUENCE_DELIMITER:
|
||||
GroupingDelimiterArea gp = new GroupingDelimiterArea();
|
||||
this.content = gp;
|
||||
break;
|
||||
case REPEAT_SEQUENCE_INNER:
|
||||
GroupingInnerArea spacer = new GroupingInnerArea();
|
||||
this.content = spacer;
|
||||
break;
|
||||
case REPEAT_SEQUENCE:
|
||||
GWT.log("FOUND SEQUENCE trying getGroup");
|
||||
SerializableRepeatableSequence serializableRepeatableSequence = (SerializableRepeatableSequence) sc.getPossibleContent();
|
||||
|
||||
GWT.log("getGroup: " + serializableRepeatableSequence.toString());
|
||||
|
||||
RepeatableSequence rps = new RepeatableSequence(presenter, serializableRepeatableSequence);
|
||||
this.content = rps;
|
||||
}
|
||||
}
|
||||
/**
|
||||
|
@ -311,6 +333,10 @@ public class TemplateComponent {
|
|||
return "headgin2Area";
|
||||
case HEADING_3:
|
||||
return "headgin3Area";
|
||||
case HEADING_4:
|
||||
return "headgin4Area";
|
||||
case HEADING_5:
|
||||
return "headgin5Area";
|
||||
default:
|
||||
return "";
|
||||
}
|
||||
|
|
|
@ -35,7 +35,7 @@ public class AttributeArea extends Composite {
|
|||
myPanel.addStyleName("attributeArea");
|
||||
|
||||
attrName = new HTML(getAttributeName(textToDisplay));
|
||||
attrName.getElement().getStyle().setMarginLeft(10, Unit.PX);
|
||||
attrName.getElement().getStyle().setMarginLeft(25, Unit.PX);
|
||||
attrName.getElement().getStyle().setMarginRight(5, Unit.PX);
|
||||
HorizontalPanel boxesPanel = new HorizontalPanel();
|
||||
boxesPanel.add(attrName);
|
||||
|
|
|
@ -41,23 +41,32 @@ public class BasicTextArea extends ReportTextArea {
|
|||
presenter.storeChangeInSession((Widget) event.getSource());
|
||||
}
|
||||
});
|
||||
textArea.setStyleName("report-ui-component");
|
||||
switch (type) {
|
||||
case TITLE:
|
||||
textArea.setStyleName("titleArea");
|
||||
textArea.addStyleName("title");
|
||||
myPanel.setTitle("Title");
|
||||
break;
|
||||
case HEADING_1:
|
||||
textArea.setStyleName("headgin1Area");
|
||||
textArea.addStyleName("heading1");
|
||||
myPanel.setTitle("Heading: Level 1");
|
||||
break;
|
||||
case HEADING_2:
|
||||
textArea.setStyleName("headgin2Area");
|
||||
textArea.addStyleName("heading2");
|
||||
myPanel.setTitle("Heading Level 2");
|
||||
break;
|
||||
case HEADING_3:
|
||||
textArea.setStyleName("headgin3Area");
|
||||
textArea.addStyleName("heading3");
|
||||
myPanel.setTitle("Heading: Level 3");
|
||||
break;
|
||||
case HEADING_4:
|
||||
textArea.addStyleName("heading4");
|
||||
myPanel.setTitle("Heading: Level 4");
|
||||
break;
|
||||
case HEADING_5:
|
||||
textArea.addStyleName("heading5");
|
||||
myPanel.setTitle("Heading: Level 5");
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
|
|
@ -0,0 +1,15 @@
|
|||
package org.gcube.portlets.user.reportgenerator.client.targets;
|
||||
|
||||
import com.google.gwt.user.client.ui.HTML;
|
||||
|
||||
|
||||
|
||||
public class GroupingDelimiterArea extends HTML {
|
||||
|
||||
public GroupingDelimiterArea() {
|
||||
super();
|
||||
setWidth("700px");
|
||||
setHeight("15px");
|
||||
setStyleName("grouping-border");
|
||||
}
|
||||
}
|
|
@ -0,0 +1,13 @@
|
|||
package org.gcube.portlets.user.reportgenerator.client.targets;
|
||||
|
||||
import com.google.gwt.user.client.ui.HTML;
|
||||
|
||||
public class GroupingInnerArea extends HTML {
|
||||
|
||||
public GroupingInnerArea() {
|
||||
super();
|
||||
setWidth("700px");
|
||||
setHeight("5px");
|
||||
setStyleName("grouping-inner");
|
||||
}
|
||||
}
|
|
@ -0,0 +1,70 @@
|
|||
package org.gcube.portlets.user.reportgenerator.client.targets;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
||||
import org.gcube.portlets.d4sreporting.common.client.uicomponents.ReportUIComponent;
|
||||
import org.gcube.portlets.d4sreporting.common.shared.ComponentType;
|
||||
import org.gcube.portlets.d4sreporting.common.shared.SerializableComponent;
|
||||
import org.gcube.portlets.d4sreporting.common.shared.SerializableRepeatableSequence;
|
||||
import org.gcube.portlets.user.reportgenerator.client.Presenter.Presenter;
|
||||
import org.gcube.portlets.user.reportgenerator.client.model.TemplateComponent;
|
||||
import org.gcube.portlets.user.reportgenerator.client.model.TemplateModel;
|
||||
|
||||
import com.google.gwt.core.client.GWT;
|
||||
import com.google.gwt.user.client.ui.VerticalPanel;
|
||||
|
||||
public class RepeatableSequence extends ReportUIComponent {
|
||||
private ArrayList<TemplateComponent> groupedComponents = new ArrayList<TemplateComponent>();
|
||||
|
||||
VerticalPanel myPanel;
|
||||
Presenter p;
|
||||
|
||||
|
||||
/**
|
||||
* constructor used by the system when reading the model
|
||||
* @param sRS
|
||||
*/
|
||||
public RepeatableSequence(Presenter p, SerializableRepeatableSequence sRS) {
|
||||
super(ComponentType.REPEAT_SEQUENCE, 0, 0, TemplateModel.TEMPLATE_WIDTH - 50, sRS.getHeight());
|
||||
this.p = p;
|
||||
myPanel = getResizablePanel();
|
||||
|
||||
int size = sRS.getGroupedComponents().size();
|
||||
for (int j = 0; j < size; j++) {
|
||||
SerializableComponent sComp = sRS.getGroupedComponents().get(j);
|
||||
add(new TemplateComponent(p.getModel(), sComp, p));
|
||||
}
|
||||
}
|
||||
|
||||
public void add(TemplateComponent toAdd) {
|
||||
groupedComponents.add(toAdd);
|
||||
GWT.log("toAdd.getContent()= NULL? " + (toAdd.getContent() == null));
|
||||
GWT.log("ToAdd= getType " + toAdd.getType());
|
||||
myPanel.add(toAdd.getContent());
|
||||
}
|
||||
|
||||
|
||||
public ArrayList<TemplateComponent> getGroupedComponents() {
|
||||
return groupedComponents;
|
||||
}
|
||||
|
||||
public void setGroupedComponents(ArrayList<TemplateComponent> groupedComponents) {
|
||||
this.groupedComponents = groupedComponents;
|
||||
}
|
||||
|
||||
public int getHeight() {
|
||||
return super.mainPanel.getOffsetHeight();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void removeTemplateComponent(ReportUIComponent toRemove) {
|
||||
// TODO Auto-generated method stub
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void lockComponent(ReportUIComponent toLock, boolean locked) {
|
||||
// TODO Auto-generated method stub
|
||||
|
||||
}
|
||||
}
|
|
@ -1,3 +1,16 @@
|
|||
.grouping-inner {
|
||||
background: url('images/grouping-border.png') repeat-x;
|
||||
display: block;
|
||||
height: 4px;
|
||||
width: 600px;
|
||||
}
|
||||
|
||||
.grouping-border {
|
||||
background: url('images/grouping-border.png') repeat-x;
|
||||
display: block;
|
||||
height: 8px;
|
||||
width: 600px;
|
||||
}
|
||||
|
||||
.tableBorder {
|
||||
border: 1px solid #CCC;
|
||||
|
@ -26,7 +39,7 @@
|
|||
|
||||
.comment-popup-textarea {
|
||||
background-color: #FFF8CC;
|
||||
border:none;
|
||||
border: none;
|
||||
font-family: Arial, Helvetica, sans-serif;
|
||||
font-size: 11px;
|
||||
}
|
||||
|
@ -51,15 +64,12 @@ tableBorder td {
|
|||
}
|
||||
|
||||
.wpFlow {
|
||||
border: 0px solid gray;
|
||||
border: none;
|
||||
margin-left: 20px;
|
||||
}
|
||||
|
||||
.highlight_background {
|
||||
background-color: #FFFE00;
|
||||
/* filter:alpha(opacity=80);
|
||||
-moz-opacity:0.8;
|
||||
-khtml-opacity: 0.8;
|
||||
opacity: 0.8;*/
|
||||
}
|
||||
|
||||
.none {
|
||||
|
@ -73,12 +83,6 @@ tableBorder td {
|
|||
border: none;
|
||||
}
|
||||
|
||||
.d4sFrame {
|
||||
border: 1px dashed #CCC;
|
||||
background-color: white;
|
||||
margin-top: 15px;
|
||||
margin-left: 15px;
|
||||
}
|
||||
|
||||
.fixedTextArea {
|
||||
font-family: Times;
|
||||
|
@ -89,8 +93,6 @@ tableBorder td {
|
|||
border: 1px dashed #CCC;
|
||||
background-image: url(images/droppingImage_bg.gif);
|
||||
background-repeat: repeat;
|
||||
margin-top: 25px;
|
||||
margin-left: 15px;
|
||||
}
|
||||
|
||||
.label {
|
||||
|
@ -165,8 +167,6 @@ tableBorder td {
|
|||
.timeseriesArea {
|
||||
border: 1px dashed #CCC;
|
||||
background-repeat: repeat;
|
||||
margin-top: 25px;
|
||||
margin-left: 15px;
|
||||
}
|
||||
|
||||
.d4sRichTextArea {
|
||||
|
@ -179,8 +179,6 @@ tableBorder td {
|
|||
.commentArea {
|
||||
background-image: url(images/comment_area.gif);
|
||||
background-repeat: no-repeat;
|
||||
margin-top: 15px;
|
||||
margin-left: 20px;
|
||||
padding-left: 15px;
|
||||
border: 0px solid gray;
|
||||
font-family: Verdana, Geneva, Arial, Helvetica, sans-serif;
|
||||
|
@ -190,11 +188,9 @@ tableBorder td {
|
|||
}
|
||||
|
||||
.attributeArea {
|
||||
background-image: url(images/attribute_area.gif);
|
||||
background-image: url(images/attribute_area.png);
|
||||
background-repeat: no-repeat;
|
||||
margin-top: 15px;
|
||||
margin-left: 20px;
|
||||
padding-left: 15px;
|
||||
padding-left: 20px;
|
||||
border: 1px dashed #CCC;
|
||||
font-family: Verdana, Geneva, Arial, Helvetica, sans-serif;
|
||||
font-size: 12px;
|
||||
|
@ -209,17 +205,18 @@ tableBorder td {
|
|||
}
|
||||
|
||||
.instructionArea {
|
||||
background-image: url(images/instruction_area.gif);
|
||||
margin-top: 5px;
|
||||
background-image: url(images/instruction_area.png);
|
||||
background-repeat: no-repeat;
|
||||
margin-top: 15px;
|
||||
margin-left: 20px;
|
||||
padding-left: 15px;
|
||||
border: 0px solid gray;
|
||||
font-family: Verdana, Geneva, Arial, Helvetica, sans-serif;
|
||||
font-size: 12px;
|
||||
font-family: "Courier New", Courier, monospace;
|
||||
font-size: 11px;
|
||||
color: #666;
|
||||
height: 20px;
|
||||
padding-left: 20px;
|
||||
padding-top: 8px;
|
||||
}
|
||||
|
||||
.gridAttribute {
|
||||
|
@ -233,56 +230,50 @@ tableBorder td {
|
|||
background-repeat: repeat-x;
|
||||
}
|
||||
|
||||
.titleArea {
|
||||
background-image: url(images/title_area.png);
|
||||
.d4sFrame {
|
||||
border: 1px dashed #CCC;
|
||||
background-color: white;
|
||||
margin-top: 5px;
|
||||
}
|
||||
|
||||
|
||||
.report-ui-component {
|
||||
background-repeat: no-repeat;
|
||||
padding-top: 5px;
|
||||
padding-left: 20px;
|
||||
margin-left: 0px;
|
||||
color: maroon;
|
||||
font-family: Verdana;
|
||||
border: none;
|
||||
font-family: Times;
|
||||
padding-top: 2px;
|
||||
padding-left: 20px;
|
||||
}
|
||||
|
||||
.title {
|
||||
background-image: url(images/title.png);
|
||||
font-size: 16pt;
|
||||
font-family: Verdana;
|
||||
color: maroon;
|
||||
}
|
||||
|
||||
.headgin1Area {
|
||||
.heading1 {
|
||||
background-image: url(images/heading_1.png);
|
||||
background-repeat: no-repeat;
|
||||
padding-top: 5px;
|
||||
padding-left: 20px;
|
||||
margin-left: 0px;
|
||||
border: none;
|
||||
font-family: Times;
|
||||
font-size: 12pt;
|
||||
font-family: Verdana;
|
||||
color: maroon;
|
||||
}
|
||||
|
||||
.headgin2Area {
|
||||
.heading2 {
|
||||
background-image: url(images/heading_2.png);
|
||||
background-repeat: no-repeat;
|
||||
padding-top: 5px;
|
||||
padding-left: 20px;
|
||||
margin-left: 0px;
|
||||
border: none;
|
||||
font-family: Times;
|
||||
font-size: 11pt;
|
||||
font-family: Verdana;
|
||||
color: maroon;
|
||||
}
|
||||
|
||||
.headgin3Area {
|
||||
.heading3 {
|
||||
background-image: url(images/heading_3.png);
|
||||
background-repeat: no-repeat;
|
||||
padding-top: 5px;
|
||||
padding-left: 20px;
|
||||
margin-left: 0px;
|
||||
border: none;
|
||||
font-family: Times;
|
||||
font-size: 10pt;
|
||||
font-family: Verdana;
|
||||
color: maroon;
|
||||
}
|
||||
|
||||
.heading4 {
|
||||
background-image: url(images/heading_4.png);
|
||||
font-size: 9pt;
|
||||
}
|
||||
|
||||
.heading5Area {
|
||||
background-image: url(images/heading_5.png);
|
||||
font-size: 8pt;
|
||||
}
|
||||
|
||||
.bodyArea {
|
||||
|
@ -319,8 +310,6 @@ tableBorder td {
|
|||
|
||||
.d4sFrame-highlight {
|
||||
background-color: #e4f2f6;
|
||||
filter: alpha(opacity = 50);
|
||||
-moz-opacity: .50;
|
||||
opacity: .50;
|
||||
cursor: pointer;
|
||||
cursor: hand;
|
||||
|
|
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 143 B |
Before Width: | Height: | Size: 675 B |
Before Width: | Height: | Size: 2.9 KiB After Width: | Height: | Size: 1.0 KiB |
Before Width: | Height: | Size: 683 B |
Before Width: | Height: | Size: 2.9 KiB After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 662 B |
Before Width: | Height: | Size: 2.9 KiB After Width: | Height: | Size: 1.1 KiB |
Before Width: | Height: | Size: 2.9 KiB After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 1.0 KiB |
After Width: | Height: | Size: 1.0 KiB |
After Width: | Height: | Size: 1.1 KiB |
After Width: | Height: | Size: 1.0 KiB |
Before Width: | Height: | Size: 3.1 KiB After Width: | Height: | Size: 1.0 KiB |