This repository was archived by the owner on Apr 4, 2023. It is now read-only.
File tree Expand file tree Collapse file tree 4 files changed +13
-22
lines changed
API/GcodeApi/Gsimulator/Gcss Expand file tree Collapse file tree 4 files changed +13
-22
lines changed Original file line number Diff line number Diff line change @@ -7,45 +7,45 @@ import Gcss from "./src/API/GcodeApi/Gsimulator/Gcss/Gcss.js";
77let a = new G0 ( { } ) ;
88
99for ( let i = 0 ; i < 3 ; i ++ ) {
10- a . moveTo ( { left : 50 , top : 50 } )
10+ a . moveTo ( { left : 10 , top : 30 } ) ;
1111}
1212
1313for ( let i = 0 ; i < 3 ; i ++ ) {
14- a . moveTo ( { left : 50 } )
14+ a . moveTo ( { left : 100 } ) ;
1515}
1616
1717for ( let i = 0 ; i < 3 ; i ++ ) {
1818 a . moveTo ( {
19- bottom : 50
19+ bottom : 50 ,
2020 } ) ;
2121}
2222
2323for ( let i = 0 ; i < 3 ; i ++ ) {
2424 a . moveTo ( {
25- right : 50
25+ right : 100 ,
2626 } ) ;
2727}
2828
2929for ( let i = 0 ; i < 3 ; i ++ ) {
3030 a . moveTo ( {
31- bottom : 50 ,
32- right : 50
31+ bottom : 50 ,
32+ right : 50 ,
3333 } ) ;
3434}
3535
3636for ( let i = 0 ; i < 3 ; i ++ ) {
3737 a . moveTo ( {
38- top : 50 ,
39- right : 50
38+ top : 50 ,
39+ right : 20 ,
4040 } ) ;
4141}
4242
4343for ( let i = 0 ; i < 4 ; i ++ ) {
44- a . moveTo ( { left : 50 } )
44+ a . moveTo ( { left : 50 } ) ;
4545}
4646
4747for ( let i = 0 ; i < 3 ; i ++ ) {
48- a . moveTo ( { bottom : 50 , left : 50 } )
48+ a . moveTo ( { bottom : 30 , left : 50 } ) ;
4949}
5050
5151let g = new Gcss ( {
Original file line number Diff line number Diff line change @@ -51,15 +51,6 @@ export default class CssLine {
5151 return remValue * 16 ;
5252 }
5353
54- // this.previusObj.x > this.currentObj.x &&
55- // this.previusObj.y < this.currentObj.y
56- // ? this.biggestPos.y
57- // : this.smallestPos.y
58-
59- // this.previusObj.x > this.currentObj.x &&
60- // this.previusObj.y < this.currentObj.y
61- // ? -1 * this.lineAngle
62- // : this.lineAngle
6354 styleLine ( ) {
6455 this . lineStylesObj = new StyleLine ( this ) . getResult ( ) ;
6556
Original file line number Diff line number Diff line change @@ -78,15 +78,15 @@ export default class StyleLine {
7878 this . obj . previusObj . x > this . obj . currentObj . x &&
7979 this . obj . currentObj . y > this . obj . previusObj . y
8080 ) {
81- return this . obj . lineAngle + 90 ;
81+ return 180 - this . obj . lineAngle ;
8282 }
8383
8484 // left and bottom
8585 if (
8686 this . obj . currentObj . x > this . obj . previusObj . x &&
8787 this . obj . previusObj . y > this . obj . currentObj . y
8888 ) {
89- return this . obj . lineAngle - 90 ;
89+ return - 1 * this . obj . lineAngle ;
9090 }
9191
9292 // normal all other direction
Original file line number Diff line number Diff line change 4040 width : var (--line-width );
4141 opacity : 1 ;
4242 }
43- }
43+ }
You can’t perform that action at this time.
0 commit comments