Ideas for A2+ enhancement
Posted: Sun Dec 01, 2019 5:04 am
Ideas for A2+ enhancement
If you put the attached file, a2p_constraintDialog.py, in the A2plus folder you should be able to try some ideas I have for enhancements. After you restart FreeCAD and select A2plus open the Constraint Tool dialog, it should look like the attached picture.
In the upper left click the “Turn Auto On Off”. This has only stated observers.
In the lower right, (Idea 1)clicking the Auto Select 2 enables you to select two parts without using the control key. You then select the constraint like you normally do.
Auto Mate: (Idea 2)If you select two surfaces the program assumes you want to create a coincident mate and makes it for you. The edit dialog shows as normal so you can accept it. If that is not the mate you want, hold down the control key when you select the second part and the mate selector will show as usual.
(idea3) Auto Approve: makes a “default” mate and approves it. To start a new mate simply select the surfaces of the next mate, which will be created and continue to the next mate. The first few mates are scary but experienced CAD user may like it. (Idea 4) If you need to add an offset click the edit icon and it will open to the latest mate.
There are some mates that are picky what is selected first. The edge to surface and point on surface are two of them. If you use the Auto mode (Idea 5) the features are checked and put in the correct order, no matter which order they were selected.
The default mates are:
1. Point coincident if two points are selected:
2. Edge coincident if two edges are selected.
3. Plane coincident for two planes. CAUTION if you select a curved face. There is not a check for those so use the Ctl key and select the mate you want.
4. When you pick any other features the selection dialogs show as normal.
5.
I would like to see the first idea implemented as l have Parkinson’s and tremors sometimes makes it very hard to hold the Ctl key down.
The code the I added in the main code body should be between #dan— code and #--dan in the file.
I hope this code works for someone.
Dan Miel
Edited: Although it is fun watching this py file crash and act weirdly, I removed this file because the features had been copied from a macro as I was trying to add my features to the familiar dialog. The macro in the third post is a macro that is closer to what I use. The concepts are the same, the macro does not crash like this file did.
If you put the attached file, a2p_constraintDialog.py, in the A2plus folder you should be able to try some ideas I have for enhancements. After you restart FreeCAD and select A2plus open the Constraint Tool dialog, it should look like the attached picture.
In the upper left click the “Turn Auto On Off”. This has only stated observers.
In the lower right, (Idea 1)clicking the Auto Select 2 enables you to select two parts without using the control key. You then select the constraint like you normally do.
Auto Mate: (Idea 2)If you select two surfaces the program assumes you want to create a coincident mate and makes it for you. The edit dialog shows as normal so you can accept it. If that is not the mate you want, hold down the control key when you select the second part and the mate selector will show as usual.
(idea3) Auto Approve: makes a “default” mate and approves it. To start a new mate simply select the surfaces of the next mate, which will be created and continue to the next mate. The first few mates are scary but experienced CAD user may like it. (Idea 4) If you need to add an offset click the edit icon and it will open to the latest mate.
There are some mates that are picky what is selected first. The edge to surface and point on surface are two of them. If you use the Auto mode (Idea 5) the features are checked and put in the correct order, no matter which order they were selected.
The default mates are:
1. Point coincident if two points are selected:
2. Edge coincident if two edges are selected.
3. Plane coincident for two planes. CAUTION if you select a curved face. There is not a check for those so use the Ctl key and select the mate you want.
4. When you pick any other features the selection dialogs show as normal.
5.
I would like to see the first idea implemented as l have Parkinson’s and tremors sometimes makes it very hard to hold the Ctl key down.
The code the I added in the main code body should be between #dan— code and #--dan in the file.
I hope this code works for someone.
Dan Miel
Edited: Although it is fun watching this py file crash and act weirdly, I removed this file because the features had been copied from a macro as I was trying to add my features to the familiar dialog. The macro in the third post is a macro that is closer to what I use. The concepts are the same, the macro does not crash like this file did.