Changeset 36267 in osm for applications/editors/josm/plugins/seachart/src/render/Rules.java
- Timestamp:
- 2024-06-03T08:28:52+02:00 (7 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/seachart/src/render/Rules.java
r35840 r36267 43 43 import s57.S57val.CatREA; 44 44 import s57.S57val.CatROD; 45 import s57.S57val.CatROS;46 45 import s57.S57val.CatSCF; 47 46 import s57.S57val.CatSEA; … … 50 49 import s57.S57val.CatSIW; 51 50 import s57.S57val.CatSLC; 51 import s57.S57val.CatVAN; 52 52 import s57.S57val.CatWED; 53 53 import s57.S57val.CatWRK; … … 56 56 import s57.S57val.FncFNC; 57 57 import s57.S57val.MarSYS; 58 import s57.S57val.NatQUA; 58 59 import s57.S57val.NatSUR; 59 import s57.S57val.NatQUA;60 60 import s57.S57val.StsSTS; 61 61 import s57.S57val.TecSOU; … … 64 64 import s57.S57val.UniHLU; 65 65 import s57.S57val.WatLEV; 66 import s57.S57val.CatVAN;67 66 import symbols.Areas; 68 67 import symbols.Beacons; … … 551 550 break; 552 551 case SNDWAV: 553 if (Renderer.zoom >= 1 2)552 if (Renderer.zoom >= 14) 554 553 Renderer.fillPattern(Areas.Sandwaves); 555 554 break; … … 560 559 if (hasAttribute(feature.type, Att.NATSUR)) { 561 560 ArrayList<NatSUR> surs = (ArrayList<NatSUR>) getAttList(feature.type, Att.NATSUR); 562 ArrayList<NatQUA> quas = new ArrayList< NatQUA>();561 ArrayList<NatQUA> quas = new ArrayList<>(); 563 562 if (hasAttribute(feature.type, Att.NATQUA)) { 564 563 quas = (ArrayList<NatQUA>) getAttList(feature.type, Att.NATQUA); … … 608 607 case SUR_MUD: 609 608 str += "M"; 609 610 610 break; 611 611 case SUR_CLAY: … … 617 617 case SUR_SAND: 618 618 str += "S"; 619 619 620 break; 620 621 case SUR_STON: 621 622 str += "St"; 623 622 624 break; 623 625 case SUR_GRVL: 624 626 str += "G"; 627 625 628 break; 626 629 case SUR_PBBL: … … 632 635 case SUR_ROCK: 633 636 str += "R"; 637 if (feature.geom.prim != Pflag.POINT) { 638 Renderer.lineSymbols(Areas.Rocks, 1, null, null, 0, Color.black); 639 } 634 640 break; 635 641 case SUR_LAVA: … … 638 644 case SUR_CORL: 639 645 str += "Co"; 646 if (feature.geom.prim != Pflag.POINT) { 647 Renderer.lineSymbols(Areas.Coral, 1, null, null, 0, Color.black); 648 } 640 649 break; 641 650 case SUR_SHEL: … … 661 670 switch ((CatWED) getAttEnum(feature.type, Att.CATWED)) { 662 671 case WED_KELP: 663 if (feature.geom.prim == Pflag. AREA) {664 Renderer. fillPattern(Areas.KelpA);672 if (feature.geom.prim == Pflag.POINT) { 673 Renderer.symbol(Areas.KelpP); 665 674 } else { 666 Renderer. symbol(Areas.KelpS);675 Renderer.fillPattern(Areas.Kelp); 667 676 } 668 677 break; … … 671 680 break; 672 681 case WED_SGRS: 673 Renderer.labelText("Sg", new Font("Arial", Font.ITALIC, 40), Color.black, new Delta(Handle.CC)); 682 if (feature.geom.prim == Pflag.POINT) { 683 Renderer.symbol(Areas.SeagrassP); 684 } else { 685 Renderer.fillPattern(Areas.Seagrass); 686 } 674 687 break; 675 688 case WED_SGSO: … … 681 694 break; 682 695 case SEGRAS: 683 Renderer.labelText("Sg", new Font("Arial", Font.ITALIC, 40), Color.black, new Delta(Handle.CC)); 696 if (Renderer.zoom >= 14) { 697 if (feature.geom.prim == Pflag.POINT) { 698 Renderer.symbol(Areas.SeagrassP); 699 } else { 700 Renderer.fillPattern(Areas.Seagrass); 701 } 702 } 684 703 break; 685 704 case SPRING: 686 Renderer.symbol(Areas.Spring); 705 if (Renderer.zoom >= 14) { 706 Renderer.symbol(Areas.Spring); 707 } 687 708 break; 688 709 case SPLARE: … … 1273 1294 Renderer.symbol(Harbours.Dolphin); 1274 1295 } 1275 Signals.addSignals();1276 1296 break; 1277 1297 case MOR_DDPN: 1278 1298 Renderer.symbol(Harbours.DeviationDolphin); 1279 Signals.addSignals();1280 1299 break; 1281 1300 case MOR_BLRD: … … 1291 1310 Renderer.symbol(Buoys.Shapes.get(shape), (1.0 / (1.0 + (0.25 * (18 - Renderer.zoom)))), getScheme(feature.type)); 1292 1311 Renderer.symbol(Topmarks.TopMooring, (1.0 / (1.0 + (0.25 * (18 - Renderer.zoom)))), Topmarks.BuoyDeltas.get(shape)); 1293 Signals.addSignals();1294 1312 addName(15, new Font("Arial", Font.BOLD, 40), new Delta(Handle.BL, AffineTransform.getTranslateInstance(60, -50))); 1295 1313 } 1296 1314 break; 1297 1315 default: 1298 break; 1299 } 1316 Renderer.symbol(Harbours.Post); 1317 break; 1318 } 1319 Signals.addSignals(); 1300 1320 } 1301 1321 } … … 1425 1445 1426 1446 private static void pipelines() { 1427 if ((Renderer.zoom >= 14) && (feature.geom.length <20)) {1447 if ((Renderer.zoom >= 14) && (feature.geom.length < 20) || (Renderer.zoom < 12) && (feature.geom.length >= 20)) { 1428 1448 if (feature.type == Obj.PIPSOL) { 1429 1449 switch ((CatPIP) getAttEnum(feature.type, Att.CATPIP)) { … … 1776 1796 } 1777 1797 } 1778 1798 1779 1799 private static void waterways() { 1780 1800 Renderer.lineVector(new LineStyle(Symbols.Bwater, 20, (feature.geom.prim == Pflag.AREA) ? Symbols.Bwater : null));
Note:
See TracChangeset
for help on using the changeset viewer.