comp.lang.ada
 help / color / mirror / Atom feed
* Re: urgent glide question
  2002-07-10 20:38 Jan Prazak
@ 2002-07-10 18:58 ` Simon Wright
  2002-07-10 22:44   ` Jan Prazak
  2002-07-10 23:19   ` Jan Prazak
  0 siblings, 2 replies; 5+ messages in thread
From: Simon Wright @ 2002-07-10 18:58 UTC (permalink / raw)


Jan Prazak <janp9@gmx.net> writes:

> When I execute it in emacs, it is shown in a separate window (below the
> source code) (that's ok), but when I enter something and press enter,
> nothing happens, the cursor just goes to next line. I have then to kill
> the running program to stop it (because ctrl+c doesn't work). What's
> that??? How to solve it? 

I think you have to C-c C-c (ie, ctrl-c _twice_).

>                          Is there a possibility to run all compiled
> programs in a terminal (KDE shell)? (There it works.)

(The version of glide I'm using may not be the same as yours, so there
may be some differences).

If you edit the Project file (Ada/Project/Edit) and select the Ada
Menu tab, there should be a section like

  Running the application (menu Ada->Run):	      [Help]  (run_cmd)
  [INS][DEL] cd ${build_dir}
  [INS][DEL] ${main}
  [INS]

If you change the ${main} line to     xterm -e ${main}

(or whatever your favourite terminal program is, with the flag to name
the program to run in it) and save the project file, you should find
Ada/Run (C-c r) runs in a separate terminal window .. well, it might
work!



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

* urgent glide question
@ 2002-07-10 20:38 Jan Prazak
  2002-07-10 18:58 ` Simon Wright
  0 siblings, 1 reply; 5+ messages in thread
From: Jan Prazak @ 2002-07-10 20:38 UTC (permalink / raw)


Hello,

I have found out that there is an IDE add-on for emacs, called glide. It
seems to be the only "good" IDE for gnat, since tia and grasp are very
user-unfriendly (and do not work correctly on my PC).

But there seems to be a problem when running terminal-applications (text
mode) under emacs/glide. Take a look at this simple example:

-----------------------
with Ada.Text_IO;
use Ada.Text_IO;

procedure LEdit is
S : String(1..20);
I : Integer;
begin
   New_Line;

   Put("Enter a string: ");

   Get_Line(S, I);

   New_Line(3);

   Put_Line("You have entered: " & S(1..I));
end LEdit;
------------------------------------------

When I execute it in emacs, it is shown in a separate window (below the
source code) (that's ok), but when I enter something and press enter,
nothing happens, the cursor just goes to next line. I have then to kill
the running program to stop it (because ctrl+c doesn't work). What's
that??? How to solve it? Is there a possibility to run all compiled
programs in a terminal (KDE shell)? (There it works.)

Thanks!
Jan




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

* Re: urgent glide question
       [not found] <mailman.1026329582.31072.comp.lang.ada@ada.eu.org>
@ 2002-07-10 22:44 ` Jan Prazak
  0 siblings, 0 replies; 5+ messages in thread
From: Jan Prazak @ 2002-07-10 22:44 UTC (permalink / raw)


On Wed, 10 Jul 2002 18:32:58 -0100, Gautier direct_replies_not_read wrote:

> I suppose it's not on Windï¿œze, otherwise there is a certain AdaGIDE you
> could try.

No, it's Linux.




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

* Re: urgent glide question
  2002-07-10 18:58 ` Simon Wright
@ 2002-07-10 22:44   ` Jan Prazak
  2002-07-10 23:19   ` Jan Prazak
  1 sibling, 0 replies; 5+ messages in thread
From: Jan Prazak @ 2002-07-10 22:44 UTC (permalink / raw)


On Wed, 10 Jul 2002 17:58:23 -0100, Simon Wright wrote:

<...>

thanks, i will try it




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

* Re: urgent glide question
  2002-07-10 18:58 ` Simon Wright
  2002-07-10 22:44   ` Jan Prazak
@ 2002-07-10 23:19   ` Jan Prazak
  1 sibling, 0 replies; 5+ messages in thread
From: Jan Prazak @ 2002-07-10 23:19 UTC (permalink / raw)


On Wed, 10 Jul 2002 17:58:23 -0100, Simon Wright wrote:


> I think you have to C-c C-c (ie, ctrl-c _twice_).

That doesn't work, it just beeps.

>   Running the application (menu Ada->Run):	      [Help]  (run_cmd)
>   [INS][DEL] cd ${build_dir}
>   [INS][DEL] ${main}
>   [INS]
> 
> If you change the ${main} line to     xterm -e ${main}
> ...

OK, it works, thanks! But I had to edit the .adp file, because when I
changed the line under the Ada-Tab in emacs, and clicked on "save",
nothing has actually been saved (I don't know why). So I added the
following line to ledit.adp (that't the project name)

run_cmd=cd ${build_dir} && konsole -e ${main}

xterm would be ok, but I don't know how to change the colors there, and
black on white doesn't look good.

But there is still a little problem, after the program has finished, the
terminal window closes immediately. I think I will have to add some line
at the end of each program, which waits for a key-press. Or is there a
utility in Linux which does the same? Of course I could also write my own
one.

Happy coding!
Jan




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

end of thread, other threads:[~2002-07-10 23:19 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <mailman.1026329582.31072.comp.lang.ada@ada.eu.org>
2002-07-10 22:44 ` urgent glide question Jan Prazak
2002-07-10 20:38 Jan Prazak
2002-07-10 18:58 ` Simon Wright
2002-07-10 22:44   ` Jan Prazak
2002-07-10 23:19   ` Jan Prazak

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