• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

DomCR / ACadSharp.Pdf / 14305897173

07 Apr 2025 09:38AM UTC coverage: 2.035% (-73.9%) from 75.959%
14305897173

push

github

DomCR
version 0.1.0-beta

125 of 8279 branches covered (1.51%)

Branch coverage included in aggregate %.

648 of 29704 relevant lines covered (2.18%)

4.64 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/src/ACadSharp.Pdf/PdfConfiguration.cs
1
using ACadSharp.IO;
2
using System;
3
using System.Collections.Generic;
4

5
namespace ACadSharp.Pdf
6
{
7
        public class PdfConfiguration
8
        {
9
                /// <summary>
10
                /// Line weight default values.
11
                /// </summary>
12
                public static readonly IReadOnlyDictionary<LineweightType, double> LineWeightDefaultValues =
×
13
                        new Dictionary<LineweightType, double>()
×
14
                {
×
15
                        { LineweightType.Default, 0 },
×
16
                        { LineweightType.W0, 0.001 },
×
17
                        { LineweightType.W5, 0.05 },
×
18
                        { LineweightType.W9, 0.09 },
×
19
                        { LineweightType.W13, 0.13 },
×
20
                        { LineweightType.W15, 0.15 },
×
21
                        { LineweightType.W18, 0.18 },
×
22
                        { LineweightType.W20, 0.20 },
×
23
                        { LineweightType.W25, 0.25 },
×
24
                        { LineweightType.W30, 0.30 },
×
25
                        { LineweightType.W35, 0.35 },
×
26
                        { LineweightType.W40, 0.40 },
×
27
                        { LineweightType.W50, 0.50 },
×
28
                        { LineweightType.W53, 0.53 },
×
29
                        { LineweightType.W60, 0.60 },
×
30
                        { LineweightType.W70, 0.70 },
×
31
                        { LineweightType.W80, 0.80 },
×
32
                        { LineweightType.W90, 0.90 },
×
33
                        { LineweightType.W100, 1.00 },
×
34
                        { LineweightType.W106, 1.06 },
×
35
                        { LineweightType.W120, 1.20 },
×
36
                        { LineweightType.W140, 1.40 },
×
37
                        { LineweightType.W158, 1.58 },
×
38
                        { LineweightType.W200, 2.00 },
×
39
                        { LineweightType.W211, 2.11 },
×
40
                };
×
41

42
                /// <summary>
43
                /// Notification event to get information about the export process.
44
                /// </summary>
45
                /// <remarks>
46
                /// The notification system informs about any issue or non critical errors during the export.
47
                /// </remarks>
48
                public event NotificationEventHandler OnNotification;
49

50
                /// <summary>
51
                /// Set the dot size.
52
                /// </summary>
53
                /// <remarks>
54
                /// The units used to draw the points are the same as the paper.
55
                /// </remarks>
56
                public double DotSize { get; set; } = 0.01d;
×
57

58
                /// <summary>
59
                /// Number of divisions performed in the arcs when drawing the shape.
60
                /// </summary>
61
                public ushort ArcPrecision { get; set; } = 256;
×
62

63
                /// <summary>
64
                /// Decimal format and precision set for the pdf file.
65
                /// </summary>
66
                public string DecimalFormat { get; set; } = "0.####";
×
67

68
                public Dictionary<LineweightType, double> LineWeightValues { get; set; } = new();
×
69

70
                public double GetLineWeightValue(LineweightType lineWeight)
71
                {
×
72
                        double value = 0.0d;
×
73
                        if (this.LineWeightValues.TryGetValue(lineWeight, out value)
×
74
                                || LineWeightDefaultValues.TryGetValue(lineWeight, out value))
×
75
                        {
×
76
                                return value;
×
77
                        }
78

79
                        return value;
×
80
                }
×
81

82
                internal void Notify(string message, NotificationType notificationType, Exception ex = null)
83
                {
×
84
                        this.OnNotification?.Invoke(this, new NotificationEventArgs(message, notificationType, ex));
×
85
                }
×
86
        }
87
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc