[PyKDE] Line numbers in TextEdit box?
Jonathan Gardner
jgardner at jonathangardner.net
Tue Aug 12 22:22:01 BST 2003
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Tuesday 12 August 2003 11:38, Peter Clark wrote:
>
> Since the only "difficult" part is understanding C++ (which, as I
> have stated before, I know next to nothing about), I was actually
> hoping that some kind soul had already done so, but after searching
> Google, it doesn't look like it. Ah, well, I'll download the source
> for QScintilla and see what we've got there.
>
Understanding C++ isn't hard... if you've been through the college
courses, read several books on the subject, and come from an MS Visual
Studio background. ;-)
>
> QScintilla looks to be like a Mach truck when all I really need is a
> moped.
>
When you think you'll only need a moped, you'll end up needing a mack
truck anyways. Eventually, your app is going to be used, and people are
going to want features you couldn't have anticipated.
> :) What I had in mind was something like
>
> http://www.sil.org/computing/shoebox/graphics/SingleGlossField.gif,
> with the left-hand column (the \lx and \ge part) "uneditable" (and
> preferably with a grey background, to indicate that), with the
> right-hand column the data entry part. The right-hand part would also
> have to be multi-lined, e.g.:
>
> Tags Values
>
> \entry | The name of the entry
> \text | Some really long text that
>
> | wraps around for a while
> | to show off line-wrapping.
>
> \date | 12 Aug 2003
>
> Text labels wouldn't work here, since the left-hand column doesn't
> necessarily have to include a set list of tags. Also, there could be
> dozens, perhaps even more such tags, and to give every last one a
> text label would create a huge window that would fit only on the
> largest of screens.
>
I'd rethink the design. Looking at the picture, I can't tell how to add
new tags or remove existing one. Can I edit the text on the left? What
about cut and paste? Does it scroll? It's not clear. GUI interfaces are
supposed to make that clear.
I find when I am trying to manipulate the widgets to do things they
weren't intended to do, I am making a bad interface that I am going to
regret later.
Have you thought of using a listview? Click on a node (a tag) and you
can edit the value. Have the tree show the first couple of characters
from the first line if necessary.
If you do decide to go with a modified widget, you should really learn
enough C++ to read the code for Qt's widgets, and then run from there.
- --
Jonathan Gardner <jgardner at jonathangardner.net>
Live Free, Use Linux!
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.1 (GNU/Linux)
iD8DBQE/OUxRWgwF3QvpWNwRAsHiAJ9ZP1DcRcLpVMc2ZLgZb1YNNxLtPQCgk3XM
jbbX1+bOTRcFBdbW+D/9Eqo=
=YRuu
-----END PGP SIGNATURE-----
More information about the PyQt
mailing list