Search found 86 matches
- Mon Oct 14, 2019 6:47 pm
- Forum: Python scripting and macros
- Topic: pause macro till other macro is finished
- Replies: 5
- Views: 1409
Re: pause macro till other macro is finished
I found a dirty solution: Because my macro requires, that a face of a prism has to be selected, before it starts. When DraftTools.Rectangle().Activated() is finished, the new rectangle is selected and it has no subelements. -> I made an observer (addEventCallback "SoEvent"), which observes...
- Sat Oct 12, 2019 12:14 pm
- Forum: Python scripting and macros
- Topic: addEventCallPivy - type of event
- Replies: 5
- Views: 1196
Re: addEventCallPivy - type of event
I'll stay at addEventCallback()
Somehow it seems more handy for me ...
Incidentally, I just noticed that I forgot on "back" in my post (addEventCallback)
Thanks to all of you
- Thu Oct 10, 2019 9:52 am
- Forum: Python scripting and macros
- Topic: addEventCallPivy - type of event
- Replies: 5
- Views: 1196
addEventCallPivy - type of event
Hi I am able, to make an observer by using addEventCall. Apparently its better to use addEventCallPivy. Really, why? I made an "Soevent" and don't know, how to recognize, which event has happened: With addEventCall I used: if arg["Type"] == "SoKeyboardEvent": ..... But ...
- Thu Oct 10, 2019 9:21 am
- Forum: Python scripting and macros
- Topic: pause macro till other macro is finished
- Replies: 5
- Views: 1409
Re: pause macro till other macro is finished
Before I can use Draft.makeRectangle(), I would to have to take care about userinput by my own (Observer,...), Drafttools-Rectangle does this anyway. I could copy the code of Drafttools in an own macro and adjust it a little bit (insert a call to another function, after it's job is done) , but I'm r...
- Wed Oct 09, 2019 6:38 pm
- Forum: Python scripting and macros
- Topic: pause macro till other macro is finished
- Replies: 5
- Views: 1409
pause macro till other macro is finished
Hi In a macro I use DrafTools.Rectangle The problem is, that the code does not stop till rectangle is finished ... r=None r = DraftTools.Rectangle().Activated() ###Here it should wait, till rectangle is finished print("Rectangle finished") # This appears immediately before the rectangle ex...
- Tue Oct 08, 2019 7:27 pm
- Forum: Forum in Deutsch
- Topic: map on face, Anzeigereihenfolge
- Replies: 5
- Views: 477
Re: map on face, Anzeigereihenfolge
Ja, das mit der Position habe ich gerade ausprobiert: Beide liegen parallel zur x-y-Ebene, Placement/Position/z beim einen=10mm, beim anderen 10,01mm: Funktioniert voll. (10,001 funktioniert nicht mehr). Aber irgendwie ... Krückenlösung. Und beim map on face (Attachement Offset/Position/z): Mit Sket...
- Tue Oct 08, 2019 5:26 pm
- Forum: Forum in Deutsch
- Topic: map on face, Anzeigereihenfolge
- Replies: 5
- Views: 477
Re: map on face, Anzeigereihenfolge
Mal abgesehen vom map on face:
Habe 2 teilweise überlappende Rechtecke (Wie 2 Papiere: eines rot, das andere blau):
Ob das rote oder das Blaue oben liegt und das andere verdeckt, soll umschaltbar sein.
Habe 2 teilweise überlappende Rechtecke (Wie 2 Papiere: eines rot, das andere blau):
Ob das rote oder das Blaue oben liegt und das andere verdeckt, soll umschaltbar sein.
- Tue Oct 08, 2019 5:00 pm
- Forum: Forum in Deutsch
- Topic: map on face, Anzeigereihenfolge
- Replies: 5
- Views: 477
map on face, Anzeigereihenfolge
Hi Wenn ich z.B ein rot gefülltes Rechteck auf eine Quaderfläche heften will: Im Sketcher die Fläche auswählen, "Neue Skizze erstellen", Rechteck zeichnen. Soweit ok. Oder? Nun das Problem: Das Rechteck ist nicht rot gefüllt, ich kann zwar die Linienfarbe ändern, aber Änderung der Flächenf...
- Sat Sep 14, 2019 9:52 am
- Forum: Forum in Deutsch
- Topic: Schaltflächen für Funktionen eines Makro
- Replies: 5
- Views: 682
Re: Schaltflächen für Funktionen eines Makro
Hab ich befürchtet.
Habe nun ein 2. Makro gemacht und dem eine Schaltfläche zugeordnet:
Nix Tragisches, wäre aber doch fein, wenn man das irgendwann innerhalb der Schaltfläche erledigen könnte.
LG
Chri
Habe nun ein 2. Makro gemacht und dem eine Schaltfläche zugeordnet:
Code: Select all
import meinmakro
meinmakro.meineKlasse.variante() #def-Name variante
LG
Chri
- Fri Sep 13, 2019 10:57 am
- Forum: Forum in Deutsch
- Topic: Schaltflächen für Funktionen eines Makro
- Replies: 5
- Views: 682
Schaltflächen für Funktionen eines Makro
Hi Es geht um Werkzeuge/Benutzerdefiniert/Makros: Wie man prinzipiell einem Makro eine Schaltfläche zuordnen kann, weiß ich. Allerdings kann man im entsprechenden Dialogfenster nur den Dateinamen angeben. Gibt es eine Möglichkeit, auch die gewünschte Funktion (def...) innerhalb des Makros anzugeben?...