From 242318d5a4ce44bff7231b18634c1846af54fc5a Mon Sep 17 00:00:00 2001 From: Joe Date: Wed, 3 Jan 2024 16:02:59 -0500 Subject: [PATCH] Parse User Defined Attributes in WMarker.cs As per the USFM Documentation: https://ubsicap.github.io/usfm/attributes/index.html#user-defined-attributes > Any user defined attributes must begin with the prefix x-. --- USFMToolsSharp/Models/Markers/WMarker.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/USFMToolsSharp/Models/Markers/WMarker.cs b/USFMToolsSharp/Models/Markers/WMarker.cs index c1a629c..9757bed 100644 --- a/USFMToolsSharp/Models/Markers/WMarker.cs +++ b/USFMToolsSharp/Models/Markers/WMarker.cs @@ -12,7 +12,7 @@ public class WMarker : Marker { public string Term; public Dictionary Attributes; - private static Regex wordAttrPattern = new Regex("([\\w]+)=?\"?([\\w,:.]*)\"?", RegexOptions.Singleline); + private static Regex wordAttrPattern = new Regex("([\\w-]+)=?\"?([\\w,:.]*)\"?", RegexOptions.Singleline); public override string Identifier => "w"; public override string PreProcess(string input)