Brennan Williams | 1 Feb 05:18
Gravatar

viewing text with CodeEditor

I'm using

Item('textstring',editor=CodeEditor())

as it gives a fixed width font which makes it easier to read.

 Is it possible to add search capability?

I tried

Item('textstring',editor=CodeEditor(search='top'))

but that had no effect.

I saw something in a previous set of posts from last Feb (Fred, Gael, 
Bryce) where Fred was looking to colour code keywords in the editor
and Gael & Bryce suggested SourceEditor. Can't get SourceEditor to work 
though as it needs a parent, just trying to work out what that is by 
looking for
PythonEditor in pyface.

I suppose my ultimate aim is to have a searchable, colour coded 
(according to some external setup file that defines my keywords) editor.

Can anyone give me a push in the right direction?

Thanks

Brennan
(Continue reading)

Gary Ruben | 1 Feb 05:47
Picon
Picon
Favicon

does EPD 6.0.2 have documentation?

Hi,
I just installed EPD 6.0.2 (32-bit) in WinXP with the Academic user
option and notice that there's no html documentation installed with it.
Just wondering whether that's expected.
Gary Ruben
Boiteux, Benoit | 1 Feb 10:16
Picon
Favicon

TableEditor & Filter

Hello,

I'm looking for an example of filtering using TableEditor (is it possible to use filters with other Editors?).

I created a basic TableEditor:
table_editor = TableEditor(
    columns = [ 
           ObjectColumn(name='id'),
           ObjectColumn(name='start_time'),
           ObjectColumn(name='delta_time'),
           ObjectColumn(name='duration'),
           ObjectColumn(name='power'),
           ],

Then,
I created a TableFilter class

class DurationFilter(TableFilter):
    tmax = Float
    tmin = Float
...
My usecase:
I generate a huge table and displays it with TableEditor
I propose controls to the user to enable/disable filters (with input values)
1- How do I need to implement the Filter class to filter 'duration' value between tmin and tmax ?
2- And then,How can I apply the filter to the TableEditor ? I have to be able to turn on/off this filter.

Thanks
Benoit
---------------------------------------------------------------------
(Continue reading)

bryce hendrix | 1 Feb 16:51

Re: viewing text with CodeEditor

Brennan Williams wrote:
> I'm using
>
> Item('textstring',editor=CodeEditor())
>
> as it gives a fixed width font which makes it easier to read.
>
>  Is it possible to add search capability?
>
> I tried
>
> Item('textstring',editor=CodeEditor(search='top'))
>
> but that had no effect.
>
> I saw something in a previous set of posts from last Feb (Fred, Gael, 
> Bryce) where Fred was looking to colour code keywords in the editor
> and Gael & Bryce suggested SourceEditor. Can't get SourceEditor to work 
> though as it needs a parent, just trying to work out what that is by 
> looking for
> PythonEditor in pyface.
>
>   

If I remember right, we did a bit of a refactor last summer and replaced 
the CodeEditor with the SourceEditor internally. Its not going to do 
exactly what you want out of the box however- you need to do the search 
yourself, then set the trait that 'selected_line' points to:

class SearchableCode(HasTraits):
(Continue reading)

Brennan Williams | 1 Feb 22:34
Gravatar

Re: viewing text with CodeEditor

bryce hendrix wrote:
> Brennan Williams wrote:
>   
>> I'm using
>>
>> Item('textstring',editor=CodeEditor())
>>
>> as it gives a fixed width font which makes it easier to read.
>>
>>  Is it possible to add search capability?
>>
>> I tried
>>
>> Item('textstring',editor=CodeEditor(search='top'))
>>
>> but that had no effect.
>>
>> I saw something in a previous set of posts from last Feb (Fred, Gael, 
>> Bryce) where Fred was looking to colour code keywords in the editor
>> and Gael & Bryce suggested SourceEditor. Can't get SourceEditor to work 
>> though as it needs a parent, just trying to work out what that is by 
>> looking for
>> PythonEditor in pyface.
>>
>>   
>>     
>
> If I remember right, we did a bit of a refactor last summer and replaced 
> the CodeEditor with the SourceEditor internally. Its not going to do 
> exactly what you want out of the box however- you need to do the search 
(Continue reading)

Brennan Williams | 2 Feb 05:04
Gravatar

Suppressing the view panel in a TreeEditor

I know there is a way/flag for doing this but I've so far failed to find 
it. I want to define a TreeEditor with a set of TreeNodes but just 
display the tree and note the associated panel containing the view for 
the currently selected tree node.

Thanks

Brennan
Warren Weckesser | 2 Feb 06:34
Gravatar

Re: Suppressing the view panel in a TreeEditor

Brennan Williams wrote:
> I know there is a way/flag for doing this but I've so far failed to find 
> it. I want to define a TreeEditor with a set of TreeNodes but just 
> display the tree and note the associated panel containing the view for 
> the currently selected tree node.
>
>   

I think you want the *editable* flag of the TreeEditor:

http://code.enthought.com/projects/traits/docs/html/TUIUG/factories_advanced_extra.html#id25

Warren
shantanu choudhary | 2 Feb 12:18
Picon
Favicon

[Patch] Some typo corrections in docs/source/mayavi/overview.rst

Hello all,

Attached is a small patch related to some typos in overview.rst file.

-- 
Regards
Shantanu Choudhary
759c759,769
< 
---
>         self.proxy_uname = QtGui.QLineEdit()
>         txt = "Enter Username"
>         self.proxy_uname.setToolTip(txt)
>         self.proxy_uname.setWhatsThis(txt)
>         self.proxy_uname.setEnabled(True)
>         self.proxy_pass = QtGui.QLineEdit()
>         txt = "Enter Password"
>         self.proxy_pass.setToolTip(txt)
>         self.proxy_pass.setWhatsThis(txt)
>         self.proxy_pass.setEnabled(True)
>         self.proxy_pass.setEchoMode(QtGui.QLineEdit.Password)
766a777,778
>         proxy_host_port_layout.addRow("&Username:", self.proxy_uname)
>         proxy_host_port_layout.addRow("&Pass:", self.proxy_pass)
783a796,797
>         uname_str = str(self.proxy_uname.text())
>         pass_str = str(self.proxy_pass.text())
787,788c801,802
(Continue reading)

shantanu choudhary | 2 Feb 12:29
Picon
Favicon

Re: [Patch] Some typo corrections in docs/source/mayavi/overview.rst

> Attached is a small patch related to some typos in overview.rst file.
Sorry for trouble, my bad, wrong patch file was attached :(
-- 
Regards
Shantanu Choudhary
Index: docs/source/mayavi/overview.rst
===================================================================
--- docs/source/mayavi/overview.rst	(revision 25186)
+++ docs/source/mayavi/overview.rst	(working copy)
@@ -6,7 +6,7 @@
 .. topic:: Section summary

     This section gives a quick summary of what is Mayavi, and should help
-    you understand where, in this manual, find relevent information to
+    you understand where, in this manual, find relevant information to
     your use case.

 Introduction
@@ -210,7 +210,7 @@
      :ref:`creating data sources with mlab <mlab_data_source>`, or simply
      the 3D plotting functions: :ref:`mlab_plotting_functions`).

-Aternatively, if you whish to gain a deeper understanding by
+Alternatively, if you wish to gain a deeper understanding by
 creating VTK data structures or files, more information on datasets in general
 is available in the :ref:`data-structures-used-by-mayavi` section.

(Continue reading)

Gael Varoquaux | 2 Feb 13:32
Favicon
Gravatar

Re: [Patch] Some typo corrections in docs/source/mayavi/overview.rst

On Tue, Feb 02, 2010 at 04:59:28PM +0530, shantanu choudhary wrote:
> > Attached is a small patch related to some typos in overview.rst file.
> Sorry for trouble, my bad, wrong patch file was attached :(

Applied in revision 25187. Thanks a lot for the patch. Do not hesitate to
submit others to improve our documentation, it is in dire need of love.

Cheers,

Gaƫl

Gmane