pspp-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: color coding of syntax


From: ft gmail
Subject: Re: color coding of syntax
Date: Wed, 22 May 2024 20:02:38 +0200
User-agent: Mozilla Thunderbird

Then this shows that ChatGpt invents answers.

Le 22/05/2024 à 19:57, Ben Pfaff a écrit :
I don't think there have ever been syntax highlighting options. It's
either supported or not.

On Wed, May 22, 2024 at 10:54 AM ft gmail <public.ftr@gmail.com> wrote:
Once I saw that ChatGPT might find something that I did not, I tried my old 
demand to color-code PSPP syntax with ChatGPT.

To no avail. It seems ChatGPT found another version of PSPP with a GUI that is not 
the one I see on my screen. There is no Edit > Preferences > Syntax 
Highlighting. Very curious.


This is a copy of the exchange with ChatGPT :

question: how to get color coding of syntax in PSPP in windows11 ?

answer of ChatGPT:

Hello! To enable syntax highlighting in PSPP on Windows 11, you can go to the "Edit" menu, select 
"Preferences," then choose the "Syntax Highlighting" tab. From there, you can customize 
the colors for different syntax elements to make your code more visually appealing and easier to read. Let me 
know if you need any more help with this!

question: There is no Preference tab under the Edit menu in PSPP 2.00 .

answer:

Hello! I'm sorry to hear that you're having trouble finding the Preference tab 
in PSPP 2.00. It seems like there might be a change in the menu layout or 
options. Have you tried looking for the Preferences settings in a different 
location within the software? If you're still unable to locate it, I recommend 
checking the software's documentation or reaching out to the support team for 
further assistance. I hope this helps!

  I send this exchange to the list as I think it is useful to know the outside 
view of PSPP.  I am somewhat baffled. Is there a syntax highlighting tab in the 
GNU version, but not in the Windows version ??

-ftr

Le 07/02/2024 à 17:31, Ben Pfaff a écrit :

That's the right place and it looks like the right contents. My guess
that it was misplaced seems wrong.

Assuming these two machines both have the same version of PSPP, I
don't know what else to guess.

On Wed, Feb 7, 2024 at 8:24 AM ft gmail <public.ftr@gmail.com>
<blp-forward@cs.stanford.edu> wrote:

Once you gave me the name of the file with the color codes as pspp.lang I found 
it in C:\Program Files\PSPP\share\pspp .

Is this the correct place ?

And this is the content. Is there anything wrong in it ?



<?xml version="1.0" encoding="UTF-8"?>
<!--
    PSPP - a program for statistical analysis.
    Copyright (C) 2006, 2009 Free Software Foundation, Inc.

    This program is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
    the Free Software Foundation, either version 3 of the License, or
    (at your option) any later version.

    This program is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU General Public License for more details.

    You should have received a copy of the GNU General Public License
    along with this program.  If not, see <http://www.gnu.org/licenses/>.
-->


<language id="pspp" _name="PSPP" version="2.0" _section="Sources">

   <styles>
     <style id="string" _name="String" map-to="def:string"/>
     <style id="escaped-character" _name="Escaped Character" 
map-to="def:special-char"/>
     <style id="data-block" _name="Data Block" map-to="def:preprocessor"/>
     <style id="included-file" _name="Included File" map-to="def:string"/>
     <style id="char" _name="Character" map-to="def:character"/>
     <style id="keyword" _name="Keyword" map-to="def:keyword"/>
     <style id="type" _name="Data Type" map-to="def:type"/>
     <style id="comment" _name="Comment" map-to="def:comment"/>
   </styles>

   <default-regex-options case-sensitive="false" />

   <definitions>

     <context id="pspp">

       <include>

         <context id="comment-star" style-ref="comment">
           <start>^[\t ]*\*</start>
           <end>^[\t ]*$|^(?=[^\t ])</end>
         </context>

         <context id="comment-keyword" style-ref="comment">
           <start>^[\t ]*COMMENT</start>
           <end>\.[\t ]*$|^[\t ]*$|^(?=[^\t ])</end>
         </context>

         <context id="data-block" style-ref="data-block">
           <start>(?&lt;=(^BEGIN DATA$))</start>
           <end>(?=(^END DATA\.?))</end>
     </context>

         <context id="string-double" end-at-line-end="true"
                  style-ref="string">
           <start>"</start>
           <end>"</end>
         </context>

         <context id="string-single" end-at-line-end="true"
                  style-ref="string">
           <start>'</start>
           <end>'</end>
         </context>

     <context id="keywords" style-ref="keyword">
           <keyword>ALL</keyword>
           <keyword>AND</keyword>
           <keyword>BY</keyword>
           <keyword>EQ</keyword>
           <keyword>GE</keyword>
           <keyword>GT</keyword>
           <keyword>LE</keyword>
           <keyword>LT</keyword>
           <keyword>NE</keyword>
           <keyword>NOT</keyword>
           <keyword>OR</keyword>
           <keyword>TO</keyword>
           <keyword>WITH</keyword>
         </context>

       </include>
     </context>
   </definitions>


</language>

Le 07/02/2024 à 17:12, Ben Pfaff a écrit :

My best guess is that the pspp.lang file, which specifies how to do
syntax highlighting, is somehow missing or misplaced on the machine
where text appears in all black. It's surprising; I don't know why
that would have happened.

On Tue, Feb 6, 2024 at 3:53 PM ft gmail <public.ftr@gmail.com> wrote:

Hi,

After an installation of pspp 2.0 on a second PC running under win 10 I found 
that color coding of syntax worked whereas on another PC under win 11 I only 
get a black syntax text. How to get a color-coded syntax  under win 11 ?

TIA

-ftr



reply via email to

[Prev in Thread] Current Thread [Next in Thread]