[PR] [0.18-0.21_pre] Arch Stair - More Geometry Control? Profile Generator

A forum dedicated to the Draft, Arch and BIM workbenches development.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
paullee
Veteran
Posts: 5135
Joined: Wed May 04, 2016 3:58 pm

Re: [PR] Arch Stair - More Geometry Control? Bug Report

Post by paullee »

ArchStairs can be created without base object (e.g Dwire, Sketch etc.)... Railing is also automatically created for this case now.

0.18_pre ArchStairs.py attached below, appreciate anyone can test before PR.

0.17 version can be back ported if anyone interested (a few commits not yet back ported at the moment) :)

Screenshot from 2018-10-07 09-00-45.png
Screenshot from 2018-10-07 09-00-45.png (254.56 KiB) Viewed 1725 times
Screenshot from 2018-10-07 10-00-35.png
Screenshot from 2018-10-07 10-00-35.png (279.75 KiB) Viewed 1725 times
Attachments
ArchStairs.py
(51.62 KiB) Downloaded 64 times
paullee
Veteran
Posts: 5135
Joined: Wed May 04, 2016 3:58 pm

Re: [PR] Arch Stair - More Geometry Control? Bug Report

Post by paullee »

For stairs created without railing ... (or for any reason with railing)...
  1. created in previous versions
  2. railings deleted etc.
makeRailing() function now can (re)-create the Railings:- :)
  1. Select the (master) Stairs
  2. Run...

    Code: Select all

    import ArchStairs
    ArchStairs.makeRailing(None)
    
  3. Then, Railings are re-Created, and are inserted in Additions
As I am not familiar with Gui, I can only add / tweak this function for Railing :oops:

Select the Stairs and Run the commands
Screenshot from 2018-10-07 12-19-27.png
Screenshot from 2018-10-07 12-19-27.png (177.85 KiB) Viewed 1720 times
Railing (re)-Created
Screenshot from 2018-10-07 12-20-13.png
Screenshot from 2018-10-07 12-20-13.png (281.09 KiB) Viewed 1720 times
Attachments
ArchStairs.py
(52.31 KiB) Downloaded 56 times
paullee
Veteran
Posts: 5135
Joined: Wed May 04, 2016 3:58 pm

Re: [PR] Arch Stair - More Geometry Control? Opening at Floor?

Post by paullee »

Thinking if something similar to Arch Window - Arch Wall could be done for Arch Stairs - 'Arch Slab / Structure / Roof'? -

(recently there are some discussion about Arch Window and opening on Arch Wall...)

E.g. Arch Structure (as slab) could automatically create an slab opening if it host an Arch Stairs?
(or in other way like current Window)

Anybody (Yorik, Vocx...) want to implement?

Screenshot from 2018-10-26 07-21-07.png
Screenshot from 2018-10-26 07-21-07.png (256.75 KiB) Viewed 1670 times
User avatar
yorik
Founder
Posts: 13665
Joined: Tue Feb 17, 2009 9:16 pm
Location: Brussels
Contact:

Re: [PR] Arch Stair - More Geometry Control? Opening at Floor?

Post by yorik »

That would not be too hard, indeed we can reuse exactly the same system. Basically:

- The Stairs object should have a "Hosts" property
- The Stairs object needs to trigger recompute of its hosts when needed (like in ArchWindow.py line 978)
- The Stairs object should have a getSubVolume(self,obj) method that returns a shape to be subtracted from host objects
- Maybe the Stairs object would also need a "Subtraction height" property, to allow to user to define the max height of the hole, like in windows
- There might be need for small further adjustments (ex. ArchComponent.py, line 537) to extend to other types (I think we could change that line to something like if hasattr(o.Proxy,"getSubVolume") so in the future, any object that has a getSubVolume() method will be considered
vocx
Veteran
Posts: 5197
Joined: Thu Oct 18, 2018 9:18 pm

Re: [PR] Arch Stair - More Geometry Control? Opening at Floor?

Post by vocx »

paullee wrote: Thu Oct 25, 2018 11:24 pm ...

Anybody (Yorik, Vocx...) want to implement?
...
I will never help you while you keep doing this: why is the Report view and Python console using a Serif font like Times?! Why?! The report view should use a monospace font, like Consolas, or Liberation Mono. Why do you use Times?! It burns my eyes! Aaah.
Screenshot from 2018-10-26 07-21-07.png
Screenshot from 2018-10-26 07-21-07.png (74.55 KiB) Viewed 1639 times
Always add the important information to your posts if you need help. Also see Tutorials and Video tutorials.
To support the documentation effort, and code development, your donation is appreciated: liberapay.com/FreeCAD.
paullee
Veteran
Posts: 5135
Joined: Wed May 04, 2016 3:58 pm

Re: [PR] Arch Stair - More Geometry Control? Opening at Floor?

Post by paullee »

vocx wrote: Fri Oct 26, 2018 5:47 pm I will never help you while you keep doing this: why is the Report view and Python console using a Serif font like Times?! Why?! The report view should use a monospace font, like Consolas, or Liberation Mono. Why do you use Times?! It burns my eyes! Aaah.
Screenshot from 2018-10-26 07-21-07.png
? Anywhere I can set this ? I just download the *.AppImage and fire it up. Where can I 'correct' this ? Thanks for pointing it out :)
yorik wrote: Fri Oct 26, 2018 3:13 pm That would not be too hard, indeed we can reuse exactly the same system. Basically:

- The Stairs object should have a "Hosts" property
- The Stairs object needs to trigger recompute of its hosts when needed (like in ArchWindow.py line 978)
- The Stairs object should have a getSubVolume(self,obj) method that returns a shape to be subtracted from host objects
- Maybe the Stairs object would also need a "Subtraction height" property, to allow to user to define the max height of the hole, like in windows
- There might be need for small further adjustments (ex. ArchComponent.py, line 537) to extend to other types (I think we could change that line to something like if hasattr(o.Proxy,"getSubVolume") so in the future, any object that has a getSubVolume() method will be considered
Thanks! Seem much easier to understand the system with this summary! I am trying to turn some ArchStairs methods accessible. See if I get lot of courage to attempt afterwards or leave it to the masters :)
vocx
Veteran
Posts: 5197
Joined: Thu Oct 18, 2018 9:18 pm

Re: [PR] Arch Stair - More Geometry Control? Opening at Floor?

Post by vocx »

paullee wrote: Fri Oct 26, 2018 6:29 pm
vocx wrote: Fri Oct 26, 2018 5:47 pm I will never help you while you keep doing this: why is the Report view and Python console using a Serif font like Times?! Why?! The report view should use a monospace font, like Consolas, or Liberation Mono. Why do you use Times?! It burns my eyes! Aaah.
Screenshot from 2018-10-26 07-21-07.png
? Anywhere I can set this ? I just download the *.AppImage and fire it up. Where can I 'correct' this ? Thanks for pointing it out :)
Menu > Edit > Preferences ... > General > Editor > Family: Liberation Mono
Always add the important information to your posts if you need help. Also see Tutorials and Video tutorials.
To support the documentation effort, and code development, your donation is appreciated: liberapay.com/FreeCAD.
paullee
Veteran
Posts: 5135
Joined: Wed May 04, 2016 3:58 pm

Re: [PR] Arch Stair - More Geometry Control? Opening at Floor?

Post by paullee »

Stuck and post for fun only :)
Screenshot from 2018-10-27 03-37-40.png
Screenshot from 2018-10-27 03-37-40.png (266.6 KiB) Viewed 1627 times
Screenshot from 2018-10-27 03-38-08.png
Screenshot from 2018-10-27 03-38-08.png (243.99 KiB) Viewed 1627 times
vocx wrote: Fri Oct 26, 2018 7:13 pm Menu > Edit > Preferences ... > General > Editor > Family: Liberation Mono
Ok, thanks. The last one with Font style 'fixed' :)
Screenshot from 2018-10-27 03-41-09.png
Screenshot from 2018-10-27 03-41-09.png (187.39 KiB) Viewed 1627 times
paullee
Veteran
Posts: 5135
Joined: Wed May 04, 2016 3:58 pm

Re: [PR] [0.18] Arch Stair - More Geometry Control? Opening at Floor?

Post by paullee »

Now, the 'multi-segment' landing can take curve :)
not fully tested.

Railing not yet :lol:

Screenshot from 2018-12-31 01-30-44.png
Screenshot from 2018-12-31 01-30-44.png (241.68 KiB) Viewed 1544 times
Last edited by paullee on Tue Feb 12, 2019 4:58 pm, edited 1 time in total.
User avatar
yorik
Founder
Posts: 13665
Joined: Tue Feb 17, 2009 9:16 pm
Location: Brussels
Contact:

Re: [PR] Arch Stair - More Geometry Control? Opening at Floor?

Post by yorik »

Awesome development! Keep it going!!
Post Reply