bprocessor-commit Mailing List for B-processor (Page 60)
Status: Pre-Alpha
Brought to you by:
henryml
You can subscribe to this list here.
2005 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(12) |
Jul
(117) |
Aug
(151) |
Sep
(157) |
Oct
(81) |
Nov
(117) |
Dec
(119) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2006 |
Jan
(183) |
Feb
(130) |
Mar
(117) |
Apr
(61) |
May
(82) |
Jun
(45) |
Jul
(149) |
Aug
(173) |
Sep
(199) |
Oct
(165) |
Nov
(107) |
Dec
(137) |
2007 |
Jan
(124) |
Feb
(58) |
Mar
(123) |
Apr
(80) |
May
(130) |
Jun
(64) |
Jul
(31) |
Aug
(42) |
Sep
(114) |
Oct
(167) |
Nov
(239) |
Dec
(200) |
2008 |
Jan
(43) |
Feb
(43) |
Mar
(4) |
Apr
(9) |
May
(5) |
Jun
(1) |
Jul
(3) |
Aug
(3) |
Sep
(13) |
Oct
(9) |
Nov
(12) |
Dec
|
2009 |
Jan
|
Feb
(20) |
Mar
(7) |
Apr
(12) |
May
(34) |
Jun
(72) |
Jul
|
Aug
(3) |
Sep
(31) |
Oct
(2) |
Nov
(8) |
Dec
(4) |
2010 |
Jan
(5) |
Feb
(32) |
Mar
(8) |
Apr
(7) |
May
(36) |
Jun
|
Jul
(11) |
Aug
(15) |
Sep
(7) |
Oct
(2) |
Nov
(13) |
Dec
(80) |
2011 |
Jan
|
Feb
|
Mar
(8) |
Apr
(12) |
May
(32) |
Jun
(9) |
Jul
(5) |
Aug
|
Sep
(2) |
Oct
|
Nov
|
Dec
(8) |
2012 |
Jan
|
Feb
|
Mar
(3) |
Apr
(5) |
May
(2) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2013 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(22) |
Jun
(5) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Nordholt <nor...@us...> - 2007-06-26 02:05:04
|
Update of /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv25744/src/net/sourceforge/bprocessor/model Modified Files: Camera.java Log Message: added generics to getClipplanes() Index: Camera.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/Camera.java,v retrieving revision 1.43 retrieving revision 1.44 diff -C2 -d -r1.43 -r1.44 *** Camera.java 24 May 2007 10:44:11 -0000 1.43 --- Camera.java 26 Jun 2007 02:05:04 -0000 1.44 *************** *** 641,645 **** * @return the list of clippingplanes */ ! public Collection getClipplanes() { return clipplanes; } --- 641,645 ---- * @return the list of clippingplanes */ ! public Collection<ClippingPlane> getClipplanes() { return clipplanes; } |
From: Nordholt <nor...@us...> - 2007-06-26 02:04:16
|
Update of /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/view In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv25699/src/net/sourceforge/bprocessor/gl/view Modified Files: View.java Log Message: some clean up Index: View.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/view/View.java,v retrieving revision 1.217 retrieving revision 1.218 diff -C2 -d -r1.217 -r1.218 *** View.java 26 Jun 2007 00:43:29 -0000 1.217 --- View.java 26 Jun 2007 02:04:17 -0000 1.218 *************** *** 84,88 **** private static Logger log = Logger.getLogger(View.class); - private static final boolean FALSE = false; private static final boolean DISP = false; --- 84,87 ---- *************** *** 154,163 **** //new float[] {0.8f, 0.7f, 0.6f, 0.50f}; - /** Front color for surfaces */ - public static final float[] FRONT_COLOR = new float[] {0.90f, 0.90f, 0.90f}; - - /** Back color for surfaces */ - public static final float[] BACK_COLOR = new float[] {0.96f, 0.87f, 0.70f}; - /** NONE color for surfaces */ public static final float[] NONE_COLOR = new float[] {0.40f, 0.58f, 0.93f}; --- 153,156 ---- *************** *** 387,390 **** --- 380,385 ---- private boolean debug = false; + + private Edge lockingEdge; static { *************** *** 491,503 **** gridColor = GRID_COLOR; constructorColor = CONSTRUCTOR_COLOR; - frontColor = FRONT_COLOR; - backColor = BACK_COLOR; noneColor = NONE_COLOR; ! tempConstructors = new HashSet(); ! tempEdges = new HashSet(); ! tempSurfaces = new HashSet(); ! tempVertices = new HashSet(); colorMap = new HashMap(); ! glObjects3D = new HashSet(); widgets = new LinkedList<Widget>(); --- 486,496 ---- gridColor = GRID_COLOR; constructorColor = CONSTRUCTOR_COLOR; noneColor = NONE_COLOR; ! tempConstructors = new HashSet<Constructor>(); ! tempEdges = new HashSet<Edge>(); ! tempSurfaces = new HashSet<Surface>(); ! tempVertices = new HashSet<Vertex>(); colorMap = new HashMap(); ! glObjects3D = new HashSet<GlObject>(); widgets = new LinkedList<Widget>(); *************** *** 1058,1062 **** Space active = Project.getInstance().getActiveSpace(); Space world = Project.getInstance().world(); ! LinkedList path = new LinkedList(); path.add(active); while (active != world) { --- 1051,1055 ---- Space active = Project.getInstance().getActiveSpace(); Space world = Project.getInstance().world(); ! LinkedList<Space> path = new LinkedList<Space>(); path.add(active); while (active != world) { *************** *** 2327,2356 **** } - - - /** - * Collect edges from surface - * @param surface The surface - * @param result The result - */ - void collectEdges(Surface surface, Collection result) { - Iterator iter = surface.getEdges().iterator(); - while (iter.hasNext()) { - result.add(iter.next()); - } - } - - /** - * Collect edges from surfaces - * @param surfaces The surfaces - * @param result The result - */ - void collectEdges(List surfaces, Collection result) { - Iterator iter = surfaces.iterator(); - while (iter.hasNext()) { - collectEdges((Surface) iter.next(), result); - } - } - /** * Setter for target that uses default target color --- 2320,2323 ---- *************** *** 2439,2443 **** Object object = null; ! Collection edges = new HashSet(); for (int i = 0; i < hits; i++) { --- 2406,2410 ---- Object object = null; ! Collection<Edge> edges = new HashSet<Edge>(); for (int i = 0; i < hits; i++) { *************** *** 2476,2480 **** } } else if (current instanceof Edge) { ! edges.add(current); if (near < nearestEdge) { nearestEdge = near; --- 2443,2447 ---- } } else if (current instanceof Edge) { ! edges.add((Edge)current); if (near < nearestEdge) { nearestEdge = near; *************** *** 2504,2510 **** bufferOffset += 3; } ! } ! ! if (surface != null) { --- 2471,2475 ---- bufferOffset += 3; } ! } if (surface != null) { *************** *** 2530,2536 **** } } ! } ! ! if (edge != null && vertex != null) { --- 2495,2499 ---- } } ! } if (edge != null && vertex != null) { *************** *** 3229,3246 **** /** - * @return Returns the backColor. - */ - public static float[] getBackColor() { - return backColor; - } - - /** - * @param backColor The backColor to set. - */ - public static void setBackColor(float[] backColor) { - View.backColor = backColor; - } - - /** * @return Returns the bgColor. */ --- 3192,3195 ---- *************** *** 3257,3274 **** /** - * @return Returns the frontColor. - */ - public static float[] getFrontColor() { - return frontColor; - } - - /** - * @param frontColor The frontColor to set. - */ - public static void setFrontColor(float[] frontColor) { - View.frontColor = frontColor; - } - - /** * @return Returns the gridColor. */ --- 3206,3209 ---- *************** *** 3415,3417 **** --- 3350,3360 ---- } } + + /** + * Sets the current locking edge + * @param lockingEdge the new locking edge + */ + public void setLockingEdge(Edge lockingEdge) { + this.lockingEdge = lockingEdge; + } } |
From: Nordholt <nor...@us...> - 2007-06-26 00:43:37
|
Update of /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/view In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv25601/src/net/sourceforge/bprocessor/gl/view Modified Files: View.java Log Message: The color of temporary vertices is now looked up in the colormap. Index: View.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/view/View.java,v retrieving revision 1.216 retrieving revision 1.217 diff -C2 -d -r1.216 -r1.217 *** View.java 25 Jun 2007 21:43:33 -0000 1.216 --- View.java 26 Jun 2007 00:43:29 -0000 1.217 *************** *** 980,986 **** { gl.glColor3fv(constructorColor, 0); ! Iterator it = tempVertices.iterator(); ! while (it.hasNext()) { ! drawGeometric((Geometric) it.next()); } } --- 980,991 ---- { gl.glColor3fv(constructorColor, 0); ! for (Vertex v : tempVertices) { ! if (colorMap.get(v) != null) { ! gl.glColor3fv((float[])colorMap.get(v), 0); ! drawGeometric(v); ! gl.glColor3fv(constructorColor, 0); ! } else { ! drawGeometric(v); ! } } } |
From: Nordholt <nor...@us...> - 2007-06-26 00:42:28
|
Update of /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/model In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv25220/src/net/sourceforge/bprocessor/gl/model Modified Files: Intersection.java Log Message: added a "LOCK_INTERSECTION" type of intersection. This type of intersection represents a intersection that was derived from a different intersection as a result of locking. This type intersection should have the original intersection as object. Index: Intersection.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/model/Intersection.java,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** Intersection.java 4 Aug 2006 11:48:11 -0000 1.5 --- Intersection.java 26 Jun 2007 00:42:17 -0000 1.6 *************** *** 37,40 **** --- 37,42 ---- public static final int PLANE_INTERSECTION = 7; + /** Lock intersection */ + public static final int LOCK_INTERSECTION = 8; /** The vertex */ *************** *** 129,132 **** --- 131,137 ---- name = "plane intersection"; break; + case Intersection.LOCK_INTERSECTION: + name = "lock intersection"; + break; } buffer.append(name); |
From: Nordholt <nor...@us...> - 2007-06-26 00:40:37
|
Update of /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv24124/src/net/sourceforge/bprocessor/gl/tool Modified Files: AbstractPencil.java Log Message: Improved snap-feedback when locked and did some clean up. Still need to do feedback to show was is locked to. Index: AbstractPencil.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/AbstractPencil.java,v retrieving revision 1.82 retrieving revision 1.83 diff -C2 -d -r1.82 -r1.83 *** AbstractPencil.java 25 Jun 2007 21:41:55 -0000 1.82 --- AbstractPencil.java 26 Jun 2007 00:40:11 -0000 1.83 *************** *** 38,42 **** import net.sourceforge.bprocessor.model.Surface; import net.sourceforge.bprocessor.model.Vertex; - import net.sourceforge.bprocessor.model.Camera; import org.apache.log4j.Logger; --- 38,41 ---- *************** *** 101,104 **** --- 100,106 ---- protected Plane lockingPlane; + /** Vertex snapped to when locking */ + protected Vertex lockSnapVertex; + /** Original vertex when snapping */ protected Vertex original; *************** *** 199,202 **** --- 201,207 ---- unwanted.addAll(elements); unwanted.addAll(excluded); + if (lockSnapVertex != null) { + unwanted.add(lockSnapVertex); + } intersection = (Intersection) glv.getView().getObjectAtPoint(e.getX(), e.getY(), *************** *** 214,218 **** v = intersection.vertex(); if (v.getOwner() != space) { ! Set vertices = space.findByLocation(v.getX(), v.getY(), v.getZ(), 0.0000001); if (!vertices.isEmpty()) { v = (Vertex) vertices.iterator().next(); --- 219,223 ---- v = intersection.vertex(); if (v.getOwner() != space) { ! Set vertices = space.findByLocation(v.getX(), v.getY(), v.getZ(), Geometry.EPS); if (!vertices.isEmpty()) { v = (Vertex) vertices.iterator().next(); *************** *** 226,230 **** if (lockingEdge != null) { Vertex vertex = lockingEdge.intersection(intersection.vertex()); ! intersection = new Intersection(vertex, Intersection.EDGE, lockingEdge); } --- 231,237 ---- if (lockingEdge != null) { Vertex vertex = lockingEdge.intersection(intersection.vertex()); ! intersection = new Intersection(vertex, ! Intersection.LOCK_INTERSECTION, ! intersection); } *************** *** 232,236 **** if (!lockingPlane.contains(intersection.vertex())) { Vertex vertex = lockingPlane.projection(intersection.vertex()); ! intersection = new Intersection(vertex, Intersection.PLANE_INTERSECTION, lockingPlane); } } --- 239,245 ---- if (!lockingPlane.contains(intersection.vertex())) { Vertex vertex = lockingPlane.projection(intersection.vertex()); ! intersection = new Intersection(vertex, ! Intersection.LOCK_INTERSECTION, ! intersection); } } *************** *** 398,402 **** */ protected List computeConstructors() { ! List constructors = new LinkedList(); if (start != null) { constructors.add(new CoordinateSystem(start.vertex().copy())); --- 407,411 ---- */ protected List computeConstructors() { ! List<Constructor> constructors = new LinkedList<Constructor>(); if (start != null) { constructors.add(new CoordinateSystem(start.vertex().copy())); *************** *** 451,455 **** Line orthogonal = null; ! if (Math.abs(direction.getZ()) < 0.0000001) { if (start != null) { orthogonal = new Line(start.vertex(), direction, true, false); --- 460,464 ---- Line orthogonal = null; ! if (Math.abs(direction.getZ()) < Geometry.EPS) { if (start != null) { orthogonal = new Line(start.vertex(), direction, true, false); *************** *** 495,533 **** excluded.addAll(feed); } - - /** - * Get the plane out of the XY XZ and YZ planes that is best aligned - * with screen. - * @return the plane - */ - protected Plane bestAlignedPlane() { - Camera camera = Project.getInstance().getCurrentCamera(); - double[] centerPoint = camera.getCenter(); - double[] cameraPoint = camera.getCamera(); - - Vertex eyeVector = new Vertex(cameraPoint[0] - centerPoint[0], - cameraPoint[1] - centerPoint[1], - cameraPoint[2] - centerPoint[2]); - eyeVector.scale(1 / eyeVector.length()); - - Vertex normal; - Vertex xyNormal = new Vertex(0, 0, 1); - Vertex xzNormal = new Vertex(0, 1, 0); - Vertex yzNormal = new Vertex(1, 0, 0); - if (Math.abs(eyeVector.dot(xyNormal)) > - Math.abs(eyeVector.dot(xzNormal))) { - normal = xyNormal; - } else { - normal = xzNormal; - } - if (Math.abs(eyeVector.dot(yzNormal)) > - Math.abs(eyeVector.dot(normal))) { - normal = yzNormal; - } - return new Plane(normal.getX(), - normal.getY(), - normal.getZ(), 0); - } - /** --- 504,507 ---- *************** *** 593,622 **** timer.restart(); if (intersection != null) { ! float[] targetColor = View.TARGET_COLOR; ! Vertex current = intersection.vertex(); ! target = current; ! switch (intersection.type()) { ! case Intersection.EDGE: ! targetColor = View.EDGE_ON_COLOR; ! break; ! case Intersection.SURFACE: ! targetColor = View.SURFACE_ON_COLOR; ! break; ! case Intersection.EDGE_MIDPOINT: ! targetColor = View.EDGE_INTERSECTION_COLOR; ! break; ! case Intersection.EDGE_INTERSECTION: ! targetColor = View.EDGE_INTERSECTION_COLOR; ! break; ! case Intersection.SURFACE_INTERSECTION: ! targetColor = View.EDGE_INTERSECTION_COLOR; ! break; ! case Intersection.PLANE_INTERSECTION: target = null; ! break; } glv.getView().makeTarget(target, targetColor); } } /** --- 567,616 ---- timer.restart(); if (intersection != null) { ! Intersection actual = intersection; ! target = intersection.vertex(); ! float[] targetColor = targetColor(intersection); ! glv.getView().removeTempVertex(lockSnapVertex); ! glv.getView().clearColor(lockSnapVertex); ! if (intersection.type() == Intersection.LOCK_INTERSECTION) { ! actual = (Intersection)actual.object(); ! lockSnapVertex = actual.vertex(); ! targetColor = targetColor(actual); ! glv.getView().addTempVertex(lockSnapVertex); ! glv.getView().changeColor(lockSnapVertex, targetColor); ! } ! if (actual.type() == Intersection.PLANE_INTERSECTION) { target = null; ! glv.getView().removeTempVertex(lockSnapVertex); ! glv.getView().clearColor(lockSnapVertex); } glv.getView().makeTarget(target, targetColor); } } + + /** + * @param intersection + * @return + */ + private float[] targetColor(Intersection intersection) { + float[] targetColor = View.TARGET_COLOR; + switch (intersection.type()) { + case Intersection.EDGE: + targetColor = View.EDGE_ON_COLOR; + break; + case Intersection.SURFACE: + targetColor = View.SURFACE_ON_COLOR; + break; + case Intersection.EDGE_MIDPOINT: + targetColor = View.EDGE_INTERSECTION_COLOR; + break; + case Intersection.EDGE_INTERSECTION: + targetColor = View.EDGE_INTERSECTION_COLOR; + break; + case Intersection.SURFACE_INTERSECTION: + targetColor = View.EDGE_INTERSECTION_COLOR; + break; + } + return targetColor; + } /** *************** *** 661,665 **** if (before != null) { Vertex v = current.vertex().minus(before); ! if (v.length() > 0.000000001) { v.scale(length / v.length()); Vertex to = before.add(v); --- 655,659 ---- if (before != null) { Vertex v = current.vertex().minus(before); ! if (v.length() > Geometry.EPS) { v.scale(length / v.length()); Vertex to = before.add(v); |
From: Nordholt <nor...@us...> - 2007-06-25 21:43:33
|
Update of /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/view In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv18051/src/net/sourceforge/bprocessor/gl/view Modified Files: View.java Log Message: a bit of code clean up. Index: View.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/view/View.java,v retrieving revision 1.215 retrieving revision 1.216 diff -C2 -d -r1.215 -r1.216 *** View.java 20 Jun 2007 12:06:30 -0000 1.215 --- View.java 25 Jun 2007 21:43:33 -0000 1.216 *************** *** 924,928 **** Space space = (Space) object; if (space.isUnion()) { ! for (Space element : (Collection<Space>) space.getElements()) { Collection<Surface> envelope = element.getEnvelope(); for (Surface surface : envelope) { --- 924,928 ---- Space space = (Space) object; if (space.isUnion()) { ! for (Space element : space.getElements()) { Collection<Surface> envelope = element.getEnvelope(); for (Surface surface : envelope) { *************** *** 951,957 **** } } ! } ! ! drawSpace(Project.getInstance().world(), false, false); --- 951,955 ---- } } ! } drawSpace(Project.getInstance().world(), false, false); *************** *** 995,1004 **** if (target instanceof Vertex) { disableClipplanes(); ! } ! ! drawGeometric((Geometric) target); ! // remember to enable clip again ! if (target instanceof Vertex) { enableClipplanes(); } } --- 993,1000 ---- if (target instanceof Vertex) { disableClipplanes(); ! drawGeometric((Geometric) target); enableClipplanes(); + } else { + drawGeometric((Geometric) target); } } *************** *** 1163,1170 **** } ! Collection elements = space.getElements(); ! Iterator iter = elements.iterator(); ! while (iter.hasNext()) { ! Space current = (Space) iter.next(); if (!(current instanceof Net) || Project.getInstance().getActiveSpace() == current) { drawSpace(current, active, selected); --- 1159,1164 ---- } ! Collection<Space> elements = space.getElements(); ! for (Space current : elements) { if (!(current instanceof Net) || Project.getInstance().getActiveSpace() == current) { drawSpace(current, active, selected); *************** *** 2266,2276 **** } } - - private void drawEdges(Collection<Edge> edges, EdgeAttributes attributes) { - apply(attributes); - for (Edge edge : edges) { - drawEdge(edge); - } - } /** --- 2260,2263 ---- |
From: Nordholt <nor...@us...> - 2007-06-25 21:42:02
|
Update of /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv17292/src/net/sourceforge/bprocessor/gl/tool Modified Files: AbstractPencil.java Log Message: a little code clean up. Index: AbstractPencil.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/AbstractPencil.java,v retrieving revision 1.81 retrieving revision 1.82 diff -C2 -d -r1.81 -r1.82 *** AbstractPencil.java 19 Jun 2007 16:11:06 -0000 1.81 --- AbstractPencil.java 25 Jun 2007 21:41:55 -0000 1.82 *************** *** 195,200 **** } } ! ! Collection unwanted = new HashSet(); unwanted.addAll(elements); --- 195,199 ---- } } ! Collection unwanted = new HashSet(); unwanted.addAll(elements); *************** *** 236,241 **** } } ! } ! return intersection; } --- 235,239 ---- } } ! } return intersection; } *************** *** 354,359 **** points.addAll(feed); showPoints(); ! } ! /** --- 352,356 ---- points.addAll(feed); showPoints(); ! } /** *************** *** 596,640 **** timer.restart(); if (intersection != null) { ! target = null; ! float[] targetColor = View.TARGET_COLOR; ! Vertex current = intersection.vertex(); switch (intersection.type()) { - case Intersection.VERTEX: - target = current; - break; case Intersection.EDGE: ! Edge edge = (Edge) intersection.object(); ! if (edge != null && edge.getStrippled()) { ! target = current; ! targetColor = View.EDGE_ON_COLOR; ! } else { ! //target = intersection.object(); ! target = current; ! targetColor = View.EDGE_ON_COLOR; ! } ! break; case Intersection.SURFACE: - //target = intersection.object(); - target = current; targetColor = View.SURFACE_ON_COLOR; - //plane = ((Surface) target).plane(); break; case Intersection.EDGE_MIDPOINT: - target = current; targetColor = View.EDGE_INTERSECTION_COLOR; break; case Intersection.EDGE_INTERSECTION: - target = current; targetColor = View.EDGE_INTERSECTION_COLOR; break; case Intersection.SURFACE_INTERSECTION: - target = current; targetColor = View.EDGE_INTERSECTION_COLOR; break; case Intersection.PLANE_INTERSECTION: target = null; - //plane = (Plane) intersection.object(); break; } --- 593,617 ---- timer.restart(); if (intersection != null) { ! float[] targetColor = View.TARGET_COLOR; Vertex current = intersection.vertex(); + target = current; switch (intersection.type()) { case Intersection.EDGE: ! targetColor = View.EDGE_ON_COLOR; break; case Intersection.SURFACE: targetColor = View.SURFACE_ON_COLOR; break; case Intersection.EDGE_MIDPOINT: targetColor = View.EDGE_INTERSECTION_COLOR; break; case Intersection.EDGE_INTERSECTION: targetColor = View.EDGE_INTERSECTION_COLOR; break; case Intersection.SURFACE_INTERSECTION: targetColor = View.EDGE_INTERSECTION_COLOR; break; case Intersection.PLANE_INTERSECTION: target = null; break; } |
From: rimestad <rim...@us...> - 2007-06-25 10:28:35
|
Update of /cvsroot/bprocessor//bprocessor In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv22246 Modified Files: constructions.txt functionals.txt construction2.txt typer.txt Log Message: changed the files holding the classification and types to not end with ---stop--- seems stupid... Index: construction2.txt =================================================================== RCS file: /cvsroot/bprocessor//bprocessor/construction2.txt,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** construction2.txt 19 Dec 2006 13:16:07 -0000 1.1 --- construction2.txt 25 Jun 2007 10:28:35 -0000 1.2 *************** *** 1544,1547 **** -700;Reserveret til fremtidige udvidelser;;;;;;;;;;;;; -800;Reserveret til fremtidige udvidelser;;;;;;;;;;;;; ! -900;Projektspecifik bygningsdel;;;;;;;;;;;;; ! --stop-- \ No newline at end of file --- 1544,1546 ---- -700;Reserveret til fremtidige udvidelser;;;;;;;;;;;;; -800;Reserveret til fremtidige udvidelser;;;;;;;;;;;;; ! -900;Projektspecifik bygningsdel;;;;;;;;;;;;; \ No newline at end of file Index: typer.txt =================================================================== RCS file: /cvsroot/bprocessor//bprocessor/typer.txt,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** typer.txt 17 Dec 2006 20:26:52 -0000 1.1 --- typer.txt 25 Jun 2007 10:28:35 -0000 1.2 *************** *** 1766,1769 **** ;;;;A;Huller for installationer;;;;;;;; ;;;;B;Huller for beslag og fastgørelser; ! ;;;;;; ! --stop-- \ No newline at end of file --- 1766,1768 ---- ;;;;A;Huller for installationer;;;;;;;; ;;;;B;Huller for beslag og fastgørelser; ! ;;;;;; \ No newline at end of file Index: functionals.txt =================================================================== RCS file: /cvsroot/bprocessor//bprocessor/functionals.txt,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** functionals.txt 29 Mar 2007 21:56:53 -0000 1.2 --- functionals.txt 25 Jun 2007 10:28:35 -0000 1.3 *************** *** 344,347 **** ;C.B;Gaderum ;C.C;Pladsrum ! -80;Exteriør;; ! --stop-- \ No newline at end of file --- 344,346 ---- ;C.B;Gaderum ;C.C;Pladsrum ! -80;Exteriør;; \ No newline at end of file Index: constructions.txt =================================================================== RCS file: /cvsroot/bprocessor//bprocessor/constructions.txt,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** constructions.txt 17 Nov 2006 14:28:06 -0000 1.1 --- constructions.txt 25 Jun 2007 10:28:35 -0000 1.2 *************** *** 1544,1547 **** -700;Reserveret til fremtidige udvidelser; -800;Reserveret til fremtidige udvidelser; ! -900;Projektspecifik bygningsdel; ! --stop-- \ No newline at end of file --- 1544,1546 ---- -700;Reserveret til fremtidige udvidelser; -800;Reserveret til fremtidige udvidelser; ! -900;Projektspecifik bygningsdel; \ No newline at end of file |
From: rimestad <rim...@us...> - 2007-06-25 10:26:47
|
Update of /cvsroot/bprocessor//model/src/net/sourceforge/bprocessor/model In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv21452/src/net/sourceforge/bprocessor/model Modified Files: Classification.java Space.java Project.java Persistence.java Added Files: ClassificationType.java ClassificationFileReader.java Log Message: Have refactored loadClassification and loadType as well as the storing of the types out of the Project and into a new class ClassificationFileLoader. Made A ClassificationType Class holding all type specific info such as u-value etc. Made Classification hold a ClassificationType root for all the possible types it can be. The Space now hold the classification and a ClassificationType that is the chosen Type of the possible types in the chosen classification. Persistence now have mothods to externalize the DBK to XML, but still need a load mechanism. NOTICE THAT PERSISTENCE AND PROJECT SEEM TO HAVE CHANGED INTIRELY BUT THEY HAVEN'T ONLY THE THINGS MENTIONED HERE HAVE BEEN CHANGED --- NEW FILE: ClassificationFileReader.java --- //--------------------------------------------------------------------------------- // $Id: ClassificationFileReader.java,v 1.1 2007/06/25 10:26:46 rimestad Exp $ // // Copyright (c) 2005 The BProcessor Team (http://bprocessor.sourceforge.net) // Released under the Lesser GNU Public License v2.1 //--------------------------------------------------------------------------------- package net.sourceforge.bprocessor.model; import java.io.BufferedReader; import java.io.File; import java.io.FileInputStream; import java.io.IOException; import java.io.InputStreamReader; import java.util.HashMap; import java.util.Map; import java.util.StringTokenizer; import org.apache.log4j.Logger; import org.apache.log4j.PropertyConfigurator; /** * A Class for reading in classifications in from txt files */ public class ClassificationFileReader { /** The logger */ private static Logger log = Logger.getLogger(ClassificationFileReader.class); /** * @param args The arguments */ public static void main(String[] args) { // TODO Auto-generated method stub try { if (args.length != 2) { System.out.println("Specify 1'st file prefix 2'nd log settings file"); } else { PropertyConfigurator.configure(args[1]); Classification construction = ClassificationFileReader.loadClassification(true, args[0]); Persistence.saveClassification(construction, new File(args[0] + "Construction.xml")); } } catch (Exception e) { log.error("Wern't able to load types and save it to xml got error:\n" + e.toString()); } } /** * This method loads the product classificationTypes * from a file into the loaded construction classification * @param locationPrefix The folderlocation of the type files * @exception IOException Thrown if an there were problems locating or reading file * @return The loaded classificationname to classificationType map */ public static Map<String, ClassificationType> loadTypes(String locationPrefix) throws IOException { Map<String, ClassificationType> res = new HashMap<String, ClassificationType>(); BufferedReader bf; bf = new BufferedReader( new InputStreamReader(new FileInputStream(locationPrefix + "typer.txt"), "ISO-8859-1")); String currentLine = ""; int lineNumber = 0; ClassificationType currentClassificationType = null; ClassificationType superClassificationType = null; ClassificationType defaultType = new ClassificationType("default", 0.0, 0.0, 0.0); res.put("default", defaultType); while ((currentLine = bf.readLine()) != null) { lineNumber++; String[] tokens = currentLine.split(";"); if (tokens.length == 0) { continue; } if (!tokens[0].equals("")) { superClassificationType = new ClassificationType(tokens[0], 0, 0, 0); res.put(tokens[0], superClassificationType); continue; } if (tokens.length < 5) { continue; } if (!tokens[3].equals("")) { //classificationTypes currentClassificationType = new ClassificationType(tokens[4], 0.0, 0.0, 0.0); superClassificationType.addSubType(currentClassificationType); continue; } if (tokens.length < 6) { continue; } if (!tokens[4].equals("")) { //subtypes if (currentClassificationType != null) { currentClassificationType.addSubType( new ClassificationType(tokens[5], 0.0, 0.0, 0.0)); } else { log.error("Error in type file format at line " + currentLine); } } } bf.close(); return res; } /** * This method loads the classification document from a file * @exception IOException Thrown if there were problems locating or reading the file * @param locationPrefix The folder location for the files * @param construction true if its construction space classification, false if functional * @return The loaded classification */ public static Classification loadClassification(boolean construction, String locationPrefix) throws IOException { Map<String, ClassificationType> typeMap = loadTypes(locationPrefix); Classification clas; String current = ""; String token = ""; String curname = ""; String curid; boolean clasmade = false; Classification parent = null; Classification last = null; int depth = 0; int lastdepth = 0; BufferedReader bf; if (construction) { bf = new BufferedReader( new InputStreamReader( new FileInputStream(locationPrefix + "construction2.txt"), "ISO-8859-1")); clas = new Classification("-1", "Constructional", null, Classification.CONSTRUCTION); } else { bf = new BufferedReader( new InputStreamReader( new FileInputStream(locationPrefix + "functionals.txt"), "ISO-8859-1")); clas = new Classification("-1", "Functional", null, Classification.FUNCTIONAL); } current = bf.readLine(); while (current != null) { StringTokenizer st = new StringTokenizer(current, ";", true); while (st.hasMoreTokens()) { token = st.nextToken(); if (!clasmade) { if (depth == 0 && !token.equalsIgnoreCase(";")) { curid = new String(token); st.nextToken(); curname = st.nextToken(); Classification curclas; if (construction) { curclas = new Classification(curid, curname, clas, 0); ClassificationType typesForCur = typeMap.get(curname); if (typesForCur == null) { typesForCur = typeMap.get("default"); } curclas.setPossibleTypes(typesForCur); clasmade = true; } else { curclas = new Classification(curid, curname, clas, 1); //curclas.setPossibleTypes(possibleTypes); clasmade = true; } parent = curclas; clas.addChild(curclas); lastdepth = 0; last = curclas; } else if (token.equalsIgnoreCase(";")) { depth++; } else if (depth != 0 && !token.equalsIgnoreCase(";")) { curid = new String(token); st.nextToken(); curname = st.nextToken(); if (depth > lastdepth) { parent = last; } if (depth < lastdepth) { parent = parent.getParent(); } Classification curclas; if (construction) { curclas = new Classification(curid, curname, parent, 0); curclas.setPossibleTypes(typeMap.get(curname)); clasmade = true; } else { curclas = new Classification(curid, curname, parent, 1); clasmade = true; } parent.addChild(curclas); last = curclas; lastdepth = depth; } } else { if (!token.equalsIgnoreCase(";")) { last.setName(token); } } } depth = 0; current = bf.readLine(); clasmade = false; } if (construction) { clas.addChild( new Classification("-99", "Egne klassifikationer", clas, 0)); } else { clas.addChild( new Classification("-99", "Egne klassifikationer", clas, 1)); } bf.close(); return clas; } } Index: Classification.java =================================================================== RCS file: /cvsroot/bprocessor//model/src/net/sourceforge/bprocessor/model/Classification.java,v retrieving revision 1.17 retrieving revision 1.18 diff -C2 -d -r1.17 -r1.18 *** Classification.java 30 May 2007 11:28:49 -0000 1.17 --- Classification.java 25 Jun 2007 10:26:45 -0000 1.18 *************** *** 34,48 **** /** The type of this classification */ ! private String product; ! ! /** The uvalue the classification */ ! private Double uvalue = 0.0; ! ! /** The density the classification */ ! private Double density = 0.0; /** The classification */ ! private Classification productType; ! /** Construction Type */ --- 34,41 ---- /** The type of this classification */ ! private ClassificationType classificationType; /** The classification */ ! private ClassificationType possibleTypes; /** Construction Type */ *************** *** 69,74 **** setId(id); setType(type); ! setParent(parent); ! setProdukt(""); } --- 62,66 ---- setId(id); setType(type); ! setParent(parent); } *************** *** 79,86 **** */ public Classification(String name, int type) { ! setName(name); ! setType(type); ! setId("-1"); ! setProdukt(""); } --- 71,75 ---- */ public Classification(String name, int type) { ! this("-1", name, null, type); } *************** *** 90,97 **** */ public Classification(int type) { ! setName("Classification"); ! setId("0"); ! setType(type); ! setProdukt(""); } --- 79,83 ---- */ public Classification(int type) { ! this("0", "Classification", null, type); } *************** *** 169,181 **** Space current = cur; String fullId = id; ! if (current != null && current.getTypeClassification() != null) { if (!("" + fullId.charAt(0)).equalsIgnoreCase("-")) { ! if (!current.getTypeClassification().getId().equalsIgnoreCase("0")) { ! fullId = current.getTypeClassification().getId() + fullId; ! } } else { ! if (!current.getTypeClassification().getId().equalsIgnoreCase("0")) { ! fullId = "-" + current.getTypeClassification().getId() + fullId.replaceFirst("-", ""); ! } } } --- 155,163 ---- Space current = cur; String fullId = id; ! if (current != null && current.getClassificationType() != null) { if (!("" + fullId.charAt(0)).equalsIgnoreCase("-")) { ! fullId = current.getClassificationType().getName(); } else { ! fullId = "-" + current.getClassificationType().getName() + fullId.replaceFirst("-", ""); } } *************** *** 228,244 **** /** ! * Get the different types for this classification * @return produkt the produkt types */ ! public String getProduct() { ! return product; } /** ! * Set the produkt type for this classification ! * @param produkt the produkt types */ ! public void setProdukt(String produkt) { ! this.product = produkt; } --- 210,226 ---- /** ! * Get the root type for this classification * @return produkt the produkt types */ ! public ClassificationType getPossibleTypes() { ! return possibleTypes; } /** ! * Set the classification type for this classification ! * @param rootType the root classification type */ ! public void setPossibleTypes(ClassificationType rootType) { ! this.possibleTypes = rootType; } *************** *** 253,258 **** res.add(new Attribute("U-value", getUvalue(), true)); res.add(new Attribute("Density", getDensity(), true)); ! if (productType != null) { ! res.add(new Attribute("Type", productType)); } return res; --- 235,240 ---- res.add(new Attribute("U-value", getUvalue(), true)); res.add(new Attribute("Density", getDensity(), true)); ! if (classificationType != null) { ! res.add(new Attribute("Type", classificationType)); } return res; *************** *** 272,283 **** while (iter.hasNext()) { Attribute a = (Attribute)iter.next(); - if (a.getName().equals("U-value")) { - setUvalue((Double)a.getValue()); - } - if (a.getName().equals("Density")) { - setDensity((Double)a.getValue()); - } if (a.getName().equals("Type")) { ! setTypeClassification((Classification)a.getValue()); } } --- 254,259 ---- while (iter.hasNext()) { Attribute a = (Attribute)iter.next(); if (a.getName().equals("Type")) { ! setClassificationType((ClassificationType)a.getValue()); } } *************** *** 290,302 **** */ public Double getUvalue() { ! return uvalue; ! } ! ! /** ! * Set the U-value for this classification ! * @param uvalue the U-value ! */ ! public void setUvalue(Double uvalue) { ! this.uvalue = uvalue; } --- 266,270 ---- */ public Double getUvalue() { ! return getClassificationType().getUvalue(); } *************** *** 306,320 **** */ public Double getDensity() { ! return density; ! } ! ! /** ! * Set the density for this classification ! * @param density the density ! */ ! public void setDensity(Double density) { ! this.density = density; } - /** --- 274,279 ---- */ public Double getDensity() { ! return getClassificationType().getDensity(); } /** *************** *** 322,327 **** * @return The product type */ ! public Classification getTypeClassification() { ! return productType; } /** --- 281,286 ---- * @return The product type */ ! public ClassificationType getClassificationType() { ! return classificationType; } /** *************** *** 329,334 **** * @param productType The product type */ ! public void setTypeClassification(Classification productType) { ! this.productType = productType; } } --- 288,293 ---- * @param productType The product type */ ! public void setClassificationType(ClassificationType productType) { ! this.classificationType = productType; } } Index: Persistence.java =================================================================== RCS file: /cvsroot/bprocessor//model/src/net/sourceforge/bprocessor/model/Persistence.java,v retrieving revision 1.38 retrieving revision 1.39 diff -C2 -d -r1.38 -r1.39 *** Persistence.java 18 May 2007 19:08:17 -0000 1.38 --- Persistence.java 25 Jun 2007 10:26:46 -0000 1.39 *************** *** 1,1405 **** ! //--------------------------------------------------------------------------------- ! // $Id$ ! // ! // Copyright (c) 2005 The BProcessor Team (http://bprocessor.sourceforge.net) ! // Released under the Lesser GNU Public License v2.1 ! //--------------------------------------------------------------------------------- ! package net.sourceforge.bprocessor.model; ! ! import net.sourceforge.bprocessor.model.modellor.Modellor; ! import net.sourceforge.bprocessor.model.xml.AxisRotateType; [...2866 lines suppressed...] ! * @return the xml object ! */ ! private static XMLSpecificType externalizeClassificationType(ClassificationType type) { ! XMLSpecificType xml = new XMLSpecificTypeImpl(); ! xml.setIndex(type.getIndex()); ! xml.setName(type.getName()); ! for (ClassificationType clasType : type.getSubTypes()) { ! if (clasType != null) { ! xml.getXMLSpecificType().add(Persistence.externalizeClassificationType(clasType)); ! } else { ! log.warn("One subtype in " + type + " were null"); ! } ! } ! Map map = new HashMap(); ! for (Attribute a : type.getAttributes()) { ! xml.getAttributes().add(externalizeKeyValue(a.getName(), a.getValue(), map)); ! } ! return xml; ! } ! } Index: Project.java =================================================================== RCS file: /cvsroot/bprocessor//model/src/net/sourceforge/bprocessor/model/Project.java,v retrieving revision 1.128 retrieving revision 1.129 diff -C2 -d -r1.128 -r1.129 *** Project.java 19 Jun 2007 14:03:27 -0000 1.128 --- Project.java 25 Jun 2007 10:26:45 -0000 1.129 *************** *** 1,1181 **** ! //--------------------------------------------------------------------------------- ! // $Id$ ! // ! // Copyright (c) 2005 The BProcessor Team (http://bprocessor.sourceforge.net) ! // Released under the Lesser GNU Public License v2.1 ! //--------------------------------------------------------------------------------- ! ! package net.sourceforge.bprocessor.model; ! ! import java.io.BufferedReader; [...2086 lines suppressed...] ! Iterator it = cl.getChildren().iterator(); ! while (it.hasNext()) { ! Classification current = (Classification) it.next(); ! if (curid.equalsIgnoreCase(current.getId())) { ! cl = current; ! } ! } ! } ! } ! return cl; ! } ! ! /** ! * getter for the copy buffer ! * @return The copyBuffer ! */ ! public Collection<Geometric> getCopyBuffer() { ! return copyBuffer; ! } ! } Index: Space.java =================================================================== RCS file: /cvsroot/bprocessor//model/src/net/sourceforge/bprocessor/model/Space.java,v retrieving revision 1.150 retrieving revision 1.151 diff -C2 -d -r1.150 -r1.151 *** Space.java 7 Jun 2007 07:04:40 -0000 1.150 --- Space.java 25 Jun 2007 10:26:45 -0000 1.151 *************** *** 125,129 **** /** The classification */ ! private Classification productType; /** If the constructionspace is transparent */ --- 125,129 ---- /** The classification */ ! private ClassificationType productType; /** If the constructionspace is transparent */ *************** *** 1132,1136 **** * @return The product type */ ! public Classification getTypeClassification() { return productType; } --- 1132,1136 ---- * @return The product type */ ! public ClassificationType getClassificationType() { return productType; } *************** *** 1139,1143 **** * @param productType The product type */ ! public void setTypeClassification(Classification productType) { this.productType = productType; } --- 1139,1143 ---- * @param productType The product type */ ! public void setClassificationType(ClassificationType productType) { this.productType = productType; } *************** *** 1494,1498 **** } } else if (a.getName().equals("Type")) { ! setTypeClassification((((Classification)a.getClassification()))); } else if (a.getName().equals("Building")) { setBuilding(((String)a.getValue().toString())); --- 1494,1498 ---- } } else if (a.getName().equals("Type")) { ! //TODO make ClassificationType attributes } else if (a.getName().equals("Building")) { setBuilding(((String)a.getValue().toString())); *************** *** 1566,1572 **** } } ! if (getClassification() != null && !getClassification().getProduct().equalsIgnoreCase("")) { ! res.add(new Attribute("Type", Project.getInstance(). ! getType(getClassification().getName()), getTypeClassification(), this)); } if (isFunctionalSpace()) { --- 1566,1573 ---- } } ! if (getClassification() != null && getClassification().getClassificationType() != null) { ! //TODO make classificationType attribute ! //res.add(new Attribute("Type", getClassification().getClassificationType(), ! // getClassificationType(), this)); } if (isFunctionalSpace()) { --- NEW FILE: ClassificationType.java --- //--------------------------------------------------------------------------------- // $Id: ClassificationType.java,v 1.1 2007/06/25 10:26:45 rimestad Exp $ // // Copyright (c) 2005 The BProcessor Team (http://bprocessor.sourceforge.net) // Released under the Lesser GNU Public License v2.1 //--------------------------------------------------------------------------------- package net.sourceforge.bprocessor.model; import java.util.ArrayList; import java.util.LinkedList; import java.util.List; /** * A placeholder for the different kind of types that can be * associated with the classifications * @author Rimestad */ public class ClassificationType { private String name; private double uvalue; private double density; private double cost; private List<ClassificationType> subTypes; private int index; /** * constructor * @param name The name for the type * @param uvalue the heatloss value * @param density the density * @param cost the cost pr m2 */ public ClassificationType(String name, double uvalue, double density, double cost) { this.name = name; this.uvalue = uvalue; this.density = density; this.cost = cost; subTypes = new LinkedList<ClassificationType>(); } /** * Add a type as subtype to this * @param subType the type to add */ public void addSubType(ClassificationType subType) { subTypes.add(subType); subType.setIndex(subTypes.size() - 1); } /** * Set the index of the classificationType * @param i The index */ private void setIndex(int i) { this.index = i; } /** * Return the index of the classificationType * @return The index */ public int getIndex() { return this.index; } /** * Return the cost value for the type * @return the cost */ public double getCost() { return cost; } /** * Set the cost for the type * @param cost the cost to set */ public void setCost(double cost) { this.cost = cost; } /** * Return the density of the type * @return the density */ public double getDensity() { return density; } /** * Set the density * @param density the density to set */ public void setDensity(double density) { this.density = density; } /** * Return the name * @return the name */ public String getName() { return name; } /** * @param name the name to set */ public void setName(String name) { this.name = name; } /** * @return the uvalue */ public double getUvalue() { return uvalue; } /** * @param uvalue the uvalue to set */ public void setUvalue(double uvalue) { this.uvalue = uvalue; } /** * @return the subTypes */ public List<ClassificationType> getSubTypes() { return subTypes; } /** * Getter for object attributes * @return the attributes associated with this object */ public List<Attribute> getAttributes() { List<Attribute> res = new ArrayList<Attribute>(); res.add(new Attribute("U-value", uvalue, true)); res.add(new Attribute("Density", density, true)); res.add(new Attribute("Cost", cost, true)); return res; } /** * Set the attribute values * @param attributes The new attribute values */ public void setAttributes(List<Attribute> attributes) { for (Attribute a : attributes) { if (a.getName().equals("U-value")) { uvalue = (Double)a.getValue(); continue; } if (a.getName().equals("Density")) { density = (Double)a.getValue(); continue; } if (a.getName().equals("Cost")) { cost = (Double)a.getValue(); } } } /** * {@inheritDoc} */ public String toString() { return name; } } |
From: rimestad <rim...@us...> - 2007-06-25 10:26:46
|
Update of /cvsroot/bprocessor//model/src/net/sourceforge/bprocessor/model/modellor In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv21452/src/net/sourceforge/bprocessor/model/modellor Modified Files: InnerWallModellor.java Log Message: Have refactored loadClassification and loadType as well as the storing of the types out of the Project and into a new class ClassificationFileLoader. Made A ClassificationType Class holding all type specific info such as u-value etc. Made Classification hold a ClassificationType root for all the possible types it can be. The Space now hold the classification and a ClassificationType that is the chosen Type of the possible types in the chosen classification. Persistence now have mothods to externalize the DBK to XML, but still need a load mechanism. NOTICE THAT PERSISTENCE AND PROJECT SEEM TO HAVE CHANGED INTIRELY BUT THEY HAVEN'T ONLY THE THINGS MENTIONED HERE HAVE BEEN CHANGED Index: InnerWallModellor.java =================================================================== RCS file: /cvsroot/bprocessor//model/src/net/sourceforge/bprocessor/model/modellor/InnerWallModellor.java,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** InnerWallModellor.java 18 May 2007 19:10:23 -0000 1.4 --- InnerWallModellor.java 25 Jun 2007 10:26:46 -0000 1.5 *************** *** 218,222 **** space.add(base); Space joist = new Space("joist", Space.CONSTRUCTION, space.getLevel() + 1, true); ! joist.setClassification(woodJoist()); space.add(joist); Vertex dir = e.getDirection(); --- 218,223 ---- space.add(base); Space joist = new Space("joist", Space.CONSTRUCTION, space.getLevel() + 1, true); ! Classification c = Project.getInstance().getClassification("-1.-205.01.01", 0); ! joist.setClassificationType(c.getPossibleTypes().getSubTypes().get(0)); space.add(joist); Vertex dir = e.getDirection(); *************** *** 733,743 **** } - private static Classification woodJoist() { - Classification c = Project.getInstance().getClassification("-1.-205.01.01", 0); - Classification type = Project.getInstance().getProductType("-1.-205.01.A01"); - c.setTypeClassification(type); - return c; - } - private static Classification woodSheet() { Classification c = Project.getInstance().getClassification("-1.-205.01.03", 0); --- 734,737 ---- |
From: rimestad <rim...@us...> - 2007-06-25 09:02:52
|
Update of /cvsroot/bprocessor//model In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv20425 Modified Files: build.xml Log Message: made small changes to the classification schema and made the build script handle several schemas when compiling Index: build.xml =================================================================== RCS file: /cvsroot/bprocessor//model/build.xml,v retrieving revision 1.18 retrieving revision 1.19 diff -C2 -d -r1.18 -r1.19 *** build.xml 2 Jan 2007 17:27:10 -0000 1.18 --- build.xml 25 Jun 2007 09:02:46 -0000 1.19 *************** *** 97,104 **** </classpath> </taskdef> ! <xjc schema="${conf.dir}/bprocessor.xsd" ! target="${xml.dir}" ! package="net.sourceforge.bprocessor.model.xml"> <arg value="-extension"/> </xjc> <javac srcdir="${xml.dir}" destdir="${xml.dir}" deprecation="yes" --- 97,104 ---- </classpath> </taskdef> ! <xjc target="${xml.dir}" ! package="net.sourceforge.bprocessor.model.xml"> <arg value="-extension"/> + <schema dir="${conf.dir}" includes="*.xsd"/> </xjc> <javac srcdir="${xml.dir}" destdir="${xml.dir}" deprecation="yes" |
From: rimestad <rim...@us...> - 2007-06-25 09:02:52
|
Update of /cvsroot/bprocessor//model/src/etc In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv20425/src/etc Modified Files: classification.xsd Log Message: made small changes to the classification schema and made the build script handle several schemas when compiling Index: classification.xsd =================================================================== RCS file: /cvsroot/bprocessor//model/src/etc/classification.xsd,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** classification.xsd 21 Jun 2007 11:49:14 -0000 1.3 --- classification.xsd 25 Jun 2007 09:02:45 -0000 1.4 *************** *** 17,22 **** <xsd:sequence> <xsd:element ref="cns:XMLSpecificType" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element name="attributes" type="MapElementType" maxOccurs="unbounded"/> </xsd:sequence> </xsd:complexType> </xsd:element> --- 17,24 ---- <xsd:sequence> <xsd:element ref="cns:XMLSpecificType" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element name="attributes" type="MapElementType" maxOccurs="unbounded" minOccurs="0"/> </xsd:sequence> + <xsd:attribute name="index" type="xsd:int" use="required"/> + <xsd:attribute name="name" type="xsd:string" use="required"/> </xsd:complexType> </xsd:element> *************** *** 25,30 **** <xsd:complexType> <xsd:sequence> ! <xsd:element ref="cns:XMLClassification" maxOccurs="unbounded"/> ! <xsd:element ref="cns:XMLSpecificType" maxOccurs="unbounded" minOccurs="0"/> </xsd:sequence> <xsd:attribute name="id" type="xsd:string" use="required"/> --- 27,32 ---- <xsd:complexType> <xsd:sequence> ! <xsd:element ref="cns:XMLClassification" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="cns:XMLSpecificType" maxOccurs="1" minOccurs="0"/> </xsd:sequence> <xsd:attribute name="id" type="xsd:string" use="required"/> |
From: rimestad <rim...@us...> - 2007-06-21 11:49:36
|
Update of /cvsroot/bprocessor//model/src/etc In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv15869/src/etc Modified Files: classification.xsd bprocessor.xsd Log Message: removed namespace from bprocessor schema and made it work without Index: classification.xsd =================================================================== RCS file: /cvsroot/bprocessor//model/src/etc/classification.xsd,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** classification.xsd 20 Jun 2007 12:07:28 -0000 1.2 --- classification.xsd 21 Jun 2007 11:49:14 -0000 1.3 *************** *** 5,16 **** $Id$ --> ! <xsd:schema ! xmlns:cls="http://bprocessor.sourceforge.net" xmlns:xsd="http://www.w3.org/2001/XMLSchema" - xmlns:bpr="bpr" xmlns:cns="classificationNS" targetNamespace="classificationNS"> ! <xsd:import namespace="bpr" schemaLocation="bprocessor.xsd"/> <!-- element definitions --> --- 5,14 ---- $Id$ --> ! <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:cns="classificationNS" targetNamespace="classificationNS"> ! <xsd:import schemaLocation="bprocessor.xsd"/> <!-- element definitions --> *************** *** 19,23 **** <xsd:sequence> <xsd:element ref="cns:XMLSpecificType" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element name="attributes" type="bpr:MapElementType" maxOccurs="unbounded"/> </xsd:sequence> </xsd:complexType> --- 17,21 ---- <xsd:sequence> <xsd:element ref="cns:XMLSpecificType" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element name="attributes" type="MapElementType" maxOccurs="unbounded"/> </xsd:sequence> </xsd:complexType> *************** *** 28,32 **** <xsd:sequence> <xsd:element ref="cns:XMLClassification" maxOccurs="unbounded"/> ! <xsd:element ref="cns:XMLSpecificType" maxOccurs="unbounded" minOccurs="1"/> </xsd:sequence> <xsd:attribute name="id" type="xsd:string" use="required"/> --- 26,30 ---- <xsd:sequence> <xsd:element ref="cns:XMLClassification" maxOccurs="unbounded"/> ! <xsd:element ref="cns:XMLSpecificType" maxOccurs="unbounded" minOccurs="0"/> </xsd:sequence> <xsd:attribute name="id" type="xsd:string" use="required"/> Index: bprocessor.xsd =================================================================== RCS file: /cvsroot/bprocessor//model/src/etc/bprocessor.xsd,v retrieving revision 1.30 retrieving revision 1.31 diff -C2 -d -r1.30 -r1.31 *** bprocessor.xsd 20 Jun 2007 12:07:28 -0000 1.30 --- bprocessor.xsd 21 Jun 2007 11:49:15 -0000 1.31 *************** *** 6,14 **** --> <xsd:schema ! xmlns:bpr="bpr" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:jaxb="http://java.sun.com/xml/ns/jaxb" xmlns:xjc="http://java.sun.com/xml/ns/jaxb/xjc" - targetNamespace="bpr" jaxb:extensionBindingPrefixes="xjc" jaxb:version="1.0"> --- 6,13 ---- --> <xsd:schema ! xmlns:bpr="http://bprocessor.sourceforge.net" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:jaxb="http://java.sun.com/xml/ns/jaxb" xmlns:xjc="http://java.sun.com/xml/ns/jaxb/xjc" jaxb:extensionBindingPrefixes="xjc" jaxb:version="1.0"> *************** *** 29,33 **** <xsd:complexType name="BasicType"> <xsd:complexContent> ! <xsd:extension base="bpr:Types"> <xsd:attribute name="id" type="xsd:long" use="required"/> </xsd:extension> --- 28,32 ---- <xsd:complexType name="BasicType"> <xsd:complexContent> ! <xsd:extension base="Types"> <xsd:attribute name="id" type="xsd:long" use="required"/> </xsd:extension> *************** *** 37,41 **** <xsd:complexType name="EntityType"> <xsd:complexContent> ! <xsd:extension base="bpr:BasicType"> <xsd:attribute name="progid" type="xsd:long" use="optional"/> </xsd:extension> --- 36,40 ---- <xsd:complexType name="EntityType"> <xsd:complexContent> ! <xsd:extension base="BasicType"> <xsd:attribute name="progid" type="xsd:long" use="optional"/> </xsd:extension> *************** *** 53,59 **** <xsd:complexType name="ClipplaneType"> <xsd:complexContent> ! <xsd:extension base="bpr:EntityType"> <xsd:sequence> ! <xsd:element name="coordinateSystem" type="bpr:CoordinateSystemType" maxOccurs="1" minOccurs="1"/> </xsd:sequence> <xsd:attribute name="Active" type="xsd:boolean" use="required"/> --- 52,58 ---- <xsd:complexType name="ClipplaneType"> <xsd:complexContent> ! <xsd:extension base="EntityType"> <xsd:sequence> ! <xsd:element name="coordinateSystem" type="CoordinateSystemType" maxOccurs="1" minOccurs="1"/> </xsd:sequence> <xsd:attribute name="Active" type="xsd:boolean" use="required"/> *************** *** 67,79 **** <xsd:complexType name="CameraType"> <xsd:complexContent> ! <xsd:extension base="bpr:EntityType"> <xsd:sequence> <xsd:element name="scalefactor" type="xsd:int" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="camera" type="bpr:TripletType" maxOccurs="1" minOccurs="1"/> ! <xsd:element name="center" type="bpr:TripletType" maxOccurs="1" minOccurs="1"/> ! <xsd:element name="roll" type="bpr:TripletType" maxOccurs="1" minOccurs="1"/> <xsd:element name="focalwidth" type="xsd:double" maxOccurs="1" minOccurs="1"/> <xsd:element name="type" type="xsd:int" maxOccurs="1" minOccurs="1"/> ! <xsd:element name="clipplanes" type="bpr:ClipplaneType" maxOccurs="unbounded" minOccurs="0"/> </xsd:sequence> <xsd:attribute name="name" type="xsd:string" use="required"/> --- 66,78 ---- <xsd:complexType name="CameraType"> <xsd:complexContent> ! <xsd:extension base="EntityType"> <xsd:sequence> <xsd:element name="scalefactor" type="xsd:int" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="camera" type="TripletType" maxOccurs="1" minOccurs="1"/> ! <xsd:element name="center" type="TripletType" maxOccurs="1" minOccurs="1"/> ! <xsd:element name="roll" type="TripletType" maxOccurs="1" minOccurs="1"/> <xsd:element name="focalwidth" type="xsd:double" maxOccurs="1" minOccurs="1"/> <xsd:element name="type" type="xsd:int" maxOccurs="1" minOccurs="1"/> ! <xsd:element name="clipplanes" type="ClipplaneType" maxOccurs="unbounded" minOccurs="0"/> </xsd:sequence> <xsd:attribute name="name" type="xsd:string" use="required"/> *************** *** 84,88 **** <xsd:complexType name="NetType"> <xsd:complexContent> ! <xsd:extension base="bpr:SpaceType"> </xsd:extension> </xsd:complexContent> --- 83,87 ---- <xsd:complexType name="NetType"> <xsd:complexContent> ! <xsd:extension base="SpaceType"> </xsd:extension> </xsd:complexContent> *************** *** 91,107 **** <xsd:complexType name="SpaceType"> <xsd:complexContent> ! <xsd:extension base="bpr:EntityType"> <xsd:sequence> <xsd:element name="description" type="xsd:string" maxOccurs="1" minOccurs="0"/> <xsd:element name="Classification" type="xsd:string" maxOccurs="1" minOccurs="0"/> <xsd:element name="boundary" type="xsd:long" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element name="constructor" type="bpr:ConstructorType" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element name="modellor" type="bpr:ModellorType" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="transforms" type="bpr:TransformType" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="bpr:space" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="bpr:surface" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="bpr:edge" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="bpr:vertex" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="bpr:material" maxOccurs="unbounded" minOccurs="0"/> </xsd:sequence> <xsd:attribute name="type" type="xsd:int" use="required"/> --- 90,106 ---- <xsd:complexType name="SpaceType"> <xsd:complexContent> ! <xsd:extension base="EntityType"> <xsd:sequence> <xsd:element name="description" type="xsd:string" maxOccurs="1" minOccurs="0"/> <xsd:element name="Classification" type="xsd:string" maxOccurs="1" minOccurs="0"/> <xsd:element name="boundary" type="xsd:long" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element name="constructor" type="ConstructorType" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element name="modellor" type="ModellorType" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="transforms" type="TransformType" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="space" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="surface" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="edge" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="vertex" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="material" maxOccurs="unbounded" minOccurs="0"/> </xsd:sequence> <xsd:attribute name="type" type="xsd:int" use="required"/> *************** *** 118,122 **** <xsd:complexType name="SurfaceType"> <xsd:complexContent> ! <xsd:extension base="bpr:EntityType"> <xsd:sequence> <xsd:element name="edgeref" type="xsd:long" maxOccurs="unbounded" minOccurs="0"/> --- 117,121 ---- <xsd:complexType name="SurfaceType"> <xsd:complexContent> ! <xsd:extension base="EntityType"> <xsd:sequence> <xsd:element name="edgeref" type="xsd:long" maxOccurs="unbounded" minOccurs="0"/> *************** *** 134,138 **** <xsd:complexType name="EdgeType"> <xsd:complexContent> ! <xsd:extension base="bpr:EntityType"> <xsd:sequence> <xsd:element name="from" type="xsd:long" maxOccurs="1" minOccurs="0"/> --- 133,137 ---- <xsd:complexType name="EdgeType"> <xsd:complexContent> ! <xsd:extension base="EntityType"> <xsd:sequence> <xsd:element name="from" type="xsd:long" maxOccurs="1" minOccurs="0"/> *************** *** 146,150 **** <xsd:complexType name="VertexType"> <xsd:complexContent> ! <xsd:extension base="bpr:EntityType"> <xsd:attribute name="x" type="xsd:double" use="required"/> <xsd:attribute name="y" type="xsd:double" use="required"/> --- 145,149 ---- <xsd:complexType name="VertexType"> <xsd:complexContent> ! <xsd:extension base="EntityType"> <xsd:attribute name="x" type="xsd:double" use="required"/> <xsd:attribute name="y" type="xsd:double" use="required"/> *************** *** 156,160 **** <xsd:complexType name="MaterialType"> <xsd:complexContent> ! <xsd:extension base="bpr:EntityType"> <xsd:attribute name="name" type="xsd:string" use="required"/> <xsd:attribute name="R" type="xsd:float" use="required"/> --- 155,159 ---- <xsd:complexType name="MaterialType"> <xsd:complexContent> ! <xsd:extension base="EntityType"> <xsd:attribute name="name" type="xsd:string" use="required"/> <xsd:attribute name="R" type="xsd:float" use="required"/> *************** *** 167,173 **** <xsd:complexType name="ConstructorType"> <xsd:complexContent> ! <xsd:extension base="bpr:EntityType"> <xsd:sequence> ! <xsd:element ref="bpr:vertex" maxOccurs="1" minOccurs="0"/> <xsd:element name="connected" type="xsd:long" maxOccurs="unbounded" minOccurs="0"/> </xsd:sequence> --- 166,172 ---- <xsd:complexType name="ConstructorType"> <xsd:complexContent> ! <xsd:extension base="EntityType"> <xsd:sequence> ! <xsd:element ref="vertex" maxOccurs="1" minOccurs="0"/> <xsd:element name="connected" type="xsd:long" maxOccurs="unbounded" minOccurs="0"/> </xsd:sequence> *************** *** 180,186 **** <xsd:complexType name="LineType"> <xsd:complexContent> ! <xsd:extension base="bpr:ConstructorType"> <xsd:sequence> ! <xsd:element ref="bpr:direction" maxOccurs="1" minOccurs="0"/> </xsd:sequence> </xsd:extension> --- 179,185 ---- <xsd:complexType name="LineType"> <xsd:complexContent> ! <xsd:extension base="ConstructorType"> <xsd:sequence> ! <xsd:element ref="direction" maxOccurs="1" minOccurs="0"/> </xsd:sequence> </xsd:extension> *************** *** 190,194 **** <xsd:complexType name="PointType"> <xsd:complexContent> ! <xsd:extension base="bpr:ConstructorType"> <xsd:sequence> </xsd:sequence> --- 189,193 ---- <xsd:complexType name="PointType"> <xsd:complexContent> ! <xsd:extension base="ConstructorType"> <xsd:sequence> </xsd:sequence> *************** *** 200,204 **** <xsd:complexType name="RelationType"> <xsd:complexContent> ! <xsd:extension base="bpr:Types"> <xsd:sequence> </xsd:sequence> --- 199,203 ---- <xsd:complexType name="RelationType"> <xsd:complexContent> ! <xsd:extension base="Types"> <xsd:sequence> </xsd:sequence> *************** *** 211,218 **** <xsd:complexType name="CoordinateSystemType"> <xsd:complexContent> ! <xsd:extension base="bpr:ConstructorType"> <xsd:sequence> ! <xsd:element ref="bpr:ijn" maxOccurs="1" minOccurs="0"/> ! <xsd:element ref="bpr:relation" maxOccurs="unbounded" minOccurs="0"/> </xsd:sequence> <xsd:attribute name="onlyplane" type="xsd:boolean" use="required"/> --- 210,217 ---- <xsd:complexType name="CoordinateSystemType"> <xsd:complexContent> ! <xsd:extension base="ConstructorType"> <xsd:sequence> ! <xsd:element ref="ijn" maxOccurs="1" minOccurs="0"/> ! <xsd:element ref="relation" maxOccurs="unbounded" minOccurs="0"/> </xsd:sequence> <xsd:attribute name="onlyplane" type="xsd:boolean" use="required"/> *************** *** 223,227 **** <xsd:complexType name="VertexesType"> <xsd:sequence> ! <xsd:element ref="bpr:vertex" maxOccurs="unbounded" minOccurs="0"/> </xsd:sequence> </xsd:complexType> --- 222,226 ---- <xsd:complexType name="VertexesType"> <xsd:sequence> ! <xsd:element ref="vertex" maxOccurs="unbounded" minOccurs="0"/> </xsd:sequence> </xsd:complexType> *************** *** 229,235 **** <xsd:complexType name="ModellorType"> <xsd:complexContent> ! <xsd:extension base="bpr:EntityType"> <xsd:sequence> ! <xsd:element name="attribute" type="bpr:MapElementType" maxOccurs="unbounded" minOccurs="0"/> </xsd:sequence> <xsd:attribute name="ty" type="xsd:string"/> --- 228,234 ---- <xsd:complexType name="ModellorType"> <xsd:complexContent> ! <xsd:extension base="EntityType"> <xsd:sequence> ! <xsd:element name="attribute" type="MapElementType" maxOccurs="unbounded" minOccurs="0"/> </xsd:sequence> <xsd:attribute name="ty" type="xsd:string"/> *************** *** 244,248 **** <xsd:complexType name="RefType"> <xsd:complexContent> ! <xsd:extension base="bpr:Types"> <xsd:sequence> <xsd:element name="ref" type="xsd:long" maxOccurs="1" minOccurs="1"/> --- 243,247 ---- <xsd:complexType name="RefType"> <xsd:complexContent> ! <xsd:extension base="Types"> <xsd:sequence> <xsd:element name="ref" type="xsd:long" maxOccurs="1" minOccurs="1"/> *************** *** 254,258 **** <xsd:complexType name="IntegerType"> <xsd:complexContent> ! <xsd:extension base="bpr:Types"> <xsd:sequence> <xsd:element name="integer" type="xsd:int" maxOccurs="1" minOccurs="1"/> --- 253,257 ---- <xsd:complexType name="IntegerType"> <xsd:complexContent> ! <xsd:extension base="Types"> <xsd:sequence> <xsd:element name="integer" type="xsd:int" maxOccurs="1" minOccurs="1"/> *************** *** 264,268 **** <xsd:complexType name="DoubleType"> <xsd:complexContent> ! <xsd:extension base="bpr:Types"> <xsd:sequence> <xsd:element name="double" type="xsd:double" maxOccurs="1" minOccurs="1"/> --- 263,267 ---- <xsd:complexType name="DoubleType"> <xsd:complexContent> ! <xsd:extension base="Types"> <xsd:sequence> <xsd:element name="double" type="xsd:double" maxOccurs="1" minOccurs="1"/> *************** *** 274,278 **** <xsd:complexType name="BooleanType"> <xsd:complexContent> ! <xsd:extension base="bpr:Types"> <xsd:sequence> <xsd:element name="boolean" type="xsd:boolean" maxOccurs="1" minOccurs="1"/> --- 273,277 ---- <xsd:complexType name="BooleanType"> <xsd:complexContent> ! <xsd:extension base="Types"> <xsd:sequence> <xsd:element name="boolean" type="xsd:boolean" maxOccurs="1" minOccurs="1"/> *************** *** 284,288 **** <xsd:complexType name="StringType"> <xsd:complexContent> ! <xsd:extension base="bpr:Types"> <xsd:sequence> <xsd:element name="string" type="xsd:string" maxOccurs="1" minOccurs="1"/> --- 283,287 ---- <xsd:complexType name="StringType"> <xsd:complexContent> ! <xsd:extension base="Types"> <xsd:sequence> <xsd:element name="string" type="xsd:string" maxOccurs="1" minOccurs="1"/> *************** *** 295,299 **** <xsd:sequence> <xsd:element name="key" type="xsd:string" maxOccurs="1" minOccurs="1"/> ! <xsd:element name="value" type="bpr:Types" maxOccurs="1" minOccurs="1"/> </xsd:sequence> </xsd:complexType> --- 294,298 ---- <xsd:sequence> <xsd:element name="key" type="xsd:string" maxOccurs="1" minOccurs="1"/> ! <xsd:element name="value" type="Types" maxOccurs="1" minOccurs="1"/> </xsd:sequence> </xsd:complexType> *************** *** 305,309 **** <xsd:complexType name="RotateType"> <xsd:complexContent> ! <xsd:extension base="bpr:TransformType"> <xsd:attribute name="x" type="xsd:double" use="required"/> <xsd:attribute name="y" type="xsd:double" use="required"/> --- 304,308 ---- <xsd:complexType name="RotateType"> <xsd:complexContent> ! <xsd:extension base="TransformType"> <xsd:attribute name="x" type="xsd:double" use="required"/> <xsd:attribute name="y" type="xsd:double" use="required"/> *************** *** 315,319 **** <xsd:complexType name="TranslateType"> <xsd:complexContent> ! <xsd:extension base="bpr:TransformType"> <xsd:attribute name="x" type="xsd:double" use="required"/> <xsd:attribute name="y" type="xsd:double" use="required"/> --- 314,318 ---- <xsd:complexType name="TranslateType"> <xsd:complexContent> ! <xsd:extension base="TransformType"> <xsd:attribute name="x" type="xsd:double" use="required"/> <xsd:attribute name="y" type="xsd:double" use="required"/> *************** *** 325,329 **** <xsd:complexType name="ScaleType"> <xsd:complexContent> ! <xsd:extension base="bpr:TransformType"> <xsd:attribute name="x" type="xsd:double" use="required"/> <xsd:attribute name="y" type="xsd:double" use="required"/> --- 324,328 ---- <xsd:complexType name="ScaleType"> <xsd:complexContent> ! <xsd:extension base="TransformType"> <xsd:attribute name="x" type="xsd:double" use="required"/> <xsd:attribute name="y" type="xsd:double" use="required"/> *************** *** 335,339 **** <xsd:complexType name="AxisRotateType"> <xsd:complexContent> ! <xsd:extension base="bpr:TransformType"> <xsd:attribute name="x" type="xsd:double" use="required"/> <xsd:attribute name="y" type="xsd:double" use="required"/> --- 334,338 ---- <xsd:complexType name="AxisRotateType"> <xsd:complexContent> ! <xsd:extension base="TransformType"> <xsd:attribute name="x" type="xsd:double" use="required"/> <xsd:attribute name="y" type="xsd:double" use="required"/> *************** *** 346,350 **** <xsd:complexType name="IDTransformType"> <xsd:complexContent> ! <xsd:extension base="bpr:TransformType"> </xsd:extension> </xsd:complexContent> --- 345,349 ---- <xsd:complexType name="IDTransformType"> <xsd:complexContent> ! <xsd:extension base="TransformType"> </xsd:extension> </xsd:complexContent> *************** *** 352,364 **** <!-- Element definitions --> ! <xsd:element name="space" type="bpr:SpaceType"/> ! <xsd:element name="surface" type="bpr:SurfaceType"/> ! <xsd:element name="edge" type="bpr:EdgeType"/> ! <xsd:element name="vertex" type="bpr:VertexType"/> ! <xsd:element name="material" type="bpr:MaterialType"/> ! <xsd:element name="origin" type="bpr:VertexType"/> ! <xsd:element name="direction" type="bpr:VertexesType"/> ! <xsd:element name="ijn" type="bpr:VertexesType"/> ! <xsd:element name="relation" type="bpr:RelationType"/> <!-- Main element --> --- 351,363 ---- <!-- Element definitions --> ! <xsd:element name="space" type="SpaceType"/> ! <xsd:element name="surface" type="SurfaceType"/> ! <xsd:element name="edge" type="EdgeType"/> ! <xsd:element name="vertex" type="VertexType"/> ! <xsd:element name="material" type="MaterialType"/> ! <xsd:element name="origin" type="VertexType"/> ! <xsd:element name="direction" type="VertexesType"/> ! <xsd:element name="ijn" type="VertexesType"/> ! <xsd:element name="relation" type="RelationType"/> <!-- Main element --> *************** *** 369,380 **** <xsd:element name="cs" type="xsd:long" maxOccurs="1" minOccurs="0"/> <xsd:element name="name" type="xsd:string" maxOccurs="1" minOccurs="0"/> ! <xsd:element ref="bpr:space" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="bpr:surface" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="bpr:edge" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="bpr:vertex" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="bpr:material" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element name="camera" type="bpr:CameraType" maxOccurs="unbounded" minOccurs="0"/> </xsd:sequence> </xsd:complexType> </xsd:element> </xsd:schema> --- 368,380 ---- <xsd:element name="cs" type="xsd:long" maxOccurs="1" minOccurs="0"/> <xsd:element name="name" type="xsd:string" maxOccurs="1" minOccurs="0"/> ! <xsd:element ref="space" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="surface" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="edge" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="vertex" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="material" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element name="camera" type="CameraType" maxOccurs="unbounded" minOccurs="0"/> </xsd:sequence> </xsd:complexType> </xsd:element> + </xsd:schema> |
From: Michael L. <he...@us...> - 2007-06-21 10:11:43
|
Update of /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv7371/src/net/sourceforge/bprocessor/gl/tool Modified Files: ExtrusionTool.java Log Message: Removed some alerts Index: ExtrusionTool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/ExtrusionTool.java,v retrieving revision 1.60 retrieving revision 1.61 diff -C2 -d -r1.60 -r1.61 *** ExtrusionTool.java 21 Jun 2007 09:52:54 -0000 1.60 --- ExtrusionTool.java 21 Jun 2007 10:01:06 -0000 1.61 *************** *** 22,26 **** import net.sourceforge.bprocessor.gl.view.Transformation; import net.sourceforge.bprocessor.gl.view.View; - import net.sourceforge.bprocessor.gui.GUI; import net.sourceforge.bprocessor.model.Constructor; import net.sourceforge.bprocessor.model.Edge; --- 22,25 ---- *************** *** 326,338 **** if (extrudeEdges.isEmpty()) { extrudeEdges = null; - if (extrudesurface == null) { - GUI.getInstance().alert("Either select a conected set of edges or a single surface" + - " to extrude or select nothing and extrude surfaces"); - } } else { if (extrudesurface != null) { extrudesurface = null; extrudeEdges = null; - GUI.getInstance().alert("Different geometrics in a selection are not extrudeable"); } } --- 325,332 ---- *************** *** 341,346 **** if (target instanceof Surface) { extrudesurface = (Surface) target; - } else { - GUI.getInstance().alert(target + " is not extrudeable only Surfaces are"); } } --- 335,338 ---- |
From: Michael L. <he...@us...> - 2007-06-21 09:52:55
|
Update of /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv4089/src/net/sourceforge/bprocessor/gl/tool Modified Files: ExtrusionTool.java Log Message: Removed some random comments Index: ExtrusionTool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/ExtrusionTool.java,v retrieving revision 1.59 retrieving revision 1.60 diff -C2 -d -r1.59 -r1.60 *** ExtrusionTool.java 20 Jun 2007 13:17:56 -0000 1.59 --- ExtrusionTool.java 21 Jun 2007 09:52:54 -0000 1.60 *************** *** 99,107 **** /** * Extrude ! * @param p the plane to extrude onto * @param all Extrude all * @param finish Finish extrusion */ ! private void extrudeOnto(Plane p, boolean all, boolean finish) { Space space = Project.getInstance().getActiveSpace(); if (extrusion != null) { --- 99,107 ---- /** * Extrude ! * @param plane the plane to extrude onto * @param all Extrude all * @param finish Finish extrusion */ ! private void extrudeOnto(Plane plane, boolean all, boolean finish) { Space space = Project.getInstance().getActiveSpace(); if (extrusion != null) { *************** *** 114,119 **** Set<Surface> tops = new HashSet<Surface>(); Surface top = null; ! if (p == null) { ! // just extrude the distance if (all) { extrudesurface.extrusionall(distance, sides, tops); --- 114,118 ---- Set<Surface> tops = new HashSet<Surface>(); Surface top = null; ! if (plane == null) { if (all) { extrudesurface.extrusionall(distance, sides, tops); *************** *** 123,131 **** } } else { - // extrude to the plane if (all) { ! extrudesurface.extrusionAllOnto(p, sides, tops); } else { ! top = extrudesurface.extrusionOnto(p, sides); extrusion.add(top); } --- 122,129 ---- } } else { if (all) { ! extrudesurface.extrusionAllOnto(plane, sides, tops); } else { ! top = extrudesurface.extrusionOnto(plane, sides); extrusion.add(top); } *************** *** 135,139 **** if (finish) { insert(space, extrusion); - } else { space.addProtected(extrusion); --- 133,136 ---- *************** *** 155,159 **** Vertex dir = to.minus(from); if (plane != null && Math.abs(plane.normal().dot(dir)) <= 0.1) { - // if the planes are parallel plane = null; } --- 152,155 ---- *************** *** 172,181 **** protected void moved(MouseEvent e) { if (extrudesurface != null) { - // a extrudesurface have been chosen to = glv.getView().toPlaneCoords(e.getX(), e.getY(), dragplane); Vertex normal = extrudesurface.normal(); - //a bit cleanup ontoPlane = null; - // the list of all extruded geometric objects Set<Geometric> elements = new HashSet<Geometric>(); if (extrusion != null) { --- 168,174 ---- *************** *** 184,188 **** elements.add(extrudesurface); } - //ignore the extruded surface and holes when extruding Set<Surface> ignore = new HashSet<Surface>(2); ignore.add(extrudesurface); --- 177,180 ---- *************** *** 198,202 **** Vertex cross = normal.cross(n); if (cross.isZero()) { - // the surfaces are coplanar Vertex v = surface.getFirstVertex(); if (!extrudesurface.plane().contains(v)) { --- 190,193 ---- *************** *** 207,211 **** ontoPlane = surface.plane(); if (Math.abs(ontoPlane.normal().dot(normal)) <= 0.1) { - // the two normals have a greater angle between 0 and 84 or 94 and 180 degrees calcDistCallExtrude(to, from, normal); } else { --- 198,201 ---- *************** *** 233,240 **** } } else if (extrudeEdges != null) { - // make the extrusion of edges to = glv.getView().toPlaneCoords(e.getX(), e.getY(), dragplane); - - //list of moving elements Set<Geometric> elements = new HashSet<Geometric>(extrudeEdges); if (extrusion != null) { --- 223,227 ---- *************** *** 242,247 **** elements.addAll(Surface.edges(extrusion)); } - - // ignore the extruded surface and holes when extruding List<Geometric> ignore = new LinkedList<Geometric>(extrudeEdges); if (extrusion != null) { --- 229,232 ---- *************** *** 279,285 **** extrudeEdgesOnto(ontoPlane, false); } else { - // do highlighting if (Selection.primary().isEmpty()) { - //the extrusion isn't started yet findTarget(e); if (target instanceof Surface) { --- 264,268 ---- *************** *** 317,321 **** protected void pressed(MouseEvent e) { if (e.getClickCount() > 1 && extrusion == null) { - // do a extrusion of the same length once more if (extrudesurface != null) { extrudeOnto(ontoPlane, true, true); --- 300,303 ---- *************** *** 326,332 **** if (start == null) { - // initialize the extrusion if (!Selection.primary().isEmpty()) { - //find the selected object to extrude extrudeEdges = new ArrayList<Edge>(); for (Object o : Selection.primary()) { --- 308,312 ---- *************** *** 352,356 **** } else { if (extrudesurface != null) { - // there were both edges and surfaces in the selection extrudesurface = null; extrudeEdges = null; --- 332,335 ---- *************** *** 359,363 **** } } else { - //find the target to extrude findTarget(e); if (target instanceof Surface) { --- 338,341 ---- *************** *** 367,371 **** } } - // Do initialization if (extrudeEdges != null) { startx = e.getX(); --- 345,348 ---- *************** *** 405,409 **** } } else { - // stop the extrusion if (extrudeEdges != null) { if (extrusion != null) { --- 382,385 ---- *************** *** 418,424 **** extrudeOnto(ontoPlane, all, true); } - } else { - //something weird happend - log.error("Got into a finalize state without initialization of either edges or surface"); } extrusion = null; --- 394,397 ---- *************** *** 490,495 **** all = false; dragplane = null; - //keep for repeat - //ontoPlane = null; from = null; to = null; --- 463,466 ---- *************** *** 497,501 **** Project.getInstance().getActiveSpace().removeProtected(extrusion); Project.getInstance().getActiveSpace().computeNextId(); - //Project.getInstance().getActiveSpace().changed(); extrusion = null; } --- 468,471 ---- |
From: Michael L. <he...@us...> - 2007-06-21 09:29:20
|
Update of /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/modellor In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv27503/src/net/sourceforge/bprocessor/model/modellor Modified Files: Frame.java Log Message: Small time progress on frame Index: Frame.java =================================================================== RCS file: /cvsroot/bprocessor/model/src/net/sourceforge/bprocessor/model/modellor/Frame.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** Frame.java 19 Jun 2007 14:03:27 -0000 1.1 --- Frame.java 21 Jun 2007 09:29:14 -0000 1.2 *************** *** 8,16 **** --- 8,19 ---- package net.sourceforge.bprocessor.model.modellor; + import java.util.LinkedList; import java.util.List; import java.util.Map; import net.sourceforge.bprocessor.model.Attribute; + import net.sourceforge.bprocessor.model.Entity; import net.sourceforge.bprocessor.model.Space; + import net.sourceforge.bprocessor.model.Surface; /** *************** *** 18,21 **** --- 21,43 ---- */ public class Frame extends Modellor { + private Space space; + + /** + * Constructor + * + */ + public Frame() { + super(); + } + + /** + * Constructor + * @param space Space + */ + public Frame(Space space) { + super(); + this.space = space; + space.setModellor(this); + } /** {@inheritDoc} */ *************** *** 42,47 **** @Override public Modellor newInstance(Space space) { ! // TODO Auto-generated method stub ! return null; } --- 64,69 ---- @Override public Modellor newInstance(Space space) { ! Modellor modellor = new Frame(space); ! return modellor; } *************** *** 63,68 **** @Override public void update(Object entity) { ! // TODO Auto-generated method stub ! } --- 85,95 ---- @Override public void update(Object entity) { ! System.out.println("update " + space); ! LinkedList<Surface> envelope = new LinkedList(space.getEnvelope()); ! if (!envelope.isEmpty()) { ! Entity.sort(envelope); ! Surface first = envelope.getFirst(); ! System.out.println("first = " + first); ! } } |
From: Michael L. <he...@us...> - 2007-06-21 09:29:18
|
Update of /cvsroot/bprocessor/gui/src/net/sourceforge/bprocessor/gui In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv27492/src/net/sourceforge/bprocessor/gui Modified Files: PopupMenu.java Log Message: Small time progress on frame Index: PopupMenu.java =================================================================== RCS file: /cvsroot/bprocessor/gui/src/net/sourceforge/bprocessor/gui/PopupMenu.java,v retrieving revision 1.36 retrieving revision 1.37 diff -C2 -d -r1.36 -r1.37 *** PopupMenu.java 19 Jun 2007 14:03:32 -0000 1.36 --- PopupMenu.java 21 Jun 2007 09:29:11 -0000 1.37 *************** *** 319,323 **** public void actionPerformed(ActionEvent e) { System.out.println("detail " + modellor); ! modellor.newInstance(space); } }; --- 319,325 ---- public void actionPerformed(ActionEvent e) { System.out.println("detail " + modellor); ! Modellor detailer = modellor.newInstance(space); ! Project.getInstance().changed(Project.getInstance()); ! Project.getInstance().addObserver(detailer); } }; |
From: Nordholt <nor...@us...> - 2007-06-20 13:18:02
|
Update of /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv1195/src/net/sourceforge/bprocessor/gl/tool Modified Files: FocusTool.java FinalMoveTool.java ArcTool.java EraserTool.java OffsetTool.java CameraTool.java CameraWalkTool.java TapeMeasure.java CameraFlyTool.java ExtrusionTool.java ClipplaneTool.java ConstructorTool.java RotationTool.java Log Message: Added simple tips for most tools. Only did a tip for the "final" movetool, other move tools have no tip. Index: OffsetTool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/OffsetTool.java,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** OffsetTool.java 18 May 2007 09:13:17 -0000 1.14 --- OffsetTool.java 20 Jun 2007 13:17:55 -0000 1.15 *************** *** 178,181 **** --- 178,182 ---- lastOffsetPoint = current.vertex().copy(); } + setTip(secondClickTip()); } } else { *************** *** 261,263 **** --- 262,283 ---- } } + + /** + * Tip on how to set the first click + * @return short describtion of what to do + */ + public String initialTip() { + return "Pick a surface to offset or use select tool to choose" + + " specific edges of a surface to offset"; + } + + /** + * Tip on how to set the second click + * @return short describtion of what to do + */ + private String secondClickTip() { + return "Place the offset." + + " Use \"length\" to type a specific distance to offset." + + " Press Escape to cancel offset"; + } } Index: ClipplaneTool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/ClipplaneTool.java,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** ClipplaneTool.java 7 May 2007 13:30:20 -0000 1.11 --- ClipplaneTool.java 20 Jun 2007 13:17:56 -0000 1.12 *************** *** 114,116 **** --- 114,124 ---- cp = null; } + + /** + * Tip on how to set the first click + * @return short describtion of what to do + */ + public String initialTip() { + return "Pick a surface to put a clipplane on and drag it in place."; + } } Index: CameraTool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/CameraTool.java,v retrieving revision 1.12 retrieving revision 1.13 diff -C2 -d -r1.12 -r1.13 *** CameraTool.java 1 Jun 2007 11:52:34 -0000 1.12 --- CameraTool.java 20 Jun 2007 13:17:55 -0000 1.13 *************** *** 76,78 **** --- 76,86 ---- orbit.released(e); } + + /** + * Tip on how to set the first click + * @return short describtion of what to do + */ + public String initialTip() { + return "Drag to rotate camera around the current viewpoint."; + } } Index: ExtrusionTool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/ExtrusionTool.java,v retrieving revision 1.58 retrieving revision 1.59 diff -C2 -d -r1.58 -r1.59 *** ExtrusionTool.java 15 May 2007 11:36:27 -0000 1.58 --- ExtrusionTool.java 20 Jun 2007 13:17:56 -0000 1.59 *************** *** 355,359 **** extrudesurface = null; extrudeEdges = null; ! GUI.getInstance().alert("Different geometrics in a selection ain't extrudeable"); } } --- 355,359 ---- extrudesurface = null; extrudeEdges = null; ! GUI.getInstance().alert("Different geometrics in a selection are not extrudeable"); } } *************** *** 364,368 **** extrudesurface = (Surface) target; } else { ! GUI.getInstance().alert(target + " ain't extrudeable only Surfaces are"); } } --- 364,368 ---- extrudesurface = (Surface) target; } else { ! GUI.getInstance().alert(target + " is not extrudeable only Surfaces are"); } } *************** *** 384,387 **** --- 384,388 ---- start = findIntersection(e); from = start.vertex(); + setTip(secondClickTip()); } else if (extrudesurface != null) { startx = e.getX(); *************** *** 401,404 **** --- 402,406 ---- all = !e.isAltDown(); active = true; + setTip(secondClickTip()); } } else { *************** *** 503,505 **** --- 505,526 ---- super.cleanUp(); } + + /** + * Tip on how to set the first click + * @return short describtion of what to do + */ + public String initialTip() { + return "Pick a surface to extrude or use select tool to select edges to extrude." + + " Double-click a surface to extrude same distance as previous extrusion."; + } + + /** + * Tip on how to set the second click + * @return short describtion of what to do + */ + private String secondClickTip() { + return "Place the extrusion." + + " Use \"length\" to type a specific distance to extrude." + + " Press Escape to cancel extrusion."; + } } Index: TapeMeasure.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/TapeMeasure.java,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** TapeMeasure.java 29 Jan 2007 15:47:15 -0000 1.3 --- TapeMeasure.java 20 Jun 2007 13:17:55 -0000 1.4 *************** *** 118,121 **** --- 118,124 ---- if (current.object() instanceof Edge) { originalEdge = (Edge) current.object(); + setTip(secondClickParaTip()); + } else { + setTip(secondClickTip()); } } else { *************** *** 175,177 **** --- 178,208 ---- super.cleanUp(); } + + /** + * Tip on how to set the first click + * @return short describtion of what to do + */ + public String initialTip() { + return "Pick a point for a new construction line" + + " or pick an edge to make a parrallel constructor"; + } + + /** + * Tip on how to set the second click + * @return short describtion of what to do + */ + private String secondClickTip() { + return "Set a direction for a constructor line. " + + " Press Escape to cancel drawing the constructor."; + } + + /** + * Tip on how to set the second click + * @return short describtion of what to do + */ + private String secondClickParaTip() { + return "Place a parrallel constructor line." + + "Use \"length\" to type a specific distance to the parrallel edge." + + " Press Escape to cancel drawing the constructor."; + } } Index: ArcTool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/ArcTool.java,v retrieving revision 1.16 retrieving revision 1.17 diff -C2 -d -r1.16 -r1.17 *** ArcTool.java 19 Jun 2007 16:11:06 -0000 1.16 --- ArcTool.java 20 Jun 2007 13:17:55 -0000 1.17 *************** *** 254,258 **** private String secondClickTip() { return "Set the second endpoint of the arc." + ! " Use \"length\" to type a specific distance to endpoint" + " Press Escape to cancel drawing"; } --- 254,258 ---- private String secondClickTip() { return "Set the second endpoint of the arc." + ! " Use \"length\" to type a specific distance to endpoint." + " Press Escape to cancel drawing"; } *************** *** 267,270 **** " Press Escape to cancel drawing"; } - } --- 267,269 ---- Index: CameraWalkTool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/CameraWalkTool.java,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** CameraWalkTool.java 1 Jun 2007 11:52:34 -0000 1.7 --- CameraWalkTool.java 20 Jun 2007 13:17:55 -0000 1.8 *************** *** 100,102 **** --- 100,111 ---- Project.getInstance().changed(c); } + + /** + * Tip on how to set the first click + * @return short describtion of what to do + */ + public String initialTip() { + return "Drag to rotate viewpoint around camera." + + " Use arrow keys to move camera in a plane."; + } } Index: CameraFlyTool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/CameraFlyTool.java,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** CameraFlyTool.java 1 Jun 2007 11:52:33 -0000 1.9 --- CameraFlyTool.java 20 Jun 2007 13:17:56 -0000 1.10 *************** *** 101,103 **** --- 101,112 ---- Project.getInstance().changed(c); } + + /** + * Tip on how to set the first click + * @return short describtion of what to do + */ + public String initialTip() { + return "Drag to rotate viewpoint around camera." + + " Use arrow keys to move camera."; + } } Index: FinalMoveTool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/FinalMoveTool.java,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** FinalMoveTool.java 6 Jun 2007 20:14:08 -0000 1.15 --- FinalMoveTool.java 20 Jun 2007 13:17:55 -0000 1.16 *************** *** 168,171 **** --- 168,172 ---- last = from; updateFeedback(); + setTip(secondClickTip()); } else { Geometric geometric = affected.iterator().next(); *************** *** 236,238 **** --- 237,258 ---- copy = false; } + + /** + * Tip on how to set the first click + * @return short describtion of what to do + */ + public String initialTip() { + return "Pick an object to move or use select tool to select object(s)" + + " to move."; + } + + /** + * Tip on how to set the second click + * @return short describtion of what to do + */ + private String secondClickTip() { + return "Pick a point to move to." + + " Use \"length\" to type a specific distance to move." + + " Press Escape to cancel move."; + } } Index: EraserTool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/EraserTool.java,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** EraserTool.java 26 Feb 2007 15:06:36 -0000 1.6 --- EraserTool.java 20 Jun 2007 13:17:55 -0000 1.7 *************** *** 69,72 **** } ! } --- 69,78 ---- } ! /** ! * Tip on how to set the first click ! * @return short describtion of what to do ! */ ! public String initialTip() { ! return "Pick an edge or a vertex to erase"; ! } } Index: ConstructorTool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/ConstructorTool.java,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** ConstructorTool.java 29 Mar 2007 13:50:08 -0000 1.14 --- ConstructorTool.java 20 Jun 2007 13:17:56 -0000 1.15 *************** *** 140,143 **** --- 140,144 ---- start = p1; active = true; + setTip(secondClickTip()); } else { if (p1.vertex().equalEps(current.vertex())) { *************** *** 150,153 **** --- 151,155 ---- } else if (p2 == null) { p2 = current; + setTip(thirdClickTip()); } else { if (p2.vertex().equalEps(current.vertex())) { *************** *** 184,186 **** --- 186,216 ---- process(null); } + + /** + * Tip on how to set the first click + * @return short describtion of what to do + */ + public String initialTip() { + return "Set origin of a constructor." + + " Double-click to make a B-point constructor."; + } + + /** + * Tip on how to set the second click + * @return short describtion of what to do + */ + private String secondClickTip() { + return "Set direction for the first vector of a constructor." + + " Double-click to make a B-line constructor." + + " Press Escape to cancel constructor."; + } + + /** + * Tip on how to set the third click + * @return short describtion of what to do + */ + private String thirdClickTip() { + return "Set direction of second vector of a B-plane." + + " Press Escape to cancel constructor."; + } } Index: FocusTool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/FocusTool.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** FocusTool.java 23 Feb 2007 11:09:18 -0000 1.2 --- FocusTool.java 20 Jun 2007 13:17:55 -0000 1.3 *************** *** 70,72 **** --- 70,80 ---- } } + + /** + * Tip on how to set the first click + * @return short describtion of what to do + */ + public String initialTip() { + return "Pick a surface to focus the camera on."; + } } Index: RotationTool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/RotationTool.java,v retrieving revision 1.26 retrieving revision 1.27 diff -C2 -d -r1.26 -r1.27 *** RotationTool.java 14 Feb 2007 14:27:24 -0000 1.26 --- RotationTool.java 20 Jun 2007 13:17:56 -0000 1.27 *************** *** 155,158 **** --- 155,159 ---- totalAngle = 0; active = true; + setTip(secondClickTip()); } } else if (p2 == null) { *************** *** 167,170 **** --- 168,172 ---- pro.setStart(from); nothits = getAffected(vertices); + setTip(fourthClickTip()); } else { finish(); *************** *** 184,187 **** --- 186,190 ---- pro = new GlProtractor(onto, p1); glv.getView().addGlObjects3D(pro); + setTip(thirdClickTip()); } *************** *** 223,227 **** */ private void updateFeedback() { ! List points = new LinkedList(); List edges = new LinkedList(); if (p1 != null) { --- 226,230 ---- */ private void updateFeedback() { ! List<Vertex> points = new LinkedList<Vertex>(); List edges = new LinkedList(); if (p1 != null) { *************** *** 381,398 **** //restore matrix gl.glPopMatrix(); - - //draw lines - /*gl.glColor3d(0.2, 0.2, 0.2); - gl.glLineWidth(1.0f); - Iterator < Line > iter = edges.iterator(); - while (iter.hasNext()) { - Line l = iter.next(); - Vertex from = l.getPointAt(-1.8 * factor); - Vertex to = l.getPointAt(1.8 * factor); - gl.glBegin(GL.GL_LINE_STRIP); - gl.glVertex3d(from.getX(), from.getY(), from.getZ()); - gl.glVertex3d(to.getX(), to.getY(), to.getZ()); - gl.glEnd(); - }*/ } --- 384,387 ---- *************** *** 427,429 **** --- 416,455 ---- } } + + /** + * Tip on how to set the first click + * @return short describtion of what to do + */ + public String initialTip() { + return "Use select tool to select object(s) to rotate," + + " then pick a center point for the rotation"; + } + + /** + * Tip on how to set the second click + * @return short describtion of what to do + */ + private String secondClickTip() { + return "Set an axis to rotate around." + + " Press Escape to cancel rotation."; + } + + /** + * Tip on how to set the third click + * @return short describtion of what to do + */ + private String thirdClickTip() { + return "Pick a start point of a rotation on the grey disc." + + " Press Escape to cancel rotation."; + } + + /** + * Tip on how to set the fourth click + * @return short describtion of what to do + */ + private String fourthClickTip() { + return "Pick an end point of a rotation on the grey disc." + + " Use \"length\" to type a specific number of degrees to rotate" + + " Press Escape to cancel rotation."; + } } |
From: rimestad <rim...@us...> - 2007-06-20 12:07:29
|
Update of /cvsroot/bprocessor//model/src/etc In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv6968/src/etc Modified Files: classification.xsd bprocessor.xsd Log Message: made bprocessor xml schema use namespace to reuse definitions for the classification schema Index: classification.xsd =================================================================== RCS file: /cvsroot/bprocessor//model/src/etc/classification.xsd,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** classification.xsd 24 Oct 2006 20:39:57 -0000 1.1 --- classification.xsd 20 Jun 2007 12:07:28 -0000 1.2 *************** *** 7,58 **** <xsd:schema xmlns:cls="http://bprocessor.sourceforge.net" ! xmlns:xsd="http://www.w3.org/2001/XMLSchema"> ! ! <!-- Type definitions --> ! <xsd:complexType name="BaseType"> ! <xsd:attribute name="id" type="xsd:long" use="required"/> ! <xsd:attribute name="name" type="xsd:string" use="required"/> ! </xsd:complexType> ! <xsd:complexType name="FirstType"> ! <xsd:complexContent> ! <xsd:extension base="BaseType"> <xsd:sequence> ! <xsd:element ref="second" maxOccurs="unbounded" minOccurs="0"/> </xsd:sequence> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="SecondType"> ! <xsd:complexContent> ! <xsd:extension base="BaseType"> ! <xsd:sequence> ! <xsd:element ref="third" maxOccurs="unbounded" minOccurs="0"/> ! </xsd:sequence> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="ThirdType"> ! <xsd:complexContent> ! <xsd:extension base="BaseType"> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <!-- Element definitions --> ! <xsd:element name="first" type="FirstType"/> ! <xsd:element name="second" type="SecondType"/> ! <xsd:element name="third" type="ThirdType"/> <!-- Main element --> ! <xsd:element name="cla"> <xsd:complexType> <xsd:sequence> ! <xsd:element ref="first" maxOccurs="unbounded" minOccurs="0"/> </xsd:sequence> </xsd:complexType> </xsd:element> - </xsd:schema> \ No newline at end of file --- 7,45 ---- <xsd:schema xmlns:cls="http://bprocessor.sourceforge.net" ! xmlns:xsd="http://www.w3.org/2001/XMLSchema" ! xmlns:bpr="bpr" ! xmlns:cns="classificationNS" ! targetNamespace="classificationNS"> ! <xsd:import namespace="bpr" schemaLocation="bprocessor.xsd"/> ! ! <!-- element definitions --> ! <xsd:element name="XMLSpecificType"> ! <xsd:complexType> <xsd:sequence> ! <xsd:element ref="cns:XMLSpecificType" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element name="attributes" type="bpr:MapElementType" maxOccurs="unbounded"/> </xsd:sequence> ! </xsd:complexType> ! </xsd:element> ! ! <xsd:element name="XMLClassification"> ! <xsd:complexType> ! <xsd:sequence> ! <xsd:element ref="cns:XMLClassification" maxOccurs="unbounded"/> ! <xsd:element ref="cns:XMLSpecificType" maxOccurs="unbounded" minOccurs="1"/> ! </xsd:sequence> ! <xsd:attribute name="id" type="xsd:string" use="required"/> ! <xsd:attribute name="name" type="xsd:string" use="required"/> ! </xsd:complexType> ! </xsd:element> <!-- Main element --> ! <xsd:element name="DBK"> <xsd:complexType> <xsd:sequence> ! <xsd:element ref="cns:XMLClassification" maxOccurs="unbounded"/> </xsd:sequence> </xsd:complexType> </xsd:element> </xsd:schema> \ No newline at end of file Index: bprocessor.xsd =================================================================== RCS file: /cvsroot/bprocessor//model/src/etc/bprocessor.xsd,v retrieving revision 1.29 retrieving revision 1.30 diff -C2 -d -r1.29 -r1.30 *** bprocessor.xsd 13 Mar 2007 09:56:50 -0000 1.29 --- bprocessor.xsd 20 Jun 2007 12:07:28 -0000 1.30 *************** *** 1,380 **** ! <?xml version="1.0" encoding="UTF-8"?> ! <!-- ! XML Schema used for persistence ! ! $Id$ ! --> ! <xsd:schema ! xmlns:bpr="http://bprocessor.sourceforge.net" ! xmlns:xsd="http://www.w3.org/2001/XMLSchema" ! xmlns:jaxb="http://java.sun.com/xml/ns/jaxb" ! xmlns:xjc="http://java.sun.com/xml/ns/jaxb/xjc" ! jaxb:extensionBindingPrefixes="xjc" ! jaxb:version="1.0"> ! ! <!-- Needed for subtypeing --> ! <xsd:annotation> ! <xsd:appinfo> ! <jaxb:globalBindings> ! <xjc:typeSubstitution type="complex"/> ! </jaxb:globalBindings> ! </xsd:appinfo> ! </xsd:annotation> ! ! ! ! <!-- Type definitions --> ! ! <xsd:complexType name="BasicType"> ! <xsd:complexContent> ! <xsd:extension base="Types"> ! <xsd:attribute name="id" type="xsd:long" use="required"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="EntityType"> ! <xsd:complexContent> ! <xsd:extension base="BasicType"> ! <xsd:attribute name="progid" type="xsd:long" use="optional"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! ! ! <xsd:complexType name="TripletType"> ! <xsd:attribute name="x" type="xsd:double" use="required"/> ! <xsd:attribute name="y" type="xsd:double" use="required"/> ! <xsd:attribute name="z" type="xsd:double" use="required"/> ! </xsd:complexType> ! ! <xsd:complexType name="ClipplaneType"> ! <xsd:complexContent> ! <xsd:extension base="EntityType"> ! <xsd:sequence> ! <xsd:element name="coordinateSystem" type="CoordinateSystemType" maxOccurs="1" minOccurs="1"/> ! </xsd:sequence> ! <xsd:attribute name="Active" type="xsd:boolean" use="required"/> ! <xsd:attribute name="friend" type="xsd:long"/> ! <xsd:attribute name="number" type="xsd:int" use="required"/> ! <xsd:attribute name="Slice" type="xsd:boolean" use="required"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="CameraType"> ! <xsd:complexContent> ! <xsd:extension base="EntityType"> ! <xsd:sequence> ! <xsd:element name="scalefactor" type="xsd:int" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="camera" type="TripletType" maxOccurs="1" minOccurs="1"/> ! <xsd:element name="center" type="TripletType" maxOccurs="1" minOccurs="1"/> ! <xsd:element name="roll" type="TripletType" maxOccurs="1" minOccurs="1"/> ! <xsd:element name="focalwidth" type="xsd:double" maxOccurs="1" minOccurs="1"/> ! <xsd:element name="type" type="xsd:int" maxOccurs="1" minOccurs="1"/> ! <xsd:element name="clipplanes" type="ClipplaneType" maxOccurs="unbounded" minOccurs="0"/> ! </xsd:sequence> ! <xsd:attribute name="name" type="xsd:string" use="required"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="NetType"> ! <xsd:complexContent> ! <xsd:extension base="SpaceType"> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="SpaceType"> ! <xsd:complexContent> ! <xsd:extension base="EntityType"> ! <xsd:sequence> ! <xsd:element name="description" type="xsd:string" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="Classification" type="xsd:string" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="boundary" type="xsd:long" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element name="constructor" type="ConstructorType" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element name="modellor" type="ModellorType" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="transforms" type="TransformType" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="space" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="surface" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="edge" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="vertex" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="material" maxOccurs="unbounded" minOccurs="0"/> ! </xsd:sequence> ! <xsd:attribute name="type" type="xsd:int" use="required"/> ! <xsd:attribute name="name" type="xsd:string"/> ! <xsd:attribute name="voidref" type="xsd:long"/> ! <xsd:attribute name="protoref" type="xsd:long"/> ! <xsd:attribute name="transparent" type="xsd:boolean" use="required"/> ! <xsd:attribute name="level" type="xsd:int" use="required"/> ! <xsd:attribute name="union" type="xsd:boolean" use="optional"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="SurfaceType"> ! <xsd:complexContent> ! <xsd:extension base="EntityType"> ! <xsd:sequence> ! <xsd:element name="edgeref" type="xsd:long" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element name="hole" type="xsd:long" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element name="back" type="xsd:long" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="front" type="xsd:long" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="exterior" type="xsd:long" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="frontMaterial" type="xsd:long" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="backMaterial" type="xsd:long" maxOccurs="1" minOccurs="0"/> ! </xsd:sequence> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="EdgeType"> ! <xsd:complexContent> ! <xsd:extension base="EntityType"> ! <xsd:sequence> ! <xsd:element name="from" type="xsd:long" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="to" type="xsd:long" maxOccurs="1" minOccurs="0"/> ! </xsd:sequence> ! <xsd:attribute name="constructor" type="xsd:boolean" use="required"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="VertexType"> ! <xsd:complexContent> ! <xsd:extension base="EntityType"> ! <xsd:attribute name="x" type="xsd:double" use="required"/> ! <xsd:attribute name="y" type="xsd:double" use="required"/> ! <xsd:attribute name="z" type="xsd:double" use="required"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="MaterialType"> ! <xsd:complexContent> ! <xsd:extension base="EntityType"> ! <xsd:attribute name="name" type="xsd:string" use="required"/> ! <xsd:attribute name="R" type="xsd:float" use="required"/> ! <xsd:attribute name="G" type="xsd:float" use="required"/> ! <xsd:attribute name="B" type="xsd:float" use="required"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="ConstructorType"> ! <xsd:complexContent> ! <xsd:extension base="EntityType"> ! <xsd:sequence> ! <xsd:element ref="vertex" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="connected" type="xsd:long" maxOccurs="unbounded" minOccurs="0"/> ! </xsd:sequence> ! <xsd:attribute name="active" type="xsd:boolean" use="required"/> ! <xsd:attribute name="editable" type="xsd:boolean" use="required"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="LineType"> ! <xsd:complexContent> ! <xsd:extension base="ConstructorType"> ! <xsd:sequence> ! <xsd:element ref="direction" maxOccurs="1" minOccurs="0"/> ! </xsd:sequence> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="PointType"> ! <xsd:complexContent> ! <xsd:extension base="ConstructorType"> ! <xsd:sequence> ! </xsd:sequence> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! ! <xsd:complexType name="RelationType"> ! <xsd:complexContent> ! <xsd:extension base="Types"> ! <xsd:sequence> ! </xsd:sequence> ! <xsd:attribute name="offset" type="xsd:string"/> ! <xsd:attribute name="geometric" type="xsd:long"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="CoordinateSystemType"> ! <xsd:complexContent> ! <xsd:extension base="ConstructorType"> ! <xsd:sequence> ! <xsd:element ref="ijn" maxOccurs="1" minOccurs="0"/> ! <xsd:element ref="relation" maxOccurs="unbounded" minOccurs="0"/> ! </xsd:sequence> ! <xsd:attribute name="onlyplane" type="xsd:boolean" use="required"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="VertexesType"> ! <xsd:sequence> ! <xsd:element ref="vertex" maxOccurs="unbounded" minOccurs="0"/> ! </xsd:sequence> ! </xsd:complexType> ! ! <xsd:complexType name="ModellorType"> ! <xsd:complexContent> ! <xsd:extension base="EntityType"> ! <xsd:sequence> ! <xsd:element name="attribute" type="MapElementType" maxOccurs="unbounded" minOccurs="0"/> ! </xsd:sequence> ! <xsd:attribute name="ty" type="xsd:string"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <!-- HASHMAP --> ! <xsd:complexType name="Types"> ! </xsd:complexType> ! ! <xsd:complexType name="RefType"> ! <xsd:complexContent> ! <xsd:extension base="Types"> ! <xsd:sequence> ! <xsd:element name="ref" type="xsd:long" maxOccurs="1" minOccurs="1"/> ! </xsd:sequence> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="IntegerType"> ! <xsd:complexContent> ! <xsd:extension base="Types"> ! <xsd:sequence> ! <xsd:element name="integer" type="xsd:int" maxOccurs="1" minOccurs="1"/> ! </xsd:sequence> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="DoubleType"> ! <xsd:complexContent> ! <xsd:extension base="Types"> ! <xsd:sequence> ! <xsd:element name="double" type="xsd:double" maxOccurs="1" minOccurs="1"/> ! </xsd:sequence> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="BooleanType"> ! <xsd:complexContent> ! <xsd:extension base="Types"> ! <xsd:sequence> ! <xsd:element name="boolean" type="xsd:boolean" maxOccurs="1" minOccurs="1"/> ! </xsd:sequence> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="StringType"> ! <xsd:complexContent> ! <xsd:extension base="Types"> ! <xsd:sequence> ! <xsd:element name="string" type="xsd:string" maxOccurs="1" minOccurs="1"/> ! </xsd:sequence> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="MapElementType"> ! <xsd:sequence> ! <xsd:element name="key" type="xsd:string" maxOccurs="1" minOccurs="1"/> ! <xsd:element name="value" type="Types" maxOccurs="1" minOccurs="1"/> ! </xsd:sequence> ! </xsd:complexType> ! ! <!-- TRANSFORMATIONS --> ! <xsd:complexType name="TransformType"> ! </xsd:complexType> ! ! <xsd:complexType name="RotateType"> ! <xsd:complexContent> ! <xsd:extension base="TransformType"> ! <xsd:attribute name="x" type="xsd:double" use="required"/> ! <xsd:attribute name="y" type="xsd:double" use="required"/> ! <xsd:attribute name="z" type="xsd:double" use="required"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="TranslateType"> ! <xsd:complexContent> ! <xsd:extension base="TransformType"> ! <xsd:attribute name="x" type="xsd:double" use="required"/> ! <xsd:attribute name="y" type="xsd:double" use="required"/> ! <xsd:attribute name="z" type="xsd:double" use="required"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="ScaleType"> ! <xsd:complexContent> ! <xsd:extension base="TransformType"> ! <xsd:attribute name="x" type="xsd:double" use="required"/> ! <xsd:attribute name="y" type="xsd:double" use="required"/> ! <xsd:attribute name="z" type="xsd:double" use="required"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="AxisRotateType"> ! <xsd:complexContent> ! <xsd:extension base="TransformType"> ! <xsd:attribute name="x" type="xsd:double" use="required"/> ! <xsd:attribute name="y" type="xsd:double" use="required"/> ! <xsd:attribute name="z" type="xsd:double" use="required"/> ! <xsd:attribute name="angle" type="xsd:double" use="required"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="IDTransformType"> ! <xsd:complexContent> ! <xsd:extension base="TransformType"> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <!-- Element definitions --> ! <xsd:element name="space" type="SpaceType"/> ! <xsd:element name="surface" type="SurfaceType"/> ! <xsd:element name="edge" type="EdgeType"/> ! <xsd:element name="vertex" type="VertexType"/> ! <xsd:element name="material" type="MaterialType"/> ! <xsd:element name="origin" type="VertexType"/> ! <xsd:element name="direction" type="VertexesType"/> ! <xsd:element name="ijn" type="VertexesType"/> ! <xsd:element name="relation" type="RelationType"/> ! ! <!-- Main element --> ! <xsd:element name="bmodel"> ! <xsd:complexType> ! <xsd:sequence> ! <xsd:element name="active" type="xsd:long" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="cs" type="xsd:long" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="name" type="xsd:string" maxOccurs="1" minOccurs="0"/> ! <xsd:element ref="space" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="surface" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="edge" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="vertex" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="material" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element name="camera" type="CameraType" maxOccurs="unbounded" minOccurs="0"/> ! </xsd:sequence> ! </xsd:complexType> ! </xsd:element> ! ! </xsd:schema> --- 1,380 ---- ! <?xml version="1.0" encoding="UTF-8"?> ! <!-- ! XML Schema used for persistence ! ! $Id$ ! --> ! <xsd:schema ! xmlns:bpr="bpr" ! xmlns:xsd="http://www.w3.org/2001/XMLSchema" ! xmlns:jaxb="http://java.sun.com/xml/ns/jaxb" ! xmlns:xjc="http://java.sun.com/xml/ns/jaxb/xjc" ! targetNamespace="bpr" ! jaxb:extensionBindingPrefixes="xjc" ! jaxb:version="1.0"> ! ! <!-- Needed for subtypeing --> ! <xsd:annotation> ! <xsd:appinfo> ! <jaxb:globalBindings> ! <xjc:typeSubstitution type="complex"/> ! </jaxb:globalBindings> ! </xsd:appinfo> ! </xsd:annotation> ! ! ! ! <!-- Type definitions --> ! ! <xsd:complexType name="BasicType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:Types"> ! <xsd:attribute name="id" type="xsd:long" use="required"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="EntityType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:BasicType"> ! <xsd:attribute name="progid" type="xsd:long" use="optional"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! ! ! <xsd:complexType name="TripletType"> ! <xsd:attribute name="x" type="xsd:double" use="required"/> ! <xsd:attribute name="y" type="xsd:double" use="required"/> ! <xsd:attribute name="z" type="xsd:double" use="required"/> ! </xsd:complexType> ! ! <xsd:complexType name="ClipplaneType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:EntityType"> ! <xsd:sequence> ! <xsd:element name="coordinateSystem" type="bpr:CoordinateSystemType" maxOccurs="1" minOccurs="1"/> ! </xsd:sequence> ! <xsd:attribute name="Active" type="xsd:boolean" use="required"/> ! <xsd:attribute name="friend" type="xsd:long"/> ! <xsd:attribute name="number" type="xsd:int" use="required"/> ! <xsd:attribute name="Slice" type="xsd:boolean" use="required"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="CameraType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:EntityType"> ! <xsd:sequence> ! <xsd:element name="scalefactor" type="xsd:int" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="camera" type="bpr:TripletType" maxOccurs="1" minOccurs="1"/> ! <xsd:element name="center" type="bpr:TripletType" maxOccurs="1" minOccurs="1"/> ! <xsd:element name="roll" type="bpr:TripletType" maxOccurs="1" minOccurs="1"/> ! <xsd:element name="focalwidth" type="xsd:double" maxOccurs="1" minOccurs="1"/> ! <xsd:element name="type" type="xsd:int" maxOccurs="1" minOccurs="1"/> ! <xsd:element name="clipplanes" type="bpr:ClipplaneType" maxOccurs="unbounded" minOccurs="0"/> ! </xsd:sequence> ! <xsd:attribute name="name" type="xsd:string" use="required"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="NetType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:SpaceType"> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="SpaceType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:EntityType"> ! <xsd:sequence> ! <xsd:element name="description" type="xsd:string" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="Classification" type="xsd:string" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="boundary" type="xsd:long" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element name="constructor" type="bpr:ConstructorType" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element name="modellor" type="bpr:ModellorType" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="transforms" type="bpr:TransformType" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="bpr:space" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="bpr:surface" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="bpr:edge" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="bpr:vertex" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="bpr:material" maxOccurs="unbounded" minOccurs="0"/> ! </xsd:sequence> ! <xsd:attribute name="type" type="xsd:int" use="required"/> ! <xsd:attribute name="name" type="xsd:string"/> ! <xsd:attribute name="voidref" type="xsd:long"/> ! <xsd:attribute name="protoref" type="xsd:long"/> ! <xsd:attribute name="transparent" type="xsd:boolean" use="required"/> ! <xsd:attribute name="level" type="xsd:int" use="required"/> ! <xsd:attribute name="union" type="xsd:boolean" use="optional"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="SurfaceType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:EntityType"> ! <xsd:sequence> ! <xsd:element name="edgeref" type="xsd:long" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element name="hole" type="xsd:long" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element name="back" type="xsd:long" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="front" type="xsd:long" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="exterior" type="xsd:long" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="frontMaterial" type="xsd:long" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="backMaterial" type="xsd:long" maxOccurs="1" minOccurs="0"/> ! </xsd:sequence> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="EdgeType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:EntityType"> ! <xsd:sequence> ! <xsd:element name="from" type="xsd:long" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="to" type="xsd:long" maxOccurs="1" minOccurs="0"/> ! </xsd:sequence> ! <xsd:attribute name="constructor" type="xsd:boolean" use="required"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="VertexType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:EntityType"> ! <xsd:attribute name="x" type="xsd:double" use="required"/> ! <xsd:attribute name="y" type="xsd:double" use="required"/> ! <xsd:attribute name="z" type="xsd:double" use="required"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="MaterialType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:EntityType"> ! <xsd:attribute name="name" type="xsd:string" use="required"/> ! <xsd:attribute name="R" type="xsd:float" use="required"/> ! <xsd:attribute name="G" type="xsd:float" use="required"/> ! <xsd:attribute name="B" type="xsd:float" use="required"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="ConstructorType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:EntityType"> ! <xsd:sequence> ! <xsd:element ref="bpr:vertex" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="connected" type="xsd:long" maxOccurs="unbounded" minOccurs="0"/> ! </xsd:sequence> ! <xsd:attribute name="active" type="xsd:boolean" use="required"/> ! <xsd:attribute name="editable" type="xsd:boolean" use="required"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="LineType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:ConstructorType"> ! <xsd:sequence> ! <xsd:element ref="bpr:direction" maxOccurs="1" minOccurs="0"/> ! </xsd:sequence> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="PointType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:ConstructorType"> ! <xsd:sequence> ! </xsd:sequence> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! ! <xsd:complexType name="RelationType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:Types"> ! <xsd:sequence> ! </xsd:sequence> ! <xsd:attribute name="offset" type="xsd:string"/> ! <xsd:attribute name="geometric" type="xsd:long"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="CoordinateSystemType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:ConstructorType"> ! <xsd:sequence> ! <xsd:element ref="bpr:ijn" maxOccurs="1" minOccurs="0"/> ! <xsd:element ref="bpr:relation" maxOccurs="unbounded" minOccurs="0"/> ! </xsd:sequence> ! <xsd:attribute name="onlyplane" type="xsd:boolean" use="required"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="VertexesType"> ! <xsd:sequence> ! <xsd:element ref="bpr:vertex" maxOccurs="unbounded" minOccurs="0"/> ! </xsd:sequence> ! </xsd:complexType> ! ! <xsd:complexType name="ModellorType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:EntityType"> ! <xsd:sequence> ! <xsd:element name="attribute" type="bpr:MapElementType" maxOccurs="unbounded" minOccurs="0"/> ! </xsd:sequence> ! <xsd:attribute name="ty" type="xsd:string"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <!-- HASHMAP --> ! <xsd:complexType name="Types"> ! </xsd:complexType> ! ! <xsd:complexType name="RefType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:Types"> ! <xsd:sequence> ! <xsd:element name="ref" type="xsd:long" maxOccurs="1" minOccurs="1"/> ! </xsd:sequence> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="IntegerType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:Types"> ! <xsd:sequence> ! <xsd:element name="integer" type="xsd:int" maxOccurs="1" minOccurs="1"/> ! </xsd:sequence> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="DoubleType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:Types"> ! <xsd:sequence> ! <xsd:element name="double" type="xsd:double" maxOccurs="1" minOccurs="1"/> ! </xsd:sequence> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="BooleanType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:Types"> ! <xsd:sequence> ! <xsd:element name="boolean" type="xsd:boolean" maxOccurs="1" minOccurs="1"/> ! </xsd:sequence> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="StringType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:Types"> ! <xsd:sequence> ! <xsd:element name="string" type="xsd:string" maxOccurs="1" minOccurs="1"/> ! </xsd:sequence> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="MapElementType"> ! <xsd:sequence> ! <xsd:element name="key" type="xsd:string" maxOccurs="1" minOccurs="1"/> ! <xsd:element name="value" type="bpr:Types" maxOccurs="1" minOccurs="1"/> ! </xsd:sequence> ! </xsd:complexType> ! ! <!-- TRANSFORMATIONS --> ! <xsd:complexType name="TransformType"> ! </xsd:complexType> ! ! <xsd:complexType name="RotateType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:TransformType"> ! <xsd:attribute name="x" type="xsd:double" use="required"/> ! <xsd:attribute name="y" type="xsd:double" use="required"/> ! <xsd:attribute name="z" type="xsd:double" use="required"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="TranslateType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:TransformType"> ! <xsd:attribute name="x" type="xsd:double" use="required"/> ! <xsd:attribute name="y" type="xsd:double" use="required"/> ! <xsd:attribute name="z" type="xsd:double" use="required"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="ScaleType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:TransformType"> ! <xsd:attribute name="x" type="xsd:double" use="required"/> ! <xsd:attribute name="y" type="xsd:double" use="required"/> ! <xsd:attribute name="z" type="xsd:double" use="required"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="AxisRotateType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:TransformType"> ! <xsd:attribute name="x" type="xsd:double" use="required"/> ! <xsd:attribute name="y" type="xsd:double" use="required"/> ! <xsd:attribute name="z" type="xsd:double" use="required"/> ! <xsd:attribute name="angle" type="xsd:double" use="required"/> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <xsd:complexType name="IDTransformType"> ! <xsd:complexContent> ! <xsd:extension base="bpr:TransformType"> ! </xsd:extension> ! </xsd:complexContent> ! </xsd:complexType> ! ! <!-- Element definitions --> ! <xsd:element name="space" type="bpr:SpaceType"/> ! <xsd:element name="surface" type="bpr:SurfaceType"/> ! <xsd:element name="edge" type="bpr:EdgeType"/> ! <xsd:element name="vertex" type="bpr:VertexType"/> ! <xsd:element name="material" type="bpr:MaterialType"/> ! <xsd:element name="origin" type="bpr:VertexType"/> ! <xsd:element name="direction" type="bpr:VertexesType"/> ! <xsd:element name="ijn" type="bpr:VertexesType"/> ! <xsd:element name="relation" type="bpr:RelationType"/> ! ! <!-- Main element --> ! <xsd:element name="bmodel"> ! <xsd:complexType> ! <xsd:sequence> ! <xsd:element name="active" type="xsd:long" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="cs" type="xsd:long" maxOccurs="1" minOccurs="0"/> ! <xsd:element name="name" type="xsd:string" maxOccurs="1" minOccurs="0"/> ! <xsd:element ref="bpr:space" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="bpr:surface" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="bpr:edge" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="bpr:vertex" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element ref="bpr:material" maxOccurs="unbounded" minOccurs="0"/> ! <xsd:element name="camera" type="bpr:CameraType" maxOccurs="unbounded" minOccurs="0"/> ! </xsd:sequence> ! </xsd:complexType> ! </xsd:element> ! </xsd:schema> |
From: rimestad <rim...@us...> - 2007-06-20 12:06:37
|
Update of /cvsroot/bprocessor//gl/src/net/sourceforge/bprocessor/gl/view In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv6578/src/net/sourceforge/bprocessor/gl/view Modified Files: View.java Log Message: set lne thickness to 1.0 i the view Index: View.java =================================================================== RCS file: /cvsroot/bprocessor//gl/src/net/sourceforge/bprocessor/gl/view/View.java,v retrieving revision 1.214 retrieving revision 1.215 diff -C2 -d -r1.214 -r1.215 *** View.java 31 May 2007 12:41:59 -0000 1.214 --- View.java 20 Jun 2007 12:06:30 -0000 1.215 *************** *** 843,851 **** /** * Draw a grid ! * @param cs the coordinatesystem */ protected void grid(CoordinateSystem cs) { double size = View.gridSize(); ! gl.glLineWidth(0.5f); gl.glColor4fv(gridColor, 0); gl.glEnable(GL.GL_DEPTH_TEST); --- 843,851 ---- /** * Draw a grid ! * @param cs the coordinatesystem, */ protected void grid(CoordinateSystem cs) { double size = View.gridSize(); ! gl.glLineWidth(1.0f); gl.glColor4fv(gridColor, 0); gl.glEnable(GL.GL_DEPTH_TEST); |
From: Michael L. <he...@us...> - 2007-06-19 20:10:26
|
Update of /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv9086/src/net/sourceforge/bprocessor/gl/tool Modified Files: AbstractTool.java PencilTool.java Pencil.java SelectTool.java Log Message: Added a few javadoc comments Index: Pencil.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/Pencil.java,v retrieving revision 1.16 retrieving revision 1.17 diff -C2 -d -r1.16 -r1.17 *** Pencil.java 19 Jun 2007 16:11:06 -0000 1.16 --- Pencil.java 19 Jun 2007 20:10:24 -0000 1.17 *************** *** 108,111 **** --- 108,114 ---- + /** + * {@inheritDoc} + */ public String initialTip() { return "Click set start point of a new edge."; Index: SelectTool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/SelectTool.java,v retrieving revision 1.62 retrieving revision 1.63 diff -C2 -d -r1.62 -r1.63 *** SelectTool.java 19 Jun 2007 16:11:06 -0000 1.62 --- SelectTool.java 19 Jun 2007 20:10:24 -0000 1.63 *************** *** 65,68 **** --- 65,71 ---- } + /** + * {@inheritDoc} + */ public String initialTip() { return "Click objects to select." + Index: PencilTool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/PencilTool.java,v retrieving revision 1.78 retrieving revision 1.79 diff -C2 -d -r1.78 -r1.79 *** PencilTool.java 19 Jun 2007 16:11:06 -0000 1.78 --- PencilTool.java 19 Jun 2007 20:10:24 -0000 1.79 *************** *** 170,173 **** --- 170,176 ---- } + /** + * {@inheritDoc} + */ public String initialTip() { return "Click set the start point of a new edge."; Index: AbstractTool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/AbstractTool.java,v retrieving revision 1.124 retrieving revision 1.125 diff -C2 -d -r1.124 -r1.125 *** AbstractTool.java 19 Jun 2007 16:11:06 -0000 1.124 --- AbstractTool.java 19 Jun 2007 20:10:23 -0000 1.125 *************** *** 918,921 **** --- 918,924 ---- } + /** + * {@inheritDoc} + */ public String initialTip() { return "No initial-tip has been written for this tool"; |
From: Nordholt <nor...@us...> - 2007-06-19 16:11:10
|
Update of /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv11909/src/net/sourceforge/bprocessor/gl/tool Modified Files: AbstractTool.java PencilTool.java Tool.java AbstractPencil.java SelectStrategy.java Pencil.java ArcTool.java SelectTool.java RectTool.java Log Message: initial work on adding tips to all tools Index: Tool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/Tool.java,v retrieving revision 1.32 retrieving revision 1.33 diff -C2 -d -r1.32 -r1.33 *** Tool.java 8 May 2007 13:24:04 -0000 1.32 --- Tool.java 19 Jun 2007 16:11:06 -0000 1.33 *************** *** 86,89 **** * Lets the tool clean up after it self before changing tool. */ ! public void cleanUp(); } --- 86,96 ---- * Lets the tool clean up after it self before changing tool. */ ! public void cleanUp(); ! ! /** ! * Gives a tip on how to use the tool ! * @return A short describtion of how to start using the tool ! * imdediately after it is activated ! */ ! public String initialTip(); } Index: SelectTool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/SelectTool.java,v retrieving revision 1.61 retrieving revision 1.62 diff -C2 -d -r1.61 -r1.62 *** SelectTool.java 21 Jun 2006 13:26:18 -0000 1.61 --- SelectTool.java 19 Jun 2007 16:11:06 -0000 1.62 *************** *** 64,66 **** --- 64,72 ---- select.released(e); } + + public String initialTip() { + return "Click objects to select." + + " Hold shift to add to selection." + + " Drag to multi-select."; + } } Index: PencilTool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/PencilTool.java,v retrieving revision 1.77 retrieving revision 1.78 diff -C2 -d -r1.77 -r1.78 *** PencilTool.java 12 Dec 2006 09:33:49 -0000 1.77 --- PencilTool.java 19 Jun 2007 16:11:06 -0000 1.78 *************** *** 149,153 **** Edge edge = new Edge(start.vertex(), current.vertex()); edge = Project.getInstance().getActiveSpace().insert(edge); ! Collection edges = new LinkedList(); edges.add(edge); Space space = Project.getInstance().getActiveSpace(); --- 149,153 ---- Edge edge = new Edge(start.vertex(), current.vertex()); edge = Project.getInstance().getActiveSpace().insert(edge); ! Collection<Edge> edges = new LinkedList<Edge>(); edges.add(edge); Space space = Project.getInstance().getActiveSpace(); *************** *** 167,170 **** --- 167,180 ---- updateFeedback(); glv.repaint(); + setTip(secondClickTip()); + } + + public String initialTip() { + return "Click set the start point of a new edge."; + } + + private String secondClickTip() { + return "Click to set the end point of the current edge or type length." + + " Double-click or press Escape to stop drawing"; } } Index: AbstractTool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/AbstractTool.java,v retrieving revision 1.123 retrieving revision 1.124 diff -C2 -d -r1.123 -r1.124 *** AbstractTool.java 1 Jun 2007 11:52:34 -0000 1.123 --- AbstractTool.java 19 Jun 2007 16:11:06 -0000 1.124 *************** *** 67,71 **** * When canceling tool action escape are called, so override if for canceling cleanup * ! * When a tool finishes, that is when another tool are chosen, cleanUp are called, so * implement it to cleanUp any unfinished business in a tool. REMEMBER TO CALL THE SUPER * IMPLEMENTATION WHEN EXTENDING --- 67,71 ---- * When canceling tool action escape are called, so override if for canceling cleanup * ! * When a tool finishes, that is when another tool is chosen, cleanUp is called, so * implement it to cleanUp any unfinished business in a tool. REMEMBER TO CALL THE SUPER * IMPLEMENTATION WHEN EXTENDING *************** *** 249,256 **** return center; } /** * Set the length-field ! * @param value Douelb */ public void setLength(double value) { --- 249,264 ---- return center; } + + /** + * Sets the tip in the tip-panel + * @param tip the tip + */ + public void setTip(String tip) { + glv.setTip(tip); + } /** * Set the length-field ! * @param value Double */ public void setLength(double value) { *************** *** 268,271 **** --- 276,286 ---- /** + * Clears the tip-panel + */ + public void clearTip() { + glv.setTip(""); + } + + /** * See if surface has become a hole in a surface in * the project. *************** *** 902,904 **** --- 917,923 ---- return null; } + + public String initialTip() { + return "No initial-tip has been written for this tool"; + } } Index: ArcTool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/ArcTool.java,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** ArcTool.java 7 May 2007 13:29:48 -0000 1.15 --- ArcTool.java 19 Jun 2007 16:11:06 -0000 1.16 *************** *** 203,208 **** --- 203,210 ---- first = current; active = true; + setTip(secondClickTip()); } else { if (end == null) { + setTip(thirdClickTip()); end = current; Vertex between = end.vertex().minus(first.vertex()); *************** *** 237,240 **** --- 239,270 ---- end = null; } + + /** + * Tip on how to set the first click + * @return short describtion of what to do + */ + public String initialTip() { + return "Set first endpoint of the arc"; + } + + /** + * Tip on how to set the second click + * @return short describtion of what to do + */ + private String secondClickTip() { + return "Set the second endpoint of the arc." + + " Use \"length\" to type a specific distance to endpoint" + + " Press Escape to cancel drawing"; + } + + /** + * Tip on how to set the third click + * @return short describtion of what to do + */ + private String thirdClickTip() { + return "Set the radius of the arc." + + "Use \"length\" to type a specific radius." + + " Press Escape to cancel drawing"; + } } Index: Pencil.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/Pencil.java,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** Pencil.java 10 Oct 2006 15:03:01 -0000 1.15 --- Pencil.java 19 Jun 2007 16:11:06 -0000 1.16 *************** *** 42,46 **** if (start != null) { Edge edge = new Edge(start.vertex(), current.vertex()); ! List edges = new LinkedList(); edges.add(edge); feedback(edges); --- 42,46 ---- if (start != null) { Edge edge = new Edge(start.vertex(), current.vertex()); ! List<Edge> edges = new LinkedList<Edge>(); edges.add(edge); feedback(edges); *************** *** 84,88 **** } else { Edge edge = new Edge(start.vertex(), current.vertex()); ! List edges = new LinkedList(); edges.add(edge); hooverEdge = edge; --- 84,88 ---- } else { Edge edge = new Edge(start.vertex(), current.vertex()); ! List<Edge> edges = new LinkedList<Edge>(); edges.add(edge); hooverEdge = edge; *************** *** 104,107 **** --- 104,118 ---- updateFeedback(); glv.repaint(); + setTip(secondClickTip()); + } + + + public String initialTip() { + return "Click set start point of a new edge."; + } + + private String secondClickTip() { + return "Click to set end point of the current edge or type length." + + " Double-click or press Escape to stop drawing"; } } Index: AbstractPencil.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/AbstractPencil.java,v retrieving revision 1.80 retrieving revision 1.81 diff -C2 -d -r1.80 -r1.81 *** AbstractPencil.java 18 May 2007 09:13:17 -0000 1.80 --- AbstractPencil.java 19 Jun 2007 16:11:06 -0000 1.81 *************** *** 753,756 **** --- 753,757 ---- active = false; dragging = false; + setTip(initialTip()); super.cleanUp(); } Index: SelectStrategy.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/SelectStrategy.java,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** SelectStrategy.java 4 Jun 2007 20:38:21 -0000 1.13 --- SelectStrategy.java 19 Jun 2007 16:11:06 -0000 1.14 *************** *** 230,233 **** } } - } --- 230,232 ---- Index: RectTool.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/tool/RectTool.java,v retrieving revision 1.18 retrieving revision 1.19 diff -C2 -d -r1.18 -r1.19 *** RectTool.java 19 Oct 2006 15:28:46 -0000 1.18 --- RectTool.java 19 Jun 2007 16:11:06 -0000 1.19 *************** *** 29,33 **** /** The edges of the rectangle */ ! private List rectangle; /** The edge that will be moving while making the rectangle */ --- 29,33 ---- /** The edges of the rectangle */ ! private List<Edge> rectangle; /** The edge that will be moving while making the rectangle */ *************** *** 56,60 **** public RectTool(GLView glv, Cursor cursor) { super(glv, cursor); ! rectangle = new LinkedList(); movingEdge = null; baseEdge = null; --- 56,60 ---- public RectTool(GLView glv, Cursor cursor) { super(glv, cursor); ! rectangle = new LinkedList<Edge>(); movingEdge = null; baseEdge = null; *************** *** 70,74 **** if (baseEdge == null) { Edge edge = new Edge(start.vertex(), current.vertex()); ! List edges = new LinkedList(); edges.add(edge); feedback(edges); --- 70,74 ---- if (baseEdge == null) { Edge edge = new Edge(start.vertex(), current.vertex()); ! List<Edge> edges = new LinkedList<Edge>(); edges.add(edge); feedback(edges); *************** *** 116,120 **** */ private void setUpRectangle() { ! rectangle = new LinkedList(); baseEdge = new Edge(start.vertex(), current.vertex()); movingEdge = new Edge(current.vertex().copy(), start.vertex().copy()); --- 116,120 ---- */ private void setUpRectangle() { ! rectangle = new LinkedList<Edge>(); baseEdge = new Edge(start.vertex(), current.vertex()); movingEdge = new Edge(current.vertex().copy(), start.vertex().copy()); *************** *** 156,162 **** lastCurrent = start.vertex(); active = true; } else if (baseEdge == null) { if (start.vertex().distance(current.vertex()) > 0.0) { ! setUpRectangle(); } } else { --- 156,164 ---- lastCurrent = start.vertex(); active = true; + setTip(secondClickTip()); } else if (baseEdge == null) { if (start.vertex().distance(current.vertex()) > 0.0) { ! setTip(thirdClickTip()); ! setUpRectangle(); } } else { *************** *** 177,183 **** movingEdge = null; start = null; ! rectangle = new LinkedList(); dragging = false; super.cleanUp(); } } --- 179,215 ---- movingEdge = null; start = null; ! rectangle = new LinkedList<Edge>(); dragging = false; super.cleanUp(); } + + /** + * Tip on how to set the first click + * @return short describtion of what to do + */ + public String initialTip() { + return "Set first corner of the rectangle"; + } + + /** + * Tip on how to set the second click + * @return short describtion of what to do + */ + private String secondClickTip() { + return "Set the height and direction of the rectangle." + + " Use \"length\" to type a specific height." + + " Press Escape to cancel drawing"; + } + + /** + * Tip on how to set the third click + * @return short describtion of what to do + */ + private String thirdClickTip() { + return "Set the width of the rectangle." + + "Use \"length\" to type a specific width." + + " Press Escape to cancel drawing"; + } + + } |
From: Nordholt <nor...@us...> - 2007-06-19 16:09:39
|
Update of /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv11182/src/net/sourceforge/bprocessor/gl Modified Files: GLView.java Log Message: changing the tip when ever a tool is chosen Index: GLView.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/GLView.java,v retrieving revision 1.60 retrieving revision 1.61 diff -C2 -d -r1.60 -r1.61 *** GLView.java 19 Jun 2007 13:38:45 -0000 1.60 --- GLView.java 19 Jun 2007 16:09:36 -0000 1.61 *************** *** 118,121 **** --- 118,122 ---- tool = ToolFactory.getFactory(this).getDefault(); + setTip(tool.initialTip()); view = new View(this); *************** *** 199,202 **** --- 200,204 ---- glc.addKeyListener(tool); setCursor(tool.getCursor()); + setTip(tool.initialTip()); } else { log.error("[changeMode] tool was null"); |
From: Nordholt <nor...@us...> - 2007-06-19 14:36:51
|
Update of /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv15481/src/net/sourceforge/bprocessor/gl Modified Files: GLView.java Log Message: added a tip-bar to the bottom of the GL-view Index: GLView.java =================================================================== RCS file: /cvsroot/bprocessor/gl/src/net/sourceforge/bprocessor/gl/GLView.java,v retrieving revision 1.59 retrieving revision 1.60 diff -C2 -d -r1.59 -r1.60 *** GLView.java 7 May 2007 13:39:39 -0000 1.59 --- GLView.java 19 Jun 2007 13:38:45 -0000 1.60 *************** *** 20,23 **** --- 20,24 ---- import java.awt.Dimension; import java.awt.BorderLayout; + import java.awt.Font; import java.awt.event.ActionEvent; import java.awt.event.MouseEvent; *************** *** 31,35 **** --- 32,38 ---- + import javax.swing.BorderFactory; import javax.swing.JComboBox; + import javax.swing.JSeparator; import javax.swing.JTextField; import javax.swing.JPanel; *************** *** 39,42 **** --- 42,46 ---- import javax.swing.JPopupMenu; import javax.swing.SwingUtilities; + import org.apache.log4j.Logger; *************** *** 64,67 **** --- 68,73 ---- private JPanel lengthPanel; + + private JLabel tipLabel; /** *************** *** 84,88 **** jp.setMinimumSize(new Dimension(320, 240)); jp.setPreferredSize(new Dimension(640, 480)); ! GUI.getInstance().incrementPB(); lengthPanel = new JPanel(); --- 90,94 ---- jp.setMinimumSize(new Dimension(320, 240)); jp.setPreferredSize(new Dimension(640, 480)); ! GUI.getInstance().incrementPB(); lengthPanel = new JPanel(); *************** *** 92,98 **** lengthPanel.add(lengthField, BorderLayout.CENTER); factor = new FactorBox(); ! //lengthPanel.add(factor, BorderLayout.EAST); ! GUI.getInstance().incrementPB(); ! jp.add(lengthPanel, BorderLayout.SOUTH); GUI.getInstance().incrementPB(); --- 98,118 ---- lengthPanel.add(lengthField, BorderLayout.CENTER); factor = new FactorBox(); ! //lengthPanel.add(factor, BorderLayout.EAST); ! ! JPanel tipPanel = new JPanel(); ! tipPanel.setLayout(new BorderLayout()); ! tipPanel.add(new JLabel("Tip: "), BorderLayout.WEST); ! tipLabel = new JLabel("Hello World!"); ! Font basicFont = tipLabel.getFont(); ! tipLabel.setFont(new Font(basicFont.getName(), Font.PLAIN, basicFont.getSize())); ! tipPanel.add(tipLabel, BorderLayout.CENTER); ! ! JPanel bottomPanel = new JPanel(); ! bottomPanel.setLayout(new BorderLayout()); ! bottomPanel.setBorder(BorderFactory.createEtchedBorder()); ! bottomPanel.add(lengthPanel, BorderLayout.NORTH); ! bottomPanel.add(new JSeparator(), BorderLayout.CENTER); ! bottomPanel.add(tipPanel, BorderLayout.SOUTH); ! jp.add(bottomPanel, BorderLayout.SOUTH); GUI.getInstance().incrementPB(); *************** *** 223,226 **** --- 243,254 ---- /** + * Sets the tip in the tip-panel + * @param tip the tip to be displayed + */ + public void setTip(String tip) { + tipLabel.setText(tip); + } + + /** * * @return String |
From: Nordholt <nor...@us...> - 2007-06-19 14:36:45
|
Update of /cvsroot/bprocessor/gui/src/net/sourceforge/bprocessor/gui In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv15188/src/net/sourceforge/bprocessor/gui Modified Files: GUI.java Log Message: removed out-commented code Index: GUI.java =================================================================== RCS file: /cvsroot/bprocessor/gui/src/net/sourceforge/bprocessor/gui/GUI.java,v retrieving revision 1.68 retrieving revision 1.69 diff -C2 -d -r1.68 -r1.69 *** GUI.java 18 Jun 2007 13:21:57 -0000 1.68 --- GUI.java 19 Jun 2007 13:38:06 -0000 1.69 *************** *** 175,195 **** // Create menu JMenu create = createCreateMenu(); - - /*JMenuItem createElement = new JMenuItem("Element"); - createElement.setMnemonic(KeyEvent.VK_E); - createElement.setEnabled(false); - create.add(createElement); - - JMenuItem createPart = new JMenuItem("Part"); - createPart.setMnemonic(KeyEvent.VK_P); - createPart.setEnabled(false); - create.add(createPart); - - JMenuItem createSurface = new JMenuItem("Surface"); - createSurface.setMnemonic(KeyEvent.VK_S); - createSurface.addActionListener(new CreateSurfaceActionListener()); - createSurface.setEnabled(false); - create.add(createSurface);*/ - menu.registerMenu(create); --- 175,178 ---- |