* nXhtml-mode font-lock customizations ??
@ 2007-05-10 16:38 William Case
2007-05-10 16:58 ` Lennart Borgman (gmail)
2007-05-10 17:34 ` William Case
0 siblings, 2 replies; 6+ messages in thread
From: William Case @ 2007-05-10 16:38 UTC (permalink / raw)
To: EMACS List
Hi;
I have been happily using nXhtml for over a week now.
I would like to take a look at the font-lock-faces for different modes
(HTML, PHP) and perhaps make minor adjustments. Do I customize the
font-lock-faces for each mode separately, change the syntax table or is
there a combined nXhtml font-lock-faces customization?
For example on my current file a long red line/underline (mainly in some
empty lines, but in some text) shows and a can't figure out what it
represents, if any thing. A red underline shows up under some tags. If
it is showing an error, those lines are not errors (I believe -- the
page works?).
--
Regards Bill
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: nXhtml-mode font-lock customizations ??
2007-05-10 16:38 nXhtml-mode font-lock customizations ?? William Case
@ 2007-05-10 16:58 ` Lennart Borgman (gmail)
2007-05-10 17:36 ` William Case
2007-05-10 17:34 ` William Case
1 sibling, 1 reply; 6+ messages in thread
From: Lennart Borgman (gmail) @ 2007-05-10 16:58 UTC (permalink / raw)
To: William Case; +Cc: EMACS List
William Case wrote:
> Hi;
>
> I have been happily using nXhtml for over a week now.
>
> I would like to take a look at the font-lock-faces for different modes
> (HTML, PHP) and perhaps make minor adjustments. Do I customize the
> font-lock-faces for each mode separately, change the syntax table or is
> there a combined nXhtml font-lock-faces customization?
You would have to do it for each mode (html-mode, php-mode etc). Please
notice however that for nxhtml-mode the fontification for html-mode is used.
> For example on my current file a long red line/underline (mainly in some
> empty lines, but in some text) shows and a can't figure out what it
> represents, if any thing. A red underline shows up under some tags. If
> it is showing an error, those lines are not errors (I believe -- the
> page works?).
See the documentation, ehum, the "News and Notes about nXhtml" for info
about the red underlines.
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: nXhtml-mode font-lock customizations ??
2007-05-10 16:58 ` Lennart Borgman (gmail)
@ 2007-05-10 17:36 ` William Case
0 siblings, 0 replies; 6+ messages in thread
From: William Case @ 2007-05-10 17:36 UTC (permalink / raw)
To: Lennart Borgman (gmail); +Cc: EMACS List
On Thu, 2007-05-10 at 18:58 +0200, Lennart Borgman (gmail) wrote:
> William Case wrote:
> > Hi;
> >
> > I have been happily using nXhtml for over a week now.
> >
> > I would like to take a look at the font-lock-faces for different modes
> > (HTML, PHP) and perhaps make minor adjustments. Do I customize the
> > font-lock-faces for each mode separately, change the syntax table or is
> > there a combined nXhtml font-lock-faces customization?
>
> You would have to do it for each mode (html-mode, php-mode etc). Please
> notice however that for nxhtml-mode the fontification for html-mode is used.
>
> > For example on my current file a long red line/underline (mainly in some
> > empty lines, but in some text) shows and a can't figure out what it
> > represents, if any thing. A red underline shows up under some tags. If
> > it is showing an error, those lines are not errors (I believe -- the
> > page works?).
>
> See the documentation, ehum, the "News and Notes about nXhtml" for info
> about the red underlines.
Lennart, excuse my most recent post. I jumped the gun. Stuff is coming
clearer as I delve deeper.
--
Regards Bill
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: nXhtml-mode font-lock customizations ??
2007-05-10 16:38 nXhtml-mode font-lock customizations ?? William Case
2007-05-10 16:58 ` Lennart Borgman (gmail)
@ 2007-05-10 17:34 ` William Case
2007-05-10 21:46 ` Lennart Borgman (gmail)
1 sibling, 1 reply; 6+ messages in thread
From: William Case @ 2007-05-10 17:34 UTC (permalink / raw)
To: EMACS List
Hi;
Stupidity Check.
On Thu, 2007-05-10 at 12:38 -0400, William Case wrote:
> Hi;
>
> I have been happily using nXhtml for over a week now.
>
> I would like to take a look at the font-lock-faces for different modes
> (HTML, PHP) and perhaps make minor adjustments. Do I customize the
> font-lock-faces for each mode separately, change the syntax table or is
> there a combined nXhtml font-lock-faces customization?
>
> For example on my current file a long red line/underline (mainly in some
> empty lines, but in some text) shows and a can't figure out what it
> represents, if any thing.
> A red underline shows up under some tags. If
> it is showing an error, those lines are not errors (I believe -- the
> page works?).
Error: Some tags are capitalized and this shows up underlined in red as
an error, as it should. Lower casing those tags removes the red
underline.
Still don't understand why <? ... ?> deserves a full line error. For
example,
" <!-- ============== STANDARD FOOTER =============== -->
<?php
include "includes/footer-oclug.html";
?> " is marked as an error. If there is, in fact, a php error here I'll
double check the manual, but I don't see it and it works. Works right
in php-mode. Getting warning in other buffer "Error
(mumamo-fontify-region): Should not happen"
Just wondering if nXhtml is correctly identifying an error.
And, I would like to brighten (change the blue shade ) of the <TAGS> and
if possible make some small changes so that php tags etc. more closely
resemble the font-lock-faces I have set up for php-mode.
--
Regards Bill
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: nXhtml-mode font-lock customizations ??
2007-05-10 17:34 ` William Case
@ 2007-05-10 21:46 ` Lennart Borgman (gmail)
0 siblings, 0 replies; 6+ messages in thread
From: Lennart Borgman (gmail) @ 2007-05-10 21:46 UTC (permalink / raw)
To: William Case; +Cc: EMACS List
William Case wrote:
> Still don't understand why <? ... ?> deserves a full line error. For
> example,
> " <!-- ============== STANDARD FOOTER =============== -->
> <?php
> include "includes/footer-oclug.html";
> ?> " is marked as an error. If there is, in fact, a php error here I'll
> double check the manual, but I don't see it and it works. Works right
> in php-mode.
This is a good question and I need to explain. The validation (that
gives the red underlines) is done by the validation code from nXml. That
code is very good for XML, but knows nothing about PHP. In nXhtml I try
to use the same validation code for PHP too. It therefore gives some
nonsense error.
In the future the validation code ought to be taken out and changed so
that it can handle PHP (and similar cases) better. However that is a big
and difficult job and nothing I can do now.
I still think however that the validation code is very useful because it
is this code that also gives the context sensitive completion in the
XHTML part of PHP code.
The red underlines are sometimes useful, sometimes not. You can turn
them of with C-c C-w.
> Getting warning in other buffer "Error
> (mumamo-fontify-region): Should not happen"
That is a bug. I hope I have fixed this. If you want to test then please
use the beta code here:
http://ourcomments.org/Emacs/DL/elisp/nxhtml/beta/
> And, I would like to brighten (change the blue shade )
That is a defcustom in the group 'mumamo (or 'nxhtml).
^ permalink raw reply [flat|nested] 6+ messages in thread
[parent not found: <mailman.490.1178815584.32220.help-gnu-emacs@gnu.org>]
* Re: nXhtml-mode font-lock customizations ??
[not found] <mailman.490.1178815584.32220.help-gnu-emacs@gnu.org>
@ 2007-05-10 16:48 ` Chris McMahan
0 siblings, 0 replies; 6+ messages in thread
From: Chris McMahan @ 2007-05-10 16:48 UTC (permalink / raw)
To: help-gnu-emacs
Those lines are flagging errors in your code. The page may display
correctly because most browsers tend to be very forgiving. You might
check to ensure all of your tags have corresponding closing tags (even
the <p> tag) as a starting point.
- Chris
William Case <billlinux@rogers.com> writes:
> Hi;
>
> I have been happily using nXhtml for over a week now.
>
> I would like to take a look at the font-lock-faces for different modes
> (HTML, PHP) and perhaps make minor adjustments. Do I customize the
> font-lock-faces for each mode separately, change the syntax table or is
> there a combined nXhtml font-lock-faces customization?
>
> For example on my current file a long red line/underline (mainly in some
> empty lines, but in some text) shows and a can't figure out what it
> represents, if any thing. A red underline shows up under some tags. If
> it is showing an error, those lines are not errors (I believe -- the
> page works?).
>
>
> --
> Regards Bill
>
>
>
--
(. .)
=ooO=(_)=Ooo=====================================
Chris McMahan | first_initiallastname@one.dot.net
=================================================
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2007-05-10 21:46 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-05-10 16:38 nXhtml-mode font-lock customizations ?? William Case
2007-05-10 16:58 ` Lennart Borgman (gmail)
2007-05-10 17:36 ` William Case
2007-05-10 17:34 ` William Case
2007-05-10 21:46 ` Lennart Borgman (gmail)
[not found] <mailman.490.1178815584.32220.help-gnu-emacs@gnu.org>
2007-05-10 16:48 ` Chris McMahan
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).