> From: Sherlock, Ric
> ... 
> On Firefox 3.5.5 the text formatting for the session log is broken by
> an unclosed <font> tag in the Welcome preamble (welcome_jfe_). IE8
> displays it OK. It causes displays a using the same font and colour as
> the preamble. After a jclear'' it the session log displays OK though.
> 
> The <font> tag gets used quite a bit as a container. It has been
> deprecated for a number of years now. I'd suggest replacing it with
> something else - perhaps <span class="myclass">.  Along the same lines
> is there a reason for manually formatting the various headings in
> welcome_jde_ rather than just using <h1> <h2> etc?
> 
> Is it possible to use something more like the following instead?
> 
> welcome=: 0 : 0
> <h1>J http server welcomes you!</h1>
> <p class="txt">Enter J sentences (&uarr;&darr; recall).<br>
> Recall &darr; has system sentences.<br>
> Avoid browser back/refresh/history.<br>
> Use browser tabs.<br>
> Bookmark this page.</p>
> 
> <h3>Script:</h3>
> <p>&nbsp;&nbsp;&nbsp;&darr;&crarr; runs <span
> class="fm">jpage'jopn'</span><br>
> &nbsp;&nbsp;&nbsp;press <span class="btn">ijs</span> to open new ijs
> form<br>
> &nbsp;&nbsp;&nbsp;edit, press <span class="btn">run</span>, and press
> <span class="btn">ijx</span></p>
> 
> <h3>Viewmat:</h3>
> <p class="fm">
> &nbsp;&nbsp;&nbsp;jvm ?20 20$2<br>
> &nbsp;&nbsp;&nbsp;jvm */~ i:9
> </p>
> 
> <h3>Plot:</h3>
> <p class="fm">
> &nbsp;&nbsp;&nbsp;'title growth' jpdf 2^i.10<br>
> &nbsp;&nbsp;&nbsp;<span class="prose">&darr; &crarr; runs</span>
> jpage'jopn'<br>
> &nbsp;&nbsp;&nbsp;<span class="prose">press <span
> class="btn">open</span> for</span> <span
> class="file">~temp\plot.pdf</span>
> </p>
> 
> <h3>Utils:</h3>
> <p class="fm">
> &nbsp;&nbsp;&nbsp;jclear''&nbsp;&nbsp;&nbsp;NB. clear LOG<br>
> &nbsp;&nbsp;&nbsp;jbd y&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;NB.
> boxdraw<br>
> &nbsp;&nbsp;&nbsp;jbd 0&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;NB. +|-<br>
> &nbsp;&nbsp;&nbsp;jhtml y&nbsp;&nbsp;&nbsp;&nbsp;NB. html output<br>
> &nbsp;&nbsp;&nbsp;jhtml'&lt;font style="font-
> size:32px;";&gt;A&lt;/font&gt;'<br>
> &nbsp;&nbsp;&nbsp;jfe_jfe_ y&nbsp;NB. toggle console/browser
> </p>
> <a href="http://www.jsoftware.com";>www.jsoftware.com</a>
> &nbsp;&nbsp;&nbsp;
> <a href="http://www.jsoftware.com/help";>www.jsoftware.com/help</a>
> )
> 
> In conjunction with the changes needed to make the style statement in
> the head like this, everything becomes more flexible.
> 
> <style type="text/css">
>  body, .prose {font-family:sans-serif; font-size:13px; color:#008080;}
>  .fm, .er, .log, .sys, .file, input {font-family:"courier
> new","courier","monospace"; font-size:12px; color:black;}
>  *.btn  {background:lightblue;font-weight:bold;}
>  *.fm   {color:black;}
>  *.er   {color:red;}
>  *.log  {color:blue;}
>  *.sys  {color:purple;}
>  *.file {color:green;}
>  input {width:100%;}
> </style>
> 
Editing the following verbs in ~system/utils/extra/jhserver.ijs will give the 
above style statement (watch wrap around).

hfont=: 3 : 0
t=.  ' body, .prose {font-family:sans-serif; font-size:13px; color:#008080;}',LF
t=.t,' .fm, .er, .log, .sys, .file, input {font-family:',PC_FONTFAMILY,'; 
font-size:',PC_FONTSIZE,'; color:',PC_FONT_COLOR,'}',LF
)

NB. je sentence - jijx mtyo class fonts
hfontclass=: 3 : 0
t=.   ' *.btn  {background:lightblue;font-weight:bold;}',LF                     
                        
t=. t,' *.fm   {color:',PC_FM_COLOR,  ';}',LF
t=. t,' *.er   {color:',PC_ER_COLOR,  ';}',LF
t=. t,' *.log  {color:',PC_LOG_COLOR, ';}',LF
t=. t,' *.sys  {color:',PC_SYS_COLOR, ';}',LF
t=. t,' *.file {color:',PC_FILE_COLOR,';}',LF
)

----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to