internal SwCommandGroup(ISwApplication app, CommandGroupSpec spec, CommandGroup cmdGroup) { Spec = spec; CommandGroup = cmdGroup; m_App = app; }
public virtual CustomFeatureState_e OnUpdateState(ISwApplication app, ISwDocument model, ISwMacroFeature feature) { return(CustomFeatureState_e.Default); }
public PropertyManagerPageListBoxControlConstructor(ISwApplication app, IIconsCreator iconsConv) : base(app.Sw, swPropertyManagerPageControlType_e.swControlType_Listbox, iconsConv) { m_SwApp = app; m_Helper = new PropertyManagerPageItemsControlConstructorHelper(); }
public override CustomFeatureRebuildResult OnRebuild(ISwApplication app, ISwDocument model, ISwMacroFeature feature) { return(base.OnRebuild(app, model, feature)); }
public virtual bool OnEditDefinition(ISwApplication app, ISwDocument model, ISwMacroFeature feature) { return(true); }
internal SwSurface(ISurface surface, ISwDocument doc, ISwApplication app) : base(surface, doc, app) { Surface = surface; m_MathUtils = app.Sw.IGetMathUtility(); }
internal SwPolylineCurve(ICurve[] curves, ISwDocument doc, ISwApplication app, bool isCreated) : base(curves, doc, app, isCreated) { }
internal NewSelectionEventHandler(SwDocument doc, ISwApplication app) : base(doc, app) { }
internal SwFeatureMgrTab(FeatureManagerTabCreator <TControl> ctrlCreator, SwDocument doc, ISwApplication app, IXLogger logger) : base(doc, app, logger) { m_ModelViewMgr = doc.Model.ModelViewManager; m_CtrlCreator = ctrlCreator; }
internal SwEdge(IEdge edge, ISwDocument doc, ISwApplication app) : base((IEntity)edge, doc, app) { Edge = edge; }
internal SwLinearEdge(IEdge edge, ISwDocument doc, ISwApplication app) : base(edge, doc, app) { }
internal DocumentRebuildEventsHandler(SwDocument doc, ISwApplication app) : base(doc, app) { }
public PropertyManagerPageCustomItemsComboBoxControlConstructor(ISwApplication app, IIconsCreator iconsConv) : base(app, iconsConv) { }
internal SwEntity(IEntity entity, ISwDocument doc, ISwApplication app) : base(entity, doc, app) { Entity = entity; }
internal SwSketchSpline(ISketchSpline spline, ISwDocument doc, ISwApplication app, bool created) : base((ISketchSegment)spline, doc, app, created) { }
public override IEnumerable <string> ProvideItems(ISwApplication app, IControl[] dependencies) => new string[] { "A", "B", "C" };
public override CustomFeatureRebuildResult OnRebuild(ISwApplication app, ISwDocument model, ISwMacroFeature <MacroFeatureEditBodiesParams> feature, MacroFeatureEditBodiesParams parameters, out AlignDimensionDelegate <MacroFeatureEditBodiesParams> alignDim) { alignDim = null; return(new CustomFeatureRebuildResult()); }
public override IEnumerable <int> ProvideItems(ISwApplication app, IControl[] dependencies) => new int[] { 1, 2, 3 };
public SwModelViewsCollection(ISwDocument3D doc, ISwApplication app) { m_Doc = doc; m_App = app; }
internal SwTempSolidBody(IBody2 body, ISwApplication app) : base(body, app) { }
public PropertyManagerPageSelectionBoxControlConstructor(ISwApplication app, IconsConverter iconsConv, IXLogger logger) : base(app.Sw, swPropertyManagerPageControlType_e.swControlType_Selectionbox, iconsConv) { m_SwApp = app; m_Logger = logger; }
internal SwTempPlanarSheetBody(IBody2 body, ISwApplication app) : base(body, app) { }
public override void OnPostRebuild(ISwApplication app, ISwDocument model, ISwMacroFeature <PmpMacroFeatData> feature, PmpMacroFeatData parameters) { base.OnPostRebuild(app, model, feature, parameters); }
public override ISwBody[] CreateGeometry(ISwApplication app, ISwDocument model, SweepSketchData data, bool isPreview, out AlignDimensionDelegate <SweepSketchData> alignDim) { m_App = app; var cutListLengthTrackingId = app.Sw.RegisterTrackingDefinition(CUT_LIST_LENGTH_TRACKING_DEF_NAME); var result = new List <ISwBody>(); Point firstCenterPt = null; Vector firstDir = null; int index = 0; var lengths = new List <double>(); var setLengthPrp = !isPreview && data.AddLengthPropety && (model as ISwPart).Part.IsWeldment(); foreach (var sketch in data.Sketches) { foreach (var seg in sketch.Entities.OfType <ISwSketchSegment>().Where(s => !s.Segment.ConstructionGeometry)) { var path = seg.Definition; var startPt = path.StartPoint.Coordinate; if (firstCenterPt == null) { firstCenterPt = startPt; } var uParam = path.Curves.First().ReverseEvaluate(startPt.X, startPt.Y, startPt.Z); var evalData = path.Curves.First().Evaluate2(uParam, 2) as double[]; var normalAtPoint = new Vector(evalData[3], evalData[4], evalData[5]); if (firstDir == null) { firstDir = normalAtPoint; } var profile = app.MemoryGeometryBuilder.CreateCircle(startPt, normalAtPoint, data.Radius * 2); var profileRegion = app.MemoryGeometryBuilder.CreateRegionFromSegments(profile); var region = app.MemoryGeometryBuilder.CreatePlanarSheet(profileRegion).Bodies.First(); var sweep = app.MemoryGeometryBuilder.CreateSolidSweep(path, region); var body = sweep.Bodies.OfType <ISwBody>().First(); if (setLengthPrp) { body.Body.SetTrackingID(cutListLengthTrackingId, index++); lengths.Add(path.Length); } result.Add(body); } } alignDim = (name, dim) => { switch (name) { case nameof(SweepSketchData.Radius): this.AlignRadialDimension(dim, firstCenterPt, firstDir); break; } }; if (setLengthPrp) { model.Tags.Put(CUT_LIST_LENGTH_TRACKING_DEF_NAME, lengths); (model as ISwPart).CutListRebuild += OnCutListRebuild; } return(result.ToArray()); }
public virtual CustomFeatureRebuildResult OnRebuild(ISwApplication app, ISwDocument model, ISwMacroFeature feature) { return(null); }
internal SwCutListCustomPropertiesCollection(CustomPropertyManager prpsMgr, ISwDocument3D parentDoc, ISwConfiguration parentConf, ISwApplication app) : base((SwDocument)parentDoc, app) { PrpMgr = prpsMgr; m_ParentDoc = parentDoc; m_ParentConf = parentConf; }
public override IEnumerable <MyItem> ProvideItems(ISwApplication app, IControl[] dependencies) => MyItem.All;
internal SwCutListCustomProperty(CustomPropertyManager prpMgr, string name, ISwDocument3D refDoc, ISwConfiguration refConf, bool isCommited, ISwApplication app) : base(prpMgr, name, isCommited, app) { m_RefDoc = refDoc; m_RefConf = refConf; }
internal SwSketchRegion(ISketchRegion region, ISwDocument doc, ISwApplication app) : base(region, doc, app) { Region = region; }
public LazyNewDocumentGeometryBuilderDocumentProvider(ISwApplication app) { m_App = app; }