Ticket #3224 (new defect)
mcedit hangs on `Paste output of...`
Reported by: | angel_il | Owned by: | |
---|---|---|---|
Priority: | major | Milestone: | Future Releases |
Component: | mcedit | Version: | master |
Keywords: | Cc: | egmont@… | |
Blocked By: | Blocking: | ||
Branch state: | no branch | Votes for changeset: |
Description
What steps will reproduce the problem?
1) start mcedit
2) mark any text
3) menu Format\Paste output of... or press ALT-u
4) input 'sort', press Enter
What is the expected output?
selected text sorted
What do you see instead?
mcedit hangs...
Change History
comment:2 Changed 10 years ago by egmont
Note that with this change, the name "Paste output of..." is no longer a good name.
Reading this old label, my expectation would be to:
- Insert at the cursor (instead, it inserts at the selection)
- Not to cut the selected text (but it cuts it)
- To have the /dev/null at the comment's input (instead it's the selected text)
A more proper name could be "Filter selection" for example, even though that doesn't suggests that it's also useful when there's no selection and you only care about the output of the app.
Maybe there could be two very similar menu entries, one above the separator line called "Insert output..." which has stdin connected to /dev/null and always inserts at the cursor position, and one called "Filter selection..." for this brand new feature which fails with an error message if no text is selected, just like the current "Sort..." entry.
Note that this brand new change makes the "Sort..." entry superfluous. All it does, compared to the new feature, is that is saves you from typing the four letters "sort", and occupies a precious shortcut key for this. If the dialog at least had a nice UI for the most common sort options so that I don't need to look up the man page...
I'm not sure what would be the best, I leave it up to you, I just wanted to point out some inconsistencies with the suggested approach. Thanks!
comment:3 follow-up: ↓ 4 Changed 10 years ago by angel_il
Note that with this change, the name "Paste output of..." is no longer a good name.
mayby "Apply external filter..."
Maybe there could be two very similar menu entries, one above the separator line called "Insert output..."
maybe need add Flag "Replace selection" ?...
╔ Paste output of external command ╗ ║ Enter shell command(s): ║ ║ _____________________________[^] ║ ║ ║ ║ [x] Replace selection ║ ║ ║ ╟──────────────────────────────────╢ ║ [< OK >] [ Cancel ] ║ ╚══════════════════════════════════╝
Note that this brand new change makes the "Sort..." entry superfluous.
you right, i've been think about too...
branch 3224_mcedit_paste_output_fix
please review