1 <?xml version="1.0" encoding="iso-8859-1"?>
2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
3 "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
4 <html xmlns="http://www.w3.org/1999/xhtml">
6 <title>News and Notes about nXhtml</title>
7 <link href="wd/grapes/nxhtml-grapes.css" rel="StyleSheet" type="text/css" />
14 <a href="nxhtml.html">To nXhtml main page</a>
17 <h1>News and Notes about nXhtml</h1>
21 <dt id="hadron-bugs" style="margin-top:1em;">Thanks for testing!</dt>
24 I want to thanks the testers, especially Hadron Quark
25 and Eric Lilja, for helping me by testing and pointing
26 out bugs and weaknesses, most related to editing of PHP.
29 It is quite a big job trying to get rid of smaller annoying bugs and bigger ones.
30 In my mailbox folder for nXhtml I have more than 500 old messages currently.
34 <dt id="state-of-the-art" style="margin-top:1em;
35 background-color: #00fa9a;
36 background-color: #20b2aa;
38 ">The State of the Art</dt>
39 <dd style="background-color: #54ff9f; padding: 0.5em">
41 I have more and more come to realize that there are two
42 main parts of nXhtml which are in quite different
43 degrees of maturity. The reason for the difference is
44 mainly that one of them, <strong>mumamo-mode</strong>, requires
45 very tight integration with Emacs in a way that
46 currently is not completely possible. Some things must
47 be changed in Emacs for this. There are also things to
48 discover in the interactions with other minor modes for
52 That said I still think mumamo-mode is mature enough for
53 serious use (though it sometimes conflicts with some other modules).
56 The other part, <strong>nxhtml-mode</strong>, is more mature,
57 since it stands more by itself and since it builds on
58 the very stable nxml-mode. I would not say nxhtml-mode
59 is finished, but it is stable and useful.
63 <dt id="magic-problems" style="margin-top:1em;">Magic major mode selection</dt>
66 Sometimes the major mode that Emacs opens a file in is
67 not what you expect. This can happen with files like PHP
68 files. The reason might be that magic-mode-alist have
69 choosen a mode based on the content of the file. The way
70 this is done does not take files with mixes a mix of for
71 example XHTML and PHP into account.
74 You may try setting magic-mode-alist to nil if this is a
79 This is now no longer necessary since the introduction
80 of magic-fallback-mode-alist in CVS Emacs on 2007-05-16.
81 (If you have an Emacs newer than that, of course.)
86 <dt id="underline-bug" style="margin-top:1em;">Long Red Underlines</dt>
89 Because of a bug in Emacs 22.1 you can sometimes (at the
90 end of a line) get long red lines instead of just a
91 single underlined character. Many users (me included)
92 find this quite a bit disturbing. I have therefore added
93 a command to quickly hide/show the underlines. This is
97 This is particular useful for example in the case where
98 you edit a PHP file and are bound to get a lot of XHTML
103 <dt id="php-attribute-values" style="margin-top:1em;">Attribute values computed by PHP</dt>
106 If you want to have attribute values computed by PHP
107 here is a way how to structure that to avoid breaking
108 completion and validation in the XHTML part unnessecary:
110 <p style="margin-left:2em">
111 <img src="images/linux.png" title="<?php foo("bar");?>"/>
114 Unfortunately that still breaks XHTML validation since
115 < is not allowed in strings. In the long run I
116 believe the XML validator has to be broken up so that it
117 avoids parsing the string here (in PHP files).
120 For now I have implemented a workaround.
121 If you are using constructs like those above then turn on <em>nxhtml-strval-mode</em>.
122 This will temporarily replace the above with
124 <p style="margin-left:2em">
125 <img src="images/linux.png" title="«?php foo("bar");?»"/>
128 However on the screen you will still see the original
129 string and when writing to file the correct characters
134 <dt id="pi-note" style="margin-top:1em;">A note for PHP and its cousins</dt>
137 The rules for a process instruction in XML, like <?php
138 ... ?> says that the text can contain any text except
139 <em>?></em>. So if you want to output that string
140 from PHP then break it up so it does not look as ?> in
144 It might be good to break up the beginning part of the
145 process instructions too. And please note that to use
146 XHTML validation or completion you should avoid using
147 < in strings, since it is not allowed there.
151 <dt id="pi-note" style="margin-top:1em;">Perl Mode slow with Mumamo Mode</dt>
154 Perl mode used with MuMaMo mode sometimes makes the
155 fontification slow for big files. I do not know the
156 reason, but I am trying to find a solution for this. If
157 you encounter this problem, just turn off mumamo-mode in
162 <dt id="tab-width-problems" style="margin-top:1em;">Tab width</dt>
165 Do you have <em>tab-width</em> to something different than 8
166 (the default)? Then please change this to 8. I have got
167 reports of problem with indentation when it is not 8.
171 <dt id="mmm-compat" style="margin-top:1em;">Why the chunks are not compatible with mmm</dt>
174 Some people have asked why the way to specify chunks in
175 mumamo-mode is not compatible with the old mmm-mode. The
176 answer is that I was not sure that the way used in
177 mmm-mode for specifying the chunks was flexible enough.
180 And I am sure that even the way used in mumamo-mode is
181 not good enough for all cases, but I let it be the way
182 it is until I have a better understanding of the
183 problem. Suggestions and comments are welcome!
189 <h1>nXhtml Changes</h1>
196 Corrected autostart for nXhtml when not used together with EmacsW32.
204 Improved display of XML path.
207 Discontinued xmple-mode.
210 New major modes nxhtml-part-mode/nxml-part-mode replaces
211 minor mode xmlpe-mode. (While moving the code to
212 nxhtml-part.el I also fixed a bug in Xmple minor mode that
213 made Emacs take 99% of the CPU.)
221 Fixed some calls to perl which prevented uploading of
222 a site of you did not have perl in the same location
226 Glued together things so that editing PHP files works
227 as I intended. (This means that Emacs switches between
228 php-mode and nxhtml-part-mode automatically when
229 moving point. And that you can use completion.)
232 Starting working on the documentation for nXhtml.
233 New layout to the documentation files.
234 Examples with images.
242 Fixes to make the switching between php and xhtml
243 style editing work better.
251 Better error handling when switching to editing
252 embedded JavaScript and CSS.
255 Removed PHP spec from embedded switching since they
256 interfered with the automatic switching between php
260 Gives an error message if web host is not defined in
261 site when trying to use View Uploaded File and
265 Gives a ready message when finished uploading a single
269 When using Mode Switching at <? ... ?> mode
270 switching could occur in wrong buffer. Fixed together
271 with some other buffer problems.
279 Add http://www.w3.org/ to the help sites for CSS.
285 Added a menu entry for bug reporting.
288 Renamed menu bar entry from XHTML to nXhtml for clarity.
289 (But nXml menu bar entry is still called XML.)
292 Added work around for globalized minor modes in the
293 cases of MLinks, XML Path and mode switching at <? ... ?>.
301 Added workaround for the problem with the first
302 keyboard key after automatically switching of mode at
311 Added support for multiple major modes with mumamo.el.
314 More conventient handling of links. They can now be
315 opened in the same window, 'other window' or in a new
324 Schema was not setup after starting new page so
325 completion did not work. Fixed.
328 Added http://xhtml.com/ to help sites for XHTML.
331 Added the concept of <em>XML validation headers</em>.
332 These are just text parsed by the nXml validation
333 parser to get a start state before starting parsing a
334 buffer. This allows the use of the nXml completion in
335 buffers where there are no XML header. Such a header
336 is often lacking for example in PHP code since the
337 XHTML header is often generated dynamically.
340 Because of the change above <em>nxhtml-part-mode</em>
341 is no longer needed and is therefore declared
345 Corrected a bug in mlinks.el that prevented opening an
346 HTML link in a other window or a new frame.
349 Added support for JSP, eRuby and some support for perl
358 Mumamo was not found when nXhtml was installed with
359 just the zip file. Corrected. (nXhtml is also
360 installed when you install EmacsW32.)
363 Enhancement to mumamo error handling when a bad mode
364 specifier for an embedded mode is found.
367 Introduced a bug for empty XHTML documents in
371 Corrected a bug for chunks 1 character long.
374 There is what I consider is a bug in Emacs 22.1 in the
375 handling of global minor mode that are not distributed
376 with Emacs. If they are turned on by customization,
377 but loaded after Emacs have loaded the customizations
378 (usually in .emacs) then they are not turned on
379 correctly. Added work-around for this.
382 <em>Extra XHTML Validation Header</em>:
385 <em>Extra XHTML Validation Header</em> state was not saved when moving between chunks. Fixed.
388 Tried to make the concept of <em>Extra XHTML Validation Header</em>
389 more clear. Added this visually to the buffer.
392 <em>Extra XHTML Validation Headers</em> can now be turned on
393 automatically based on file name.
398 <em>nXhtml menu:</em>
401 Reorganized the nXhtml menu.
404 Added <em>customization</em> groups for help libraries to nXhtml.
407 Added an entry for customization of nXhtml to the menus.
410 Added <em>Tidy</em> to the menus again.
415 Corrected bug in <em>XML Path</em> (nxml-where) for single tags.
416 Other small fixes to nxhtml-where.
419 Documentation enhancements.
420 Added <em>The Quick Guide</em>.
428 Fixed a serious bug in the cooperation between nxhtml-mode and mumamo-mode.
431 Turn on mumamo-mode by file name (mumamo-global-mode).
434 Extra XHTML Validation Header:
437 The Extra XHTML Validation Header state were not saved when changing major mode in MuMaMo. Corrected.
440 Added more alternatives to the Extra XHTML Validation Header list.
441 This should make it easier to use completion with for example PHP.
444 Added default value for the Extra XHTML Validation Header.
447 Tried to make the use of Extra XHTML Validation Header more automatic and therefore useful.
448 Also tried to make it play better with setting schema file.
449 (There is no need normally to set schema file by hand.)
452 To turn this on by default customize nxhtml-global-validation-header-mode.
457 Possible to hide validation warnings without turning
458 on validation (which would make completion in the
459 XHTML part impossible).
462 Some fixes to php-mode:
464 <li>Using the character # for comments now works for most cases.</li>
465 <li>Now uses the fontification faces in a more standard way which calms down the look.</li>
466 <li>Initialization bug fixes.</li>
467 <li>Renamed php-mode-user-hook to php-mode-hook to follow standard.</li>
474 Various corrections to indentation in mumamo.
477 Added the possibility to use TAB to indent regions
478 (indent-region-mode).
481 Warn about bad indentation in mixed PHP/HTML code
482 when using php-mode only.
487 Fontification now fontifies all text first in main
488 major mode and thereafter applies submodes. (This
489 avoids some problems with around a submode chunk.)
492 Reorganized the nXhtml menu:
495 There is now a minor mode for the nXhtml
496 menu. This makes it possible to easier use common
497 features when in buffers not in nxhtml-mode.
500 The nXhtml menu does not disappear when moving
501 into a chunk where the major mode is not
502 nxhtml-mode. The changes also makes it easy to
503 access uploading functions functions etc from
504 other modes than nxhtml-mode since the
505 <em>nXhtml</em> may also be shown in them.
508 The nXhtml menu can be turned on globally by default.
509 Customize nxhtml-menu-mode for that.
519 Reached version number 1.00 - which you maybe believe
520 means the bugs should be gone? Sorry, it is just that
521 I ran out of version numbers ;-) However it looks like
522 much fewer bugs at least.
525 Fixed problems mostly related to global turn on of different features in nXhtml.
528 Small fixes to indentation.
531 nxhtml-mode could get confused by php tags.
534 nxhtml-mode did not indent <!DOCTYPE in a sensible way.
537 Electric keys now works in embedded php when using mumamo-mode.
542 Tidy was very misbehaving since the output buffer was
543 not erased between different files. But I have got no
544 bug reports on this ;-)
547 Fixed a bug in validation that should up when using muamo-mode.
550 Fixed bug in <script ...> and <style ...> chunk dividing.
553 Added support for OpenLaszlo.
556 Corrections to mlinks-mode (visible mostly as links in
560 Links disappeared when a new file was
564 Links were not correctly updated at changes in the
565 buffer when mumamo-mode was used. Fixed.
570 The welcome message for nXhtml could be shown too
571 early sometimes when loading, before nXhtml actually
572 knew if it should be shown or not. Tried to fix it.
580 Reported wrong version number for nXhtml in the menus. Fixed.
583 <em>If you use the zip file to install nXhtml please
584 notice that it has now a top level nxml.</em> Sorry for not
585 having zipped it like that before!
588 The url links in <em>Welcome to nXhtml</em> was a bit
589 incorrect and did not work on all OS:es. Fixed.
592 Added customization of popup completion to the 'nxhtml
593 customization group so they are easier to find.
599 Struggled a bit with the load sequences of the elisp
600 libraries used by nXhtml when using MuMaMo.
603 Tried to get the global turn on of mumam-mode to work
607 The screen was blinking when changing overlays after
608 changes in the buffer. Tried to fix this.
611 Minor fixes do syntax highlighting, like taking care of single ':s.
614 Fixes to the support for JSP and eRuby.
617 Made the support for perl here documents a bit better.
618 Large perl documents are however still quite slow when
619 using mumamo-mode. I do not know the reason yet.
622 Refontification could miss some parts when buffer
623 changes caused chunk division changes. Complex,
624 tried to fix it, but I am a bit unsure that it
628 Cleaned up mumamo.el a bit.
631 Rewrote mumamo-test.el and functions called from it in
632 mumamo.el a bit to make tracebacks from errors more
633 useful. Changed keybindings in mumamo-test.el from
634 global to a minor mode <em>mumamo-test-mode</em>.
635 Renamed mumamo-notest.el to mumamo-test.el. Added it
636 to the zipped distribution of nXhtml.
641 Fixed a bug related to links and buffer changes.
649 Fixed a refontification bug that occured after changes.
657 Added the possibility to call GIMP.
660 Reworked the messages for fontification errors to try
661 to catch an error that shows up sometimes. Tried to
662 avoid disturbing normal use in spite of that error.
665 Reverted to using a short delay before switching major
666 mode when moving between buffers.
674 Completion in empty buffers with a completion header
678 Multiple major modes:
681 Better error tracing for some functions.
684 Position was garbled when a ;-char was inserted in php-mode chunk. Fixed.
689 Extra XHTML Validation Header:
692 View File did not work correctly when an extra
693 XHTML validation header was used. Corrected.
696 Extra XHTML validation headers are no longer
697 turned on by default in any buffers.
702 Tried to fix a problem when using newline-and-indent.
703 When this was in a mode derived from C the indentation
707 Added a workaround for <a
708 href="#php-attribute-values">Attribute values computed
715 Multiple major mode turned on by default for .rhtml files when this mode is global.
718 Multiple major mode is no longer turned on when rub-mode is turned on.
723 Added .nosearch to subdirectories with no elisp files.
726 Added support for Firefox add-on It's All Text.
729 Added the possibility to easily view the output of scripts on the server (if they require no parameters).
730 You can now do that from the nXhtml menu.
731 Previously only html files on the server could be viewed that way.
732 Image files can also be viewed this way.
735 Upgraded htmlize.el to version 1.34
738 Added functions for unfilling.
741 Added keybindings and menu entries for longlines-mode, fill-paragraph and unfill-paragraph.
744 Added image-mode to those that are encompassed by
745 nxhtml-global-minor-mode so that images can be
746 uploaded more easily.
749 Added <em>edit with GIMP</em> and <em>upload</em> to the popup menu for links.
750 This avoids the need to load the linked files in Emacs first.
753 Fixed incorrect checks for mlinks-mode in menu building.
763 Copyright © 2007 OurComments.org
765 Latest update 2007-05-06