Problem with di.applyOperation (op);
Moderator: andrew
Forum rules
Always indicate your operating system and QCAD version.
Attach drawing files, scripts and screenshots.
Post one question per topic.
Always indicate your operating system and QCAD version.
Attach drawing files, scripts and screenshots.
Post one question per topic.
-
- Full Member
- Posts: 83
- Joined: Fri Apr 17, 2015 6:40 am
- Location: http://creativitainformaticart.altervista.org
Problem with di.applyOperation (op);
Hello
I have a problem with di.applyOperation (op); in row 1161
QCAD turns off, I tried to insert it at various points in the code, but QCAD keeps turning off, just commenting it doesn't turn off.
I attach files
http://creativitainformaticart.altervis ... :49:43.mp4
I have a problem with di.applyOperation (op); in row 1161
QCAD turns off, I tried to insert it at various points in the code, but QCAD keeps turning off, just commenting it doesn't turn off.
I attach files
http://creativitainformaticart.altervis ... :49:43.mp4
- Attachments
-
- OrthogonalProjections.js
- (85.14 KiB) Downloaded 555 times
Re: Problem with di.applyOperation (op);
Are you adding a RModifyObjectsOperation?
Or
Are you adding a new Object?
Or are you trying to do both in one go.
Then I think you have to preset the property of the object.
And add a RAddObjectsOperation.
Wild guess.
Regards,
CVH
Or
Are you adding a new Object?
Or are you trying to do both in one go.
Then I think you have to preset the property of the object.
And add a RAddObjectsOperation.
Wild guess.
Regards,
CVH
-
- Full Member
- Posts: 83
- Joined: Fri Apr 17, 2015 6:40 am
- Location: http://creativitainformaticart.altervista.org
Re: Problem with di.applyOperation (op);
Thanks, I also tried with RAddObjectsOperation, it continues to give me the same problem
Re: Problem with di.applyOperation (op);
What is the error while in debugger mode?
CVH
CVH
-
- Full Member
- Posts: 83
- Joined: Fri Apr 17, 2015 6:40 am
- Location: http://creativitainformaticart.altervista.org
Re: Problem with di.applyOperation (op);
I can't use the debugger mode, if QCAD shuts down before I get to my script:
viewtopic.php?f=30&t=6810
viewtopic.php?f=30&t=6810
-
- Full Member
- Posts: 83
- Joined: Fri Apr 17, 2015 6:40 am
- Location: http://creativitainformaticart.altervista.org
Re: Problem with di.applyOperation (op);
Running QCAD from Terminal you can see these messages:
- Attachments
-
- Istantanea_2020-01-02_22-02-42.png (212.84 KiB) Viewed 12887 times
Re: Problem with di.applyOperation (op);
That are 2 include exceptions for the same CAM script.pietro_72_ wrote: ↑Thu Jan 02, 2020 9:35 pmI can't use the debugger mode, if QCAD shuts down before I get to my script:
viewtopic.php?f=30&t=6810
Qcad is still gathering its addons...
Meaning your code did not run yet.
Qcad can't locate LayerDialogPro.js
Could be a bad includeBasePath, an init that did not run ....
Or .... missing somewhere one bracket ([{ }]), a semicolon ....
Apart from that:
This is nothing you can fix with placing a copy of that script under scripts.
Its PRO and not released on GIT.
I supose you don't use that.
Try without CAM.
If that doesn't fail then you need a clean install I presume.
BTW, your code looks much neater now...
CVH
-
- Full Member
- Posts: 83
- Joined: Fri Apr 17, 2015 6:40 am
- Location: http://creativitainformaticart.altervista.org
Re: Problem with di.applyOperation (op);
ok I will try, I will use and text my program On QCAD / CAM that I purchased some time ago, meanwhile thanks, I thought, if possible, that I could make sure that your FlexPainter program allows users to create arbitrary forms to follow path , or already does it?
Re: Problem with di.applyOperation (op);
I get what you mean by that.pietro_72_ wrote: ↑Thu Jan 02, 2020 11:33 pmI thought, if possible, that I could make sure that your FlexPainter program allows users to create arbitrary forms to follow path
Reply see:
https://qcad.org/rsforum/viewtopic.php?t=6857#p26113
Regards,
CVH
-
- Full Member
- Posts: 83
- Joined: Fri Apr 17, 2015 6:40 am
- Location: http://creativitainformaticart.altervista.org
Re: Problem with di.applyOperation (op);
My program also appears to work on the Community Edition, but it continues to give me the same problem
Ok
Hi, good night and good job
Ok
Hi, good night and good job
- Attachments
-
- ParallelLines.zip
- (10.9 KiB) Downloaded 569 times
-
- OrthogonalProjections.zip
- (52.45 KiB) Downloaded 555 times
-
- Istantanea_2020-01-03_00-59-03.png (290.83 KiB) Viewed 12868 times
Re: Problem with di.applyOperation (op);
I see,
Same problem with the debugger too?
CVH
Same problem with the debugger too?
CVH
-
- Full Member
- Posts: 83
- Joined: Fri Apr 17, 2015 6:40 am
- Location: http://creativitainformaticart.altervista.org
Re: Problem with di.applyOperation (op);
Got something similar...pietro_72_ wrote: ↑Thu Jan 02, 2020 6:36 pmI have a problem with di.applyOperation (op); in row 1161
And maybe a solution...
I was altering Explode.js to interpolation...
After a few edits I needed to do a lot of heavy type banging.
Been busy since... since... before christmas actually...
Entities, Shapes, Objects, QSharedPointer, New RxxxEntities ......
Entities from data, data from entities ......
(eg.: entity.getData().castToShape() or shape = shapes[k].data();)
Then its a function, then it is not.
Then its an array.
Then its a Qlist, what isn't an array per se.
In the debugger an array top is voided, a Qlist shows a copy of the first item.
........
Or there is even nothing readable about an item in the In the debugger.
Expanding the item in interest may lead to a crach from the debugger.
Hovering over the vars works safer....untill you hover and get a black screen.
I can not grasp the differences, nor is there something written about it to be found.
It is probably pritty simple and logic once you see the trees in the wood.
My method: Trial and error .... in this case type banging
Banging untill its accepted.
Maybe this will help a bit:
Explode.js
Explode.explodeSelection = function(di, toolTitle)
section:
Code: Select all
// add explosion result and delete original:
Code: Select all
if (isEntity(news[k])) {
var newEntity = news[k];
op.addObject(newEntity, false, true);
Code: Select all
else {
var newShape = news[k];
e = shapeToEntity(entity.getDocument(), newShape);
op.addObject(e, false);
In your case that's obvious.
Regards,
CVH
-
- Full Member
- Posts: 83
- Joined: Fri Apr 17, 2015 6:40 am
- Location: http://creativitainformaticart.altervista.org
Re: Problem with di.applyOperation (op);
I solved taking inspiration from this post by Andrew:
viewtopic.php?f=30&t=6651&p=25120&hilit ... ion#p25120
modifying the for loop as seen in line 1154
viewtopic.php?f=30&t=6651&p=25120&hilit ... ion#p25120
modifying the for loop as seen in line 1154
- Attachments
-
- OrthogonalProjections.js
- (85.83 KiB) Downloaded 561 times