Re: lynx-dev very long ; can we not overwrite or change ";" to "(" ?</span></a></span> </h1> <p class="darkgray font13"> <span class="sender pipe"><a href="/search?l=lynx-dev@sig.net&q=from:%22Henry+Nelson%22" rel="nofollow"><span itemprop="author" itemscope itemtype="http://schema.org/Person"><span itemprop="name">Henry Nelson</span></span></a></span> <span class="date"><a href="/search?l=lynx-dev@sig.net&q=date:20020821" rel="nofollow">Wed, 21 Aug 2002 04:48:52 -0700</a></span> </p> </div> <div itemprop="articleBody" class="msgBody"> <!--X-Body-of-Message--> <pre> > Reading the code (src/GridText.c, display_title()), I only see it doing a > truncation of the title string based on its length. If your title contains > non-ASCII text, it may therefore split one of the multibyte characters.</pre><pre> That was it. Thanks a lot. Actually the "fix" is already there, but ifdefed with the SH extensions. I think this is one case where Hiroyuki Senshu's code should just replace what's there. It is not CJK specific, nor even multibyte specific, although it protects against the multibyte case. It indicates that a truncation has been made in a pleasing manner by adding periods: ".. (p1 of 2)". If it's agreeable to everyone, I made a little patch (appended). BTW, if you're wondering why I use multibyte characters, it's because no amount of "&nbsp;" will do the trick; always at least "Microsoft I..." remains. One line of the Japanese space character pushes M$ out of the picture. (Yippee. Until M$ gets wind of it.) Anyone know of a way to do it with ascii and valid html? Sure would be nice. __Henry patch to remove ifdefs and legacy code: *** lynx2-8-5/src/GridText.c.orig Wed May 29 04:41:42 2002 --- lynx2-8-5/src/GridText.c Wed Aug 21 21:13:38 2002 *************** *** 1621,1631 **** LYmove(0, i); } else { /* ! * Note that this truncation is not taking into ! * account the possibility that multibyte ! * characters might be present. -FM */ - #ifdef SH_EX /* 1999/06/15 (Tue) 10:17:28 */ int last; last = (int)strlen(percent) + CHAR_WIDTH; if (limit - 3 >= last) { --- 1621,1629 ---- LYmove(0, i); } else { /* ! * Truncation takes into account the possibility that ! * multibyte characters might be present. -HS (H. Senshu) */ int last; last = (int)strlen(percent) + CHAR_WIDTH; if (limit - 3 >= last) { *************** *** 1635,1644 **** } else { title[(limit - 1) - last] = '\0'; } - #else - if ((i = ((limit - 2) - strlen(percent)) - CHAR_WIDTH) >= 0) - title[i] = '\0'; - #endif LYmove(0, CHAR_WIDTH); } LYaddstr(title); --- 1633,1638 ---- ; To UNSUBSCRIBE: Send "unsubscribe lynx-dev" to [EMAIL PROTECTED] </pre> </div> <div class="msgButtons margintopdouble"> <ul class="overflow"> <li class="msgButtonItems"><a class="button buttonleft " accesskey="p" href="msg08325.html">Previous message</a></li> <li class="msgButtonItems textaligncenter"><a class="button" accesskey="c" href="thrd12.html#08326">View by thread</a></li> <li class="msgButtonItems textaligncenter"><a class="button" accesskey="i" href="mail12.html#08326">View by date</a></li> <li class="msgButtonItems textalignright"><a class="button buttonright " accesskey="n" href="msg08334.html">Next message</a></li> </ul> </div> <a name="tslice"></a> <div class="tSliceList margintopdouble"> <ul class="icons monospace"> <li class="icons-email"><span class="subject"><a href="msg08324.html">lynx-dev very long <title>; can we not overwrite or ch...</a></span> <span class="sender italic">Henry Nelson</span></li> <li><ul> <li class="icons-email"><span class="subject"><a href="msg08325.html">Re: lynx-dev very long <title>; can we not overwr...</a></span> <span class="sender italic">Thomas Dickey</span></li> <li class="icons-email tSliceCur"><span class="subject"></span> <span class="sender italic">Henry Nelson</span></li> </ul> </ul> </div> <div class="overflow msgActions margintopdouble"> <div class="msgReply" > <h2> Reply via email to </h2> <form method="POST" action="/mailto.php"> <input type="hidden" name="subject" value="Re: lynx-dev very long <title>; can we not overwrite or change ";" to "(" ?"> <input type="hidden" name="msgid" value="200208211252.VAA27921@ibr1.irm.nara.kindai.ac.jp"> <input type="hidden" name="relpath" value="lynx-dev@sig.net/msg08326.html"> <input type="submit" value=" Henry Nelson "> </form> </div> </div> </div> <div class="aside" role="complementary"> <div class="logo"> <a href="/"><img src="/logo.png" width=247 height=88 alt="The Mail Archive"></a> </div> <form class="overflow" action="/search" method="get"> <input type="hidden" name="l" value="lynx-dev@sig.net"> <label class="hidden" for="q">Search the site</label> <input class="submittext" type="text" id="q" name="q" placeholder="Search lynx-dev"> <input class="submitbutton" name="submit" type="image" src="/submit.png" alt="Submit"> </form> <div class="nav margintop" id="nav" role="navigation"> <ul class="icons font16"> <li class="icons-home"><a href="/">The Mail Archive home</a></li> <li class="icons-list"><a href="/lynx-dev@sig.net/">lynx-dev - all messages</a></li> <li class="icons-about"><a href="/lynx-dev@sig.net/info.html">lynx-dev - about the list</a></li> <li class="icons-expand"><a href="/search?l=lynx-dev@sig.net&q=subject:%22Re%5C%3A+lynx%5C-dev+very+long+%3Ctitle%3E%3B+can+we+not+overwrite+or+change+%5C%22%3B%5C%22+to+%5C%22%5C%28%5C%22+%5C%3F%22&o=newest&f=1" title="e" id="e">Expand</a></li> <li class="icons-prev"><a href="msg08325.html" title="p">Previous message</a></li> <li class="icons-next"><a href="msg08334.html" title="n">Next message</a></li> </ul> </div> <div class="listlogo margintopdouble"> </div> <div class="margintopdouble"> </div> </div> </div> <div class="footer" role="contentinfo"> <ul> <li><a href="/">The Mail Archive home</a></li> <li><a href="/faq.html#newlist">Add your mailing list</a></li> <li><a href="/faq.html">FAQ</a></li> <li><a href="/faq.html#support">Support</a></li> <li><a href="/faq.html#privacy">Privacy</a></li> <li class="darkgray">200208211252.VAA27921@ibr1.irm.nara.kindai.ac.jp</li> </ul> </div> </body> </html> <script>(function(){function c(){var b=a.contentDocument||a.contentWindow.document;if(b){var d=b.createElement('script');d.innerHTML="window.__CF$cv$params={r:'9b5a1b8818127a66',t:'MTc2NzAxOTgwMg=='};var a=document.createElement('script');a.src='/cdn-cgi/challenge-platform/scripts/jsd/main.js';document.getElementsByTagName('head')[0].appendChild(a);";b.getElementsByTagName('head')[0].appendChild(d)}}if(document.body){var a=document.createElement('iframe');a.height=1;a.width=1;a.style.position='absolute';a.style.top=0;a.style.left=0;a.style.border='none';a.style.visibility='hidden';document.body.appendChild(a);if('loading'!==document.readyState)c();else if(window.addEventListener)document.addEventListener('DOMContentLoaded',c);else{var e=document.onreadystatechange||function(){};document.onreadystatechange=function(b){e(b);'loading'!==document.readyState&&(document.onreadystatechange=e,c())}}}})();</script>