src/org/simantics/databoard/standardTypes.dbt,\\r
examples/,\\r
testcases/,\\r
- doc-isv/\r
+ src-isv/\r
.,\\r
plugin.xml,\\r
webdefault.xml,\\r
- scl/,\\r
+ scl/\r
src.includes = scl/\r
\r
SG.Node.children _ : L0.List
@L0.list
_ : VIEWS.Composite
- VIEWS.Composite.layout _ : VIEWS.GridLayout
- VIEWS.GridLayout.columnCount 19
+ VIEWS.Composite.layout _ : VIEWS.RowLayout
+ //VIEWS.RowLayout.type VIEWS.Control.Style.Constant.Horizontal
+ //VIEWS.RowLayout.spacing 0
+ //VIEWS.RowLayout.justify true
+ //VIEWS.RowLayout.pack true
+ //VIEWS.RowLayout.wrap true
VIEWS.Control.layoutData _ : VIEWS.GridLayout.GridData
VIEWS.GridLayout.GridData.horizontalGrab true
SG.Node.children _ : L0.List
VIEWS.Button.tooltip "Makes selection bold or inserts some bold text at cursor"
VIEWS.Button.modifier UI.Functions.boldModifier : L0.Function
VIEWS.Button.image SILK.text_bold
- VIEWS.Control.layoutData _ : VIEWS.GridLayout.GridData
- VIEWS.GridLayout.GridData.horizontalAlignment VIEWS.GridLayout.GridData.BEGINNING
- VIEWS.GridLayout.GridData.verticalAlignment VIEWS.GridLayout.GridData.BEGINNING
+ VIEWS.Control.layoutData _ : VIEWS.RowLayout.RowData
_ : VIEWS.Button
VIEWS.Button.tooltip "Makes selection italic or inserts some italic text at cursor"
VIEWS.Button.modifier UI.Functions.italicModifier : L0.Function
VIEWS.Button.image SILK.text_italic
- VIEWS.Control.layoutData _ : VIEWS.GridLayout.GridData
- VIEWS.GridLayout.GridData.horizontalAlignment VIEWS.GridLayout.GridData.BEGINNING
- VIEWS.GridLayout.GridData.verticalAlignment VIEWS.GridLayout.GridData.BEGINNING
+ VIEWS.Control.layoutData _ : VIEWS.RowLayout.RowData
_ : VIEWS.Button
VIEWS.Button.tooltip "Makes selection strikethrough or inserts some strikethrough text at cursor"
VIEWS.Button.modifier UI.Functions.strikethroughModifier : L0.Function
VIEWS.Button.image SILK.text_strikethrough
- VIEWS.Control.layoutData _ : VIEWS.GridLayout.GridData
- VIEWS.GridLayout.GridData.horizontalAlignment VIEWS.GridLayout.GridData.BEGINNING
- VIEWS.GridLayout.GridData.verticalAlignment VIEWS.GridLayout.GridData.BEGINNING
+ VIEWS.Control.layoutData _ : VIEWS.RowLayout.RowData
_ : VIEWS.Button
VIEWS.Button.tooltip "Makes selection underlined or inserts some underlined text at cursor"
VIEWS.Button.modifier UI.Functions.underlineModifier : L0.Function
VIEWS.Button.image SILK.text_underline
- VIEWS.Control.layoutData _ : VIEWS.GridLayout.GridData
- VIEWS.GridLayout.GridData.horizontalAlignment VIEWS.GridLayout.GridData.BEGINNING
- VIEWS.GridLayout.GridData.verticalAlignment VIEWS.GridLayout.GridData.BEGINNING
+ VIEWS.Control.layoutData _ : VIEWS.RowLayout.RowData
_ : VIEWS.Button
VIEWS.Button.tooltip "Inserts a horizontal ruler at cursor"
VIEWS.Button.modifier UI.Functions.horizontalRulerModifier : L0.Function
VIEWS.Button.image SILK.text_horizontalrule
- VIEWS.Control.layoutData _ : VIEWS.GridLayout.GridData
- VIEWS.GridLayout.GridData.horizontalAlignment VIEWS.GridLayout.GridData.BEGINNING
- VIEWS.GridLayout.GridData.verticalAlignment VIEWS.GridLayout.GridData.BEGINNING
+ VIEWS.Control.layoutData _ : VIEWS.RowLayout.RowData
_ : VIEWS.Button
VIEWS.Button.tooltip "Indents text"
VIEWS.Button.modifier UI.Functions.indentModifier : L0.Function
VIEWS.Button.image SILK.text_indent
- VIEWS.Control.layoutData _ : VIEWS.GridLayout.GridData
- VIEWS.GridLayout.GridData.horizontalAlignment VIEWS.GridLayout.GridData.BEGINNING
- VIEWS.GridLayout.GridData.verticalAlignment VIEWS.GridLayout.GridData.BEGINNING
+ VIEWS.Control.layoutData _ : VIEWS.RowLayout.RowData
_ : VIEWS.Button
VIEWS.Button.tooltip "Modifies selection font or inserts text with font settings"
VIEWS.Button.modifier UI.Functions.fontModifier : L0.Function
VIEWS.Button.image SILK.font
- VIEWS.Control.layoutData _ : VIEWS.GridLayout.GridData
- VIEWS.GridLayout.GridData.horizontalAlignment VIEWS.GridLayout.GridData.BEGINNING
- VIEWS.GridLayout.GridData.verticalAlignment VIEWS.GridLayout.GridData.BEGINNING
+ VIEWS.Control.layoutData _ : VIEWS.RowLayout.RowData
_ : VIEWS.Button
VIEWS.Button.tooltip "Inserts an image"
VIEWS.Button.modifier UI.Functions.imageModifier : L0.Function
VIEWS.Button.image SILK.image
- VIEWS.Control.layoutData _ : VIEWS.GridLayout.GridData
- VIEWS.GridLayout.GridData.horizontalAlignment VIEWS.GridLayout.GridData.BEGINNING
- VIEWS.GridLayout.GridData.verticalAlignment VIEWS.GridLayout.GridData.BEGINNING
+ VIEWS.Control.layoutData _ : VIEWS.RowLayout.RowData
+ _ : VIEWS.Button
+ VIEWS.Button.tooltip "Inserts an internal model-specific document link"
+ VIEWS.Button.modifier UI.Functions.internalLinkModifier : L0.Function
+ VIEWS.Button.image SILK.database_link
+ VIEWS.Control.layoutData _ : VIEWS.RowLayout.RowData
+ _ : VIEWS.Button
+ VIEWS.Button.tooltip "Inserts an external website link"
+ VIEWS.Button.modifier UI.Functions.linkModifier : L0.Function
+ VIEWS.Button.image SILK.world_link
+ VIEWS.Control.layoutData _ : VIEWS.RowLayout.RowData
_ : VIEWS.Button
VIEWS.Button.tooltip "Inserts a 1st level header"
VIEWS.Button.modifier UI.Functions.header1Modifier : L0.Function
VIEWS.Button.image SILK.text_heading_1
- VIEWS.Control.layoutData _ : VIEWS.GridLayout.GridData
- VIEWS.GridLayout.GridData.horizontalAlignment VIEWS.GridLayout.GridData.BEGINNING
- VIEWS.GridLayout.GridData.verticalAlignment VIEWS.GridLayout.GridData.BEGINNING
+ VIEWS.Control.layoutData _ : VIEWS.RowLayout.RowData
_ : VIEWS.Button
VIEWS.Button.tooltip "Inserts a 2nd level header"
VIEWS.Button.modifier UI.Functions.header2Modifier : L0.Function
VIEWS.Button.image SILK.text_heading_2
- VIEWS.Control.layoutData _ : VIEWS.GridLayout.GridData
- VIEWS.GridLayout.GridData.horizontalAlignment VIEWS.GridLayout.GridData.BEGINNING
- VIEWS.GridLayout.GridData.verticalAlignment VIEWS.GridLayout.GridData.BEGINNING
+ VIEWS.Control.layoutData _ : VIEWS.RowLayout.RowData
_ : VIEWS.Button
VIEWS.Button.tooltip "Inserts a 3rd level header"
VIEWS.Button.modifier UI.Functions.header3Modifier : L0.Function
VIEWS.Button.image SILK.text_heading_3
- VIEWS.Control.layoutData _ : VIEWS.GridLayout.GridData
- VIEWS.GridLayout.GridData.horizontalAlignment VIEWS.GridLayout.GridData.BEGINNING
- VIEWS.GridLayout.GridData.verticalAlignment VIEWS.GridLayout.GridData.BEGINNING
+ VIEWS.Control.layoutData _ : VIEWS.RowLayout.RowData
_ : VIEWS.Button
VIEWS.Button.tooltip "Inserts a 4th level header"
VIEWS.Button.modifier UI.Functions.header4Modifier : L0.Function
VIEWS.Button.image SILK.text_heading_4
- VIEWS.Control.layoutData _ : VIEWS.GridLayout.GridData
- VIEWS.GridLayout.GridData.horizontalAlignment VIEWS.GridLayout.GridData.BEGINNING
- VIEWS.GridLayout.GridData.verticalAlignment VIEWS.GridLayout.GridData.BEGINNING
+ VIEWS.Control.layoutData _ : VIEWS.RowLayout.RowData
_ : VIEWS.Button
VIEWS.Button.tooltip "Inserts a numbered list"
VIEWS.Button.modifier UI.Functions.numberedListModifier : L0.Function
VIEWS.Button.image SILK.text_list_numbers
- VIEWS.Control.layoutData _ : VIEWS.GridLayout.GridData
- VIEWS.GridLayout.GridData.horizontalAlignment VIEWS.GridLayout.GridData.BEGINNING
- VIEWS.GridLayout.GridData.verticalAlignment VIEWS.GridLayout.GridData.BEGINNING
+ VIEWS.Control.layoutData _ : VIEWS.RowLayout.RowData
_ : VIEWS.Button
VIEWS.Button.tooltip "Inserts a bullet list"
VIEWS.Button.modifier UI.Functions.bulletListModifier : L0.Function
VIEWS.Button.image SILK.text_list_bullets
- VIEWS.Control.layoutData _ : VIEWS.GridLayout.GridData
- VIEWS.GridLayout.GridData.horizontalAlignment VIEWS.GridLayout.GridData.BEGINNING
- VIEWS.GridLayout.GridData.verticalAlignment VIEWS.GridLayout.GridData.BEGINNING
+ VIEWS.Control.layoutData _ : VIEWS.RowLayout.RowData
_ : VIEWS.Button
VIEWS.Button.tooltip "Inserts a table"
VIEWS.Button.modifier UI.Functions.tableModifier : L0.Function
VIEWS.Button.image SILK.table
- VIEWS.Control.layoutData _ : VIEWS.GridLayout.GridData
- VIEWS.GridLayout.GridData.horizontalAlignment VIEWS.GridLayout.GridData.BEGINNING
- VIEWS.GridLayout.GridData.verticalAlignment VIEWS.GridLayout.GridData.BEGINNING
- _ : VIEWS.Button
- VIEWS.Button.tooltip "Inserts an external website link"
- VIEWS.Button.modifier UI.Functions.linkModifier : L0.Function
- VIEWS.Button.image SILK.link
- VIEWS.Control.layoutData _ : VIEWS.GridLayout.GridData
- VIEWS.GridLayout.GridData.horizontalAlignment VIEWS.GridLayout.GridData.BEGINNING
- VIEWS.GridLayout.GridData.verticalAlignment VIEWS.GridLayout.GridData.BEGINNING
+ VIEWS.Control.layoutData _ : VIEWS.RowLayout.RowData
_ : VIEWS.Button
VIEWS.Button.text "&Styles"
VIEWS.Button.tooltip "Edits document styles"
VIEWS.Button.modifier UI.Functions.styleModifier : L0.Function
- VIEWS.Control.layoutData _ : VIEWS.GridLayout.GridData
- VIEWS.GridLayout.GridData.horizontalAlignment VIEWS.GridLayout.GridData.BEGINNING
- VIEWS.GridLayout.GridData.verticalAlignment VIEWS.GridLayout.GridData.BEGINNING
+ VIEWS.Control.layoutData _ : VIEWS.RowLayout.RowData
_ : VIEWS.Button
VIEWS.Button.text "&Apply changes"
VIEWS.Button.tooltip "Applies any changes in the wiki markup into the document"
VIEWS.Button.modifier UI.Functions.wikitextModifier : L0.Function
- VIEWS.Control.layoutData _ : VIEWS.GridLayout.GridData
- VIEWS.GridLayout.GridData.horizontalAlignment VIEWS.GridLayout.GridData.BEGINNING
- VIEWS.GridLayout.GridData.verticalAlignment VIEWS.GridLayout.GridData.BEGINNING
+ VIEWS.Control.layoutData _ : VIEWS.RowLayout.RowData
_ : VIEWS.Button
VIEWS.Button.text "Delete document"
VIEWS.Button.tooltip "Deletes the document"
VIEWS.Button.modifier UI.Functions.onDeleteDocumentButton : L0.Function
- VIEWS.Control.layoutData _ : VIEWS.GridLayout.GridData
- VIEWS.GridLayout.GridData.horizontalAlignment VIEWS.GridLayout.GridData.BEGINNING
- VIEWS.GridLayout.GridData.verticalAlignment VIEWS.GridLayout.GridData.BEGINNING
+ VIEWS.Control.layoutData _ : VIEWS.RowLayout.RowData
UI.WikitextContribution.View.TextContainer : VIEWS.Composite
VIEWS.Control.layoutData _ : VIEWS.GridLayout.GridData
VIEWS.GridLayout.GridData.verticalGrab true
VIEWS.Browser.variable DOC.Functions.documentationRootVariable
VIEWS.Browser.document DOC.Functions.documentationText
+ VIEWS.Browser.locationChanging UI.Functions.locationChanging : L0.Function
+ L0.HasValueType "a -> Boolean"
UI.WikitextContribution.View
UI.NoDocument : VIEWS.Composite
public final Resource Functions_horizontalRulerModifier;\r
public final Resource Functions_imageModifier;\r
public final Resource Functions_indentModifier;\r
+ public final Resource Functions_internalLinkModifier;\r
public final Resource Functions_isWikitext;\r
public final Resource Functions_italicModifier;\r
public final Resource Functions_linkModifier;\r
+ public final Resource Functions_locationChanging;\r
public final Resource Functions_noDocumentText;\r
public final Resource Functions_numberedListModifier;\r
public final Resource Functions_onCreateDocumentButton;\r
public static final String Functions_horizontalRulerModifier = "http://www.simantics.org/DocumentUI-1.1/Functions/horizontalRulerModifier";\r
public static final String Functions_imageModifier = "http://www.simantics.org/DocumentUI-1.1/Functions/imageModifier";\r
public static final String Functions_indentModifier = "http://www.simantics.org/DocumentUI-1.1/Functions/indentModifier";\r
+ public static final String Functions_internalLinkModifier = "http://www.simantics.org/DocumentUI-1.1/Functions/internalLinkModifier";\r
public static final String Functions_isWikitext = "http://www.simantics.org/DocumentUI-1.1/Functions/isWikitext";\r
public static final String Functions_italicModifier = "http://www.simantics.org/DocumentUI-1.1/Functions/italicModifier";\r
public static final String Functions_linkModifier = "http://www.simantics.org/DocumentUI-1.1/Functions/linkModifier";\r
+ public static final String Functions_locationChanging = "http://www.simantics.org/DocumentUI-1.1/Functions/locationChanging";\r
public static final String Functions_noDocumentText = "http://www.simantics.org/DocumentUI-1.1/Functions/noDocumentText";\r
public static final String Functions_numberedListModifier = "http://www.simantics.org/DocumentUI-1.1/Functions/numberedListModifier";\r
public static final String Functions_onCreateDocumentButton = "http://www.simantics.org/DocumentUI-1.1/Functions/onCreateDocumentButton";\r
Functions_horizontalRulerModifier = getResourceOrNull(graph, URIs.Functions_horizontalRulerModifier);\r
Functions_imageModifier = getResourceOrNull(graph, URIs.Functions_imageModifier);\r
Functions_indentModifier = getResourceOrNull(graph, URIs.Functions_indentModifier);\r
+ Functions_internalLinkModifier = getResourceOrNull(graph, URIs.Functions_internalLinkModifier);\r
Functions_isWikitext = getResourceOrNull(graph, URIs.Functions_isWikitext);\r
Functions_italicModifier = getResourceOrNull(graph, URIs.Functions_italicModifier);\r
Functions_linkModifier = getResourceOrNull(graph, URIs.Functions_linkModifier);\r
+ Functions_locationChanging = getResourceOrNull(graph, URIs.Functions_locationChanging);\r
Functions_noDocumentText = getResourceOrNull(graph, URIs.Functions_noDocumentText);\r
Functions_numberedListModifier = getResourceOrNull(graph, URIs.Functions_numberedListModifier);\r
Functions_onCreateDocumentButton = getResourceOrNull(graph, URIs.Functions_onCreateDocumentButton);\r
*******************************************************************************/\r
package org.simantics.document.ui;\r
\r
+import org.eclipse.jface.action.Action;\r
+import org.eclipse.jface.action.IAction;\r
+import org.eclipse.swt.widgets.Composite;\r
+import org.eclipse.ui.IWorkbenchPart;\r
import org.simantics.ui.workbench.IPropertyPage;\r
+import org.simantics.utils.ui.BundleUtils;\r
import org.simantics.views.swt.ModelledView;\r
\r
/**\r
*/\r
public class DocumentView extends ModelledView {\r
\r
+ private boolean pinSelection = false;\r
+\r
@Override\r
protected String configurationURI() {\r
return DocumentUIResource.URIs.View;\r
return null;\r
}\r
\r
+ @Override\r
+ protected void inputChanged(IWorkbenchPart provider, Object input) {\r
+ if (pinSelection)\r
+ return;\r
+ super.inputChanged(provider, input);\r
+ }\r
+\r
+ @Override\r
+ public void createPartControl(Composite parent) {\r
+ super.createPartControl(parent);\r
+ getViewSite().getActionBars().getToolBarManager().add(new PinSelection());\r
+ }\r
+\r
+ private class PinSelection extends Action {\r
+ public PinSelection() {\r
+ super("Pin Selection", IAction.AS_CHECK_BOX);\r
+ setImageDescriptor(\r
+ BundleUtils.getImageDescriptorFromPlugin(\r
+ "org.eclipse.ui",\r
+ "icons/full/etool16/pin_editor.png"));\r
+ }\r
+\r
+ @Override\r
+ public void run() {\r
+ pinSelection = isChecked();\r
+ }\r
+ }\r
+\r
}\r
\r
import java.util.TreeMap;\r
\r
+import org.eclipse.core.runtime.IStatus;\r
+import org.eclipse.core.runtime.Status;\r
import org.eclipse.jface.viewers.ISelectionProvider;\r
import org.eclipse.jface.viewers.StructuredSelection;\r
+import org.eclipse.swt.browser.LocationEvent;\r
import org.eclipse.swt.graphics.FontData;\r
import org.eclipse.swt.graphics.Point;\r
import org.eclipse.swt.graphics.RGB;\r
import org.simantics.databoard.Bindings;\r
import org.simantics.db.ReadGraph;\r
import org.simantics.db.Resource;\r
+import org.simantics.db.Session;\r
import org.simantics.db.WriteGraph;\r
import org.simantics.db.common.request.ReadRequest;\r
+import org.simantics.db.common.request.UnaryRead;\r
import org.simantics.db.common.request.WriteRequest;\r
import org.simantics.db.common.utils.Logger;\r
import org.simantics.db.common.utils.NameUtils;\r
+import org.simantics.db.common.utils.RequestUtil;\r
import org.simantics.db.exception.DatabaseException;\r
import org.simantics.db.layer0.adapter.Instances;\r
import org.simantics.db.layer0.request.PossibleModel;\r
+import org.simantics.db.layer0.request.PossibleResource;\r
import org.simantics.db.layer0.util.RemoverUtil;\r
import org.simantics.db.layer0.variable.RVI;\r
import org.simantics.db.layer0.variable.Variable;\r
+import org.simantics.db.layer0.variable.Variables;\r
+import org.simantics.document.DocumentDialect;\r
import org.simantics.document.DocumentResource;\r
import org.simantics.document.DocumentUtils;\r
+import org.simantics.document.ui.Activator;\r
import org.simantics.document.ui.CSSEditor;\r
import org.simantics.layer0.Layer0;\r
import org.simantics.scenegraph.INode;\r
import org.simantics.scenegraph.loader.ScenegraphLoaderUtils;\r
import org.simantics.scenegraph.loader.ScenegraphLoaderUtils.ScenegraphPropertyReference;\r
import org.simantics.scl.reflection.annotations.SCLValue;\r
+import org.simantics.scl.runtime.function.Function1;\r
import org.simantics.scl.runtime.function.FunctionImpl1;\r
import org.simantics.scl.runtime.function.FunctionImpl3;\r
+import org.simantics.ui.SimanticsUI;\r
import org.simantics.ui.workbench.ResourceEditorInput2;\r
+import org.simantics.ui.workbench.action.DefaultActions;\r
import org.simantics.utils.threads.SWTThread;\r
import org.simantics.utils.ui.workbench.WorkbenchUtils;\r
\r
@Override\r
void perform(String before, String selected, String after, Point selection) {\r
\r
- textReference.setValue(before + "[[Image:root://Library/image.png|100px]]" + selected + after);\r
+ textReference.setValue(before + "[[Image:root://Library/image.png|100px]]" + "\r\n" + selected + after);\r
\r
}\r
\r
\r
}\r
\r
+ @SCLValue(type = "ReadGraph -> Resource -> Variable -> b")\r
+ public static Object internalLinkModifier(ReadGraph graph, Resource resource, final Variable context) throws DatabaseException {\r
+ return new WikiButtonModifier(graph, context) {\r
+ @Override\r
+ void perform(String before, String selected, String after, Point selection) {\r
+ textReference.setValue(before +\r
+ "[[Media:root://Documents/Document.pdf|Link to a file within the model]]\r\n" + selected + after);\r
+ \r
+ }\r
+ };\r
+ }\r
+ \r
@SCLValue(type = "ReadGraph -> Resource -> Variable -> b")\r
public static Object linkModifier(ReadGraph graph, Resource resource, final Variable context) throws DatabaseException {\r
\r
@Override\r
void perform(String before, String selected, String after, Point selection) {\r
\r
- textReference.setValue(before + "\r\n" +\r
- "[http://www.simantics.org External Website Link]\r\n" + selected + after);\r
+ textReference.setValue(before +\r
+ "[http://www.simantics.org External Website Link]\r\n" + selected + after);\r
\r
}\r
\r
return true;\r
\r
}\r
- \r
+\r
+ private static class ResolveURI extends UnaryRead<String, Object> {\r
+ public ResolveURI(String uri) {\r
+ super(uri);\r
+ }\r
+ @Override\r
+ public Object perform(ReadGraph graph) throws DatabaseException {\r
+ Object result = graph.syncRequest(new PossibleResource(parameter));\r
+ if (result == null)\r
+ result = Variables.getPossibleVariable(graph, parameter);\r
+ return result;\r
+ }\r
+ }\r
+\r
+ private static final Function1<Object, Boolean> PERFORM_DEFAULT_ACTION_FOR_URI_RESOURCE = new Function1<Object, Boolean>() {\r
+ @Override\r
+ public Boolean apply(Object p0) {\r
+ LocationEvent le = (LocationEvent) p0;\r
+ if (le.location.startsWith(DocumentDialect.SIMANTICS_INTERNAL_URI_PREFIX)) {\r
+ // This is not a valid URL anyway so deny relocation.\r
+ le.doit = false;\r
+\r
+ // Try to execute default action for the resource or variable\r
+ // that the URI represents.\r
+ String uri = le.location.substring(DocumentDialect.SIMANTICS_INTERNAL_URI_PREFIX.length());\r
+ try {\r
+ Session s = Simantics.getSession();\r
+ Object input = RequestUtil.trySyncRequest(s,\r
+ SimanticsUI.UI_THREAD_REQUEST_START_TIMEOUT,\r
+ SimanticsUI.UI_THREAD_REQUEST_EXECUTION_TIMEOUT,\r
+ new ResolveURI(uri));\r
+ if (input != null) {\r
+ DefaultActions.asyncPerformDefaultAction(s, input, false, false, false);\r
+ }\r
+ } catch (DatabaseException | InterruptedException e) {\r
+ Activator.getDefault().getLog().log(new Status(IStatus.ERROR, Activator.PLUGIN_ID, "Failed to resolve URI to a database resource or variable: " + uri, e));\r
+ }\r
+ }\r
+ return true;\r
+ }\r
+ };\r
+\r
+ @SCLValue(type = "ReadGraph -> Resource -> Variable -> b")\r
+ public static Function1<Object, Boolean> locationChanging(ReadGraph graph, Resource variable, Variable context) throws DatabaseException {\r
+ return PERFORM_DEFAULT_ACTION_FOR_URI_RESOURCE;\r
+ }\r
+\r
}\r
*******************************************************************************/\r
package org.simantics.document;\r
\r
-import java.io.File;\r
import java.io.IOException;\r
import java.math.BigInteger;\r
+import java.nio.file.Files;\r
+import java.nio.file.Path;\r
import java.security.MessageDigest;\r
import java.security.NoSuchAlgorithmException;\r
import java.util.regex.Matcher;\r
import org.simantics.db.common.request.PossibleIndexRoot;\r
import org.simantics.db.exception.DatabaseException;\r
import org.simantics.image2.ontology.ImageResource;\r
-import org.simantics.utils.FileUtils;\r
-\r
\r
public class DocumentDialect {\r
- \r
- final Pattern imagePattern = Pattern.compile("\\[\\[Image(?::([^\\]]+))?\\]\\]");\r
\r
final static public DocumentDialect INSTANCE = new DocumentDialect();\r
\r
- public String transform(ReadGraph graph, Resource res, String options) {\r
- \r
+ public static final String SIMANTICS_INTERNAL_URI_PREFIX = "http://simantics-internal/";\r
+\r
+ private static final String HTTP = "http://";\r
+ private static final String ROOT = "root:/";\r
+ private static final String IMAGE = "image";\r
+ private static final String MEDIA = "media";\r
+\r
+ final Pattern imageOrMediaPattern = Pattern.compile("\\[\\[([Ii]mage|[Mm]edia)(?::([^\\]]+))?\\]\\]");\r
+\r
+ private static String digest(byte[] bytes) throws NoSuchAlgorithmException {\r
+ MessageDigest md = MessageDigest.getInstance("MD5");\r
+ md.update(bytes);\r
+ BigInteger number = new BigInteger(1, md.digest());\r
+ return number.toString(16);\r
+ }\r
+\r
+ private static String imageExtension(ReadGraph graph, Resource image) throws DatabaseException {\r
+ ImageResource IMAGE = ImageResource.getInstance(graph);\r
+ if (graph.isInstanceOf(image, IMAGE.PngImage))\r
+ return ".png";\r
+ else if (graph.isInstanceOf(image, IMAGE.JpegImage))\r
+ return ".jpg";\r
+ return null;\r
+ }\r
+\r
+ public String transform(ReadGraph graph, Resource res, String type, String options) {\r
try {\r
- \r
String[] parts = options.split("\\|");\r
- if(parts.length > 0) {\r
- \r
+ if (parts.length > 0) {\r
String uri = parts[0];\r
+\r
Resource indexRoot = graph.syncRequest(new PossibleIndexRoot(res));\r
- if(indexRoot == null) return null;\r
+ if (indexRoot == null) return null;\r
String rootURI = graph.getURI(indexRoot);\r
- uri = uri.replace("root:/", rootURI);\r
- // (Apros #12268) For easier image linking, allow users to\r
- // write white space as ' ' in the wiki-style image links.\r
+\r
+ uri = uri.replace(ROOT, rootURI);\r
+\r
+ // (Apros #12268) For more user-friendly linking, allow users to\r
+ // write white space as ' ' in the wiki-style image links instead\r
+ // of having to write %20.\r
uri = uri.replace(" ", "%20");\r
- Resource image = graph.getPossibleResource(uri);\r
- if(image == null) return null;\r
- byte[] bytes = graph.getValue(image, Bindings.BYTE_ARRAY);\r
- MessageDigest md;\r
- md = MessageDigest.getInstance("MD5");\r
- md.update(bytes);\r
- BigInteger number = new BigInteger(1, md.digest());\r
- String digest = number.toString(16);\r
- File dir = Simantics.getTemporaryDirectory("documentImages");\r
- dir.mkdirs();\r
- \r
- ImageResource IMAGE = ImageResource.getInstance(graph);\r
- \r
- String extension;\r
- if(graph.isInstanceOf(image, IMAGE.PngImage)) extension = ".png";\r
- else if(graph.isInstanceOf(image, IMAGE.JpegImage)) extension = ".jpg";\r
- else return null;\r
- \r
- File f = new File(dir, digest + extension);\r
- if(!f.exists())\r
- FileUtils.writeFile(f, bytes);\r
- StringBuilder sb = new StringBuilder();\r
- sb.append("[[File: " + f.toURI());\r
- for(int i=1;i<parts.length;i++) {\r
- sb.append("|");\r
- sb.append(parts[i]);\r
+\r
+ if (IMAGE.equals(type)) {\r
+ Resource image = graph.getPossibleResource(uri);\r
+ if (image == null)\r
+ return null;\r
+\r
+ String extension = imageExtension(graph, image);\r
+ if (extension == null)\r
+ return null;\r
+\r
+ byte[] bytes = graph.getValue(image, Bindings.BYTE_ARRAY);\r
+ String digest = digest(bytes);\r
+\r
+ Path dir = Simantics.getTemporaryDirectory("documentImages").toPath();\r
+ Files.createDirectories(dir);\r
+\r
+ Path f = dir.resolve(digest + extension);\r
+ if (!Files.exists(f))\r
+ Files.write(f, bytes);\r
+\r
+ StringBuilder sb = new StringBuilder(128);\r
+ sb.append("[[File: ").append(f.toUri());\r
+ for (int i = 1; i < parts.length; i++)\r
+ sb.append("|").append(parts[i]);\r
+ sb.append("]]");\r
+ return sb.toString();\r
+ } else if (MEDIA.equals(type)) {\r
+ Resource image = graph.getPossibleResource(uri);\r
+ if (image == null)\r
+ return null;\r
+\r
+ StringBuilder sb = new StringBuilder();\r
+ sb.append("[").append(SIMANTICS_INTERNAL_URI_PREFIX).append(uri);\r
+ for (int i = 1; i < parts.length; i++)\r
+ sb.append(" ").append(parts[i]);\r
+ sb.append("]");\r
+ return sb.toString();\r
}\r
- sb.append("]]");\r
- return sb.toString();\r
+\r
}\r
- \r
} catch (DatabaseException e) {\r
} catch (NoSuchAlgorithmException e) {\r
} catch (IOException e) {\r
}\r
\r
return null;\r
- \r
}\r
\r
public String apply(ReadGraph graph, Resource res, String markup) throws DatabaseException {\r
\r
StringBuffer sb = new StringBuffer();\r
- Matcher matcher = imagePattern.matcher(markup);\r
+ Matcher matcher = imageOrMediaPattern.matcher(markup);\r
while(matcher.find()) {\r
matcher.appendReplacement(sb, "");\r
- String options = matcher.group(1);\r
- String match = transform(graph, res, options);\r
+ String type = matcher.group(1);\r
+ String options = matcher.group(2);\r
+ String match = transform(graph, res, type.toLowerCase(), options);\r
if(match != null) sb.append(match);\r
else sb.append("[[Image:" + options + "]]");\r
}\r
return result.toString();\r
}\r
\r
- \r
}\r
contribution.setCategoryId("category_" + toc.getLabel());\r
contribution.setPrimary(true);\r
contribution.setContributorId(Activator.PLUGIN_ID);\r
- \r
+ contribution.setExtraDocuments(new String[0]);\r
contribution.setToc(toc);\r
contributions.add(contribution);\r
}\r
src.includes = history.txt,\\r
examples/,\\r
test/,\\r
- doc-isv/\r
+ src-isv/\r
import org.simantics.scl.compiler.errors.CompilationError;\r
import org.simantics.scl.compiler.errors.Locations;\r
import org.simantics.structural.stubs.StructuralResource2;\r
+import org.simantics.structural2.utils.StructuralUtils;\r
import org.simantics.ui.workbench.ResourceEditorInput;\r
import org.simantics.utils.logging.TimeLogger;\r
\r
\r
protected Resource resource;\r
protected String currentText;\r
+ protected boolean immutable;\r
protected boolean errorHappened;\r
\r
protected AnnotationModel annotationModel = new AnnotationModel();\r
public Document perform(ReadGraph graph) throws DatabaseException {\r
StructuralResource2 STR = StructuralResource2.getInstance(graph);\r
currentText = graph.getRelatedValue(resource, STR.ComponentTypeScript_code, Bindings.STRING);\r
+ Resource owner = graph.getPossibleObject(resource, STR.ComponentType_hasScript_Inverse);\r
+ immutable = owner != null && StructuralUtils.isImmutable(graph, owner);\r
errorHappened = false;\r
return new Document(currentText != null ? currentText : "");\r
}\r
\r
@Override\r
public boolean isModifiable(Object element) {\r
- return !errorHappened;\r
+ return !errorHappened && !immutable;\r
}\r
\r
@Override\r
public boolean isReadOnly(Object element) {\r
- return errorHappened;\r
+ return errorHappened || immutable;\r
}\r
\r
- @Override\r
- public boolean canSaveDocument(Object element) {\r
- return !errorHappened && !getDocument(element).get().equals(currentText);\r
- }\r
- \r
}\r
import org.simantics.db.common.request.UniqueRead;\r
import org.simantics.db.common.utils.NameUtils;\r
import org.simantics.db.exception.DatabaseException;\r
+import org.simantics.db.layer0.util.Layer0Utils;\r
import org.simantics.db.procedure.Listener;\r
import org.simantics.db.request.Read;\r
-import org.simantics.db.service.XSupport;\r
import org.simantics.layer0.Layer0;\r
import org.simantics.modeling.ui.Activator;\r
import org.simantics.operation.Layer0X;\r
Layer0 L0 = Layer0.getInstance(graph);\r
Layer0X L0X = Layer0X.getInstance(graph);\r
StructuralResource2 STR = StructuralResource2.getInstance(graph);\r
+\r
+ boolean typeIsImmutable = graph.isImmutable(data.componentType)\r
+ || graph.hasStatement(data.componentType, STR.ComponentType_Locked)\r
+ || Layer0Utils.isPublished(graph, data.componentType)\r
+ || Layer0Utils.isContainerPublished(graph, data.componentType);\r
+\r
for(Resource relation : graph.getObjects(data.componentType, L0.DomainOf)) {\r
if(graph.isSubrelationOf(relation, L0.HasProperty)) {\r
String name = graph.getRelatedValue(relation, L0.HasName);\r
\r
String valid = expression != null ? DerivedPropertiesSection.validateMonitorExpression(graph, data.componentType, relation, expression) : null; \r
\r
- boolean immutable = graph.isImmutable(relation);\r
+ boolean immutable = typeIsImmutable || graph.isImmutable(relation);\r
ComponentTypeViewerPropertyInfo info =\r
new ComponentTypeViewerPropertyInfo(relation, name, type, defaultValue, numberType, unit, label, description, expression, valid, immutable);\r
\r
}\r
}\r
Collections.sort(result);\r
- XSupport xs = graph.peekService(XSupport.class);\r
- boolean immutable = xs != null ? xs.getImmutable(data.componentType) : false;\r
- return new ComponentTypePropertiesResult(result, connectionPoints, immutable);\r
+ return new ComponentTypePropertiesResult(result, connectionPoints, typeIsImmutable);\r
}\r
}, new Listener<ComponentTypePropertiesResult>() {\r
@Override\r
\r
import java.io.PrintWriter;\r
import java.io.StringWriter;\r
-import java.util.Arrays;\r
import java.util.Collections;\r
import java.util.List;\r
\r
import org.simantics.db.layer0.util.Layer0Utils;\r
import org.simantics.layer0.Layer0;\r
import org.simantics.scl.compiler.errors.CompilationError;\r
-import org.simantics.scl.compiler.errors.Failable;\r
-import org.simantics.scl.compiler.errors.Failure;\r
import org.simantics.scl.compiler.errors.Locations;\r
-import org.simantics.scl.compiler.module.Module;\r
-import org.simantics.scl.compiler.module.repository.UpdateListener;\r
-import org.simantics.scl.osgi.SCLOsgi;\r
-import org.simantics.scl.runtime.SCLContext;\r
import org.simantics.ui.workbench.ResourceEditorInput;\r
import org.simantics.utils.logging.TimeLogger;\r
\r
}\r
}\r
\r
- // While this editor is active we do not want that this listener gets collected\r
- private UpdateListener listener = new UpdateListener() {\r
- @Override\r
- public void notifyAboutUpdate() {\r
- updateAnnotations();\r
- }\r
- };\r
-\r
protected void updateAnnotations() {\r
Simantics.getSession().asyncRequest(new ReadRequest() {\r
@Override\r
public void run(ReadGraph graph) throws DatabaseException {\r
-// String moduleName = graph.getURI(resource);\r
-// SCLContext context = SCLContext.getCurrent();\r
-// context.put("graph", graph);\r
-// Failable<Module> result = SCLOsgi.MODULE_REPOSITORY.getModule(moduleName, listener);\r
-// \r
-// if(result instanceof Failure) {\r
-// Failure failure = (Failure)result;\r
-// setAnnotations(Arrays.asList(failure.errors));\r
-// }\r
-// else {\r
-// setAnnotations(Collections.<CompilationError>emptyList());\r
-// }\r
- setAnnotations(Collections.<CompilationError>emptyList());\r
+ setAnnotations(Collections.emptyList());\r
}\r
});\r
}\r
return errorHappened;\r
}\r
\r
- @Override\r
- public boolean canSaveDocument(Object element) {\r
- return !errorHappened && !getDocument(element).get().equals(currentText);\r
- }\r
-\r
}\r
import org.simantics.scl.osgi.SCLOsgi;\r
import org.simantics.scl.runtime.SCLContext;\r
import org.simantics.scl.ui.editor.SCLSourceViewerConfigurationNew;\r
+import org.simantics.structural2.utils.StructuralUtils;\r
import org.simantics.ui.workbench.ResourceEditorInput;\r
import org.simantics.utils.logging.TimeLogger;\r
\r
\r
protected Resource resource;\r
protected String currentText;\r
+ protected boolean immutable;\r
protected boolean errorHappened;\r
\r
protected AnnotationModel annotationModel = new AnnotationModel();\r
public Document perform(ReadGraph graph) throws DatabaseException {\r
Layer0 L0 = Layer0.getInstance(graph);\r
currentText = graph.getRelatedValue(resource, L0.SCLModule_definition, Bindings.STRING);\r
+ immutable = StructuralUtils.isImmutable(graph, resource);\r
errorHappened = false;\r
return new Document(currentText != null ? currentText : "");\r
}\r
\r
@Override\r
public boolean isModifiable(Object element) {\r
- return !errorHappened;\r
+ return !errorHappened && !immutable;\r
}\r
\r
@Override\r
public boolean isReadOnly(Object element) {\r
- return errorHappened;\r
- }\r
-\r
- @Override\r
- public boolean canSaveDocument(Object element) {\r
- return !errorHappened && !getDocument(element).get().equals(currentText);\r
+ return errorHappened || immutable;\r
}\r
\r
}\r
return errorHappened;\r
}\r
\r
- @Override\r
- public boolean canSaveDocument(Object element) {\r
- return !errorHappened && !getDocument(element).get().equals(currentText);\r
- }\r
-\r
}\r
public Variable perform(ReadGraph graph) throws DatabaseException {\r
\r
DiagramResource DIA = DiagramResource.getInstance(graph);\r
+ ModelingResources MOD = ModelingResources.getInstance(graph);\r
\r
String uri = graph.getPossibleRelatedValue(resource, DIA.RuntimeDiagram_HasVariable);\r
if (uri == null)\r
if (var == null)\r
return null;\r
\r
- Resource config = graph.getPossibleObject(resource2, ModelingResources.getInstance(graph).ElementToComponent);\r
- if (config == null)\r
+ Resource config = graph.getPossibleObject(resource2, MOD.ElementToComponent);\r
+ if (config == null) {\r
+ // Apros #9646: if resource2 is the diagram\r
+ // itself, return the diagram composite variable\r
+ // since it is generally more useful than the\r
+ // variable to the diagram.\r
+ Resource composite = graph.getPossibleObject(resource2, MOD.DiagramToComposite);\r
+ if (composite != null && composite.equals(var.getPossibleRepresents(graph))) {\r
+ //return Variables.getPossibleVariable(graph, resource2);\r
+ return var;\r
+ }\r
+\r
return null;\r
+ }\r
\r
return var.browsePossible(graph, config);\r
\r
import org.simantics.scl.compiler.source.StringModuleSource;\r
import org.simantics.scl.compiler.source.repository.ModuleSourceRepository;\r
import org.simantics.scl.runtime.SCLContext;\r
+import org.simantics.structural2.utils.StructuralUtils;\r
import org.simantics.scl.runtime.tuple.Tuple0;\r
\r
import gnu.trove.procedure.TObjectProcedure;\r
\r
public static class GraphModuleSource extends StringModuleSource {\r
\r
- public GraphModuleSource(String moduleName, ClassLoader classLoader, String moduleText) {\r
+ private final boolean immutable;\r
+\r
+ public GraphModuleSource(String moduleName, ClassLoader classLoader, String moduleText, boolean immutable) {\r
super(moduleName, classLoader, moduleText);\r
+ this.immutable = immutable;\r
}\r
\r
@Override\r
public boolean isUpdateable() {\r
- return true;\r
+ return !immutable;\r
}\r
\r
@Override\r
if(!graph.isInstanceOf(moduleResource, L0.SCLModule))\r
return null;\r
String text = graph.getRelatedValue(moduleResource, L0.SCLModule_definition);\r
- return new GraphModuleSource(parameter, getClass().getClassLoader(), text);\r
+ boolean immutable = StructuralUtils.isImmutable(graph, moduleResource);\r
+ return new GraphModuleSource(parameter, getClass().getClassLoader(), text, immutable);\r
}\r
}\r
\r
bin.includes = META-INF/,\\r
.,\\r
scl/\r
-src.includes = scl/,\\r
- jdom-2.0.6.jar\r
+src.includes = scl/\r
}\r
else {\r
Activator.logError("Method " + method.getName() + " in class " + \r
- clazz.getCanonicalName() + " has incompantible SCL type in the SCLValue annotation."\r
+ clazz.getCanonicalName() + " has incompatible SCL type in the SCLValue annotation."\r
);\r
ReflectionUtils.isCompatible(scheme, type, method);\r
}\r
}\r
else {\r
Activator.logError("Constructor of " + \r
- clazz.getCanonicalName() + " has incompantible SCL type in the SCLValue annotation."\r
+ clazz.getCanonicalName() + " has incompatible SCL type in the SCLValue annotation."\r
);\r
}\r
} catch (TypeNotFoundException e) {\r
}\r
else {\r
Activator.logError("Field " + field.getName() + " in class " + \r
- clazz.getCanonicalName() + " has incompantible SCL type in the SCLValue annotation."\r
+ clazz.getCanonicalName() + " has incompatible SCL type in the SCLValue annotation."\r
);\r
}\r
} catch (TypeNotFoundException e) {\r
style="push">\r
</command>\r
</menuContribution>\r
- <menuContribution\r
- allPopups="false"\r
- locationURI="org.simantics.scl.ui.menuContribution1">\r
- </menuContribution>\r
</extension>\r
<extension\r
point="org.eclipse.ui.commands">\r
\r
@Override\r
public Object visit(AstIdentifier id) {\r
- throw new IllegalStateException();\r
+ return FormulaError2.NAME.getString();\r
+ //throw new IllegalStateException();\r
}\r
\r
@Override\r
public <T> void edit(Transaction<Write> transaction, String location, String property, T value, Binding binding, Consumer<?> callback) {\r
\r
if (ClientModel.ITERATION_ENABLED.equals(location)) {\r
- \r
+ Simantics.getSession().asyncRequest(new ReadRequest() {\r
+ @Override\r
+ public void run(ReadGraph graph) throws DatabaseException {\r
+ getBook(graph).setIterationEnabled((boolean)value);\r
+ }\r
+ });\r
+ return;\r
}\r
\r
if (ClientModel.MODE.equals(location)) {\r
\r
public Map<Integer, SpreadsheetElement> children = new HashMap<>();\r
\r
+ private boolean iterationEnabled;\r
+\r
public int getNewId(SpreadsheetElement element) {\r
int result = idCounter++;\r
children.put(result, element);\r
\r
}\r
\r
+ public void setIterationEnabled(boolean value) {\r
+ this.iterationEnabled = value;\r
+ }\r
+ \r
+ public boolean isIterationEnabled() {\r
+ return iterationEnabled;\r
+ }\r
+\r
}\r
AstValue value = ((SpreadsheetFormula)content).value;\r
if(this.inProgress == true) this.iterations++;\r
\r
- if(env.iterationEnabled == false){\r
+ if(!env.getBook().isIterationEnabled()){\r
if(this.inProgress == false){\r
this.inProgress = true;\r
f.result = value.accept(visitor);\r
}\r
else f.result = FormulaError2.CIRCULAR_REF.getString();\r
}\r
- else if(iterations<env.iterationLimit){\r
+ else if(this.iterations<env.iterationLimit){\r
this.inProgress = true;\r
f.result = value.accept(visitor);\r
}\r
- else f.result = 0.0;\r
+ else {\r
+ if(f.result==null)\r
+ f.result = 0.0;\r
+ }\r
\r
env.getBook().registerReferences(makeReferenceKey(), visitor.getReferences());\r
}\r
this.inProgress = false;\r
+ this.iterations = 0;\r
return (T)f.result;\r
} else if (content instanceof SpreadsheetSCLConstant) {\r
SpreadsheetSCLConstant sclConstant = (SpreadsheetSCLConstant) content;\r
final private SpreadsheetBook book;\r
private Map<String, CellFormulaFunction<?>> functions = new HashMap<>();\r
public int iterationLimit = 100;\r
- public boolean iterationEnabled = false;\r
- \r
\r
public SpreadsheetEvaluationEnvironment(SpreadsheetBook book) {\r
this.book = book;\r
@Override\r
public void actionPerformed(ActionEvent e) {\r
System.out.println("state is " + iterationEnabled.isSelected());\r
+ CellEditor editor = serverInterface.getAdapter(CellEditor.class);\r
+ if(editor != null) {\r
+ editor.edit(null, ClientModel.ITERATION_ENABLED, ClientModel.ITERATION_ENABLED, iterationEnabled.isSelected(), null, null);\r
+ }\r
}\r
});\r
\r
import org.simantics.db.WriteGraph;\r
import org.simantics.db.common.CommentMetadata;\r
import org.simantics.db.common.request.ObjectsWithType;\r
+import org.simantics.db.common.request.PossibleTypedParent;\r
import org.simantics.db.common.utils.NameUtils;\r
import org.simantics.db.exception.DatabaseException;\r
import org.simantics.db.layer0.exception.MissingVariableException;\r
}\r
return null;\r
}\r
- \r
+\r
+ public static boolean isImmutable(ReadGraph graph, Resource r) throws DatabaseException {\r
+ StructuralResource2 STR = StructuralResource2.getInstance(graph);\r
+ Resource uc = graph.syncRequest(new PossibleTypedParent(r, STR.ComponentType));\r
+ return graph.isImmutable(r)\r
+ // Anything under a published or locked user component is published as well\r
+ || (uc != null && (Layer0Utils.isPublished(graph, uc)\r
+ || graph.hasStatement(uc, STR.ComponentType_Locked)))\r
+ // Anything under a published container (shared library) is published as well\r
+ || Layer0Utils.isContainerPublished(graph, r)\r
+ ;\r
+ }\r
+\r
}\r
source.. = src/\r
output.. = bin/\r
bin.includes = META-INF/,\\r
- .\r
+ .
\ No newline at end of file
Views.Control.Style.Constant.Wrap = 64 : L0.Integer
Views.Control.Style.Constant.HScroll = 256 : L0.Integer
Views.Control.Style.Constant.VScroll = 512 : L0.Integer
+Views.Control.Style.Constant.Horizontal = 256 : L0.Integer
+Views.Control.Style.Constant.Vertical = 512 : L0.Integer
Views.Control.Style.Constant.Border = 2048 : L0.Integer
Views.Control.Style.Constant.FullSelection = 65536 : L0.Integer
Views.Control.Style.Constant.NoFocus = 524288 : L0.Integer
Views.Browser <T Views.Control
>-- Views.Browser.document ==> "String" <R SG.Node.HasProperty : L0.FunctionalRelation
>-- Views.Browser.variable ==> "Variable" <R SG.Node.HasProperty : L0.FunctionalRelation
+ >-- Views.Browser.locationChanging ==> "a -> Boolean" <R SG.Node.HasProperty : L0.FunctionalRelation
Views.WikiBrowser <T Views.Control
>-- Views.WikiBrowser.document ==> "String" <R SG.Node.HasProperty : L0.FunctionalRelation
Views.GridLayout.GridData.END = 3 : L0.Integer
Views.GridLayout.GridData.FILL = 4 : L0.Integer
+Views.RowLayout <T Views.Layout
+ @L0.assert L0.HasValueType "RowLayout"
+ @L0.assert
+ L0.ConvertsToValueWith
+ Views.Functions.rowLayout : L0.ExternalValue
+ >-- Views.RowLayout.type ==> "Integer" <R L0.HasProperty : L0.FunctionalRelation
+ >-- Views.RowLayout.spacing ==> "Integer" <R L0.HasProperty : L0.FunctionalRelation
+ >-- Views.RowLayout.center ==> "Boolean" <R L0.HasProperty : L0.FunctionalRelation
+ >-- Views.RowLayout.fill ==> "Boolean" <R L0.HasProperty : L0.FunctionalRelation
+ >-- Views.RowLayout.justify ==> "Boolean" <R L0.HasProperty : L0.FunctionalRelation
+ >-- Views.RowLayout.pack ==> "Boolean" <R L0.HasProperty : L0.FunctionalRelation
+ >-- Views.RowLayout.wrap ==> "Boolean" <R L0.HasProperty : L0.FunctionalRelation
+ >-- Views.RowLayout.extendedMargins ==> "a" <R L0.HasProperty : L0.FunctionalRelation
+ @L0.assert Views.RowLayout.type Views.Control.Style.Constant.Horizontal
+ @L0.assert Views.RowLayout.spacing 3
+ @L0.assert Views.RowLayout.center false
+ @L0.assert Views.RowLayout.fill false
+ @L0.assert Views.RowLayout.justify false
+ @L0.assert Views.RowLayout.pack true
+ @L0.assert Views.RowLayout.wrap true
+ @L0.assert Views.RowLayout.extendedMargins
+ (3,3,3,3) : Views.RowLayout.ExtendedMargins
+
+Views.RowLayout.ExtendedMargins <T L0.Literal
+ @L0.assert L0.HasDataType $(Integer,Integer,Integer,Integer)
+
+Views.RowLayout.RowData <T L0.Value
+ @L0.assert L0.HasValueType "RowData"
+ @L0.assert
+ L0.ConvertsToValueWith
+ Views.Functions.rowData : L0.ExternalValue
+ >-- Views.RowLayout.RowData.width ==> "Integer" <R L0.HasProperty : L0.FunctionalRelation
+ >-- Views.RowLayout.RowData.height ==> "Integer" <R L0.HasProperty : L0.FunctionalRelation
+ @L0.assert Views.RowLayout.RowData.width -1
+ @L0.assert Views.RowLayout.RowData.height -1
+
Views.SingleColumn
@Views.Explorer.Column.full "single" "Entries" "LEFT" 150 "Entries" true 1
public final Resource Browser;\r
public final Resource Browser_document;\r
public final Resource Browser_document_Inverse;\r
+ public final Resource Browser_locationChanging;\r
+ public final Resource Browser_locationChanging_Inverse;\r
public final Resource Browser_variable;\r
public final Resource Browser_variable_Inverse;\r
public final Resource BundleImage;\r
public final Resource Control_Style_Constant_Check;\r
public final Resource Control_Style_Constant_FullSelection;\r
public final Resource Control_Style_Constant_HScroll;\r
+ public final Resource Control_Style_Constant_Horizontal;\r
public final Resource Control_Style_Constant_Multi;\r
public final Resource Control_Style_Constant_NoFocus;\r
public final Resource Control_Style_Constant_None;\r
public final Resource Control_Style_Constant_Push;\r
public final Resource Control_Style_Constant_ReadOnly;\r
public final Resource Control_Style_Constant_VScroll;\r
+ public final Resource Control_Style_Constant_Vertical;\r
public final Resource Control_Style_Constant_Wrap;\r
public final Resource Control_Style_HasConstant;\r
public final Resource Control_Style_HasConstant_Inverse;\r
public final Resource Functions_gridLayout;\r
public final Resource Functions_parameterValue;\r
public final Resource Functions_resourceURI;\r
+ public final Resource Functions_rowData;\r
+ public final Resource Functions_rowLayout;\r
public final Resource Functions_singleResourceSelection;\r
public final Resource Functions_style;\r
public final Resource Functions_tabChildNames;\r
public final Resource ResourceURI;\r
public final Resource ResourceURI_HasResource;\r
public final Resource ResourceURI_HasResource_Inverse;\r
+ public final Resource RowLayout;\r
+ public final Resource RowLayout_ExtendedMargins;\r
+ public final Resource RowLayout_RowData;\r
+ public final Resource RowLayout_RowData_height;\r
+ public final Resource RowLayout_RowData_height_Inverse;\r
+ public final Resource RowLayout_RowData_width;\r
+ public final Resource RowLayout_RowData_width_Inverse;\r
+ public final Resource RowLayout_center;\r
+ public final Resource RowLayout_center_Inverse;\r
+ public final Resource RowLayout_extendedMargins;\r
+ public final Resource RowLayout_extendedMargins_Inverse;\r
+ public final Resource RowLayout_fill;\r
+ public final Resource RowLayout_fill_Inverse;\r
+ public final Resource RowLayout_justify;\r
+ public final Resource RowLayout_justify_Inverse;\r
+ public final Resource RowLayout_pack;\r
+ public final Resource RowLayout_pack_Inverse;\r
+ public final Resource RowLayout_spacing;\r
+ public final Resource RowLayout_spacing_Inverse;\r
+ public final Resource RowLayout_type;\r
+ public final Resource RowLayout_type_Inverse;\r
+ public final Resource RowLayout_wrap;\r
+ public final Resource RowLayout_wrap_Inverse;\r
public final Resource SashForm;\r
public final Resource SashForm_Horizontal;\r
public final Resource SashForm_Vertical;\r
public static final String Browser = "http://www.simantics.org/Views-1.2/Browser";\r
public static final String Browser_document = "http://www.simantics.org/Views-1.2/Browser/document";\r
public static final String Browser_document_Inverse = "http://www.simantics.org/Views-1.2/Browser/document/Inverse";\r
+ public static final String Browser_locationChanging = "http://www.simantics.org/Views-1.2/Browser/locationChanging";\r
+ public static final String Browser_locationChanging_Inverse = "http://www.simantics.org/Views-1.2/Browser/locationChanging/Inverse";\r
public static final String Browser_variable = "http://www.simantics.org/Views-1.2/Browser/variable";\r
public static final String Browser_variable_Inverse = "http://www.simantics.org/Views-1.2/Browser/variable/Inverse";\r
public static final String BundleImage = "http://www.simantics.org/Views-1.2/BundleImage";\r
public static final String Control_Style_Constant_Check = "http://www.simantics.org/Views-1.2/Control/Style/Constant/Check";\r
public static final String Control_Style_Constant_FullSelection = "http://www.simantics.org/Views-1.2/Control/Style/Constant/FullSelection";\r
public static final String Control_Style_Constant_HScroll = "http://www.simantics.org/Views-1.2/Control/Style/Constant/HScroll";\r
+ public static final String Control_Style_Constant_Horizontal = "http://www.simantics.org/Views-1.2/Control/Style/Constant/Horizontal";\r
public static final String Control_Style_Constant_Multi = "http://www.simantics.org/Views-1.2/Control/Style/Constant/Multi";\r
public static final String Control_Style_Constant_NoFocus = "http://www.simantics.org/Views-1.2/Control/Style/Constant/NoFocus";\r
public static final String Control_Style_Constant_None = "http://www.simantics.org/Views-1.2/Control/Style/Constant/None";\r
public static final String Control_Style_Constant_Push = "http://www.simantics.org/Views-1.2/Control/Style/Constant/Push";\r
public static final String Control_Style_Constant_ReadOnly = "http://www.simantics.org/Views-1.2/Control/Style/Constant/ReadOnly";\r
public static final String Control_Style_Constant_VScroll = "http://www.simantics.org/Views-1.2/Control/Style/Constant/VScroll";\r
+ public static final String Control_Style_Constant_Vertical = "http://www.simantics.org/Views-1.2/Control/Style/Constant/Vertical";\r
public static final String Control_Style_Constant_Wrap = "http://www.simantics.org/Views-1.2/Control/Style/Constant/Wrap";\r
public static final String Control_Style_HasConstant = "http://www.simantics.org/Views-1.2/Control/Style/HasConstant";\r
public static final String Control_Style_HasConstant_Inverse = "http://www.simantics.org/Views-1.2/Control/Style/HasConstant/Inverse";\r
public static final String Functions_gridLayout = "http://www.simantics.org/Views-1.2/Functions/gridLayout";\r
public static final String Functions_parameterValue = "http://www.simantics.org/Views-1.2/Functions/parameterValue";\r
public static final String Functions_resourceURI = "http://www.simantics.org/Views-1.2/Functions/resourceURI";\r
+ public static final String Functions_rowData = "http://www.simantics.org/Views-1.2/Functions/rowData";\r
+ public static final String Functions_rowLayout = "http://www.simantics.org/Views-1.2/Functions/rowLayout";\r
public static final String Functions_singleResourceSelection = "http://www.simantics.org/Views-1.2/Functions/singleResourceSelection";\r
public static final String Functions_style = "http://www.simantics.org/Views-1.2/Functions/style";\r
public static final String Functions_tabChildNames = "http://www.simantics.org/Views-1.2/Functions/tabChildNames";\r
public static final String ResourceURI = "http://www.simantics.org/Views-1.2/ResourceURI";\r
public static final String ResourceURI_HasResource = "http://www.simantics.org/Views-1.2/ResourceURI/HasResource";\r
public static final String ResourceURI_HasResource_Inverse = "http://www.simantics.org/Views-1.2/ResourceURI/HasResource/Inverse";\r
+ public static final String RowLayout = "http://www.simantics.org/Views-1.2/RowLayout";\r
+ public static final String RowLayout_ExtendedMargins = "http://www.simantics.org/Views-1.2/RowLayout/ExtendedMargins";\r
+ public static final String RowLayout_RowData = "http://www.simantics.org/Views-1.2/RowLayout/RowData";\r
+ public static final String RowLayout_RowData_height = "http://www.simantics.org/Views-1.2/RowLayout/RowData/height";\r
+ public static final String RowLayout_RowData_height_Inverse = "http://www.simantics.org/Views-1.2/RowLayout/RowData/height/Inverse";\r
+ public static final String RowLayout_RowData_width = "http://www.simantics.org/Views-1.2/RowLayout/RowData/width";\r
+ public static final String RowLayout_RowData_width_Inverse = "http://www.simantics.org/Views-1.2/RowLayout/RowData/width/Inverse";\r
+ public static final String RowLayout_center = "http://www.simantics.org/Views-1.2/RowLayout/center";\r
+ public static final String RowLayout_center_Inverse = "http://www.simantics.org/Views-1.2/RowLayout/center/Inverse";\r
+ public static final String RowLayout_extendedMargins = "http://www.simantics.org/Views-1.2/RowLayout/extendedMargins";\r
+ public static final String RowLayout_extendedMargins_Inverse = "http://www.simantics.org/Views-1.2/RowLayout/extendedMargins/Inverse";\r
+ public static final String RowLayout_fill = "http://www.simantics.org/Views-1.2/RowLayout/fill";\r
+ public static final String RowLayout_fill_Inverse = "http://www.simantics.org/Views-1.2/RowLayout/fill/Inverse";\r
+ public static final String RowLayout_justify = "http://www.simantics.org/Views-1.2/RowLayout/justify";\r
+ public static final String RowLayout_justify_Inverse = "http://www.simantics.org/Views-1.2/RowLayout/justify/Inverse";\r
+ public static final String RowLayout_pack = "http://www.simantics.org/Views-1.2/RowLayout/pack";\r
+ public static final String RowLayout_pack_Inverse = "http://www.simantics.org/Views-1.2/RowLayout/pack/Inverse";\r
+ public static final String RowLayout_spacing = "http://www.simantics.org/Views-1.2/RowLayout/spacing";\r
+ public static final String RowLayout_spacing_Inverse = "http://www.simantics.org/Views-1.2/RowLayout/spacing/Inverse";\r
+ public static final String RowLayout_type = "http://www.simantics.org/Views-1.2/RowLayout/type";\r
+ public static final String RowLayout_type_Inverse = "http://www.simantics.org/Views-1.2/RowLayout/type/Inverse";\r
+ public static final String RowLayout_wrap = "http://www.simantics.org/Views-1.2/RowLayout/wrap";\r
+ public static final String RowLayout_wrap_Inverse = "http://www.simantics.org/Views-1.2/RowLayout/wrap/Inverse";\r
public static final String SashForm = "http://www.simantics.org/Views-1.2/SashForm";\r
public static final String SashForm_Horizontal = "http://www.simantics.org/Views-1.2/SashForm/Horizontal";\r
public static final String SashForm_Vertical = "http://www.simantics.org/Views-1.2/SashForm/Vertical";\r
Browser = getResourceOrNull(graph, URIs.Browser);\r
Browser_document = getResourceOrNull(graph, URIs.Browser_document);\r
Browser_document_Inverse = getResourceOrNull(graph, URIs.Browser_document_Inverse);\r
+ Browser_locationChanging = getResourceOrNull(graph, URIs.Browser_locationChanging);\r
+ Browser_locationChanging_Inverse = getResourceOrNull(graph, URIs.Browser_locationChanging_Inverse);\r
Browser_variable = getResourceOrNull(graph, URIs.Browser_variable);\r
Browser_variable_Inverse = getResourceOrNull(graph, URIs.Browser_variable_Inverse);\r
BundleImage = getResourceOrNull(graph, URIs.BundleImage);\r
Control_Style_Constant_Check = getResourceOrNull(graph, URIs.Control_Style_Constant_Check);\r
Control_Style_Constant_FullSelection = getResourceOrNull(graph, URIs.Control_Style_Constant_FullSelection);\r
Control_Style_Constant_HScroll = getResourceOrNull(graph, URIs.Control_Style_Constant_HScroll);\r
+ Control_Style_Constant_Horizontal = getResourceOrNull(graph, URIs.Control_Style_Constant_Horizontal);\r
Control_Style_Constant_Multi = getResourceOrNull(graph, URIs.Control_Style_Constant_Multi);\r
Control_Style_Constant_NoFocus = getResourceOrNull(graph, URIs.Control_Style_Constant_NoFocus);\r
Control_Style_Constant_None = getResourceOrNull(graph, URIs.Control_Style_Constant_None);\r
Control_Style_Constant_Push = getResourceOrNull(graph, URIs.Control_Style_Constant_Push);\r
Control_Style_Constant_ReadOnly = getResourceOrNull(graph, URIs.Control_Style_Constant_ReadOnly);\r
Control_Style_Constant_VScroll = getResourceOrNull(graph, URIs.Control_Style_Constant_VScroll);\r
+ Control_Style_Constant_Vertical = getResourceOrNull(graph, URIs.Control_Style_Constant_Vertical);\r
Control_Style_Constant_Wrap = getResourceOrNull(graph, URIs.Control_Style_Constant_Wrap);\r
Control_Style_HasConstant = getResourceOrNull(graph, URIs.Control_Style_HasConstant);\r
Control_Style_HasConstant_Inverse = getResourceOrNull(graph, URIs.Control_Style_HasConstant_Inverse);\r
Functions_gridLayout = getResourceOrNull(graph, URIs.Functions_gridLayout);\r
Functions_parameterValue = getResourceOrNull(graph, URIs.Functions_parameterValue);\r
Functions_resourceURI = getResourceOrNull(graph, URIs.Functions_resourceURI);\r
+ Functions_rowData = getResourceOrNull(graph, URIs.Functions_rowData);\r
+ Functions_rowLayout = getResourceOrNull(graph, URIs.Functions_rowLayout);\r
Functions_singleResourceSelection = getResourceOrNull(graph, URIs.Functions_singleResourceSelection);\r
Functions_style = getResourceOrNull(graph, URIs.Functions_style);\r
Functions_tabChildNames = getResourceOrNull(graph, URIs.Functions_tabChildNames);\r
ResourceURI = getResourceOrNull(graph, URIs.ResourceURI);\r
ResourceURI_HasResource = getResourceOrNull(graph, URIs.ResourceURI_HasResource);\r
ResourceURI_HasResource_Inverse = getResourceOrNull(graph, URIs.ResourceURI_HasResource_Inverse);\r
+ RowLayout = getResourceOrNull(graph, URIs.RowLayout);\r
+ RowLayout_ExtendedMargins = getResourceOrNull(graph, URIs.RowLayout_ExtendedMargins);\r
+ RowLayout_RowData = getResourceOrNull(graph, URIs.RowLayout_RowData);\r
+ RowLayout_RowData_height = getResourceOrNull(graph, URIs.RowLayout_RowData_height);\r
+ RowLayout_RowData_height_Inverse = getResourceOrNull(graph, URIs.RowLayout_RowData_height_Inverse);\r
+ RowLayout_RowData_width = getResourceOrNull(graph, URIs.RowLayout_RowData_width);\r
+ RowLayout_RowData_width_Inverse = getResourceOrNull(graph, URIs.RowLayout_RowData_width_Inverse);\r
+ RowLayout_center = getResourceOrNull(graph, URIs.RowLayout_center);\r
+ RowLayout_center_Inverse = getResourceOrNull(graph, URIs.RowLayout_center_Inverse);\r
+ RowLayout_extendedMargins = getResourceOrNull(graph, URIs.RowLayout_extendedMargins);\r
+ RowLayout_extendedMargins_Inverse = getResourceOrNull(graph, URIs.RowLayout_extendedMargins_Inverse);\r
+ RowLayout_fill = getResourceOrNull(graph, URIs.RowLayout_fill);\r
+ RowLayout_fill_Inverse = getResourceOrNull(graph, URIs.RowLayout_fill_Inverse);\r
+ RowLayout_justify = getResourceOrNull(graph, URIs.RowLayout_justify);\r
+ RowLayout_justify_Inverse = getResourceOrNull(graph, URIs.RowLayout_justify_Inverse);\r
+ RowLayout_pack = getResourceOrNull(graph, URIs.RowLayout_pack);\r
+ RowLayout_pack_Inverse = getResourceOrNull(graph, URIs.RowLayout_pack_Inverse);\r
+ RowLayout_spacing = getResourceOrNull(graph, URIs.RowLayout_spacing);\r
+ RowLayout_spacing_Inverse = getResourceOrNull(graph, URIs.RowLayout_spacing_Inverse);\r
+ RowLayout_type = getResourceOrNull(graph, URIs.RowLayout_type);\r
+ RowLayout_type_Inverse = getResourceOrNull(graph, URIs.RowLayout_type_Inverse);\r
+ RowLayout_wrap = getResourceOrNull(graph, URIs.RowLayout_wrap);\r
+ RowLayout_wrap_Inverse = getResourceOrNull(graph, URIs.RowLayout_wrap_Inverse);\r
SashForm = getResourceOrNull(graph, URIs.SashForm);\r
SashForm_Horizontal = getResourceOrNull(graph, URIs.SashForm_Horizontal);\r
SashForm_Vertical = getResourceOrNull(graph, URIs.SashForm_Vertical);\r
package org.simantics.views.swt.client.base;\r
\r
import org.eclipse.jface.layout.GridLayoutFactory;\r
+import org.eclipse.jface.layout.RowLayoutFactory;\r
import org.eclipse.swt.SWT;\r
import org.eclipse.swt.layout.GridData;\r
import org.eclipse.swt.layout.GridLayout;\r
+import org.eclipse.swt.layout.RowData;\r
+import org.eclipse.swt.layout.RowLayout;\r
import org.eclipse.swt.widgets.Layout;\r
import org.simantics.browsing.ui.Column;\r
import org.simantics.browsing.ui.Column.Align;\r
import org.simantics.views.ViewUtils.ColumnBean;\r
import org.simantics.views.ViewUtils.GridDataBean;\r
import org.simantics.views.ViewUtils.GridLayoutBean;\r
+import org.simantics.views.ViewUtils.LayoutBean;\r
+import org.simantics.views.ViewUtils.LayoutDataBean;\r
+import org.simantics.views.ViewUtils.RowDataBean;\r
+import org.simantics.views.ViewUtils.RowLayoutBean;\r
\r
public class SWTViewUtils {\r
\r
result.marginBottom = bean.marginBottom;\r
return result;\r
}\r
- \r
- \r
+\r
+ public static Layout toLayout(RowLayoutBean bean) {\r
+ RowLayout result = RowLayoutFactory.fillDefaults().create();\r
+ result.type = bean.type;\r
+ result.spacing = bean.spacing;\r
+ result.center = bean.center;\r
+ result.fill = bean.fill;\r
+ result.justify = bean.justify;\r
+ result.pack = bean.pack;\r
+ result.wrap = bean.wrap;\r
+ result.marginLeft = bean.marginLeft;\r
+ result.marginRight = bean.marginRight;\r
+ result.marginTop = bean.marginTop;\r
+ result.marginBottom = bean.marginBottom;\r
+ return result;\r
+ }\r
+\r
public static GridData toGridData(GridDataBean bean) {\r
- GridData result = new GridData(SWT.FILL, SWT.FILL, true, false); \r
+ GridData result = new GridData(SWT.FILL, SWT.FILL, true, false);\r
result.horizontalSpan = bean.horizontalSpan;\r
result.grabExcessHorizontalSpace = bean.grabExcessHorizontalSpace;\r
result.grabExcessVerticalSpace = bean.grabExcessVerticalSpace;\r
\r
}\r
\r
+ public static RowData toRowData(RowDataBean bean) {\r
+ return new RowData(bean.width, bean.height);\r
+ }\r
+\r
+ public static Layout toLayout(LayoutBean layout) {\r
+ if (layout instanceof GridLayoutBean)\r
+ return toLayout((GridLayoutBean) layout);\r
+ if (layout instanceof RowLayoutBean)\r
+ return toLayout((RowLayoutBean) layout);\r
+ throw new IllegalArgumentException("unrecognized layout: " + layout);\r
+ }\r
+\r
+\r
+ public static Object toLayoutData(LayoutDataBean layoutData) {\r
+ if (layoutData instanceof GridDataBean)\r
+ return toGridData((GridDataBean) layoutData);\r
+ if (layoutData instanceof RowDataBean)\r
+ return toRowData((RowDataBean) layoutData);\r
+ throw new IllegalArgumentException("unrecognized layout data: " + layoutData);\r
+ }\r
+\r
private static Align getAlign(String alignment) {\r
if("LEFT".equals(alignment)) return Align.LEFT;\r
else if("CENTER".equals(alignment)) return Align.CENTER;\r
import org.simantics.ui.fonts.Fonts;\r
import org.simantics.utils.threads.IThreadWorkQueue;\r
import org.simantics.utils.threads.SWTThread;\r
-import org.simantics.views.ViewUtils.GridDataBean;\r
+import org.simantics.views.ViewUtils.LayoutDataBean;\r
\r
abstract public class SingleSWTViewNode<T extends Control> extends SWTParentNode implements LoaderNode {\r
\r
private Map<String, Object> genericProperties = new HashMap<String, Object>();\r
\r
public Function2<String, Object, Boolean> propertyCallback;\r
- public GridDataBean layoutData;\r
+ public LayoutDataBean layoutData;\r
public int style;\r
public String text;\r
public RGB.Integer background;\r
final public void synchronizeStyle(int style) {\r
}\r
\r
- final public void synchronizeLayoutData(GridDataBean layoutData) {\r
- if(layoutData != null) control.setLayoutData(SWTViewUtils.toGridData(layoutData));\r
+ final public void synchronizeLayoutData(LayoutDataBean layoutData) {\r
+ if(layoutData != null) control.setLayoutData(SWTViewUtils.toLayoutData(layoutData));\r
}\r
\r
}\r
import org.eclipse.jface.layout.GridDataFactory;\r
import org.eclipse.jface.layout.GridLayoutFactory;\r
import org.eclipse.swt.browser.Browser;\r
+import org.eclipse.swt.browser.LocationEvent;\r
+import org.eclipse.swt.browser.LocationListener;\r
import org.eclipse.swt.widgets.Composite;\r
import org.simantics.db.layer0.variable.Variable;\r
+import org.simantics.scl.runtime.function.Function1;\r
import org.simantics.utils.datastructures.map.Tuple;\r
import org.simantics.views.swt.client.base.SingleSWTViewNode;\r
\r
\r
private static final long serialVersionUID = -2704760050046054447L;\r
\r
- public String document;\r
- public Variable variable;\r
+ public String document;\r
+ public Variable variable;\r
+ public Function1<Object, Boolean> locationChanging;\r
\r
- private Tuple lastAppliedParametrization;\r
+ private Tuple lastAppliedParametrization;\r
\r
@Override\r
public void reset() {\r
control = new Browser(parent, style);\r
GridDataFactory.fillDefaults().grab(true, true).applyTo(control);\r
\r
+ control.addLocationListener(new LocationListener() {\r
+ @Override\r
+ public void changing(LocationEvent event) {\r
+ Function1<Object, Boolean> lc = locationChanging;\r
+ if (lc != null)\r
+ lc.apply(event);\r
+ }\r
+ @Override\r
+ public void changed(LocationEvent event) {\r
+ }\r
+ });\r
+\r
setProperties();\r
\r
}\r
package org.simantics.views.swt.client.impl;\r
\r
import org.eclipse.swt.widgets.Composite;\r
-import org.simantics.views.ViewUtils.GridLayoutBean;\r
+import org.simantics.views.ViewUtils.LayoutBean;\r
import org.simantics.views.swt.client.base.SWTViewUtils;\r
import org.simantics.views.swt.client.base.SingleSWTViewNode;\r
\r
\r
private static final long serialVersionUID = 7932335224632082902L;\r
\r
- public GridLayoutBean layout;\r
+ public LayoutBean layout;\r
\r
@Override\r
public void createControls(org.eclipse.swt.widgets.Composite parent) {\r
\r
}\r
\r
- final public void synchronizeLayout(GridLayoutBean layout) {\r
+ final public void synchronizeLayout(LayoutBean layout) {\r
if(layout != null) control.setLayout(SWTViewUtils.toLayout(layout));\r
}\r
\r
import org.simantics.browsing.ui.swt.widgets.impl.WidgetSupportImpl;\r
import org.simantics.scl.runtime.function.Function1;\r
import org.simantics.views.ViewUtils.ColumnBean;\r
-import org.simantics.views.ViewUtils.GridLayoutBean;\r
+import org.simantics.views.ViewUtils.LayoutBean;\r
import org.simantics.views.swt.client.base.SWTViewUtils;\r
import org.simantics.views.swt.client.base.SingleSWTViewNode;\r
\r
\r
private static final long serialVersionUID = 7932335224632082902L;\r
\r
- public GridLayoutBean layout;\r
+ public LayoutBean layout;\r
public String browseContext;\r
public String contextMenuId;\r
public String uiContext;\r
}\r
}\r
\r
- final public void synchronizeLayout(GridLayoutBean layout) {\r
+ final public void synchronizeLayout(LayoutBean layout) {\r
}\r
\r
}\r
import org.eclipse.swt.custom.SashForm;\r
import org.eclipse.swt.widgets.Control;\r
import org.eclipse.swt.widgets.Sash;\r
-import org.simantics.views.ViewUtils.GridLayoutBean;\r
+import org.simantics.views.ViewUtils.LayoutBean;\r
import org.simantics.views.swt.client.base.SWTViewUtils;\r
import org.simantics.views.swt.client.base.SingleSWTViewNode;\r
\r
\r
private static final long serialVersionUID = 7932335224632082902L;\r
\r
- public GridLayoutBean layout;\r
+ public LayoutBean layout;\r
public int[] weights;\r
public Integer orientation;\r
\r
\r
}\r
\r
- final public void synchronizeLayout(GridLayoutBean layout) {\r
+ final public void synchronizeLayout(LayoutBean layout) {\r
if(layout != null) control.setLayout(SWTViewUtils.toLayout(layout));\r
}\r
\r
import org.eclipse.swt.widgets.Display;\r
import org.eclipse.swt.widgets.Event;\r
import org.eclipse.swt.widgets.Listener;\r
-import org.simantics.views.ViewUtils.GridLayoutBean;\r
+import org.simantics.views.ViewUtils.LayoutBean;\r
import org.simantics.views.swt.client.base.SWTViewUtils;\r
import org.simantics.views.swt.client.base.SingleSWTViewNode;\r
\r
\r
private static final long serialVersionUID = 7932335224632082902L;\r
\r
- public GridLayoutBean layout;\r
+ public LayoutBean layout;\r
\r
private int minSize = 100;\r
\r
\r
}\r
\r
- final public void synchronizeLayout(GridLayoutBean layout) {\r
+ final public void synchronizeLayout(LayoutBean layout) {\r
if(layout != null) control.setLayout(SWTViewUtils.toLayout(layout));\r
}\r
\r
import org.eclipse.swt.widgets.Control;\r
import org.simantics.browsing.ui.swt.widgets.GraphExplorerComposite;\r
import org.simantics.utils.ui.jface.BasePostSelectionProvider;\r
-import org.simantics.views.ViewUtils.GridLayoutBean;\r
+import org.simantics.views.ViewUtils.LayoutBean;\r
import org.simantics.views.swt.client.base.ISWTViewNode;\r
import org.simantics.views.swt.client.base.SingleSWTViewNode;\r
\r
\r
public List<String> childNames;\r
\r
- public GridLayoutBean layout;\r
+ public LayoutBean layout;\r
\r
final BasePostSelectionProvider selectionProvider = new BasePostSelectionProvider();\r
\r
\r
}\r
\r
- final public void synchronizeLayout(GridLayoutBean layout) {\r
+ final public void synchronizeLayout(LayoutBean layout) {\r
}\r
\r
}\r
\r
@SCLValue(type = "ReadGraph -> Resource -> Variable -> a")\r
public static Object gridData(ReadGraph graph, Resource converter, Variable context) throws DatabaseException {\r
- return ViewUtils.getGridData(graph, converter);\r
+ return ViewUtils.getGridData(graph, converter);\r
}\r
\r
@SCLValue(type = "ReadGraph -> Resource -> Variable -> a")\r
public static Object gridLayout(ReadGraph graph, Resource converter, Variable context) throws DatabaseException {\r
- return ViewUtils.getLayout(graph, converter);\r
+ return ViewUtils.getLayout(graph, converter);\r
+ }\r
+\r
+ @SCLValue(type = "ReadGraph -> Resource -> Variable -> a")\r
+ public static Object rowData(ReadGraph graph, Resource converter, Variable context) throws DatabaseException {\r
+ return ViewUtils.getRowData(graph, converter);\r
+ }\r
+\r
+ @SCLValue(type = "ReadGraph -> Resource -> Variable -> a")\r
+ public static Object rowLayout(ReadGraph graph, Resource converter, Variable context) throws DatabaseException {\r
+ return ViewUtils.getRowLayout(graph, converter);\r
}\r
\r
@SCLValue(type = "ReadGraph -> Resource -> Variable -> a")\r
}\r
\r
public static final Binding EXTENDED_MARGINS_BINDING = Bindings.getBindingUnchecked(ExtendedMargins.class);\r
- \r
- public static class GridLayoutBean extends Bean {\r
- \r
- public int numColumns;\r
- public int horizontalSpacing;\r
- public int verticalSpacing;\r
+\r
+ public static class LayoutBean extends Bean {\r
public int marginLeft;\r
public int marginRight;\r
public int marginTop;\r
public int marginBottom;\r
+ }\r
+\r
+ public static class GridLayoutBean extends LayoutBean {\r
+ \r
+ public int numColumns;\r
+ public int horizontalSpacing;\r
+ public int verticalSpacing;\r
\r
}\r
- \r
- public static class GridDataBean extends Bean {\r
+\r
+ public static class RowLayoutBean extends LayoutBean {\r
+ public int type;\r
+ public int spacing;\r
+ public boolean center;\r
+ public boolean fill;\r
+ public boolean justify;\r
+ public boolean pack;\r
+ public boolean wrap;\r
+ }\r
+\r
+ public static class LayoutDataBean extends Bean {}\r
+\r
+ public static class GridDataBean extends LayoutDataBean {\r
\r
public int horizontalSpan;\r
public boolean grabExcessHorizontalSpace;\r
public int heightHint;\r
\r
}\r
- \r
+\r
+ public static class RowDataBean extends LayoutDataBean {\r
+ public int width;\r
+ public int height;\r
+ }\r
+\r
public static class ColumnBean extends Bean {\r
\r
public String key;\r
\r
}\r
\r
+ public static RowLayoutBean getRowLayout(RequestProcessor processor, Resource configuration) throws DatabaseException {\r
+ return processor.sync(new ResourceRead<RowLayoutBean>(configuration) {\r
+ @Override\r
+ public RowLayoutBean perform(ReadGraph graph) throws DatabaseException {\r
+ ViewsResources VIEW = ViewsResources.getInstance(graph);\r
+ Integer type = graph.getPossibleRelatedValue(resource, VIEW.RowLayout_type, Bindings.INTEGER);\r
+ Integer spacing = graph.getPossibleRelatedValue(resource, VIEW.RowLayout_spacing, Bindings.INTEGER);\r
+ Boolean center = graph.getPossibleRelatedValue(resource, VIEW.RowLayout_center, Bindings.BOOLEAN);\r
+ Boolean fill = graph.getPossibleRelatedValue(resource, VIEW.RowLayout_fill, Bindings.BOOLEAN);\r
+ Boolean justify = graph.getPossibleRelatedValue(resource, VIEW.RowLayout_justify, Bindings.BOOLEAN);\r
+ Boolean pack = graph.getPossibleRelatedValue(resource, VIEW.RowLayout_pack, Bindings.BOOLEAN);\r
+ Boolean wrap = graph.getPossibleRelatedValue(resource, VIEW.RowLayout_wrap, Bindings.BOOLEAN);\r
+ ExtendedMargins extendedMargins = graph.getPossibleRelatedValue(resource, VIEW.RowLayout_extendedMargins, EXTENDED_MARGINS_BINDING);\r
+\r
+ RowLayoutBean layout = new RowLayoutBean();\r
+ layout.type = type;\r
+ layout.spacing = spacing;\r
+ layout.center = center;\r
+ layout.fill = fill;\r
+ layout.justify = justify;\r
+ layout.pack = pack;\r
+ layout.wrap = wrap;\r
+ layout.marginLeft = extendedMargins.left;\r
+ layout.marginRight = extendedMargins.right;\r
+ layout.marginTop = extendedMargins.top;\r
+ layout.marginBottom = extendedMargins.bottom;\r
+ return layout;\r
+ }\r
+ });\r
+ }\r
+\r
+ public static RowDataBean getRowData(RequestProcessor processor, Resource configuration) throws DatabaseException {\r
+ return processor.sync(new ResourceRead<RowDataBean>(configuration) {\r
+ @Override\r
+ public RowDataBean perform(ReadGraph graph) throws DatabaseException {\r
+ ViewsResources VIEW = ViewsResources.getInstance(graph);\r
+ RowDataBean data = new RowDataBean();\r
+ data.width = graph.getPossibleRelatedValue(resource, VIEW.GridLayout_GridData_preferredWidth, Bindings.INTEGER);\r
+ data.height = graph.getPossibleRelatedValue(resource, VIEW.GridLayout_GridData_preferredHeight, Bindings.INTEGER);\r
+ return data;\r
+ }\r
+ });\r
+ }\r
+\r
public static int getStyle(RequestProcessor processor, Resource configuration) throws DatabaseException {\r
\r
return processor.sync(new ResourceRead<Integer>(configuration) {\r
\r
Simantics.getSession().async(new TernaryRead<Resource, Variable, String, T> (configuration, context, relationURI) {\r
\r
+ @SuppressWarnings("unchecked")\r
@Override\r
public T perform(ReadGraph graph) throws DatabaseException {\r
Object value = graph.getRelatedValue2(parameter, graph.getResource(parameter3), parameter2);\r
bin.includes = META-INF/,\\r
.,\\r
plugin.xml,\\r
- scl/\r
<version>1.0.0-SNAPSHOT</version>\r
</parent>\r
\r
+ <build>\r
+ <plugins>\r
+ <plugin>\r
+ <groupId>org.eclipse.tycho</groupId>\r
+ <artifactId>tycho-compiler-plugin</artifactId>\r
+ <version>${tycho.version}</version>\r
+ <configuration>\r
+ <compilerArgument>-err:-forbidden</compilerArgument>\r
+ </configuration>\r
+ </plugin>\r
+ <plugin>\r
+ <groupId>org.eclipse.tycho</groupId>\r
+ <artifactId>tycho-source-plugin</artifactId>\r
+ <version>${tycho.version}</version>\r
+ <executions>\r
+ <execution>\r
+ <id>plugin-source</id>\r
+ <goals>\r
+ <goal>plugin-source</goal>\r
+ </goals>\r
+ </execution>\r
+ </executions>\r
+ </plugin>\r
+ </plugins>\r
+ </build>\r
+\r
<modules>\r
<module>com.famfamfam.silk</module>\r
<module>org.simantics</module>\r
<module>org.simantics.workbench.search</module>\r
<module>winterwell.markdown</module>\r
</modules>\r
-</project>
\ No newline at end of file
+</project>\r
.,\
lib/
src.includes = src/,\
- pom.xml,\
- plugin.xml,\
icons/,\
lib/,\
.project,\
# VTT Technical Research Centre of Finland - initial API and implementation\r
# Semantum Oy - update to Eclipse Mars.1 (4.5.1)\r
###############################################################################\r
-bin.includes=features.xml\r
+bin.includes=feature.xml\r
root.win32.win32.x86=bin/win32/win32/x86\r
root.win32.win32.x86_64=bin/win32/win32/x86_64
\ No newline at end of file
<feature\r
id="org.simantics.rcp"\r
label="Simantics Rich Client Platform"\r
- version="1.25.0.qualifier"\r
+ version="1.25.1.qualifier"\r
provider-name="VTT Technical Research Centre of Finland">\r
\r
<description>\r
install-size="0"\r
version="0.0.0"/>\r
\r
+ <plugin\r
+ id="org.slf4j.api"\r
+ download-size="0"\r
+ install-size="0"\r
+ version="0.0.0"\r
+ unpack="false"/>\r
+\r
</feature>\r
<version>1.0.0-SNAPSHOT</version>\r
</parent>\r
\r
+ <build>\r
+ <plugins>\r
+ <plugin>\r
+ <groupId>org.eclipse.tycho.extras</groupId>\r
+ <artifactId>tycho-source-feature-plugin</artifactId>\r
+ <version>${tycho.extras.version}</version>\r
+ <executions>\r
+ <execution>\r
+ <id>source-feature</id>\r
+ <phase>package</phase>\r
+ <goals>\r
+ <goal>source-feature</goal>\r
+ </goals>\r
+ <configuration>\r
+ <excludes>\r
+ <!-- ID of the non-source bundle(s) to exclude from the generated source feature -->\r
+ <plugin id="com.famfamfam.silk"/>\r
+ <plugin id="javax.vecmath"/>\r
+ <plugin id="org.apache.poi.ooxml-schemas"/>\r
+\r
+ <plugin id="org.eclipse.core.filesystem.aix.ppc"/>\r
+ <plugin id="org.eclipse.core.filesystem.aix.ppc64"/>\r
+ <plugin id="org.eclipse.core.filesystem.hpux.ia64"/>\r
+ <plugin id="org.eclipse.core.filesystem.linux.x86"/>\r
+ <plugin id="org.eclipse.core.filesystem.linux.x86_64"/>\r
+ <plugin id="org.eclipse.core.filesystem.linux.ppc"/>\r
+ <plugin id="org.eclipse.core.filesystem.linux.ppc64"/>\r
+ <plugin id="org.eclipse.core.filesystem.linux.ppc64le"/>\r
+ <plugin id="org.eclipse.core.filesystem.macosx"/>\r
+ <plugin id="org.eclipse.core.filesystem.solaris.sparc"/>\r
+ <plugin id="org.eclipse.core.filesystem.win32.x86"/>\r
+ <plugin id="org.eclipse.core.filesystem.win32.x86_64"/>\r
+ <plugin id="org.eclipse.core.net.linux.x86"/>\r
+ <plugin id="org.eclipse.core.net.linux.x86_64"/>\r
+ <plugin id="org.eclipse.core.net.win32.x86"/>\r
+ <plugin id="org.eclipse.core.net.win32.x86_64"/>\r
+ <plugin id="org.eclipse.core.resources.win32.x86"/>\r
+ <plugin id="org.eclipse.core.resources.win32.x86_64"/>\r
+ <plugin id="javax.xml"/>\r
+ <plugin id="org.sat4j.core"/>\r
+ <plugin id="org.sat4j.pb"/>\r
+ <plugin id="org.eclipse.mylyn.wikitext.core"/>\r
+ <plugin id="org.eclipse.mylyn.wikitext.core.ant"/>\r
+ <plugin id="org.eclipse.mylyn.wikitext.core.osgi"/>\r
+ <plugin id="org.eclipse.mylyn.wikitext.mediawiki.core"/>\r
+ <plugin id="org.eclipse.mylyn.wikitext.mediawiki.ui"/>\r
+ <plugin id="org.eclipse.mylyn.wikitext.ui"/>\r
+\r
+ <feature id="org.eclipse.ecf.core.feature"/>\r
+ <feature id="org.eclipse.ecf.core.ssl.feature"/>\r
+ <feature id="org.eclipse.ecf.filetransfer.feature"/>\r
+ <feature id="org.eclipse.ecf.filetransfer.ssl.feature"/>\r
+ <feature id="org.eclipse.ecf.filetransfer.httpclient4.feature"/>\r
+ <feature id="org.eclipse.ecf.filetransfer.httpclient4.ssl.feature"/>\r
+ <feature id="org.eclipse.emf.common"/>\r
+ <feature id="org.eclipse.emf.ecore"/>\r
+ <feature id="org.eclipse.epp.mpc"/>\r
+ <feature id="org.eclipse.equinox.p2.discovery.feature"/>\r
+ <feature id="org.eclipse.equinox.executable"/>\r
+ </excludes>\r
+ </configuration>\r
+ </execution>\r
+ </executions>\r
+ </plugin>\r
+ <plugin>\r
+ <groupId>org.eclipse.tycho</groupId>\r
+ <artifactId>tycho-p2-plugin</artifactId>\r
+ <version>${tycho.version}</version>\r
+ <executions>\r
+ <execution>\r
+ <id>attach-p2-metadata</id>\r
+ <phase>package</phase>\r
+ <goals>\r
+ <goal>p2-metadata</goal>\r
+ </goals>\r
+ </execution>\r
+ </executions>\r
+ </plugin>\r
+ </plugins>\r
+ </build>\r
+ \r
<modules>\r
<module>com.lowagie.text.feature</module>\r
<module>org.apache.lucene4.feature</module>\r
+ <module>org.jfree.feature</module>\r
<module>org.simantics.browsing.ui.feature</module>\r
<module>org.simantics.charts.feature</module>\r
<module>org.simantics.data.feature</module>\r
<module>org.simantics.wiki.ui.feature</module>\r
<module>org.simantics.workbench.feature</module>\r
</modules>\r
-</project>
\ No newline at end of file
+</project>\r
--- /dev/null
+Run mvn p2:site to build the P2 repository of the external components listed in pom.xml.
\ No newline at end of file
<groupId>org.simantics</groupId>\r
<artifactId>org.simantics.sdk.build.p2.site</artifactId>\r
<packaging>pom</packaging>\r
- <version>1.24.0</version>\r
+ <version>1.25.0</version>\r
\r
<properties>\r
+ <itext.version.actual>2.1.7.b1</itext.version.actual>\r
<lucene.version>4.9.0</lucene.version>\r
+ <lucene.version.actual>4.9.0.b0003</lucene.version.actual>\r
<lucene.prefix>org.apache.lucene4</lucene.prefix>\r
</properties>\r
\r
<source>true</source>\r
<instructions>\r
<Bundle-SymbolicName>${lucene.prefix}.core</Bundle-SymbolicName>\r
+ <Bundle-Version>${lucene.version.actual}</Bundle-Version>\r
+ <Export-Package>*;version="${lucene.version}"</Export-Package>\r
</instructions>\r
</artifact>\r
<artifact>\r
<source>true</source>\r
<instructions>\r
<Bundle-SymbolicName>${lucene.prefix}.queries</Bundle-SymbolicName>\r
+ <Bundle-Version>${lucene.version.actual}</Bundle-Version>\r
+ <Require-Bundle>${lucene.prefix}.core;bundle-version="${lucene.version}"</Require-Bundle>\r
+ <Export-Package>*;version="${lucene.version}"</Export-Package>\r
+ <Import-Package>!org.apache.lucene.*,*;resolution:=optional</Import-Package>\r
</instructions>\r
</artifact>\r
<artifact>\r
<source>true</source>\r
<instructions>\r
<Bundle-SymbolicName>${lucene.prefix}.sandbox</Bundle-SymbolicName>\r
+ <Bundle-Version>${lucene.version.actual}</Bundle-Version>\r
+ <Require-Bundle>${lucene.prefix}.core;bundle-version="${lucene.version}"</Require-Bundle>\r
+ <Export-Package>*;version="${lucene.version}"</Export-Package>\r
+ <Import-Package>!org.apache.lucene.*,*;resolution:=optional</Import-Package>\r
</instructions>\r
</artifact>\r
<artifact>\r
- <id>org.apache.lucene:lucene-queryparser:${lucene.version}</id>\r
+ <id>org.apache.lucene:lucene-analyzers-common:${lucene.version}</id>\r
<source>true</source>\r
<instructions>\r
- <Bundle-SymbolicName>${lucene.prefix}.queryparser</Bundle-SymbolicName>\r
+ <Bundle-SymbolicName>${lucene.prefix}.analyzers-common</Bundle-SymbolicName>\r
+ <Bundle-Version>${lucene.version.actual}</Bundle-Version>\r
+ <Require-Bundle>${lucene.prefix}.core;bundle-version="${lucene.version}"</Require-Bundle>\r
+ <Export-Package>*;version="${lucene.version}"</Export-Package>\r
+ <Import-Package>!org.apache.lucene.*,*;resolution:=optional</Import-Package>\r
</instructions>\r
</artifact>\r
<artifact>\r
- <id>org.apache.lucene:lucene-analyzers-common:${lucene.version}</id>\r
+ <id>org.apache.lucene:lucene-queryparser:${lucene.version}</id>\r
<source>true</source>\r
<instructions>\r
- <Bundle-SymbolicName>${lucene.prefix}.analyzers-common</Bundle-SymbolicName>\r
+ <Bundle-SymbolicName>${lucene.prefix}.queryparser</Bundle-SymbolicName>\r
+ <Bundle-Version>${lucene.version.actual}</Bundle-Version>\r
+ <Require-Bundle>${lucene.prefix}.core;bundle-version="${lucene.version}",${lucene.prefix}.queries;bundle-version="${lucene.version}",${lucene.prefix}.sandbox;bundle-version="${lucene.version}"</Require-Bundle>\r
+ <Export-Package>*;version="${lucene.version}"</Export-Package>\r
+ <Import-Package>!org.apache.lucene.*,*;resolution:=optional</Import-Package>\r
</instructions>\r
</artifact>\r
<artifact>\r
<id>org.apache.pdfbox:fontbox:2.0.2</id>\r
<source>true</source>\r
</artifact>\r
+ <artifact>\r
+ <id>org.apache.pdfbox:xmpbox:2.0.2</id>\r
+ <source>true</source>\r
+ </artifact>\r
<artifact>\r
<id>log4j:log4j:1.2.17</id>\r
<source>true</source>\r
</artifact>\r
<artifact>\r
<id>org.eclipse.collections:eclipse-collections-api:7.1.0</id>\r
+ <override>true</override>\r
<source>true</source>\r
+ <instructions>\r
+ <Export-Package>org.eclipse.collections.*</Export-Package>\r
+ </instructions>\r
</artifact>\r
<artifact>\r
<id>org.eclipse.collections:eclipse-collections:7.1.0</id>\r
<source>true</source>\r
<instructions>\r
<Bundle-SymbolicName>com.lowagie.text</Bundle-SymbolicName>\r
+ <Bundle-Version>${itext.version.actual}</Bundle-Version>\r
</instructions>\r
</artifact>\r
<artifact>\r
<id>org.mozilla:rhino:1.7.7.1</id>\r
<source>true</source>\r
</artifact>\r
+ <artifact>\r
+ <id>net.java.dev.jna:jna:4.2.2</id>\r
+ <source>true</source>\r
+ </artifact>\r
+ <artifact>\r
+ <id>net.java.dev.jna:jna-platform:4.2.2</id>\r
+ <source>true</source>\r
+ </artifact>\r
</artifacts>\r
</configuration>\r
</execution>\r
</webApp>\r
</configuration>\r
</plugin>\r
-\r
</plugins>\r
</build>\r
\r
</pluginRepository>\r
</pluginRepositories>\r
\r
-</project>
\ No newline at end of file
+</project>\r
<unit id="org.objectweb.asm.tree.source" version="5.0.1.v201404251740"/>\r
<unit id="org.objectweb.asm.analysis" version="5.0.1.v201505121915"/>\r
<unit id="org.objectweb.asm.tree" version="5.0.1.v201404251740"/>\r
-<repository location="http://download.eclipse.org/tools/orbit/downloads/drops/R20160221192158/repository/"/>\r
+<repository location="http://www.simantics.org/update/tools/orbit/downloads/drops/R20160221192158/repository/"/>\r
</location>\r
<location includeAllPlatforms="true" includeConfigurePhase="false" includeMode="slicer" includeSource="true" type="InstallableUnit">\r
<unit id="org.eclipse.mylyn.wikitext_feature.feature.group" version="2.7.0.v20151015-1452"/>\r
<repository location="http://www.simantics.org/update/nebula/Q22016/release/"/>\r
</location>\r
<location includeAllPlatforms="true" includeConfigurePhase="false" includeMode="slicer" includeSource="true" type="InstallableUnit">\r
-<unit id="org.apache.lucene4.queries" version="4.9.0"/>\r
+<unit id="org.apache.lucene4.queries" version="4.9.0.b0003"/>\r
<unit id="org.apache.commons.lang.source" version="2.6.0"/>\r
-<unit id="org.apache.lucene4.sandbox.source" version="4.9.0"/>\r
+<unit id="org.apache.lucene4.sandbox.source" version="4.9.0.b0003"/>\r
<unit id="org.antlr.runtime.source" version="3.5.2"/>\r
<unit id="org.apache.commons.compress" version="1.12.0"/>\r
<unit id="org.apache.pdfbox.source" version="2.0.2"/>\r
<unit id="org.eclipse.collections.eclipse-collections.source" version="7.1.0"/>\r
<unit id="freemarker" version="2.3.23.stable"/>\r
<unit id="com.github.virtuald.curvesapi.source" version="1.3.0"/>\r
-<unit id="org.apache.lucene4.analyzers-common" version="4.9.0"/>\r
+<unit id="org.apache.lucene4.analyzers-common" version="4.9.0.b0003"/>\r
<unit id="org.apache.commons.collections.source" version="3.2.2"/>\r
<unit id="org.apache.pdfbox.fontbox" version="2.0.2"/>\r
<unit id="org.apache.commons.compress.source" version="1.12.0"/>\r
<unit id="org.mozilla.rhino.source" version="1.7.7.1"/>\r
-<unit id="org.apache.lucene4.queries.source" version="4.9.0"/>\r
+<unit id="org.apache.lucene4.queries.source" version="4.9.0.b0003"/>\r
<unit id="freemarker.source" version="2.3.23.stable"/>\r
<unit id="jakarta-regexp" version="1.4.0"/>\r
<unit id="net.jcip.annotations.source" version="1.0.0"/>\r
<unit id="org.apache.log4j.source" version="1.2.17"/>\r
-<unit id="org.apache.lucene4.sandbox" version="4.9.0"/>\r
+<unit id="org.apache.lucene4.sandbox" version="4.9.0.b0003"/>\r
<unit id="org.apache.commons.logging.source" version="1.2.0"/>\r
<unit id="org.apache.commons.io.source" version="1.4.0"/>\r
-<unit id="org.apache.lucene4.core" version="4.9.0"/>\r
+<unit id="org.apache.lucene4.core" version="4.9.0.b0003"/>\r
<unit id="com.healthmarketscience.jackcess" version="2.1.3"/>\r
<unit id="org.bouncycastle.bctsp-jdk14.source" version="1.38.0"/>\r
<unit id="org.eclipse.collections.eclipse-collections-api" version="7.1.0"/>\r
<unit id="org.bouncycastle.bcprov-jdk14.source" version="1.38.0"/>\r
<unit id="stax.api" version="1.0.1"/>\r
<unit id="org.apache.pdfbox.fontbox.source" version="2.0.2"/>\r
-<unit id="org.apache.lucene4.analyzers-common.source" version="4.9.0"/>\r
+<unit id="org.apache.lucene4.analyzers-common.source" version="4.9.0.b0003"/>\r
<unit id="it.unimi.dsi.fastutil" version="7.0.12"/>\r
<unit id="net.jcip.annotations" version="1.0.0"/>\r
<unit id="org.bouncycastle.bctsp-jdk14" version="1.38.0"/>\r
<unit id="org.jfree.jchart.source" version="1.0.19"/>\r
-<unit id="org.apache.lucene4.queryparser" version="4.9.0"/>\r
+<unit id="org.apache.lucene4.queryparser" version="4.9.0.b0003"/>\r
<unit id="org.apache.poi.ooxml-schemas" version="3.14.0"/>\r
<unit id="org.bouncycastle.bcprov-jdk14" version="1.38.0"/>\r
<unit id="org.apache.poi" version="3.14.0"/>\r
<unit id="org.apache.commons.lang" version="2.6.0"/>\r
<unit id="org.jfree.jchart" version="1.0.19"/>\r
<unit id="org.apache.commons.codec.source" version="1.10.0"/>\r
-<unit id="com.lowagie.text.source" version="2.1.7"/>\r
+<unit id="com.lowagie.text.source" version="2.1.7.b1"/>\r
<unit id="org.supercsv.source" version="2.4.0"/>\r
<unit id="com.github.virtuald.curvesapi" version="1.3.0"/>\r
<unit id="org.eclipse.collections.eclipse-collections" version="7.1.0"/>\r
<unit id="org.apache.log4j" version="1.2.17"/>\r
-<unit id="com.lowagie.text" version="2.1.7"/>\r
+<unit id="com.lowagie.text" version="2.1.7.b1"/>\r
<unit id="org.apache.poi.ooxml" version="3.14.0"/>\r
<unit id="org.apache.pdfbox" version="2.0.2"/>\r
<unit id="org.bouncycastle.bcmail-jdk14" version="1.38.0"/>\r
<unit id="javax.vecmath" version="1.5.2"/>\r
<unit id="bouncycastle.bcprov-jdk14" version="138.0.0"/>\r
<unit id="org.ini4j.source" version="0.5.4"/>\r
-<unit id="org.apache.lucene4.core.source" version="4.9.0"/>\r
-<unit id="org.apache.lucene4.queryparser.source" version="4.9.0"/>\r
-<repository location="http://www.simantics.org/update/external-components/master"/>\r
+<unit id="org.apache.lucene4.core.source" version="4.9.0.b0003"/>\r
+<unit id="org.apache.lucene4.queryparser.source" version="4.9.0.b0003"/>\r
+<repository location="http://www.simantics.org/download/master/external-components"/>\r
</location>\r
<location includeAllPlatforms="true" includeConfigurePhase="false" includeMode="slicer" includeSource="true" type="InstallableUnit">\r
-<unit id="org.eclipse.e4.tools.spies.feature.feature.group" version="0.17.0.v20160520-1109"/>\r
-<repository location="http://download.eclipse.org/e4/snapshots/org.eclipse.e4.tools/latest/"/>\r
+<unit id="org.eclipse.e4.tools.spies.feature.feature.group" version="0.17.0.v20160811-1516"/>\r
+<repository location="http://www.simantics.org/update/e4/snapshots/org.eclipse.e4.tools/latest/"/>\r
</location>\r
<location includeAllPlatforms="true" includeConfigurePhase="false" includeMode="slicer" includeSource="true" type="InstallableUnit">\r
<unit id="org.eclipse.nebula.incubation.feature.feature.group" version="1.0.0.201605182147"/>\r
<unit id="org.eclipse.nebula.widgets.nattable.extension.e4.feature.feature.group" version="1.0.0.201606011907"/>\r
<unit id="org.eclipse.nebula.widgets.nattable.extension.nebula.source.feature.feature.group" version="1.0.0.201606011907"/>\r
<unit id="org.eclipse.nebula.widgets.nattable.extension.poi.source.feature.feature.group" version="1.4.0.201606011907"/>\r
-<repository location="http://download.eclipse.org/nattable/releases/1.4.0/repository/"/>\r
+<repository location="http://www.simantics.org/update/nebula/nattable/releases/1.4.0/repository/"/>\r
</location>\r
</locations>\r
</target>\r
<?xml version="1.0" encoding="UTF-8"?>\r
<site>\r
- <feature url="features/org.simantics.sdk_1.24.0.jar" id="org.simantics.sdk" version="1.24.0">\r
+ <feature url="features/org.simantics.sdk_1.25.0.jar" id="org.simantics.sdk" version="1.25.0">\r
<category name="org.simantics.target"/>\r
</feature>\r
<category-def name="org.simantics.target" label="Simantics Target">\r
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">\r
<modelVersion>4.0.0</modelVersion>\r
<artifactId>org.simantics.sdk.repository</artifactId>\r
- <version>1.24.0-SNAPSHOT</version>\r
+ <version>1.25.0-SNAPSHOT</version>\r
<packaging>eclipse-repository</packaging>\r
\r
<parent>\r
</plugins>\r
</pluginManagement>\r
</build>\r
-</project>
\ No newline at end of file
+</project>\r
\r
<properties>\r
<tycho.version>0.25.0</tycho.version>\r
+ <tycho.extras.version>0.25.0</tycho.extras.version>\r
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>\r
<mars-repo.url>http://download.eclipse.org/releases/mars</mars-repo.url>\r
</properties>\r
</artifact>\r
</target>\r
<environments>\r
+<!--\r
<environment>\r
<os>linux</os>\r
<ws>gtk</ws>\r
<ws>gtk</ws>\r
<arch>x86_64</arch>\r
</environment>\r
+-->\r
<environment>\r
<os>win32</os>\r
<ws>win32</ws>\r
<ws>win32</ws>\r
<arch>x86_64</arch>\r
</environment>\r
+<!--\r
<environment>\r
<os>macosx</os>\r
<ws>cocoa</ws>\r
<arch>x86_64</arch>\r
</environment>\r
+-->\r
</environments>\r
</configuration>\r
</plugin>\r
</plugins>\r
</build>\r
-</project>
\ No newline at end of file
+</project>\r