When we do
$ d.text
there is no comment seen in the "wish" window telling us to return to
the terminal window and enter text.
P.S., and when we do go there, we see
bad window path name ".pw.f0.frame.optwin.fra.frame.lab4"
--- Headers Follow ---
From jidanni@jidanni.org Sun Dec 5 06:36:16 2004
Return-Path: <jidanni@jidanni.org>
Delivered-To: grass-bugs@lists.intevation.de
Received: from mail.intevation.de (aktaia [212.95.126.10])
by lists.intevation.de (Postfix) with ESMTP id 03EA9100167
for <grass-bugs@lists.intevation.de>; Sun, 5 Dec 2004 06:36:16 +0100 (CET)
Received: from localhost (localhost [127.0.0.1])
by mail.intevation.de (Postfix) with ESMTP id 6F29536F13
for <grass-bugs@lists.intevation.de>; Sun, 5 Dec 2004 06:35:35 +0100 (CET)
Received: from frodo.hserus.net (frodo.hserus.net [204.74.68.40])
by mail.intevation.de (Postfix) with ESMTP id A139336DE2
for <grass-bugs@intevation.de>; Sun, 5 Dec 2004 06:35:33 +0100 (CET)
Received: from [219.69.72.195] (port=35038 helo=jidanni1)
by frodo.hserus.net with esmtpsa
(Cipher TLSv1:RC4-SHA:128) (Exim 4.43 #0)
id 1Cap3T-000DU9-M7 by authid <jidanni> with plain
for <grass-bugs@intevation.de>; Sun, 05 Dec 2004 11:05:32 +0530
To: grass-bugs@intevation.de
Subject: d.text when interactive should say where to enter text
From: Dan Jacobson <jidanni@jidanni.org>
Date: Sun, 05 Dec 2004 12:02:35 +0800
Message-ID: <877jnxs884.fsf@jidanni.org>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
X-Spam-Status: No, hits=-4.9 tagged_above=-999.0 required=3.0 tests=BAYES_00
X-Spam-Level:
-------------------------------------------- Managed by Request Tracker
When we do
$ d.text
there is no comment seen in the "wish" window telling us to return to
the terminal window and enter text.
true. try "echo `g.version` | d.text"
from the help page:
"DESCRIPTION
d.text draws text in the active display frame on the graphics
monitor. Text can be provided through standard input or redirected
from a file (using the UNIX redirection mechanism)."
Yes, a text= option like d.text.freetype is missing.
Perhaps change the module's description until that is done?
I've been meaning to do further cleanups & sync'ing between d.text and
d.text.freetype for a while. Also merge in mouse placement from
d.barscale. It's not a high priority for me though.
P.S., and when we do go there, we see
bad window path name ".pw.f0.frame.optwin.fra.frame.lab4"
When we do
$ d.text
there is no comment seen in the "wish" window telling us to return to
the terminal window and enter text.
true. try "echo `g.version` | d.text"
from the help page:
"DESCRIPTION
d.text draws text in the active display frame on the graphics
monitor. Text can be provided through standard input or redirected
from a file (using the UNIX redirection mechanism)."
Yes, a text= option like d.text.freetype is missing.
Perhaps change the module's description until that is done?
I've been meaning to do further cleanups & sync'ing between d.text and
d.text.freetype for a while. Also merge in mouse placement from
d.barscale. It's not a high priority for me though.
P.S., and when we do go there, we see
bad window path name ".pw.f0.frame.optwin.fra.frame.lab4"
fixed after 5.7.0.
Hamish
____________________
C. Michael Barton, Professor of Anthropology
School of Human Evolution and Social Change
PO Box 872402
Arizona State University
Tempe, AZ 85287-2402
USA
>> this bug's URL: http://intevation.de/rt/webrt?serial_num=2776
>> -------------------------------------------------------------------
>>
>> $ d.text
>> there is no comment seen in the "wish" window telling us to return
>to> the terminal window and enter text.
>
> true. try "echo `g.version` | d.text"
>
> from the help page:
>
> "DESCRIPTION
> d.text draws text in the active display frame on the graphics
> monitor. Text can be provided through standard input or
> redirected from a file (using the UNIX redirection mechanism)."
>
>
> Yes, a text= option like d.text.freetype is missing.
> Perhaps change the module's description until that is done?
>
> I've been meaning to do further cleanups & sync'ing between d.text
> and d.text.freetype for a while. Also merge in mouse placement from
> d.barscale. It's not a high priority for me though.
Should this be run in an xterm from the GUI instead of from a tcltk
dialog?
I don't think this would help any.
The 5.0-5.4 tcltkgrass menu entry for d.text has an entry for input
file, which it pipes from stdin with "<":
interface_build {
{d.text} 0
{Draws text.}
{entry size {Letters height in % of frame height (0-100) [5]:} 0 ""}
{entry color {Text color [gray]:} 0 color}
{entry line {Screen line number on which text will begin (1-1000) [1]:} 0 ""}
{entry < {Text command file:} 0 file}
}
e.g.
d.text < input_file.txt
For short bits of text you might want to enter from the GUI there
should be a text="your text here" option like d.text.freetype. But
doing this is a little bit complicated because of the way d.text
saves itself to the display's command history .. so it hasn't
happened yet.
note d.text can do some fancy things with the correct commands, but I
think it is better to leave that to advanced users piping from the
command line.
Perhaps d.text should be removed from the d.m menu until we have a
solution. (as it won't actually do anything)
On 12/5/04 4:50 PM, "Hamish" <hamish_nospam@yahoo.com> wrote:
Perhaps d.text should be removed from the d.m menu until we have a
solution. (as it won't actually do anything)
____________________
C. Michael Barton, Professor of Anthropology
School of Human Evolution and Social Change
PO Box 872402
Arizona State University
Tempe, AZ 85287-2402
USA
I tried this and you were right originally. When I run it from the GUI using
the term procedure, it opens an xterm but also goes to the tcltk dialog
which gets us nowhere (i.e., the xterm accepts no input). I also tried it
from the command line. The only way to bypass the tcltk dialog is to follow
d.text by an argument (e.g., -b or size=5). Then it will go to an
interactive xterm.
It seems like the only way to make it useable from the GUI is either to add
add a standard input box as you did in d.text.freetype (but you said this
was problematic) or to make a script that will accept user input, then run
d.text as a command-line command.
Michael
On 12/5/04 6:53 PM, "Hamish" <hamish_nospam@yahoo.com> wrote:
Perhaps d.text should be removed from the d.m menu until we have a
solution. (as it won't actually do anything)
sorry, I was mistaken, d.text will work from a xterm:
if (isatty(0))
fprintf (stdout,"\nPlease enter text instructions. Enter EOF (ctrl-d) on
last line to quit\n") ;
so d.m should launch it that way.
Hamish
____________________
C. Michael Barton, Professor of Anthropology
School of Human Evolution and Social Change
PO Box 872402
Arizona State University
Tempe, AZ 85287-2402
USA