一部のレイヤーのみのエクスポートとリスケーリング
Contents
[
Hide
]一部のレイヤーのみのエクスポートとリスケーリング (CADNET-559)
問題: 一部のレイヤーのみのエクスポートとリスケーリングの方法 (CADNET-559)。
ヒント: これを行うには、必要なレイヤーを選択し、それらを CadBaseEntity 配列に追加し、次に描画エンティティに割り当てて UpdateSize を実行します。
例:
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
List<CadBaseEntity> validEntities = new List<CadBaseEntity>(); | |
foreach (CadBaseEntity entity in cadImage.Entities) | |
{ | |
if (entity.LayerName == "Layer1" || entity.LayerName == "Layer2") | |
{ | |
validEntities.Add(entity); | |
} | |
} | |
cadImage.Entities = validEntities.ToArray(); | |
cadImage.UpdateSize(); |