개정판 f1f822e9
issue #00000 svg 기능 수정
Change-Id: Ic1575964db1f861ca637c7073dfa382fee4bbcd4
KCOM/Events/PasteCommand.cs | ||
---|---|---|
7 | 7 |
using Newtonsoft.Json.Converters; |
8 | 8 |
using Newtonsoft.Json.Linq; |
9 | 9 |
using Newtonsoft.Json.Serialization; |
10 |
using Svg2Xaml; |
|
11 | 10 |
using System; |
12 | 11 |
using System.Collections; |
13 | 12 |
using System.Collections.Generic; |
... | ... | |
174 | 173 |
System.Windows.Controls.Image img = new System.Windows.Controls.Image(); |
175 | 174 |
if (filename.Contains(".svg")) |
176 | 175 |
{ |
177 |
byte[] imageData = null; |
|
178 |
DrawingImage image = null; |
|
179 |
using (System.Net.WebClient web = new System.Net.WebClient()) |
|
180 |
{ |
|
181 |
imageData = web.DownloadData(new Uri(filename)); |
|
182 |
System.IO.Stream stream = new System.IO.MemoryStream(imageData); |
|
183 |
image = SvgReader.Load(stream); |
|
184 |
} |
|
185 |
img.Source = image; |
|
176 |
SharpVectors.Converters.SvgImageExtension svgImage = new SharpVectors.Converters.SvgImageExtension(filename); |
|
177 |
img.Source = (DrawingImage)svgImage.ProvideValue(null); |
|
186 | 178 |
} |
187 | 179 |
else |
188 | 180 |
{ |
내보내기 Unified diff