资源简介
网上下了几个都不是真正的破解,只好自己动手!压缩包内包含解密文件及一个c#winfrom读取dwg、dxf的示例,vs2010下测试通过,支持最新的cad2014格式,更多示例可从官方下载。
代码片段和文件信息
#region (C) Wout Ware 2005-2007
//
// File: DxfViewExample.cs
//
// (c) 2005-2007 Wout Ware All Rights Reserved.
//
#endregion
using System;
using System.Drawing;
using System.IO;
using System.Windows.Forms;
using WW.Cad.base;
using WW.Cad.Drawing;
using WW.Cad.Drawing.GDI;
using WW.Cad.IO;
using WW.Cad.Model;
using WW.Math;
using Color = System.Drawing.Color;
using System.Collections.Generic;
using WW.Cad.Model.Entities;
using WW.Actions;
using WW.Cad.Model.Tables;
using WW.Cad.Model.objects;
namespace DxfViewExample {
///
/// A basic DXF viewer example.
///
public partial class DxfView : Form {
private DxfModel model;
private GDIGraphics3D gdiGraphics3D;
private Bounds3D bounds;
private Matrix4D modelTransform = Matrix4D.Identity;
private double scaleFactor = 1d;
private Matrix4D from2DTransform;
private Vector3D translation = Vector3D.Zero;
private bool mouseDown;
private bool shiftPressed;
private Point lastMouseLocation;
private Point mouseClickLocation;
public event EventHandler EntitySelected;
public DxfView() {
//
// The InitializeComponent() call is required for Windows Forms designer support.
//
gdiGraphics3D = new GDIGraphics3D(GraphicsConfig.BlackBackgroundCorrectForBackColor);
InitializeComponent();
}
private void CalculateTo2DTransform() {
if (bounds != null) {
Matrix4D to2DTransform = DxfUtil.GetScaleTransform(
bounds.Corner1
bounds.Corner2
bounds.Center
new Point3D(0d ClientSize.Height 0d)
new Point3D(ClientSize.Width 0d 0d)
new Point3D(ClientSize.Width / 2 ClientSize.Height / 2 0d)
);
gdiGraphics3D.To2DTransform = to2DTransform * modelTransform;
}
}
protected override void onresize(EventArgs e) {
base.onresize(e);
CalculateTo2DTransform1();
Invalidate();
}
protected override void OnPaint(PaintEventArgs e) {
//if (this.toolStripButton4.Text == “高清显示“)
//e.Graphics.SmoothingMode = System.Drawing.Drawing2D.SmoothingMode.HighQuality;
////else
e.Graphics.SmoothingMode = System.Drawing.Drawing2D.SmoothingMode.AntiAlias;
gdiGraphics3D.Draw(e.Graphics ClientRectangle);
}
protected override void onmousedown(MouseEventArgs e)
{
base.onmousedown(e);
lastMouseLocation = e.Location;
mouseClickLocation = e.Location;
mouseDown = true;
//shiftPressed = ModifierKeys == Keys.Shift
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
文件 2654208 2015-01-26 22:29 WW.Cad.dll
文件 85504 2015-01-26 22:16 WW.GL.dll
文件 161280 2015-01-26 21:43 WW.Pdf.dll
文件 506368 2015-01-26 22:46 WW.dll
文件 144 2010-07-10 12:04 WinFormsViewDwg2013\app.config
文件 200704 2011-10-06 12:12 WinFormsViewDwg2013\bin\ICSharpCode.SharpZipLib.dll
文件 19787 2013-12-30 21:40 WinFormsViewDwg2013\bin\Image Example.dxf
文件 27648 2015-01-27 09:32 WinFormsViewDwg2013\bin\WinFormsViewExample.exe
文件 144 2010-07-10 12:04 WinFormsViewDwg2013\bin\WinFormsViewExample.exe.config
文件 40448 2015-01-27 09:32 WinFormsViewDwg2013\bin\WinFormsViewExample.pdb
文件 11592 2015-01-27 09:39 WinFormsViewDwg2013\bin\WinFormsViewExample.vshost.exe
文件 144 2010-07-10 12:04 WinFormsViewDwg2013\bin\WinFormsViewExample.vshost.exe.config
文件 2654208 2015-01-26 22:29 WinFormsViewDwg2013\bin\WW.Cad.dll
文件 506368 2015-01-26 22:46 WinFormsViewDwg2013\bin\WW.dll
文件 85504 2015-01-26 22:16 WinFormsViewDwg2013\bin\WW.GL.dll
文件 7168 2013-06-04 17:04 WinFormsViewDwg2013\bin\WW.License.dll
文件 161280 2015-01-26 21:43 WinFormsViewDwg2013\bin\WW.Pdf.dll
文件 16408 2015-01-27 09:32 WinFormsViewDwg2013\DxfViewExample.cs
文件 7138 2013-12-30 21:36 WinFormsViewDwg2013\DxfViewExample.Designer.cs
文件 18579 2013-12-30 21:36 WinFormsViewDwg2013\DxfViewExample.resx
文件 1278 2015-01-26 10:41 WinFormsViewDwg2013\obj\Debug\DesignTimeResolveAssemblyReferences.cache
文件 6033 2015-01-27 09:32 WinFormsViewDwg2013\obj\Debug\DesignTimeResolveAssemblyReferencesInput.cache
文件 9315 2015-01-27 09:32 WinFormsViewDwg2013\obj\Debug\DxfViewExample.DxfView.resources
文件 4608 2013-12-23 10:23 WinFormsViewDwg2013\obj\Debug\TempPE\Properties.Resources.Designer.cs.dll
文件 27648 2015-01-27 09:32 WinFormsViewDwg2013\obj\Debug\WinFormsViewExample.exe
文件 40448 2015-01-27 09:32 WinFormsViewDwg2013\obj\Debug\WinFormsViewExample.pdb
文件 180 2015-01-27 09:32 WinFormsViewDwg2013\obj\Debug\WinFormsViewExample.Properties.Resources.resources
文件 4943 2015-01-27 09:39 WinFormsViewDwg2013\obj\Debug\WinFormsViewExampleCS VS2010.csproj.FileListAbsolute.txt
文件 984 2015-01-26 10:42 WinFormsViewDwg2013\obj\Debug\WinFormsViewExampleCS VS2010.csproj.GenerateResource.Cache
文件 54994 2015-01-26 17:37 WinFormsViewDwg2013\obj\Debug\WinFormsViewExampleCS VS2010.csprojResolveAssemblyReference.cache
............此处省略20个文件信息
- 上一篇:职工信息管理系统visual c# 源代码
- 下一篇:学生管理系统.rar
相关资源
- Asp.net学生信息管理系统源码
- asp.net C#购物车源代码
- ASP.NET实验室预约管理系统
- 020ASP.NET车辆综合管理系统.zip
- c# 高校档案信息管理系统
- asp.net中c#做的躲避小游戏,希望大家
- ASP.NET C# 工资管理系统
- 一款漂亮的灯光闪烁的圣诞树(C# V
- C#笔试题大全C#面试集合包括了,.ne
- ASP.NET客户管理系统(毕业设计 C#
- 在线求职系统(C#ASP.NET源码)
- .NET C# Custom Form Designer (附源碼)
- C#冒泡排序动态演示程序(看了就会)
- 酒店管理系统(c#.net源码)
- asp.net 在线考试系统及论文
- winform实时获取网卡网速全部源码,获
- ASP.Net文件上传管理源码
- ArcGIS Runtime SDK for .NET
- C# .NET5.0(net core)基于WPF(XAML)开发
- Quartz.NET定时任务框架
- .net core 动态生成 Word文档(word Expor
- 《OA企业办公自动化》asp.net 源码(附
- .net 检测新版本-自动升级程序
- tcp和udp(Mina.net)
- asp.netc#开发规范
- ADO.NET操作EXCEL
- asp.net 大文件上传(带进度条)
- 通过程序自动填充并提交ASP.NET表单(
- ASP.NET 基础编程文档(PPT电子教案)
-
ASP.NET_xm
l深入编程技术
评论
共有 条评论