This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| string markdown = tx.SaveMarkdown(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using var tx = new ServerTextControl(); | |
| tx.Create(); | |
| tx.LoadMarkdown("# Quarterly Report"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <!doctype html> | |
| <html lang="en"> | |
| <head> | |
| <meta charset="utf-8"> | |
| <title>Invoice Summary</title> | |
| </head> | |
| <body> | |
| <h1>Invoice #TX-2042</h1> | |
| <p>Prepared for <strong>Contoso Publishing</strong> on <em>June 11, 2026</em>.</p> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var html = File.ReadAllText(htmlFile); | |
| var markdown = | |
| ConvertHtmlToMarkdownWithTextControl(html).Trim() | |
| + Environment.NewLine; | |
| var outputFile = Path.Combine( | |
| outputDirectory, | |
| $"{Path.GetFileNameWithoutExtension(htmlFile)}.md"); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var htmlFiles = Directory | |
| .EnumerateFiles(inputDirectory, "*.html", SearchOption.TopDirectoryOnly) | |
| .OrderBy(file => file, StringComparer.OrdinalIgnoreCase) | |
| .ToArray(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| tx.LoadMarkdown("# Hello from Markdown"); | |
| string markdown = tx.SaveMarkdown(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using var tx = new ServerTextControl(); | |
| if (!tx.Create()) | |
| { | |
| throw new InvalidOperationException( | |
| "Could not create the TX Text Control ServerTextControl instance."); | |
| } | |
| tx.Load(html, StringStreamType.HTMLFormat); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using System.Security.Cryptography.X509Certificates; | |
| using TXTextControl; | |
| using var tx = new ServerTextControl(); | |
| tx.Create(); | |
| tx.Load( | |
| "signature.tx", | |
| StreamType.InternalUnicodeFormat); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using System.Drawing; | |
| using System.Security.Cryptography.X509Certificates; | |
| using TXTextControl; | |
| using var tx = new ServerTextControl(); | |
| tx.Create(); | |
| var signatureField = new SignatureField( | |
| new Size(2000, 2000), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| using System.Security.Cryptography.X509Certificates; | |
| using TXTextControl; | |
| using var tx = new ServerTextControl(); | |
| tx.Create(); | |
| tx.Text = "This is a signed PDF document."; | |
| var certificate = new X509Certificate2( |
NewerOlder