How to stop paths automatically being inserted?

瀏覽次數:82 次
跳到第一則未讀訊息

Kyron Du Casse

未讀,
2021年5月6日 中午12:36:282021/5/6
收件者:Paper.js

Hello all

I have been using paper-jsdom and normally I avoid adding paths to the project by using

var x = new paper.path({insert:false});

Its very annoying to have to use this everytime, and when using bool operations etc I think paths get added anyways or something.

is there a global command to stop inserts from happening full stop?

Thanks

MUKUND THAKARE

未讀,
2021年5月25日 清晨7:30:522021/5/25
收件者:Paper.js
I personally believe there isn't any such a global command.
But what you can do to achieve such a behavior is to write utility for creating a path like below.

_createPath(argNeededToCreatePath) : paper.Path{
        return new paper.Path(args,{insert : false})
  }

And use this function every time to create the path.


asensi...@gmail.com

未讀,
2021年5月25日 下午1:28:592021/5/25
收件者:Paper.js
Hello,

in fact, this setting do exist as a property of the PaperScope instance paper.settings.insertItems
回覆所有人
回覆作者
轉寄
0 則新訊息