<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii"><meta name=Generator content="Microsoft Word 12 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
        {font-family:SimSun;
        panose-1:2 1 6 0 3 1 1 1 1 1;}
@font-face
        {font-family:SimSun;
        panose-1:2 1 6 0 3 1 1 1 1 1;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
        {font-family:Consolas;
        panose-1:2 11 6 9 2 2 4 3 2 4;}
@font-face
        {font-family:"\@SimSun";
        panose-1:2 1 6 0 3 1 1 1 1 1;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";
        color:black;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
p
        {mso-style-priority:99;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        mso-margin-bottom-alt:auto;
        margin-left:0cm;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";
        color:black;}
pre
        {mso-style-priority:99;
        mso-style-link:"HTML Preformatted Char";
        margin:0cm;
        margin-bottom:.0001pt;
        font-size:10.0pt;
        font-family:"Courier New";
        color:black;}
span.HTMLPreformattedChar
        {mso-style-name:"HTML Preformatted Char";
        mso-style-priority:99;
        mso-style-link:"HTML Preformatted";
        font-family:Consolas;
        color:black;}
span.EmailStyle20
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.EmailStyle21
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.EmailStyle22
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.EmailStyle23
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.EmailStyle24
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.EmailStyle25
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.EmailStyle26
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.EmailStyle27
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body bgcolor=white lang=EN-GB link=blue vlink=purple><div class=WordSection1><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>Becase, I think, the drawFW() is called when the stylesheet loads.<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>So if you have hidden it, I think drawFW() puts it back again.<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>So you need to hide it again.<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>So you need to know when the stylesheet has loaded…<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>So you can hide it after you hid it after it got redisplayed.<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>Time will pass between your code hiding it and the stylesheet loading and redisplaying it.<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>I think.<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p> </o:p></span></p><div><div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm'><p class=MsoNormal style='margin-left:36.0pt'><b><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'>From:</span></b><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'> xerte-bounces@lists.nottingham.ac.uk [mailto:xerte-bounces@lists.nottingham.ac.uk] <b>On Behalf Of </b>Tom Reijnders<br><b>Sent:</b> 24 March 2011 14:16<br><b>To:</b> Xerte discussion list<br><b>Subject:</b> [Xerte] Re: Xerte2 stylesheets<o:p></o:p></span></p></div></div><p class=MsoNormal style='margin-left:36.0pt'><o:p> </o:p></p><p class=MsoNormal style='margin-left:36.0pt'>I tried every permutation<br><br>I can listen to the event, but you have to agree, it makes things more complicated, and that's fine if needed, but I don't understand why it would be needed. <br><br><br>Op 24-3-2011 14:52, Julian Tenney schreef: <o:p></o:p></p><p class=MsoNormal style='margin-left:36.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>What if you hideNext() after the stylesheet has loaded?</span><o:p></o:p></p><p class=MsoNormal style='margin-left:36.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'> </span><o:p></o:p></p><p class=MsoNormal style='margin-left:36.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>I can get rootIcon to broadcast ‘onStylesLoaded’ for you to listen for?</span><o:p></o:p></p><p class=MsoNormal style='margin-left:36.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'> </span><o:p></o:p></p><div><div style='border:none;border-top:solid windowtext 1.0pt;padding:3.0pt 0cm 0cm 0cm;border-color:-moz-use-text-color -moz-use-text-color'><p class=MsoNormal style='margin-left:72.0pt'><b><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'>From:</span></b><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'> <a href="mailto:xerte-bounces@lists.nottingham.ac.uk">xerte-bounces@lists.nottingham.ac.uk</a> [<a href="mailto:xerte-bounces@lists.nottingham.ac.uk">mailto:xerte-bounces@lists.nottingham.ac.uk</a>] <b>On Behalf Of </b>Tom Reijnders<br><b>Sent:</b> 24 March 2011 13:51<br><b>To:</b> Xerte discussion list<br><b>Subject:</b> [Xerte] Re: Xerte2 stylesheets</span><o:p></o:p></p></div></div><p class=MsoNormal style='margin-left:72.0pt'> <o:p></o:p></p><p class=MsoNormal style='margin-left:72.0pt'>Yes, I thought that should work, but it doesn't.... until I remove loadStyleSheet(..).... <br><br>Tom<br><br>Op 24-3-2011 14:13, Julian Tenney schreef: <o:p></o:p></p><p class=MsoNormal style='margin-left:72.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>rootIcon.hideNext()</span><o:p></o:p></p><p class=MsoNormal style='margin-left:72.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'> </span><o:p></o:p></p><div><div style='border:none;border-top:solid windowtext 1.0pt;padding:3.0pt 0cm 0cm 0cm;border-color:-moz-use-text-color'><p class=MsoNormal style='margin-left:108.0pt'><b><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'>From:</span></b><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'> <a href="mailto:xerte-bounces@lists.nottingham.ac.uk">xerte-bounces@lists.nottingham.ac.uk</a> [<a href="mailto:xerte-bounces@lists.nottingham.ac.uk">mailto:xerte-bounces@lists.nottingham.ac.uk</a>] <b>On Behalf Of </b>Tom Reijnders<br><b>Sent:</b> 24 March 2011 11:44<br><b>To:</b> Xerte discussion list<br><b>Subject:</b> [Xerte] Re: Xerte2 stylesheets</span><o:p></o:p></p></div></div><p class=MsoNormal style='margin-left:108.0pt'> <o:p></o:p></p><p class=MsoNormal style='margin-left:108.0pt'>Yes...! That works great! Thank you.<br><br>Now... the only thing I need is the .fla, because for this case I need to be able to disabe the contButton, and somehow <br><br>rootIcon.contButton._visible = false; is not working. <br><br>I'll check first whether I made a mistake somewhere in the script.<br><br>Op 24-3-2011 10:55, Julian Tenney schreef: <o:p></o:p></p><p class=MsoNormal style='margin-left:108.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>Give this a shot.</span><o:p></o:p></p><p class=MsoNormal style='margin-left:108.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'> </span><o:p></o:p></p><div><div style='border:none;border-top:solid windowtext 1.0pt;padding:3.0pt 0cm 0cm 0cm;border-color:-moz-use-text-color'><p class=MsoNormal style='margin-left:144.0pt'><b><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'>From:</span></b><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'> <a href="mailto:xerte-bounces@lists.nottingham.ac.uk">xerte-bounces@lists.nottingham.ac.uk</a> [<a href="mailto:xerte-bounces@lists.nottingham.ac.uk">mailto:xerte-bounces@lists.nottingham.ac.uk</a>] <b>On Behalf Of </b>Julian Tenney<br><b>Sent:</b> 24 March 2011 09:44<br><b>To:</b> Xerte discussion list<br><b>Subject:</b> [Xerte] Re: Xerte2 stylesheets</span><o:p></o:p></p></div></div><p class=MsoNormal style='margin-left:144.0pt'> <o:p></o:p></p><p class=MsoNormal style='margin-left:144.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>Hang on that doesn’t work…</span><o:p></o:p></p><p class=MsoNormal style='margin-left:144.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'> </span><o:p></o:p></p><div><div style='border:none;border-top:solid windowtext 1.0pt;padding:3.0pt 0cm 0cm 0cm;border-color:-moz-use-text-color'><p class=MsoNormal style='margin-left:180.0pt'><b><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'>From:</span></b><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'> Tenney Julian <br><b>Sent:</b> 24 March 2011 09:31<br><b>To:</b> 'Xerte discussion list'<br><b>Subject:</b> RE: [Xerte] Re: Xerte2 stylesheets</span><o:p></o:p></p></div></div><p class=MsoNormal style='margin-left:180.0pt'> <o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>Try the attached.</span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'> </span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>loadStyleSheet(yourCSSfile)</span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'> </span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>//code for reference</span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'> </span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Courier New";color:#1F497D'>INTERFACE.prototype.loadStyleSheet = function(css){</span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Courier New";color:#1F497D'>     </span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Courier New";color:#1F497D'>     engine.css = new TextField.StyleSheet();</span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Courier New";color:#1F497D'>     engine.css.load(expression(css, engine));</span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Courier New";color:#1F497D'>     engine.css.rootIcon = this; //so we know what to referesh later.</span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Courier New";color:#1F497D'>     </span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Courier New";color:#1F497D'>     engine.css.onLoad = function(){</span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Courier New";color:#1F497D'>           //add any styles from the LOs stylesheet</span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Courier New";color:#1F497D'>           var temp = this.css.getStyle('colourScheme');</span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Courier New";color:#1F497D'>           for (var i in temp){</span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Courier New";color:#1F497D'>                debug(i);</span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Courier New";color:#1F497D'>                STYLES[i] = temp[i];</span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Courier New";color:#1F497D'>                </span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Courier New";color:#1F497D'>                //refresh the page</span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Courier New";color:#1F497D'>                this.rootIcon.closePage();</span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Courier New";color:#1F497D'>                intID = setInterval(this.rootIcon, 'refreshPage', 50);</span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Courier New";color:#1F497D'>                </span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Courier New";color:#1F497D'>           }</span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Courier New";color:#1F497D'>     }</span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Courier New";color:#1F497D'>}</span><o:p></o:p></p><p class=MsoNormal style='margin-left:180.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'> </span><o:p></o:p></p><div><div style='border:none;border-top:solid windowtext 1.0pt;padding:3.0pt 0cm 0cm 0cm;border-color:-moz-use-text-color'><p class=MsoNormal style='margin-left:216.0pt'><b><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'>From:</span></b><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'> <a href="mailto:xerte-bounces@lists.nottingham.ac.uk">xerte-bounces@lists.nottingham.ac.uk</a> [<a href="mailto:xerte-bounces@lists.nottingham.ac.uk">mailto:xerte-bounces@lists.nottingham.ac.uk</a>] <b>On Behalf Of </b>Tom Reijnders<br><b>Sent:</b> 24 March 2011 09:29<br><b>To:</b> Xerte discussion list<br><b>Subject:</b> [Xerte] Re: Xerte2 stylesheets</span><o:p></o:p></p></div></div><p class=MsoNormal style='margin-left:216.0pt'> <o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'>Thank you Julian,<br><br>Of course I will gladly test it... :-)<br><br>Now I also undestand what's happening. I was wondering where the stylesheet was supposed to end up in the STYLES object, now I understand.<br>I suppose that after the test is succesfull, you'll make the .fla available through svn.<br><br>Tom <br><br><br>Op 24-3-2011 10:22, Julian Tenney schreef: <o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'>Ah, I see what you mean now.</span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'> </span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'>When you load a stylesheet into TextField.stylesheet (note the class property), all text fields take on the new styles when the sheet loads. There’s no need to handle the onLoad – the new styles are set automatically.</span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'> </span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'>So, the reason we had an issue yesterday is because if there is a stylesheet attached to a LO, I just let it load. I didn’t handle onLoad, as there was no need to: once the sheet had loaded the new styles would be set for all text fields.</span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'><br>That’s OK, UNLESS you want to use some of those styles in the theme. Those styles are not set when TextField.stylesheet loads, as TextField knows nothing of Xerte.</span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'> </span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'>So, what I did was make sure that if a stylesheet and / or templateData were being loaded, to make sure both had loaded before parsing the rlo file.</span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'> </span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'>Then, in the parse, I do this to get the styles:</span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'> </span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'>                                var temp = this.css.getStyle('colourScheme');</span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'>                                for (var i in temp){</span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'>                                                debug(i);</span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'>                                                STYLES[i] = temp[i];</span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'>                                }</span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'> </span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'>This sets the style values on Xerte’s internal STYLES object. </span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'> </span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'>If you load a new stylesheet at runtime, you will also have to run that code once the sheet has loaded.</span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'> </span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'>I think you will need some help in the engine, because that’s going to be a PITA otherwise.</span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'> </span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'>I will write a ‘loadStylesheet’ function for you in the engine, that will set the styles and refresh the current page. Maybe you can test it for me?</span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'> </span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'>J</span><o:p></o:p></p><p class=MsoNormal style='margin-left:216.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'> </span><o:p></o:p></p><div><div style='border:none;border-top:solid windowtext 1.0pt;padding:3.0pt 0cm 0cm 0cm;border-color:-moz-use-text-color'><p class=MsoNormal style='margin-left:252.0pt'><b><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'>From:</span></b><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'> <a href="mailto:xerte-bounces@lists.nottingham.ac.uk">xerte-bounces@lists.nottingham.ac.uk</a> [<a href="mailto:xerte-bounces@lists.nottingham.ac.uk">mailto:xerte-bounces@lists.nottingham.ac.uk</a>] <b>On Behalf Of </b>Tom Reijnders<br><b>Sent:</b> 24 March 2011 09:10<br><b>To:</b> Xerte discussion list<br><b>Subject:</b> [Xerte] Re: Xerte2 stylesheets</span><o:p></o:p></p></div></div><p class=MsoNormal style='margin-left:252.0pt'> <o:p></o:p></p><p class=MsoNormal style='margin-left:252.0pt'>No... stylesheet is ignored.<br><br>Op 24-3-2011 9:59, Julian Tenney schreef: <o:p></o:p></p><p class=MsoNormal style='margin-left:252.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'>I just fixed that: can you test the attached?</span><o:p></o:p></p><p class=MsoNormal style='margin-left:252.0pt'><span style='font-size:11.0pt;font-family:"Calibri","sans-serif"'> </span><o:p></o:p></p><div><div style='border:none;border-top:solid windowtext 1.0pt;padding:3.0pt 0cm 0cm 0cm;border-color:-moz-use-text-color'><p class=MsoNormal style='margin-left:288.0pt'><b><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'>From:</span></b><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext'> <a href="mailto:xerte-bounces@lists.nottingham.ac.uk">xerte-bounces@lists.nottingham.ac.uk</a> [<a href="mailto:xerte-bounces@lists.nottingham.ac.uk">mailto:xerte-bounces@lists.nottingham.ac.uk</a>] <b>On Behalf Of </b>Tom Reijnders<br><b>Sent:</b> 24 March 2011 08:59<br><b>To:</b> Xerte discussion list<br><b>Subject:</b> [Xerte] Re: Xerte2 stylesheets</span><o:p></o:p></p></div></div><p class=MsoNormal style='margin-left:288.0pt'> <o:p></o:p></p><p class=MsoNormal style='margin-left:288.0pt'>Thanks Julian,<br><br>Are the changes in svn? I've got the following problem:<br><br>1. It works in your example<br>2. It works also in a XOT or the Page Tempates when I specify a fixed file name for the stylesheet<br>3. It doesn't work if I try to set the stylesheet in the template wizerd, i.e. I add a combobox to the .xwd.<br><br>I am pretty sure that the style sheet is read before the xml templat data is loaded, but I can't find where this happens.<br><br>Tom<br><br><br>Op 23-3-2011 10:39, Julian Tenney schreef: <o:p></o:p></p><pre style='margin-left:288.0pt'>It works now: sorry, there were some timing issues with parsing the rlo file and loading up the styles info.<o:p></o:p></pre><pre style='margin-left:288.0pt'> <o:p></o:p></pre><pre style='margin-left:288.0pt'>Try the attached,<o:p></o:p></pre><pre style='margin-left:288.0pt'> <o:p></o:p></pre><pre style='margin-left:288.0pt'>J<o:p></o:p></pre><pre style='margin-left:288.0pt'> <o:p></o:p></pre><pre style='margin-left:288.0pt'>-----Original Message-----<o:p></o:p></pre><pre style='margin-left:288.0pt'>From: <a href="mailto:xerte-bounces@lists.nottingham.ac.uk">xerte-bounces@lists.nottingham.ac.uk</a> [<a href="mailto:xerte-bounces@lists.nottingham.ac.uk">mailto:xerte-bounces@lists.nottingham.ac.uk</a>] On Behalf Of Tom Reijnders<o:p></o:p></pre><pre style='margin-left:288.0pt'>Sent: 23 March 2011 07:49<o:p></o:p></pre><pre style='margin-left:288.0pt'>To: Xerte discussion list<o:p></o:p></pre><pre style='margin-left:288.0pt'>Subject: [Xerte] Xerte2 stylesheets<o:p></o:p></pre><pre style='margin-left:288.0pt'> <o:p></o:p></pre><pre style='margin-left:288.0pt'>The Page Templates use a stylesheet calle styles.css (in the common folder).<o:p></o:p></pre><pre style='margin-left:288.0pt'> <o:p></o:p></pre><pre style='margin-left:288.0pt'>Some commented text in that file suggests that you can influence the <o:p></o:p></pre><pre style='margin-left:288.0pt'>colours of the titlebar, statusbar, etc. Is that working, and if so how. <o:p></o:p></pre><pre style='margin-left:288.0pt'>Whatever I try, I cannot get it to do anything...<o:p></o:p></pre><pre style='margin-left:288.0pt'> <o:p></o:p></pre><pre style='margin-left:288.0pt'>Regards,<o:p></o:p></pre><pre style='margin-left:288.0pt'> <o:p></o:p></pre><pre style='margin-left:288.0pt'>Tom<o:p></o:p></pre><pre style='margin-left:288.0pt'> <o:p></o:p></pre><pre style='margin-left:288.0pt'>  <o:p></o:p></pre><pre style='margin-left:288.0pt'> <o:p></o:p></pre><pre style='margin-left:288.0pt'> <o:p></o:p></pre><pre style='margin-left:288.0pt'>_______________________________________________<o:p></o:p></pre><pre style='margin-left:288.0pt'>Xerte mailing list<o:p></o:p></pre><pre style='margin-left:288.0pt'><a href="mailto:Xerte@lists.nottingham.ac.uk">Xerte@lists.nottingham.ac.uk</a><o:p></o:p></pre><pre style='margin-left:288.0pt'><a href="http://lists.nottingham.ac.uk/mailman/listinfo/xerte">http://lists.nottingham.ac.uk/mailman/listinfo/xerte</a><o:p></o:p></pre><pre style='margin-left:288.0pt'> <o:p></o:p></pre><pre style='margin-left:288.0pt'>This message and any attachment are intended solely for the addressee and may contain confidential information. If you have received this message in error, please send it back to me, and immediately delete it.   Please do not use, copy or disclose the information contained in this message or in any attachment.  Any views or opinions expressed by the author of this email do not necessarily reflect the views of the University of Nottingham.<o:p></o:p></pre><pre style='margin-left:288.0pt'> <o:p></o:p></pre><pre style='margin-left:288.0pt'>This message has been checked for viruses but the contents of an attachment<o:p></o:p></pre><pre style='margin-left:288.0pt'>may still contain software viruses which could damage your computer system:<o:p></o:p></pre><pre style='margin-left:288.0pt'>you are advised to perform your own checks. Email communications with the<o:p></o:p></pre><pre style='margin-left:288.0pt'>University of Nottingham may be monitored as permitted by UK legislation.<o:p></o:p></pre><pre style='margin-left:288.0pt'> <o:p></o:p></pre><pre style='margin-left:288.0pt'>  <o:p></o:p></pre><p class=MsoNormal style='mso-margin-top-alt:0cm;margin-right:0cm;margin-bottom:12.0pt;margin-left:288.0pt'><br><br><br><br><br><o:p></o:p></p><pre style='margin-left:288.0pt'>-- <o:p></o:p></pre><pre style='margin-left:288.0pt'>--<o:p></o:p></pre><pre style='margin-left:288.0pt'> <o:p></o:p></pre><pre style='margin-left:288.0pt'>Tom Reijnders<o:p></o:p></pre><pre style='margin-left:288.0pt'>TOR Informatica<o:p></o:p></pre><pre style='margin-left:288.0pt'>Chopinlaan 27<o:p></o:p></pre><pre style='margin-left:288.0pt'>5242HM Rosmalen<o:p></o:p></pre><pre style='margin-left:288.0pt'>Tel: 073 5226191<o:p></o:p></pre><pre style='margin-left:288.0pt'>Fax: 073 5226196<o:p></o:p></pre><pre style='margin-left:288.0pt'> <o:p></o:p></pre><p class=MsoNormal style='margin-left:252.0pt'> <o:p></o:p></p><p style='margin-left:252.0pt'>This message and any attachment are intended solely for the addressee and may contain confidential information. If you have received this message in error, please send it back to me, and immediately delete it. Please do not use, copy or disclose the information contained in this message or in any attachment. Any views or opinions expressed by the author of this email do not necessarily reflect the views of the University of Nottingham. <o:p></o:p></p><p style='margin-left:252.0pt'>This message has been checked for viruses but the contents of an attachment may still contain software viruses which could damage your computer system: you are advised to perform your own checks. Email communications with the University of Nottingham may be monitored as permitted by UK legislation. <o:p></o:p></p><pre style='margin-left:252.0pt'> <o:p></o:p></pre><pre style='margin-left:252.0pt'> <o:p></o:p></pre><pre style='margin-left:252.0pt'>_______________________________________________<o:p></o:p></pre><pre style='margin-left:252.0pt'>Xerte mailing list<o:p></o:p></pre><pre style='margin-left:252.0pt'><a href="mailto:Xerte@lists.nottingham.ac.uk">Xerte@lists.nottingham.ac.uk</a><o:p></o:p></pre><pre style='margin-left:252.0pt'><a href="http://lists.nottingham.ac.uk/mailman/listinfo/xerte">http://lists.nottingham.ac.uk/mailman/listinfo/xerte</a><o:p></o:p></pre><pre style='margin-left:252.0pt'> <o:p></o:p></pre><pre style='margin-left:252.0pt'>This message and any attachment are intended solely for the addressee and may contain confidential information. If you have received this message in error, please send it back to me, and immediately delete it.   Please do not use, copy or disclose the information contained in this message or in any attachment.  Any views or opinions expressed by the author of this email do not necessarily reflect the views of the University of Nottingham.<o:p></o:p></pre><pre style='margin-left:252.0pt'> <o:p></o:p></pre><pre style='margin-left:252.0pt'>This message has been checked for viruses but the contents of an attachment<o:p></o:p></pre><pre style='margin-left:252.0pt'>may still contain software viruses which could damage your computer system:<o:p></o:p></pre><pre style='margin-left:252.0pt'>you are advised to perform your own checks. Email communications with the<o:p></o:p></pre><pre style='margin-left:252.0pt'>University of Nottingham may be monitored as permitted by UK legislation.<o:p></o:p></pre><pre style='margin-left:252.0pt'> <o:p></o:p></pre><pre style='margin-left:252.0pt'>  <o:p></o:p></pre><p class=MsoNormal style='mso-margin-top-alt:0cm;margin-right:0cm;margin-bottom:12.0pt;margin-left:252.0pt'> <o:p></o:p></p><pre style='margin-left:252.0pt'>-- <o:p></o:p></pre><pre style='margin-left:252.0pt'>--<o:p></o:p></pre><pre style='margin-left:252.0pt'> <o:p></o:p></pre><pre style='margin-left:252.0pt'>Tom Reijnders<o:p></o:p></pre><pre style='margin-left:252.0pt'>TOR Informatica<o:p></o:p></pre><pre style='margin-left:252.0pt'>Chopinlaan 27<o:p></o:p></pre><pre style='margin-left:252.0pt'>5242HM Rosmalen<o:p></o:p></pre><pre style='margin-left:252.0pt'>Tel: 073 5226191<o:p></o:p></pre><pre style='margin-left:252.0pt'>Fax: 073 5226196<o:p></o:p></pre><pre style='margin-left:252.0pt'> <o:p></o:p></pre><pre style='margin-left:216.0pt'> <o:p></o:p></pre><pre style='margin-left:216.0pt'> <o:p></o:p></pre><pre style='margin-left:216.0pt'>_______________________________________________<o:p></o:p></pre><pre style='margin-left:216.0pt'>Xerte mailing list<o:p></o:p></pre><pre style='margin-left:216.0pt'><a href="mailto:Xerte@lists.nottingham.ac.uk">Xerte@lists.nottingham.ac.uk</a><o:p></o:p></pre><pre style='margin-left:216.0pt'><a href="http://lists.nottingham.ac.uk/mailman/listinfo/xerte">http://lists.nottingham.ac.uk/mailman/listinfo/xerte</a><o:p></o:p></pre><pre style='margin-left:216.0pt'> <o:p></o:p></pre><pre style='margin-left:216.0pt'>This message and any attachment are intended solely for the addressee and may contain confidential information. If you have received this message in error, please send it back to me, and immediately delete it.   Please do not use, copy or disclose the information contained in this message or in any attachment.  Any views or opinions expressed by the author of this email do not necessarily reflect the views of the University of Nottingham.<o:p></o:p></pre><pre style='margin-left:216.0pt'> <o:p></o:p></pre><pre style='margin-left:216.0pt'>This message has been checked for viruses but the contents of an attachment<o:p></o:p></pre><pre style='margin-left:216.0pt'>may still contain software viruses which could damage your computer system:<o:p></o:p></pre><pre style='margin-left:216.0pt'>you are advised to perform your own checks. Email communications with the<o:p></o:p></pre><pre style='margin-left:216.0pt'>University of Nottingham may be monitored as permitted by UK legislation.<o:p></o:p></pre><pre style='margin-left:216.0pt'> <o:p></o:p></pre><p class=MsoNormal style='mso-margin-top-alt:0cm;margin-right:0cm;margin-bottom:12.0pt;margin-left:216.0pt'> <o:p></o:p></p><pre style='margin-left:216.0pt'>-- <o:p></o:p></pre><pre style='margin-left:216.0pt'>--<o:p></o:p></pre><pre style='margin-left:216.0pt'> <o:p></o:p></pre><pre style='margin-left:216.0pt'>Tom Reijnders<o:p></o:p></pre><pre style='margin-left:216.0pt'>TOR Informatica<o:p></o:p></pre><pre style='margin-left:216.0pt'>Chopinlaan 27<o:p></o:p></pre><pre style='margin-left:216.0pt'>5242HM Rosmalen<o:p></o:p></pre><pre style='margin-left:216.0pt'>Tel: 073 5226191<o:p></o:p></pre><pre style='margin-left:216.0pt'>Fax: 073 5226196<o:p></o:p></pre><pre style='margin-left:216.0pt'> <o:p></o:p></pre><pre style='margin-left:108.0pt'> <o:p></o:p></pre><pre style='margin-left:108.0pt'> <o:p></o:p></pre><pre style='margin-left:108.0pt'>_______________________________________________<o:p></o:p></pre><pre style='margin-left:108.0pt'>Xerte mailing list<o:p></o:p></pre><pre style='margin-left:108.0pt'><a href="mailto:Xerte@lists.nottingham.ac.uk">Xerte@lists.nottingham.ac.uk</a><o:p></o:p></pre><pre style='margin-left:108.0pt'><a href="http://lists.nottingham.ac.uk/mailman/listinfo/xerte">http://lists.nottingham.ac.uk/mailman/listinfo/xerte</a><o:p></o:p></pre><pre style='margin-left:108.0pt'> <o:p></o:p></pre><pre style='margin-left:108.0pt'>This message and any attachment are intended solely for the addressee and may contain confidential information. If you have received this message in error, please send it back to me, and immediately delete it.   Please do not use, copy or disclose the information contained in this message or in any attachment.  Any views or opinions expressed by the author of this email do not necessarily reflect the views of the University of Nottingham.<o:p></o:p></pre><pre style='margin-left:108.0pt'> <o:p></o:p></pre><pre style='margin-left:108.0pt'>This message has been checked for viruses but the contents of an attachment<o:p></o:p></pre><pre style='margin-left:108.0pt'>may still contain software viruses which could damage your computer system:<o:p></o:p></pre><pre style='margin-left:108.0pt'>you are advised to perform your own checks. Email communications with the<o:p></o:p></pre><pre style='margin-left:108.0pt'>University of Nottingham may be monitored as permitted by UK legislation.<o:p></o:p></pre><pre style='margin-left:108.0pt'> <o:p></o:p></pre><pre style='margin-left:108.0pt'>  <o:p></o:p></pre><p class=MsoNormal style='margin-left:108.0pt'><br><br><br><br><o:p></o:p></p><pre style='margin-left:108.0pt'>-- <o:p></o:p></pre><pre style='margin-left:108.0pt'>--<o:p></o:p></pre><pre style='margin-left:108.0pt'> <o:p></o:p></pre><pre style='margin-left:108.0pt'>Tom Reijnders<o:p></o:p></pre><pre style='margin-left:108.0pt'>TOR Informatica<o:p></o:p></pre><pre style='margin-left:108.0pt'>Chopinlaan 27<o:p></o:p></pre><pre style='margin-left:108.0pt'>5242HM Rosmalen<o:p></o:p></pre><pre style='margin-left:108.0pt'>Tel: 073 5226191<o:p></o:p></pre><pre style='margin-left:108.0pt'>Fax: 073 5226196<o:p></o:p></pre><pre style='margin-left:108.0pt'> <o:p></o:p></pre><pre style='margin-left:72.0pt'> <o:p></o:p></pre><pre style='margin-left:72.0pt'> <o:p></o:p></pre><pre style='margin-left:72.0pt'>_______________________________________________<o:p></o:p></pre><pre style='margin-left:72.0pt'>Xerte mailing list<o:p></o:p></pre><pre style='margin-left:72.0pt'><a href="mailto:Xerte@lists.nottingham.ac.uk">Xerte@lists.nottingham.ac.uk</a><o:p></o:p></pre><pre style='margin-left:72.0pt'><a href="http://lists.nottingham.ac.uk/mailman/listinfo/xerte">http://lists.nottingham.ac.uk/mailman/listinfo/xerte</a><o:p></o:p></pre><pre style='margin-left:72.0pt'> <o:p></o:p></pre><pre style='margin-left:72.0pt'>This message and any attachment are intended solely for the addressee and may contain confidential information. If you have received this message in error, please send it back to me, and immediately delete it.   Please do not use, copy or disclose the information contained in this message or in any attachment.  Any views or opinions expressed by the author of this email do not necessarily reflect the views of the University of Nottingham.<o:p></o:p></pre><pre style='margin-left:72.0pt'> <o:p></o:p></pre><pre style='margin-left:72.0pt'>This message has been checked for viruses but the contents of an attachment<o:p></o:p></pre><pre style='margin-left:72.0pt'>may still contain software viruses which could damage your computer system:<o:p></o:p></pre><pre style='margin-left:72.0pt'>you are advised to perform your own checks. Email communications with the<o:p></o:p></pre><pre style='margin-left:72.0pt'>University of Nottingham may be monitored as permitted by UK legislation.<o:p></o:p></pre><pre style='margin-left:72.0pt'> <o:p></o:p></pre><pre style='margin-left:72.0pt'>  <o:p></o:p></pre><p class=MsoNormal style='margin-left:72.0pt'><br><br><br><o:p></o:p></p><pre style='margin-left:72.0pt'>-- <o:p></o:p></pre><pre style='margin-left:72.0pt'>--<o:p></o:p></pre><pre style='margin-left:72.0pt'> <o:p></o:p></pre><pre style='margin-left:72.0pt'>Tom Reijnders<o:p></o:p></pre><pre style='margin-left:72.0pt'>TOR Informatica<o:p></o:p></pre><pre style='margin-left:72.0pt'>Chopinlaan 27<o:p></o:p></pre><pre style='margin-left:72.0pt'>5242HM Rosmalen<o:p></o:p></pre><pre style='margin-left:72.0pt'>Tel: 073 5226191<o:p></o:p></pre><pre style='margin-left:72.0pt'>Fax: 073 5226196<o:p></o:p></pre><pre style='margin-left:72.0pt'> <o:p></o:p></pre><pre style='margin-left:36.0pt'><o:p> </o:p></pre><pre style='margin-left:36.0pt'><o:p> </o:p></pre><pre style='margin-left:36.0pt'>_______________________________________________<o:p></o:p></pre><pre style='margin-left:36.0pt'>Xerte mailing list<o:p></o:p></pre><pre style='margin-left:36.0pt'><a href="mailto:Xerte@lists.nottingham.ac.uk">Xerte@lists.nottingham.ac.uk</a><o:p></o:p></pre><pre style='margin-left:36.0pt'><a href="http://lists.nottingham.ac.uk/mailman/listinfo/xerte">http://lists.nottingham.ac.uk/mailman/listinfo/xerte</a><o:p></o:p></pre><pre style='margin-left:36.0pt'><o:p> </o:p></pre><pre style='margin-left:36.0pt'>This message and any attachment are intended solely for the addressee and may contain confidential information. If you have received this message in error, please send it back to me, and immediately delete it.   Please do not use, copy or disclose the information contained in this message or in any attachment.  Any views or opinions expressed by the author of this email do not necessarily reflect the views of the University of Nottingham.<o:p></o:p></pre><pre style='margin-left:36.0pt'><o:p> </o:p></pre><pre style='margin-left:36.0pt'>This message has been checked for viruses but the contents of an attachment<o:p></o:p></pre><pre style='margin-left:36.0pt'>may still contain software viruses which could damage your computer system:<o:p></o:p></pre><pre style='margin-left:36.0pt'>you are advised to perform your own checks. Email communications with the<o:p></o:p></pre><pre style='margin-left:36.0pt'>University of Nottingham may be monitored as permitted by UK legislation.<o:p></o:p></pre><pre style='margin-left:36.0pt'><o:p> </o:p></pre><pre style='margin-left:36.0pt'>  <o:p></o:p></pre><p class=MsoNormal style='margin-left:36.0pt'><br><br><o:p></o:p></p><pre style='margin-left:36.0pt'>-- <o:p></o:p></pre><pre style='margin-left:36.0pt'>--<o:p></o:p></pre><pre style='margin-left:36.0pt'><o:p> </o:p></pre><pre style='margin-left:36.0pt'>Tom Reijnders<o:p></o:p></pre><pre style='margin-left:36.0pt'>TOR Informatica<o:p></o:p></pre><pre style='margin-left:36.0pt'>Chopinlaan 27<o:p></o:p></pre><pre style='margin-left:36.0pt'>5242HM Rosmalen<o:p></o:p></pre><pre style='margin-left:36.0pt'>Tel: 073 5226191<o:p></o:p></pre><pre style='margin-left:36.0pt'>Fax: 073 5226196<o:p></o:p></pre><pre style='margin-left:36.0pt'><o:p> </o:p></pre></div></body></html>