Web Dialog

Good evening to everyone

I am converting some parametric plugins (parametric.rb) from imput type dialog box to Web Dialog in order to implement different languages. However, I have a problem of visualization that does not depend on the PC or the version of Sketchup, in practice wrapped it happens that the web dialog appears empty and passing on it with the mause you discover the fields of imput. pressing the F5 key solves the problem momentarily.


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><title>SOFTDEG_vetrate</title>

<style type="text/css">

body {
	background-color: #fff;
	font-family: Arial,Helvetica;
	font-size:10pt;
	margin:0px;
	padding:20px;
}

table {
	font-size:10pt;
}

input {
	border-color:#aaa; 
	border-style:solid; 
	border-width:1px; 
	font-size:10pt;
}

button {
	border-style:outset; 
}

  </style></head><body>
<table style="text-align: left; width: 821px; height: 365px;" border="0" cellpadding="2" cellspacing="2">

  <tbody>
    <tr>
      <td style="vertical-align: top;">
      <table id="settings" style="padding: 3px; margin-top: 3px; margin-bottom: 3px; height: 645px; width: 507px;">
        <tbody>
          <tr style="background-color: rgb(238, 238, 238); width: 406px;">
            <td style="width: 349px;">01 - Larghezza</td>
            <td style="width: 119px;"><input id="w" value="" type="text"></td>
          </tr>
          <tr>
            <td style="width: 349px;">02 - Altezza - (compreso spessore
soglia)</td>
            <td style="width: 119px;"><input id="h" value="" type="text"></td>
          </tr>
          <tr style="background-color: rgb(238, 238, 238);">
            <td style="width: 349px;">03 - Inverti misure
Larghezza/Altezza <br>
            <div style="text-align: right;">(0=No/1=Si)</div>
</td>
            <td style="width: 119px;"><select id="g" size="1" style="width: 100%;"></select></td>
          </tr>
          <tr>
            <td style="width: 349px;">04 - Intradosso - Esterno </td>
            <td style="width: 119px;"><input id="ie" value="" type="text"></td>
          </tr>
          <tr style="background-color: rgb(238, 238, 238);">
            <td style="width: 349px;">05 - --------------- - Interno
(compreso infisso)</td>
            <td style="width: 119px;"><input id="ii" value="" type="text"></td>
          </tr>
          <tr>
            <td style="width: 349px;">06 - Infisso - Spessore</td>
            <td style="width: 119px;"><input id="sf" value="" type="text"></td>
          </tr>
          <tr style="background-color: rgb(238, 238, 238);">
            <td style="width: 349px;">07 - --------- - Profondità
Incasso </td>
            <td style="width: 119px;"><input id="pif" value="" type="text"></td>
          </tr>
          <tr>
            <td style="width: 349px;">08 - Destra - Sguancio Interno
(infisso) </td>
            <td style="width: 119px;"><input id="dx_si" value="" type="text"></td>
          </tr>
          <tr style="background-color: rgb(238, 238, 238);">
            <td style="width: 349px;">09 - --------- - Sguancio Esterno
(filo parete) </td>
            <td style="width: 119px;"><input id="dx_se" value="" type="text"></td>
          </tr>
          <tr>
            <td style="width: 349px;">10 - Sinistra - Sguancio Interno
(infisso) </td>
            <td style="width: 119px;"><input id="sx_si" value="" type="text"></td>
          </tr>
          <tr style="background-color: rgb(238, 238, 238);">
            <td style="width: 349px;">11 - ----------- - Sguancio
Esterno
(filo parete) </td>
            <td style="width: 119px;"><input id="sx_se" value="" type="text"></td>
          </tr>
          <tr>
            <td style="width: 349px;">12 - Alto - Sguancio Interno
(infisso) </td>
            <td style="width: 119px;"><input id="top_si" value="" type="text"></td>
          </tr>
          <tr style="background-color: rgb(238, 238, 238);">
            <td style="width: 349px;">13 - ------ - Sguancio Esterno
(filo parete) </td>
            <td style="width: 119px;"><input id="top_se" value="" type="text"></td>
          </tr>
          <tr>
            <td style="width: 349px;">14 - Basso - Sguancio Interno
(infisso) </td>
            <td style="width: 119px;"><input id="bot_si" value="" type="text"></td>
          </tr>
          <tr style="background-color: rgb(238, 238, 238);">
            <td style="width: 349px;">15 - --------- - Sguancio Esterno
(filo parete) </td>
            <td style="width: 119px;"><input id="bot_se" value="" type="text"></td>
          </tr>
          <tr>
            <td style="width: 349px;">16 - Soglia - Sporgenza Esterna e
Laterale </td>
            <td style="width: 119px;"><input id="dav_spe" value="" type="text"></td>
          </tr>
          <tr style="background-color: rgb(238, 238, 238);">
            <td style="width: 349px;">17 - --------- - Sporgenza
Interna </td>
            <td style="width: 119px;"><input id="dav_spi" value="" type="text"></td>
          </tr>
          <tr>
            <td style="width: 349px;">18 - --------- - Spessore </td>
            <td style="width: 119px;"><input id="dav_th" value="" type="text"></td>
          </tr>
          <tr style="background-color: rgb(238, 238, 238);">
            <td style="width: 349px;">19 - --------- - Tipologia <br>
            <div style="text-align: right;">(0=Piana/1=Sovrapposta)</div>
</td>
            <td style="width: 119px;"><select id="t" size="1" style="width: 100%;"></select></td>
          </tr>
          <tr>
            <td style="width: 349px;">20 - Incasso Sotto Soglia -
Profondità </td>
            <td style="width: 119px;"><input id="dav_i" value="" type="text"></td>
          </tr>
          <tr style="background-color: rgb(238, 238, 238);">
            <td style="width: 349px;">21 - Rimuovi Veletta Pavimento <br>
            <div style="text-align: right;">(0=No/1=Si)</div>
</td>
            <td style="width: 119px;"><select id="r" size="1" style="width: 100%;"></select></td>
          </tr>
          <tr>
            <td style="width: 119px;" colspan="2">&nbsp;<br>
            </td>
          </tr>
          <tr>
            <td colspan="1" style="text-align: center; width: 349px;"><input value="Chiudi" onclick="window.location='skp:close@'" type="button"></td>
            <td style="vertical-align: top; text-align: center; width: 119px;"><input value="Applica" onclick="window.location='skp:submit@'" type="button"></td>
          </tr>
        </tbody>
      </table>
      </td>
      <td style="text-align: center;"><img src="Sguanci_img.jpg" alt="" style="padding: 3px; margin-top: 5px; margin-bottom: 3px; width: 376px; height: 606px;" align="middle"><br>
      </td>
    </tr>
  </tbody>
</table>

<script>
window.location="skp:populate@";
</script>
</body></html>

I cannot reproduce it, for me the html displays completely. It looks more like a rendering problem in your browser.

  • Have you tried different doctypes?
  • Have you tried UI::HtmlDialog, which uses a different rendering engine? Possibly the same problem does not occur in both at the same time.

You should also add a <meta charset="utf-8" /> in the head, so that the browser is forced to dispay characters from the charset in which you provided the string (utf-8), otherwise old-fashioned browsers (like IE) default to a local charset and may display à instead of à.

if you really are still using SU v8, there where a host of IE and Safari issues that required very specific ‘hacks’…

search for the ‘compatibility mode’ meta that was often needed…

john

Buonasera, il problema è che l’errore di visualizzazione non si verifica sempre,
ad esempio tre o quatto volte va bene e una no ( sia in modalità Create che in modalità Edit).
Allego il plugin per le verifiche. ringrazio anticipatamente per la collaborazione.
SOFTDEG_sguanci_v1.20.rbz (502.5 KB)

1 Like

your html isn’t properly encoded…

all the ¿ chars can break html, most editors have a zap gremlins function to fix them, or set it to use unix line endings…

john

Could it be that these are just DOS line endings (two character \r\n)? But I haven’t seen that an editor represents them as ¿. One could argue about what is the right way, but I personally find the more logical line ending style is \n (one thing one character). But DOS line endings do no real harm, and it should work as it is.

For me the dialog content renders in both WebDialog and HtmlDialog. I would be interested how it works for you when you use a UI::HtmlDialog?

And in many languages, molto bene!

Hello, I noticed that in slower PCs (i3) the problem occurs more, while in those faster (i7) occurs rarely, the strange thing is that the page seems to display correctly before becoming empty (this is what you can see it in very slow PCs)

Hi, Mr. tiziano.traini

I’d like to know if you have any video to show how you create stairs by using your sketchup extension “SOFTDEG_scale - Crea scale parametriche”. Thank you so much.

Hi,
I’ll send you a video soon.

Tiziano Traini

Hello

I apologize, but I can’t make a video on the SOFTDEG_Scale plugin, if you foresee which aspect of the clarifications you want, we can hear you via email

tiziano.traini at gmail.com

Hi Mr. jingze211

I attach a file with some achievable scales, by modifying them you will be able to see the parameters I have set.

Greetings Tiziano

scale.skp (2.26 MB)