<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
Ooops, it was my bad.<br>
I was loading a markdown from GitHub pages, and it seems that GitHub
pages automatically translates markdown into HTML<br>
if the markdown is named like index.md...<br>
<br>
Problem solved, it's a GitHub pages one, not a JavaFX one :)<br>
<br>
Thanks<br>
Davide<br>
<br>
Il 06/01/2024 13:22, Davide Perini ha scritto:<br>
<blockquote type="cite"
cite="mid:a7104eb8-4e27-4f9e-9d62-72f280b43474@dpsoftware.org">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
I think that the webview itself is able to turn the markdown into
something that is correctly rendered.<br>
<br>
[this text](<a class="moz-txt-link-freetext"
href="http://acme.org" moz-do-not-send="true">http://acme.org</a>)<br>
for example is correctly turned into a clickable link, where the
text of the link is "this text" and the click opens the acme.org
website.<br>
<br>
I'm not really into the webview implementation...<br>
<br>
<br>
<div class="moz-cite-prefix">Il 05/01/2024 22:34, Tom Eugelink ha
scritto:<br>
</div>
<blockquote type="cite"
cite="mid:1631f5da-b658-4240-a1f9-fc86e746d479@tbee.org">
<meta http-equiv="Content-Type"
content="text/html; charset=UTF-8">
<div class="moz-cite-prefix">I'm missing the part on how the
markdown is turned into HTML. Because the WebView cannot
render markdown directly...?</div>
<div class="moz-cite-prefix"><br>
</div>
<div class="moz-cite-prefix">Bold in HTML is not done using **,
it is done with font-weight (<a class="moz-txt-link-freetext"
href="https://www.udacity.com/blog/2021/01/html-css-font-weight.html"
moz-do-not-send="true">https://www.udacity.com/blog/2021/01/html-css-font-weight.html</a>)
or <b> (<a class="moz-txt-link-freetext"
href="https://www.w3schools.com/tags/tag_b.asp"
moz-do-not-send="true">https://www.w3schools.com/tags/tag_b.asp</a>),
so something is turning that ** into actual HTML, and that is
not working.</div>
<div class="moz-cite-prefix"><br>
</div>
<div class="moz-cite-prefix"><br>
</div>
<div class="moz-cite-prefix"><br>
</div>
<div class="moz-cite-prefix">On 2024-01-05 18:45, Davide Perini
wrote:<br>
</div>
<blockquote type="cite"
cite="mid:0101ccd5-7a22-4972-a8a8-df2d13323211@dpsoftware.org">
<meta http-equiv="content-type"
content="text/html; charset=UTF-8">
Hi all,<br>
I have a simple javafx.scene.web.WebView<br>
<br>
code is as simple as this:<br>
<br>
<div style="background-color:#1e1f22;color:#bcbec4">
<div style="background-color:#1e1f22;color:#bcbec4">
<div style="background-color:#1e1f22;color:#bcbec4">
<pre
style="font-family:'JetBrains Mono',monospace;font-size:9,8pt;">WebView <span
style="color:#c77dbb;">wv </span>= <span
style="color:#cf8e6d;">new </span>WebView();
<span style="color:#c77dbb;">wv</span>.getEngine().load(webUrl);
</pre>
<div style="background-color:#1e1f22;color:#bcbec4">
<pre
style="font-family:'JetBrains Mono',monospace;font-size:9,8pt;">Alert alert = createAlert(title, header, alertType);
alert.getDialogPane().setContent(<span style="color:#c77dbb;">wv</span>);
alert.showAndWait();
</pre>
</div>
</div>
</div>
</div>
<br>
As you can see the webview loads a webUrl, that web url
returns a markdown.<br>
<br>
Mark down is correctly rendered, I can see correct headings,
links are interpreted correctly like links and are clickable,
ecc.<br>
The only things that seems to not work is the bold text.<br>
<br>
Bold text **like this** or __like this__<br>
is interpreted "like this", without the ** or __<br>
but it's not bold, it is rendered like a normal text.<br>
<br>
Any idea on how to fix it? :)<br>
<br>
Thanks<br>
Davide<br>
<br>
<br>
<br>
<br>
</blockquote>
<p><br>
</p>
</blockquote>
<br>
</blockquote>
<br>
</body>
</html>