[prev in list] [next in list] [prev in thread] [next in thread]
List: kwrite-devel
Subject: Re: Review Request 115589: Add puppet syntax file
From: "Sven Brauch" <svenbrauch () googlemail ! com>
Date: 2014-02-08 22:17:20
Message-ID: 20140208221720.13692.46861 () probe ! kde ! org
[Download RAW message or body]
[Attachment #2 (multipart/alternative)]
> On Feb. 8, 2014, 8:56 p.m., Sven Brauch wrote:
> > New highlighting files are always welcome I guess ;)
> > License-wise this should be fine since the original license is kept and the \
> > author is given credit.
> > The file name issue is difficult. On one hand, I'd guess (but I might be wrong) \
> > that pascal is more popular. On the other hand, the risk of people thinking kate \
> > doesn't support puppet and thus highlights their files as pascal is higher than \
> > the other way round. Maybe you could even use the message widget for that? "File \
> > type foo is ambiguous [use pascal] [use puppet] [ ] remember choice"?
> > One thing I dislike is the high number of hardcoded colors. On the sprint we \
> > discussed that we want to get away from hardcoded colors in syntax files \
> > completely, because the idea is simply broken in interaction with \
> > user-configurable colour schemes. Maybe at least some can be removed, when \
> > there's viable default styles available?
>
> Michal Humpula wrote:
> Ok, I've just removed the colors. I think most of the groups are not even used in \
> puppet config. Seems like ruby.xml relicts to me. I will try to clean that up \
> later.
> As for configurable colour schemes and specific colors reduction... you will have \
> to add more default text styles, right?
Yes, the idea I discussed with Christoph back then bolied down to providing maybe 5 \
to 10 "misc1...misc5" default colors not associated with a particular kind of item \
but instead free to use by the languages. The idea was then to replace all fixed \
colors by those misc colors (and enventually even forbid fixed colors completely).
The advantage is that a color scheme can ship with 10 misc colors which fit the \
scheme, and -- tada -- highlighting will look ok in all languages (which is not the \
case today, if you make the background color dark, lots of languages have issues with \
bad contrast and you need to reconfigure 10 colors for each one by hand). It needs a \
bit more thinking but in my opinion long-term it's the only useful thing to do.
- Sven
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://git.reviewboard.kde.org/r/115589/#review49294
-----------------------------------------------------------
On Feb. 8, 2014, 10:12 p.m., Michal Humpula wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://git.reviewboard.kde.org/r/115589/
> -----------------------------------------------------------
>
> (Updated Feb. 8, 2014, 10:12 p.m.)
>
>
> Review request for Kate.
>
>
> Repository: kate
>
>
> Description
> -------
>
> Not sure if adding yet another syntax file is ok, or not:-) This one is shamelessly \
> copied from http://projects.puppetlabs.com/issues/8608. I've just cleanup the \
> whitespaces a little bit and changed indeter to ruby. It's LGPLv2+ so I guess \
> inclusion like this is ok.
> problems:
> * it's based on the ruby syntax file so I guess it has the same buggy corner case \
> issues
> * the "*.pp" colides with pascal, which has higher priority (= 8) so the .pp files \
> are in default displayed with pascal syntax. So, how is priority decided? If by \
> human feeling, then I guess there are not many people, who write pascal code in \
> kate these days in contrast with the number of people who write puppet \
> configuration and use kate as their primary editor;-)
>
> Diffs
> -----
>
> part/syntax/data/puppet.xml PRE-CREATION
>
> Diff: https://git.reviewboard.kde.org/r/115589/diff/
>
>
> Testing
> -------
>
>
> Thanks,
>
> Michal Humpula
>
>
[Attachment #5 (text/html)]
<html>
<body>
<div style="font-family: Verdana, Arial, Helvetica, Sans-Serif;">
<table bgcolor="#f9f3c9" width="100%" cellpadding="8" style="border: 1px #c9c399 \
solid;"> <tr>
<td>
This is an automatically generated e-mail. To reply, visit:
<a href="https://git.reviewboard.kde.org/r/115589/">https://git.reviewboard.kde.org/r/115589/</a>
</td>
</tr>
</table>
<br />
<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;"> <p style="margin-top: 0;">On February 8th, 2014, 8:56 p.m. UTC, <b>Sven \
Brauch</b> wrote:</p> <blockquote style="margin-left: 1em; border-left: 2px solid \
#d0d0d0; padding-left: 10px;"> <pre style="white-space: pre-wrap; white-space: \
-moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: \
break-word;">New highlighting files are always welcome I guess ;) License-wise this \
should be fine since the original license is kept and the author is given credit.
The file name issue is difficult. On one hand, I'd guess (but I might be wrong) \
that pascal is more popular. On the other hand, the risk of people thinking kate \
doesn't support puppet and thus highlights their files as pascal is higher than \
the other way round. Maybe you could even use the message widget for that? "File \
type foo is ambiguous [use pascal] [use puppet] [ ] remember choice"?
One thing I dislike is the high number of hardcoded colors. On the sprint we \
discussed that we want to get away from hardcoded colors in syntax files completely, \
because the idea is simply broken in interaction with user-configurable colour \
schemes. Maybe at least some can be removed, when there's viable default styles \
available?</pre> </blockquote>
<p>On February 8th, 2014, 10:09 p.m. UTC, <b>Michal Humpula</b> wrote:</p>
<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: \
10px;"> <pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Ok, I've just \
removed the colors. I think most of the groups are not even used in puppet config. \
Seems like ruby.xml relicts to me. I will try to clean that up later.
As for configurable colour schemes and specific colors reduction... you will have to \
add more default text styles, right?</pre> </blockquote>
</blockquote>
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: \
-pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Yes, the idea I \
discussed with Christoph back then bolied down to providing maybe 5 to 10 \
"misc1...misc5" default colors not associated with a particular kind of \
item but instead free to use by the languages. The idea was then to replace all fixed \
colors by those misc colors (and enventually even forbid fixed colors completely).
The advantage is that a color scheme can ship with 10 misc colors which fit the \
scheme, and -- tada -- highlighting will look ok in all languages (which is not the \
case today, if you make the background color dark, lots of languages have issues with \
bad contrast and you need to reconfigure 10 colors for each one by hand). It needs a \
bit more thinking but in my opinion long-term it's the only useful thing to \
do.</pre> <br />
<p>- Sven</p>
<br />
<p>On February 8th, 2014, 10:12 p.m. UTC, Michal Humpula wrote:</p>
<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" \
style="background-image: \
url('https://git.reviewboard.kde.org/static/rb/images/review_request_box_top_bg.ab6f3b1072c9.png'); \
background-position: left top; background-repeat: repeat-x; border: 1px black \
solid;"> <tr>
<td>
<div>Review request for Kate.</div>
<div>By Michal Humpula.</div>
<p style="color: grey;"><i>Updated Feb. 8, 2014, 10:12 p.m.</i></p>
<div style="margin-top: 1.5em;">
<b style="color: #575012; font-size: 10pt;">Repository: </b>
kate
</div>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Description </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" \
style="border: 1px solid #b8b5a0"> <tr>
<td>
<pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: \
-moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: \
break-word;">Not sure if adding yet another syntax file is ok, or not:-) This one is \
shamelessly copied from http://projects.puppetlabs.com/issues/8608. I've just \
cleanup the whitespaces a little bit and changed indeter to ruby. It's LGPLv2+ so \
I guess inclusion like this is ok.
problems:
* it's based on the ruby syntax file so I guess it has the same buggy corner case \
issues
* the "*.pp" colides with pascal, which has higher priority (= 8) so the \
.pp files are in default displayed with pascal syntax. So, how is priority decided? \
If by human feeling, then I guess there are not many people, who write pascal code in \
kate these days in contrast with the number of people who write puppet configuration \
and use kate as their primary editor;-)</pre> </td>
</tr>
</table>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> </h1>
<ul style="margin-left: 3em; padding-left: 0;">
<li>part/syntax/data/puppet.xml <span style="color: grey">(PRE-CREATION)</span></li>
</ul>
<p><a href="https://git.reviewboard.kde.org/r/115589/diff/" style="margin-left: \
3em;">View Diff</a></p>
</td>
</tr>
</table>
</div>
</body>
</html>
_______________________________________________
KWrite-Devel mailing list
KWrite-Devel@kde.org
https://mail.kde.org/mailman/listinfo/kwrite-devel
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic