OSDN Git Service

ストローク周りで互換性がない部分を修正した
authortest <test@yahoo.co.jp>
Sat, 22 Aug 2020 04:42:57 +0000 (13:42 +0900)
committertest <test@yahoo.co.jp>
Sat, 22 Aug 2020 04:42:57 +0000 (13:42 +0900)
Core/Direct2D/CustomTextRenderer.cs
Core/Direct2D/D2DRenderCommon.cs

index 84b6b9c..6b77527 100644 (file)
@@ -141,7 +141,7 @@ namespace FooEditEngine
                 float thickness = effect.isBoldLine ? D2DRenderCommon.BoldThickness : D2DRenderCommon.NormalThickness;
                 if (effect.Stroke == HilightType.Squiggle)
                 {
-                    SquilleLineMarker marker = new D2DSquilleLineMarker(this.render, this.brushes.Get(effect.Fore), this.strokes.Get(effect.Stroke), 1);
+                    SquilleLineMarker marker = new D2DSquilleLineMarker(this.render, this.brushes.Get(effect.Fore), this.strokes.Get(this.render,effect.Stroke), 1);
                     marker.Draw(
                         baselineOriginX, baselineOriginY + underline.Offset,
                         underline.Width, underline.RunHeight
@@ -149,7 +149,7 @@ namespace FooEditEngine
                 }
                 else
                 {
-                    LineMarker marker = new LineMarker(this.render, this.brushes.Get(effect.Fore), this.strokes.Get(effect.Stroke), GetThickness(thickness));
+                    LineMarker marker = new LineMarker(this.render, this.brushes.Get(effect.Fore), this.strokes.Get(this.render,effect.Stroke), GetThickness(thickness));
                     marker.Draw(
                         baselineOriginX, baselineOriginY + underline.Offset,
                         underline.Width, 0
index 88f7604..505fcd7 100644 (file)
@@ -728,7 +728,7 @@ namespace FooEditEngine
         public void DrawLine(Point from, Point to)
         {
             D2D.Brush brush = this.Brushes.Get(this.Foreground);
-            D2D.StrokeStyle stroke = this.Strokes.Get(HilightType.Sold);
+            D2D.StrokeStyle stroke = this.Strokes.Get(this.D2DFactory,HilightType.Sold);
             this.render.DrawLine(from, to, brush, 1.0f, stroke);
         }
 
@@ -754,13 +754,13 @@ namespace FooEditEngine
             D2D.SolidColorBrush brush = this.Brushes.Get(color);
 
             if (type == HilightType.Squiggle)
-                effecter = new D2DSquilleLineMarker(this.render, brush, this.Strokes.Get(HilightType.Squiggle), thickness);
+                effecter = new D2DSquilleLineMarker(this.render, brush, this.Strokes.Get(this.D2DFactory, HilightType.Squiggle), thickness);
             else if (type == HilightType.Select)
                 effecter = new HilightMarker(this.render, brush);
             else if (type == HilightType.None)
                 effecter = null;
             else
-                effecter = new LineMarker(this.render, brush, this.Strokes.Get(type), thickness);
+                effecter = new LineMarker(this.render, brush, this.Strokes.Get(this.D2DFactory,type), thickness);
 
             if (effecter != null)
             {