原創|產品更新|編輯:我只采一朵|2016-03-07 13:57:01.000|閱讀 1290 次
概述:DevExpress最新升級至 v15.2.7 ,多個API有重大變化,歡迎下載試用最新版.
# 界面/圖表報表/文檔/IDE等千款熱門軟控件火熱銷售中 >>
以下是 DevExpress 15.2.7 API重大變化,請注意更新相應代碼,歡迎下載試用最新版:
新增以下元素:
已刪除以下元素:
幾個負責更新LinksControl.ItemsSource屬性值的方法從LinksControl類和子類中移除了。
1) The ConnectorPointsCollection class 更名為 DiagramPointCollection.
2) The DiagramItem.ConnectionPoints 屬性類型從 System.Windows.Media.PointCollection 更改為 DiagramPointCollection.
- The PropertiesPanelVisibility 屬性類型從 System.Windows.Visibility 更改為 DevExpress.Diagram.Core.PropertiesPanelVisibility.
- The ToolboxViewMode property 更名為 ToolboxVisibility.
- ToolboxVisibility屬性的 'Normal' 和 'Collapsed' 狀態分別更名為 'Full' 和 'Closed' .
- PropertiesPanelVisibility屬性的 "Hidden" 和 "Collapsed" 狀態分別更名為 'Collapsed' 和 'Closed'.
在以前的版本中,添加一個新的存儲進程如果與已存在的參數名沖突會拋出一個異常"An item with the same key has already been added".從v15.2.7開始,指定已存在的參數名稱使用以下模式:
"DataSourceName.StoredProcedureName.ParameterName"
( DataSourceName 是一個報表數據源對象的名稱 )
示例:
[C#] ReportParameter[] reportParameters = new ReportParameter[] { new ReportParameter { Path = "Northwind.CustOrderHist.@CustomerID", Value = "ALFKI" }}; var bytes = Task.Factory.ExportReportAsync(client, new ReportNameIdentity(reportsList.SelectedItem.Text), new PdfExportOptions (), reportParameters, null).Result;
- DiagramConnector.IntermediatePoints 屬性更名為 DiagramConnector.Points .
- DiagramConnector.Points 屬性類型更改為 DiagramPointCollection.
- DiagramConnector.Points 集合變為只讀類型.
CalcHitInfo方法現在只接受帶點的參數,DiagramHitInfo對象集合的所有圖形元素放在點后面。這個方法可以用于復雜的場景,比如需要放置一個圖形的內部元素(如selector box),或者刪除重疊的圖形。請看示例:
[C#] // determine if there is a connector point at this position and if there is, assign a corresponding connector to the 'connector' field var connector = diagram .CalcHitInfo(e.ControlMousePosition) .Select(x => x.MatchHitInfo<DiagramConnector>(connectorPoint : (c, type) => c)) .FirstOrDefault();
對于比較簡單的情況,用CalcHitItem方法返回最上面的 diagram 項:
[C#] var item = diagram.CalcHitItem(e.ControlMousePosition);
如果你想編輯一個在DiagramControl單獨對話框中的圖形,用DiagramDesignerForm類:
[C#] using DevExpress.XtraDiagram.Designer; ... using (var form = new DiagramDesignerForm()) { form.ShowDialog(); }
從15.2.7開始, RepositoryItemTreeListLookUpEdit.ExportMode默認值主要視為 DisplayText,類似于查找編輯器。此外,還新增了一個靜態屬性RepositoryItemTreeListLookUpEdit.DefaultExportMode用于控制TreeListLookUp的當前輸出模式。
DevExpress v15.2.7完整更新信息請看這里:
本站文章除注明轉載外,均為本站原創或翻譯。歡迎任何形式的轉載,但請務必注明出處、不得修改原文相關鏈接,如果存在內容上的異議請郵件反饋至chenjj@fc6vip.cn