import FreeCAD, Part, Drawing if len(Gui.Selection.getSelectionEx())>1: App.Console.PrintError("Warning: Only the first item is generate") if len(Gui.Selection.getSelectionEx())==0: App.Console.PrintError("Warning: Need to select one item") Piece=Gui.Selection.getSelectionEx()[0] App.activeDocument().addObject('Drawing::FeaturePage','AutoDrawing') App.activeDocument().AutoDrawing.Template = App.getResourceDir()+'Mod/Drawing/Templates/A3_Landscape_plain.svg' #Create IsotView1 App.activeDocument().addObject('Drawing::FeatureViewPart','IsoView1') App.activeDocument().IsoView1.Source =Piece.Object App.activeDocument().IsoView1.Direction = (1,-1,-1) App.activeDocument().IsoView1.Rotation=60 App.activeDocument().IsoView1.Scale = 2 App.activeDocument().IsoView1.X = 180 App.activeDocument().IsoView1.Y = 150 App.activeDocument().IsoView1.ShowHiddenLines=False App.activeDocument().AutoDrawing.addObject(App.activeDocument().IsoView1) #Create IsotView2 App.activeDocument().addObject('Drawing::FeatureViewPart','IsoView2') App.activeDocument().IsoView2.Source =Piece.Object App.activeDocument().IsoView2.Direction = (1,1,1) App.activeDocument().IsoView2.Rotation=240 App.activeDocument().IsoView2.Scale = 2 App.activeDocument().IsoView2.X = 120 App.activeDocument().IsoView2.Y = 120 App.activeDocument().IsoView2.ShowHiddenLines=False App.activeDocument().AutoDrawing.addObject(App.activeDocument().IsoView2)