What is missing from Padre?

brian_d_foy on 2008-10-28T17:18:00

I have started to develop Padre about four months ago and version 0.14 that has just arrived to CPAN is already slightly usable.

I'd like to get your help to find out what are the most important things I should focus in the next four months?

I am sure you either use vi or emacs and you are totally satisfied with your development environment but, please for a short time imagine you are stuck in a well paying job and your management mandates you to use Padre.

Please give me the 5 most important things that are still missing from it so you can also say it is usable.

In order to do this obviously you will have to install it which might be a bit difficult if your OS does not come with binary version of wxPerl. On the other hand if you are lucky you'll only have to type cpan Padre, answer a few questions and wait till all the prereqs get installed. For some help with the installation check out the download page.

Thank you for your help


Binary installations

gabor on 2008-10-28T18:04:57

I don't seem to be able to edit the article on the front-page, so here is a little addition:

For those who want to cheat and skip the installation process there is a binary version of Padre for Linux and a Portable Strawberry Perl with Padre for Windows. Both can be found via the same download page.

What is missing from Padre?

taro-nishino on 2008-10-28T18:34:59

As you presumably know, I'm a Japanese.
So, I always need to write Japanese literals into Perl sources,
unfortunately, however, Padre at the moment doesn't support utf8.
The worst downside of Parde missing is not supporting utf8.

Re:What is missing from Padre?

Alias on 2008-10-29T01:15:17

Patches welcome :)

Re:What is missing from Padre?

gabor on 2008-10-29T05:47:52

I have added a small change to Padre that should do the trick. So far I see Hungarian accented characters working fine but they worked earlier as well.

Hebrew on the other hand is still broken:
I can type the letters and sometimes they show up. The direction is unclear but it is not RTL.

All that on Ubuntu with locale being set to UTF-8. On my Windows for some reason I could not install the Hebrew keyboard.

So there is more work to do. Even if you can't patch it I'd appreciate if you checked out from SVN and ran it from there telling us if there is any improvement on your side and/or what is still broken.

My 30 second review

stu42j on 2008-10-29T02:54:23

First thing: auto-indent.

Second: I like that you've got Ack but I'm really loving my Ack/Vim integration so you'll have to be as good. That means hyper-linking the results.

Auto indention.

aero on 2008-10-29T03:56:58

1. "Show indention guide" seems does not work.

2. Auto indention.

Re:Auto indention.

gabor on 2008-10-29T10:21:25

1. "Show indention guide" when set, should show a vertical bar in the text on every line where the indentation is at least 2 levels deep. It worksforme on both Windows and Linux. If you still cannot see, please file a bug with details of your installation.

2. Auto indentation was added. If you have time please check out from Subversion (r562 or later) and let me know if it works for you?

one showstopper, 3 important misses.

jquelin on 2008-10-29T09:40:20

1. detect if a file has been updated outside padre, and prompt user for reload/continue. major showstopper here, since git will happily overwrite files when switching branches.
2. non intrusive search box - either same as vim, or see how firefox implemented it
3. auto-indent & tab manipulation
4. possibility to wrap a paragraph intelligently (what gqip is doing in vim)

Re:one showstopper, 3 important misses.

gabor on 2008-11-04T09:26:12

1. and 2.a (autoindent) are implemented in 0.15 Can you please check and explain what do you mean by tab manipulation?

There are tickets for 3. and 4.

thanks

Re:one showstopper, 3 important misses.

jquelin on 2008-11-04T15:44:42

ok, it detects if file has changed when saving... but that's a bit too late imho. i'd like padre to monitor open files on a regular basis (every 10 seconds?) to warn asap, and propose to reload file / ignore changes.
tab manipulation: ability to change all tabs to spaces. or pressing tab / shift+tab anywhere on a line indents / unindents the line. (or whatever key combination)

file changed on disk

gabor on 2008-11-04T15:56:45

so what happens if the file changed, you get a popup and you say ignore?

Should that stop checking till you save or reload next time?

Should it bugger you every 10 seconds?

Should it warn again only if the file changes again on the disk?

Something else?

Re:file changed on disk

jquelin on 2008-11-04T16:16:44

i'd say it warns again only if the file changes again on the disk.
but that would be a judgement call with stop checking till save/reload.

What a padre needs...

duff on 2008-10-29T20:23:03

  • When I attempt to run my perl programs it says "Only .pl files can be executed" Almost none of my perl programs are named something.pl. But they do all start with a #! line. Padre should have mulitple ways to check the type of file if it's going to do the check.
  • Textmate has a panel on the side (much like where you have the subroutine names now) which allows for filesystem navigation. Such a thing would be useful in Padre. Perhaps have that side panel be tabbed too, with one tab showing the subroutines in the currently selected file and the other tab showing the filesystem. (Or do like textmate and put the list of subs in a pop-up that appears along the bottom of the window)
  • Links to the documentation for perl functions. Clicking on "push" in one of my programs, for instance, should pull up a window the the push docs in it. Bonus points would be doing the same sort of thing but for any arbitrary module that happens to be used.
  • vim-mode :-) I still prefer to use the keyboard ala vi rather than the mouse.
  • integrated test support. I should be able to run tests and if any fail, link directly from the failure report to the failing test.
  • subroutines names should match /\w+(::\w+)*/ Right now it looks like it's only getting the first identifier.

Re:What a padre needs...

duff on 2008-10-29T21:38:10

Ah, it looks like I'm not the only one to have this idea. For a poor-man's version of vim+textmate marriage, see http://vimmate.rubyforge.org/

It's no where near as full featured or as "clean" as I would want it though.

Re:What a padre needs...

Alias on 2008-10-30T03:15:24

Responses:

The .pl files limitation is imposed by the first (pre-document-model) generation of file type code. We should be able to upgrade this fairly easily by adding perl type awareness to the ::Document::Perl class and then upgrading the limitation.

The tabbed list on the right is a want-to-have already, you can see it's currently got that extra space at the top where the tabs should hopefully appear. Additionally, a file tree needs to wait for Project support.

Anything that allows linking to function documentation will also allow us to add documentation for installed modules. I personally think we need to add a bit better support for HTML rendering of POD first though.

Compatibility modes for other programs will probably need to wait for a bit, at least until key commands are configurable.

Integrated test support requires the implementation of Projects first.

syntax highlighting

pshangov on 2008-10-30T16:54:31

Better syntax highlighting: Vim supports highlighting of special characters within regexes and double-quoted strings, which makes it very easy for me to see what is going on in the regex and locate small errors. No other editor on the market currently offers highlighting as rich as in vim, and this is the sole reason why I have not been able to move away from it so far (and I have tried most other IDEs). Scintilla does not offer an easy way to modify syntax highlighting rules, unless you know C (which I don't), so I do not see how that problem can be fixed by the Padre developers.

Note: As I am writing this post I have not been able to install Padre yet, as some failure in my local Module::Build prevents me from installing the last dependencies (App::Ack and Wx::Perl::Dialog) and I am too tired to investigate this today.

Re:syntax highlighting

gabor on 2008-10-31T08:38:17

The default perl5 syntax highlighter of scintilla might not do it for you but with Padre you can actually write your own syntax highlighter in Perl.

So if you have the time for that, it would be great to try to implement such a thing. I'd recommend using PPI. Though Adam said it might be too slow for this purpose and he knows a bit more about PPI than I do :-), you might still beat him at his own game. That would be awesome.

There are very naive syntax highlighters in some of the Padre::Document::* modules that you can look at to see how to colourise() once you know what part you want to be red or green.

Re:syntax highlighting

jrockway on 2008-11-02T03:06:57

FWIW, I have experimented with PPI-based highlighting in emacs. It is fast enough.

Re:syntax highlighting

Alias on 2008-11-02T19:28:24

It may be that if we make sure to disable PPI past a certain threshold (say, more than 1 second of CPU for a reflow, which would happen at around 2000 lines) we could make it fast enough.

Re:syntax highlighting

gabor on 2008-11-05T09:33:52

We just found out that the version of Scintilla we are using does not support 5.10 so we seriously need to look into alternative syntax highlighting.

There is already a first version in place but it is slow.

Could you share your results/experience/code with us?

maybe on #padre ?

Re:syntax highlighting

jrockway on 2008-11-02T03:06:04

No other editor on the market currently offers highlighting as rich as in vim

If by vim, you mean emacs. Trust me, cperl-mode is much more complete than anything vim has.

another 30 second review

notbenh on 2008-10-30T20:54:06

This is my first time playing, so far it seems like a very good start. All the basics are covered and didn't stumble in to anything that would completely stop me from getting work done if this was my only option. That said though there are some things that I find missing when compaired with my current editor of choice (vim + perl-support.vim).

On to the issues, there might be some historical reasons for some decisions that I've missed but here are my thoughts:

  • [install]
    • the ubuntu method described fails post install (Failed to find share dir for dist 'Padre' at /usr/share/perl5/Padre/Frame.pm line 220), an update via CPAN fixed that.
  • [trac]
    • it would be nice to allow anon issue reporting, if I can avoid creating a new account just to report a bug (or allow the use of CPAN's RT).
  • [editor]
    • change font size seems backwards ( '+' decreases, '-' increases).
    • I'll second the .pl restriction as annoying, I just expected the 'run' to just do `perl $file`.
    • for 'run', any shorthand for 'path of current buffer', so that we could at least sidestep the .pl restriction?
    • with perl-support.vim you gain the ability to have little snippits of code that are only a hotkey away, any plans for this kind of feature?
    • expected Ctrl+t to open new tab and Ctrl+n to open new window.
    • it seems that there is no option for line-wrapping.
    • I noticed a bunch of requests for vi key bindings, it would be nice if there was an binding editor that would allow us to 'write our own'.
    • did not see an option for setting tabs => X spaces.

I'll keep playing and see if there's anything else that I can come up with, other then that though it seems like a great editor in the making.

Re:another 30 second review

gabor on 2008-11-04T09:49:12

Thanks for your reply.

some of these already have tickets, for others I opened now.

tabs => X spaces is in Edit/Preferences
change font size fixed but I think only after 0.15 came out
Ctrl+t Ctrl+n swapped, but I think we'll change it back and then give you the option to change it as you want.
You are welcome on #padre or send an e-mail if you really don't want to create an account.

small things, big difference (for me)

garu on 2008-10-31T02:56:22

Here's my take on some things I believe can make a difference, and appear easy enough to be handled in the given timeframe (in my own wishlist order):

- The options already available in the menus (specially "Edit", "View" and "Perl") should really also be available as shortcut icons in the toolbar. Oh, you should also be able to control the toolbar adding/removing icons like (MS|Open)Office, but it's not really a problem for now, so don't bother - just keep it in mind :P

- Enabling/Disabling the right thingie that shows the subroutines via the "View" menu.

- I agree with jquelin, a non intrusive search box (preferably in the toolbar) would be great, like the approaches from vim and firefox.

- I'd also like to be able to set (and load, the latter probably in a submenu from "new") some code templates for new files (for pl, pm, even TT)

- I loved the Module::Starter integration, but it really should be a submenu entry for "new" ("new->module" or "new->module for cpan" or whatever). Also, since you're wrapping the module-starter helper so nicely, why not also wrap the catalyst.pl helper in "new->catalyst project" (or whatever)? Which brings me to the next feature request...

- Projects!

- One last (but not so easy imho) thing, if it's not too much to ask: debugger integration =)

So far you've done an amazing job! Congratulations (and many thanks!)

Re:small things, big difference (for me)

gabor on 2008-11-04T09:53:35

Thanks for your comments. All missing issues were added to trac and see my grant request for debugger integration

why another editor?

jozef on 2008-10-31T18:01:34

1. if my manager will will mandate on using some editor i will just ignore him. that makes no sense.

2. another this that makes no sense is to write another editor these days. gabor why do you waste you talent and time on creating editor??? there are so many to choose and if you are missing some feature - contribute to one.

i'm subscribed to test-automation-tips@szabgab.com since the beginning and there were two post in ~5 months. there is plenty to say about testing. that will be better spend time.

to people looking for editor written in perl i recommend Kephra - http://search.cpan.org/perldoc?Kephra it's working and it has plenty of features already.

Re:why another editor?

Alias on 2008-11-02T19:33:10

Historically, it has been somewhat difficult to contribute to Kephra.

Additionally, the source code for it is rather large and somewhat monolithic.

I certainly feel that there may be some advantages to having a pair of competing editors. Certainly we are already seeing some evidence that they are driving each other forwards to implement things.

(s)FTP access

wirebird on 2008-11-01T14:28:06

Being able to edit files across disparate systems would be spiffy.

Debugger

SuperCruncher on 2008-11-05T10:36:51

I'm quite happy with Vim personally, but would consider using Padre a bit if it supported a debugger similar to the Emacs Perl debugger. It would be fantastic if it could support ActiveState's DBGP remote debugging protocol too.