1
0
Fork 0
mirror of https://github.com/Nioux/AideDeJeu.git synced 2025-10-29 22:45:44 +00:00

Correction cartes

This commit is contained in:
Yan Maniez 2018-06-01 17:45:34 +02:00
parent 90105c3d4e
commit 8f9f0fe0c9
2 changed files with 11 additions and 4 deletions

View file

@ -73,7 +73,7 @@ namespace AideDeJeuLib.Cards
foreach (var content in description.ChildNodes)
{
//Debug.WriteLine(content.NodeType + " " + content.Name + " " + content.InnerText);
if (content.NodeType == HtmlNodeType.Element && content.Name == "strong")
if ((content.NodeType == HtmlNodeType.Element || content.NodeType == HtmlNodeType.Document) && content.Name == "strong")
{
if (currentText.Length > 0)
{
@ -82,7 +82,7 @@ namespace AideDeJeuLib.Cards
}
contents.Add(new SectionCardContent(content.InnerText));
}
else if (content.NodeType == HtmlNodeType.Element && content.Name == "em")
else if ((content.NodeType == HtmlNodeType.Element || content.NodeType == HtmlNodeType.Document) && content.Name == "em")
{
currentText += "<em>" + content.InnerText + "</em>";
}
@ -141,9 +141,9 @@ namespace AideDeJeuLib.Cards
new PropertyCardContent("Durée", spell.Duration),
new RuleCardContent(),
//new FillCardContent(1),
//new TextCardContent(spell.Description),
//new TextCardContent(spell.DescriptionText),
});
var description = ToContents(spell.DescriptionDiv);
var description = ToContents(spell.DescriptionDiv.Element("div"));
foreach (var line in description)
{
int size = contents.Sum(cc => cc.Height);

View file

@ -0,0 +1,7 @@
{
"profiles": {
"AideDeJeu": {
"commandName": "Project"
}
}
}