翻譯|使用教程|編輯:況魚杰|2019-09-20 10:18:21.130|閱讀 199 次
概述:本系列教程整理了VectorDraw Developer Framework(VDF)最常見問題,教程整理的很齊全,非常適合新手學習,本節教程將會介紹如何初始化具有特定值的bhatch對話框。
# 界面/圖表報表/文檔/IDE等千款熱門軟控件火熱銷售中 >>
相關鏈接:
VectorDraw Developer Framework(VDF)是一個用于應用程序可視化的圖形引擎庫。有了VDF提供的功能,您可以輕松地創建、編輯、管理、輸出、輸入和打印2D和3D圖形文件。
VectorDraw Developer Framework試用版下載
問:
如果想初始化具有特定值的bhatch對話框或保留對話框以前的值,應該怎么做?
答:
請檢查下面的代碼,演示如何覆蓋默認的bHatch命令實現并使用特定值調用對話框。
void CommandLine_CommandExecute(string commandname, bool isDefaultImplemented, ref bool success) { if (string.Compare(commandname, "bhatch", true) == 0) { vdDocument doc = vdFramedControl1.BaseControl.ActiveDocument; //Set some initial values for the dialog , This can be global to an application so these values can be changed. //You can call the following dialog with a different constructor (with vdHatchproperties) in order to set these values in a global properties application dialog that you may have. vdHatchProperties SetBhatchInitialValues = new vdHatchProperties(); SetBhatchInitialValues.FillMode = VectorDraw.Professional.Constants.VdConstFill.VdFillModeHatchBlock; SetBhatchInitialValues.FillColor.ColorIndex = 0; //Keep in a variable the current ActiveHatchProperties vdHatchProperties KeepActiveHatch = new vdHatchProperties(); KeepActiveHatch.CopyFrom(doc.ActiveHatchProperties); //Set the ActiveHatchProperties to the above value doc.ActiveHatchProperties.CopyFrom(SetBhatchInitialValues); //Call the dialog. vdFigure ret = VectorDraw.Professional.Dialogs.frmGetHatchDialog.Show(null,doc, doc.ActionControl); //Return ActiveHatchProperties values as it was before the dialog. doc.ActiveHatchProperties.CopyFrom (KeepActiveHatch); success = true; return; } }
對于以上問答,如果您有任何的疑惑都可以在評論區留言,我們會及時回復。此系列的問答教程我們會持續更新,如果您感興趣,可以多多關注本教程。
相關資料推薦:
VectorDraw Developer Framework(VDF)示例
如果您對想要購買正版授權VectorDraw Developer Framework(VDF),可以聯系咨詢相關問題。
關注慧聚IT微信公眾號 ???,了解產品的最新動態及最新資訊。
本站文章除注明轉載外,均為本站原創或翻譯。歡迎任何形式的轉載,但請務必注明出處、不得修改原文相關鏈接,如果存在內容上的異議請郵件反饋至chenjj@fc6vip.cn
文章轉載自: