comp.lang.ada
 help / color / mirror / Atom feed
* Two miscellaneous questions about GPS : Ada indentation and then SPARK integration
@ 2010-06-01  7:20 Yannick Duchêne (Hibou57)
  2010-06-01  8:26 ` Alexander Senier
  2010-06-02  8:55 ` Yannick Duchêne (Hibou57)
  0 siblings, 2 replies; 4+ messages in thread
From: Yannick Duchêne (Hibou57) @ 2010-06-01  7:20 UTC (permalink / raw)


Hillo,

I oftenly don't use GPS (I use a markup driven outlining editor instead),  
so I'm not a GPS guru.

I have an expected behavior with the editor : in the configuration, Edit  
-> Preferences -> Editor -> Ada, I have disabled the check box “Use  
tabulations”, to not have tab characters and just spaces. For  
“continuation lines”, “Record indentations”, “Conditional continuation  
lines” and “Default indentation”, I have set 3 spaces, for all.

Despite of that, when I hit the tab key, the editor still input a  
tabulation characters, moreover, this tabulation is 8 characters wide.

The three spaces (with no tab characters), only occurs when the editor do  
automatic indent.

Did I miss something in the configuration or is this the expected behavior  
?

The second question, is related to SPARK integration (I came back to GPS  
for SPARK, which is more handy than from the command line) : when I do  
SPARK -> POGS, a summary file is opened in GPS (OK). If then I do SPARK ->  
Examine File, then SPARK complains it cannot find my index file, although  
the configuration specifies the good file name. It only occurs after an  
invokation of POGS. If I close GPS then re-open it, the Examine File  
command works as expected (as it does all the time, if no POGS command was  
executed before).

Is it a known issue ? Should I submit a report for that or not ? (I will  
look at the files used for SPARK integration into GPS, to see if i can  
correct it)

Have a nice day



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Two miscellaneous questions about GPS : Ada indentation and then SPARK integration
  2010-06-01  7:20 Two miscellaneous questions about GPS : Ada indentation and then SPARK integration Yannick Duchêne (Hibou57)
@ 2010-06-01  8:26 ` Alexander Senier
  2010-06-01 10:01   ` Yannick Duchêne (Hibou57)
  2010-06-02  8:55 ` Yannick Duchêne (Hibou57)
  1 sibling, 1 reply; 4+ messages in thread
From: Alexander Senier @ 2010-06-01  8:26 UTC (permalink / raw)


On Tue, 01 Jun 2010 09:20:45 +0200
Yannick Duchêne (Hibou57) <yannick_duchene@yahoo.fr> wrote:

> I have an expected behavior with the editor : in the configuration,
> Edit -> Preferences -> Editor -> Ada, I have disabled the check box
> “Use tabulations”, to not have tab characters and just spaces. For  
> “continuation lines”, “Record indentations”, “Conditional
> continuation lines” and “Default indentation”, I have set 3 spaces,
> for all.
> 
> Despite of that, when I hit the tab key, the editor still input a  
> tabulation characters, moreover, this tabulation is 8 characters wide.
> 
> The three spaces (with no tab characters), only occurs when the
> editor do automatic indent.
> 
> Did I miss something in the configuration or is this the expected
> behavior ?

To get the desired behavior, you have to assign the tab key to the
"Editor -> Insert Tab With Spaces" action in the key shortcuts
dialog (Edit -> Key Shortcuts). At least in GPS 4.4.1 this substitutes
tabs by spaces also on manual indentations.

HTH
Alex




^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Two miscellaneous questions about GPS : Ada indentation and then SPARK integration
  2010-06-01  8:26 ` Alexander Senier
@ 2010-06-01 10:01   ` Yannick Duchêne (Hibou57)
  0 siblings, 0 replies; 4+ messages in thread
From: Yannick Duchêne (Hibou57) @ 2010-06-01 10:01 UTC (permalink / raw)


Le Tue, 01 Jun 2010 10:26:07 +0200, Alexander Senier <mail@senier.net> a  
écrit:

Hi Alex,
> To get the desired behavior, you have to assign the tab key to the
> "Editor -> Insert Tab With Spaces" action in the key shortcuts
> dialog (Edit -> Key Shortcuts). At least in GPS 4.4.1 this substitutes
> tabs by spaces also on manual indentations.
Confirmed, it works (on GPS 4.3.1)

I was lucky you were there, otherwise I would not have though to look in  
Edit -> Key Shortcuts.

Have a sweet day!

-- 
There is even better than a pragma Assert: a SPARK --# check.
--# check C and WhoKnowWhat and YouKnowWho;
--# assert Ada;
--  i.e. forget about previous premises which leads to conclusion
--  and start with new conclusion as premise.



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Two miscellaneous questions about GPS : Ada indentation and then SPARK integration
  2010-06-01  7:20 Two miscellaneous questions about GPS : Ada indentation and then SPARK integration Yannick Duchêne (Hibou57)
  2010-06-01  8:26 ` Alexander Senier
@ 2010-06-02  8:55 ` Yannick Duchêne (Hibou57)
  1 sibling, 0 replies; 4+ messages in thread
From: Yannick Duchêne (Hibou57) @ 2010-06-02  8:55 UTC (permalink / raw)


Le Tue, 01 Jun 2010 09:20:45 +0200, Yannick Duchêne (Hibou57)  
<yannick_duchene@yahoo.fr> a écrit:
> The second question, is related to SPARK integration (I came back to GPS  
> for SPARK, which is more handy than from the command line) : when I do  
> SPARK -> POGS, a summary file is opened in GPS (OK). If then I do SPARK  
> -> Examine File, then SPARK complains it cannot find my index file,  
> although the configuration specifies the good file name. It only occurs  
> after an invokation of POGS. If I close GPS then re-open it, the Examine  
> File command works as expected (as it does all the time, if no POGS  
> command was executed before).

About this one, I've found a track : the current directory is changed when  
POGS is executed. So if the index file is not specified using an absolute  
path, then the Examine File command do not find it anymore.

Probably there is a way to fix it, and this suggest a workaround : always  
use an absolute path for SPARK index file (may not be nice if one want a  
GPR file with relative paths only, while this can be acceptable)

-- 
There is even better than a pragma Assert: a SPARK --# check.
--# check C and WhoKnowWhat and YouKnowWho;
--# assert Ada;
--  i.e. forget about previous premises which leads to conclusion
--  and start with new conclusion as premise.



^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2010-06-02  8:55 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-06-01  7:20 Two miscellaneous questions about GPS : Ada indentation and then SPARK integration Yannick Duchêne (Hibou57)
2010-06-01  8:26 ` Alexander Senier
2010-06-01 10:01   ` Yannick Duchêne (Hibou57)
2010-06-02  8:55 ` Yannick Duchêne (Hibou57)

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox