|
|
|
|
|
using System;
|
|
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
|
using System.Linq;
|
|
|
|
|
|
using System.Text;
|
|
|
|
|
|
using System.Threading.Tasks;
|
|
|
|
|
|
|
|
|
|
|
|
namespace GeoSigma.SigmaDrawerStyle.Converter
|
|
|
|
|
|
{
|
|
|
|
|
|
public class AlignHorizionConverter : EnumConverter<TextStyleFlags>
|
|
|
|
|
|
{
|
|
|
|
|
|
protected override Dictionary<TextStyleFlags, string> CreateMaps()
|
|
|
|
|
|
{
|
|
|
|
|
|
return new Dictionary<TextStyleFlags, string>
|
|
|
|
|
|
{
|
|
|
|
|
|
{TextStyleFlags.alignLeft, "居左" },
|
|
|
|
|
|
{TextStyleFlags.alignCenterH, "居中" },
|
|
|
|
|
|
{TextStyleFlags.alignRight, "居右" },
|
|
|
|
|
|
};
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
public class AlignHorizionMultConverter : EnumConverter<TextStyleFlags>
|
|
|
|
|
|
{
|
|
|
|
|
|
protected override Dictionary<TextStyleFlags, string> CreateMaps()
|
|
|
|
|
|
{
|
|
|
|
|
|
return new Dictionary<TextStyleFlags, string>
|
|
|
|
|
|
{
|
|
|
|
|
|
{TextStyleFlags.alignLeftMult, "左对齐" },
|
|
|
|
|
|
{TextStyleFlags.alignCenterMult, "居中对齐" },
|
|
|
|
|
|
{TextStyleFlags.alignRightMult, "右对齐" },
|
|
|
|
|
|
};
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public class AlignVerticalConverter : EnumConverter<TextStyleFlags>
|
|
|
|
|
|
{
|
|
|
|
|
|
protected override Dictionary<TextStyleFlags, string> CreateMaps()
|
|
|
|
|
|
{
|
|
|
|
|
|
return new Dictionary<TextStyleFlags, string>
|
|
|
|
|
|
{
|
|
|
|
|
|
{TextStyleFlags.alignTop, "居上" },
|
|
|
|
|
|
{TextStyleFlags.alignCenterV, "居中" },
|
|
|
|
|
|
{TextStyleFlags.alignBottom, "居下" },
|
|
|
|
|
|
};
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public class BorderTypeConverter : EnumConverter<TextStyleFlags>
|
|
|
|
|
|
{
|
|
|
|
|
|
protected override Dictionary<TextStyleFlags, string> CreateMaps()
|
|
|
|
|
|
{
|
|
|
|
|
|
return new Dictionary<TextStyleFlags, string>
|
|
|
|
|
|
{
|
|
|
|
|
|
{TextStyleFlags.frameNull, "空" },
|
|
|
|
|
|
{TextStyleFlags.frameRect, "矩形" },
|
|
|
|
|
|
{TextStyleFlags.frameCircle, "圆" },
|
|
|
|
|
|
{TextStyleFlags.frameEllipse, "椭圆" },
|
|
|
|
|
|
};
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|