Pārlūkot izejas kodu

Fixed a bug in Paragraph.AppendHyperlink(h) that caused any custom formatting to be applied to the runs before the Hyperlink instead of the Hyperlink itself. The below is now possible

Paragraph p = document.InsertParagraph();
p.Append("Check out this ").Color(Color.Red).AppendHyperlink(h).Color(Color.Green).Append(", it's really cool").Color(Color.Blue);
master
coffeycathal_cp pirms 15 gadiem
vecāks
revīzija
37a584e15f
3 mainītis faili ar 2 papildinājumiem un 1 dzēšanām
  1. 1
    1
      DocX/Paragraph.cs
  2. 1
    0
      DocX/_Enumerations.cs
  3. Binārs
      DocX/bin/Debug/DocX.dll

+ 1
- 1
DocX/Paragraph.cs Parādīt failu

@@ -1891,7 +1891,7 @@ namespace Novacode
Xml.Add(h.Xml);
Xml.Elements().Last().SetAttributeValue(DocX.r + "id", rel.Id);
this.runs = Xml.Elements(XName.Get("r", DocX.w.NamespaceName)).Reverse().Take(h.Xml.Elements(XName.Get("r", DocX.w.NamespaceName)).Count()).ToList();
this.runs = Xml.Elements().Last().Elements(XName.Get("r", DocX.w.NamespaceName)).ToList();
BuildRunLookup(Xml);
return this;

+ 1
- 0
DocX/_Enumerations.cs Parādīt failu

@@ -5,6 +5,7 @@ using System.Text;
namespace Novacode
{
public enum Orientation { Portrait, Landscape };
public enum XmlDocument { Main, HeaderOdd, HeaderEven, HeaderFirst, FooterOdd, FooterEven, FooterFirst };
public enum MatchFormattingOptions { ExactMatch, SubsetMatch};
public enum Script { superscript, subscript, none }

Binārs
DocX/bin/Debug/DocX.dll Parādīt failu


Notiek ielāde…
Atcelt
Saglabāt