Thanks Andrew,
I confirm that setting the Qt.WA_DeleteOnClose attribute fix the problem.
sramp
Search found 26 matches
- Wed Mar 26, 2014 12:48 pm
- Forum: QCAD Programming, Script Programming and Contributing
- Topic: Safely destroy widget
- Replies: 2
- Views: 6247
- Mon Mar 24, 2014 11:42 pm
- Forum: QCAD Programming, Script Programming and Contributing
- Topic: Safely destroy widget
- Replies: 2
- Views: 6247
Safely destroy widget
Hello, in my script I create a widget with WidgetFactory.createWidget. It's a window with buttons, labels, edit fields and a table. Since the script is called repeatedly , when the user close the window I prefer to destroy it in this way : this.mw.close(); this.mw.destroy(); After this, sometimes, t...
- Fri Mar 07, 2014 6:39 pm
- Forum: QCAD Programming, Script Programming and Contributing
- Topic: Drawing Unit
- Replies: 1
- Views: 4951
Drawing Unit
Hello, first of all please excuse me for the question but I'm really new with CAD applications. I would like to know if the Drawing Unit (Drawing Preferences:General:Drawing Unit) is automatically set after I open a drawing. I'm asking this since I have noticed some incongruences between the Drawing...
- Sun Feb 23, 2014 5:51 pm
- Forum: QCAD Programming, Script Programming and Contributing
- Topic: Edit block
- Replies: 2
- Views: 5490
Re: Edit block
Andrew,
thank you very much.
It is exactly what I was looking for.
sramp
thank you very much.
It is exactly what I was looking for.
sramp
- Fri Feb 21, 2014 12:43 pm
- Forum: QCAD Programming, Script Programming and Contributing
- Topic: Edit block
- Replies: 2
- Views: 5490
Edit block
Hello,
when I double click on a block the application goes in the edit block mode.
Please, is it possible to intercept this event?
I would like to avoid to edit the block.
Thanks
sramp
when I double click on a block the application goes in the edit block mode.
Please, is it possible to intercept this event?
I would like to avoid to edit the block.
Thanks
sramp
- Thu Feb 13, 2014 10:26 am
- Forum: QCAD Programming, Script Programming and Contributing
- Topic: Clear undo stack
- Replies: 3
- Views: 7560
Re: Clear undo stack
There is an error in my logic and this is the real cause of the problem. I create some lines ( undoable true ) .... I delete the lines ( undoable false ) If I set as undoable every operation everything works fine. I could set not undoable the lines creation too, but this makes the tools less usable ...
- Tue Feb 11, 2014 5:27 pm
- Forum: QCAD Programming, Script Programming and Contributing
- Topic: Clear undo stack
- Replies: 3
- Views: 7560
Clear undo stack
Hello, I'm building a custom tool and to help the user the tool creates some construction lines ( RLineEntity ). These lines will be deleted at the end by the script. The tool works as expected, but I have some problems with the undo command, since I got a crash. I suppose that references of constru...
- Mon Feb 10, 2014 6:14 pm
- Forum: QCAD Programming, Script Programming and Contributing
- Topic: Best strategies to identify entities
- Replies: 5
- Views: 10812
Re: Best strategies to identify entities
Andrew,
thank you very much.
Very useful function !
thank you very much.
Very useful function !
- Thu Feb 06, 2014 11:38 am
- Forum: QCAD Programming, Script Programming and Contributing
- Topic: Identifying entities recently added
- Replies: 2
- Views: 5794
Re: Identifying entities recently added
Hello, maybe I've found a solution of my problem. I have added to my script a RTransactionListenerAdapter. In this way I can retrieve the ids of the segments while I'm building the closed polygon. To learn more just study the example script ExTransactionListener.js. Please let me know if there is a ...
- Wed Feb 05, 2014 12:29 pm
- Forum: QCAD Programming, Script Programming and Contributing
- Topic: Identifying entities recently added
- Replies: 2
- Views: 5794
Identifying entities recently added
Hello, I'm modifying the Line2p.js scritp since I would like to create a new tool able to create automatically a new block built with a closed polygon. To create the block I need to know the entities which forming the closed polygon. Is there a way to know the ids of these entities? I see that the e...
- Fri Jan 31, 2014 11:41 am
- Forum: QCAD Programming, Script Programming and Contributing
- Topic: Best strategies to identify entities
- Replies: 5
- Views: 10812
Re: Best strategies to identify entities
Andrew,
thank you very much for your very useful answers.
Thank you again to have put in evidence the problems about entities duplicates.
It is a real issue and could create some problems.
I'm glad to know about the object handles, this will simplify a lot my script.
Best
sramp
thank you very much for your very useful answers.
Thank you again to have put in evidence the problems about entities duplicates.
It is a real issue and could create some problems.
I'm glad to know about the object handles, this will simplify a lot my script.
Best
sramp
- Fri Jan 31, 2014 11:22 am
- Forum: QCAD Programming, Script Programming and Contributing
- Topic: queryEntity
- Replies: 4
- Views: 10207
Re: queryEntity
Andrew, thank you for the hint, it's good to know. Concerning this specific case I've written a test script and I have found that if I set my document in the beginEvent method everything works. I'm pretty new with Javascript, so I post here my code, maybe I'm wrong somewhere. include("../WidgetFacto...
- Fri Jan 24, 2014 3:51 pm
- Forum: QCAD Programming, Script Programming and Contributing
- Topic: queryEntity
- Replies: 4
- Views: 10207
Re: queryEntity
Andrew, thanks for the reply. I'm confused since sometimes the code is executed without problem. Sometime I'm not able to obtain the document ( document=null). ven gen 24 12:37:37 2014 Uncaught exception at scripts/Italsoft/Entry/Entry.js:279: TypeError: Result of expression 'document' [null] is not...
- Thu Jan 23, 2014 5:17 pm
- Forum: QCAD Programming, Script Programming and Contributing
- Topic: queryEntity
- Replies: 4
- Views: 10207
queryEntity
Hello, I'm encountering a problem when I try to get an entity from the document. I wrote this code to debug the problem, but QCAD-Pro crashes when I execute the queryEntity. I have checked step by step with the debugger and I have seen that document is not null. this.theEntityId is the id of a line ...
- Sat Jan 18, 2014 9:43 am
- Forum: QCAD Programming, Script Programming and Contributing
- Topic: Best strategies to identify entities
- Replies: 5
- Views: 10812
Best strategies to identify entities
Hi, please I would like to know which are the best strategies to identify the elements of the drawing in a unique way and retrieve them subsequently. I need to retrieve, after save operations, some elements of the drawing like layers and entities. Reading the forum I understand that the id could cha...