怡宁塑胶模具设计

  博客园  :: 首页  :: 新随笔  :: 联系 :: 订阅 订阅  :: 管理

VS2010 NX8.5

Annotations::SimpleDraftingAid *nullAnnotations_SimpleDraftingAid(NULL);
Annotations::DraftingNoteBuilder *draftingNoteBuilder1;
draftingNoteBuilder1 = workPart->Annotations()->CreateDraftingNoteBuilder(nullAnnotations_SimpleDraftingAid);
draftingNoteBuilder1->Origin()->SetAnchor(Annotations::OriginBuilder::AlignmentPositionMidCenter);
draftingNoteBuilder1->SetTextAlignment(Annotations::DraftingNoteBuilder::TextAlignBelowbottom);
draftingNoteBuilder1->Origin()->Plane()->SetPlaneMethod(Annotations::PlaneBuilder::PlaneMethodTypeXyPlane);
std::vector<NXString> text1(2);//设置本内容
text1[0] = "Alan Huang";
text1[1] = "QQ:185266370";
draftingNoteBuilder1->Text()->TextBlock()->SetText(text1);
draftingNoteBuilder1->Style()->LetteringStyle()->SetGeneralTextSize(10.0);//设置字高
View *nullView(NULL);
Point3d point1(150, 130, 0.0);
draftingNoteBuilder1->Origin()->Origin()->SetValue(NULL, nullView, point1);

NXObject *nXObject1;
nXObject1 = draftingNoteBuilder1->Commit();

draftingNoteBuilder1->Destroy();

 

posted on 2021-03-28 11:39  怡宁塑胶模具设计  阅读(283)  评论(0编辑  收藏  举报