123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230 |
- using ComPDFKitViewer.AnnotEvent;
- using PDF_Master.CustomControl.CompositeControl;
- using PDF_Master.Helper;
- using PDF_Master.Properties;
- using PDFSettings;
- using Prism.Mvvm;
- using System;
- using System.Collections.Generic;
- using System.Linq;
- using System.Text;
- using System.Threading.Tasks;
- using System.Windows.Media;
- namespace PDF_Master.Model.AnnotPanel
- {
-
- public class AnnotCommon : BindableBase
- {
-
- private AnnotArgsType _annotType;
- public AnnotArgsType AnnotType
- {
- get { return _annotType; }
- set => SetProperty(ref _annotType, value);
- }
-
- private string _annotTypeTitle;
- public string AnnotTypeTitle
- {
- get { return _annotTypeTitle; }
- set => SetProperty(ref _annotTypeTitle, value);
- }
- #region 线条
-
- private double _annotThickness = 1;
- public double AnnotThickness
- {
- get { return _annotThickness; }
- set => SetProperty(ref _annotThickness, value);
- }
-
- private DashStyle dash = new DashStyle();
- public DashStyle Dash
- {
- get { return dash; }
- set => SetProperty(ref dash, value);
- }
- #endregion 线条
- #region 填充
-
- private double fillOpacity = 1;
- public double FillOpacity
- {
- get { return fillOpacity; }
- set => SetProperty(ref fillOpacity, value);
- }
-
- private Brush _currentFillColor = App.Current.FindResource("color.sys.layout.divider.text-date-fill") as Brush;
- public Brush CurrentFillColor
- {
- get { return _currentFillColor; }
- set => SetProperty(ref _currentFillColor, value);
- }
-
- private Brush fillColor = new SolidColorBrush(Colors.Transparent);
- public Brush FillColor
- {
- get { return fillColor; }
- set { SetProperty(ref fillColor, value); CurrentFillColor = fillColor; }
- }
-
- private List<ColorItem> _colorItems = new List<ColorItem>();
- public List<ColorItem> ColorItems
- {
- get { return _colorItems; }
- set => SetProperty(ref _colorItems, value);
- }
-
- private List<ColorItem> _fillColorItems = new List<ColorItem>();
- public List<ColorItem> FillColorItems
- {
- get { return _fillColorItems; }
- set => SetProperty(ref _fillColorItems, value);
- }
- #endregion 填充
- #region 边框
-
- private double _borderOpacity = 1;
- public double BorderOpacity
- {
- get { return _borderOpacity; }
- set => SetProperty(ref _borderOpacity, value);
- }
- private Brush _borderColor = new SolidColorBrush(Colors.Transparent);
- public Brush BorderColor
- {
- get { return _borderColor; }
- set { SetProperty(ref _borderColor, value); CurrentBorderColor = _borderColor; }
- }
-
- private Brush _currentBorderColor = App.Current.FindResource("color.sys.layout.divider.shapes-border") as Brush;
- public Brush CurrentBorderColor
- {
- get { return _currentBorderColor; }
- set => SetProperty(ref _currentBorderColor, value);
- }
- private Brush _fontColor = new SolidColorBrush(Colors.Transparent);
- public Brush FontColor
- {
- get { return _fontColor; }
- set { SetProperty(ref _fontColor, value); CurrentFontColor = _fontColor; }
- }
-
- private Brush _currentFontColor=App.Current.FindResource("color.sys.layout.divider.pen") as Brush;
- public Brush CurrentFontColor
- {
- get { return _currentFontColor; }
- set => SetProperty(ref _currentFontColor, value);
- }
-
- private bool _isSolidLine = true;
- public bool IsSolidLine
- {
- get { return _isSolidLine; }
- set => SetProperty(ref _isSolidLine, value);
- }
-
- private bool _isDashLine = true;
- public bool IsDashLine
- {
- get { return _isDashLine; }
- set => SetProperty(ref _isDashLine, value);
- }
-
- public string strOtherTag { get; private set; }
-
- public void SetOtherTag(string str)
- {
- strOtherTag = str;
- }
- #endregion 边框
- #region 多选
-
- private bool _isMultiSelected = false;
- public bool IsMultiSelected
- {
- get { return _isMultiSelected; }
- set => SetProperty(ref _isMultiSelected, value);
- }
- private bool isFreeHandSelected = true;
- public bool IsFreeHandSelected
- {
- get { return isFreeHandSelected; }
- set
- {
- SetProperty(ref isFreeHandSelected, value);
- }
- }
- private bool isSharpAnnotSelected = true;
- public bool IsSharpAnnotSelected
- {
- get { return isSharpAnnotSelected; }
- set
- {
- SetProperty(ref isSharpAnnotSelected, value);
- }
- }
- #endregion 多选
-
-
-
- public event EventHandler<object> SelectedAnnotInvokeToUI;
-
-
-
- public void InvokeToUI(object sender, object value)
- {
- SelectedAnnotInvokeToUI?.Invoke(sender, value);
- }
- }
- }
|