Suppose you have the following Shells and Walls:
1.Select all the elements shown (Roof, Shell, Walls).
2.From the context menu, go to Connect and choose Trim Elements to Roof/Shell.
3.In the appearing dialog box, click Trim.
4.View the result in 3D:
For another example of an automatic trim, see Cross-Gable Roof.