Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??
My thoughts on this are pretty straight-forward, and it looks like you've got some of the same ideas in the ticket.

My suggestion would be to look for the use of several different line-endings in the same file and if found, display a dialog informing the user of the counts of each type of line ending with a radio-button next to each type. The default selection for this dialog could be several different things, depending on how you look at it. Anyhow... offer to change all endings to the selected ending, or ignore the discrepancy.

Of course, this feature should be able to be switched off in Padre's preferences.

Regarding the default selection in the dialog, I personally would have a "default line-ending for new files" setting in Padre's preferences with the usual options, and the default of the dialog would be whatever this was set to.

Something that could be nice for newbies could be to somehow annotate, both in Padre's prefs and in the "mixed line-endings" dialog, what the "native" line-ending is for their platform.

Something else I'd probably add is perhaps a little help-button to explain to the novice *why* having mixed line-endings is a bad idea and why it should be fixed, along with what could go wrong (yep, I've seen programmers mix them *on purpose*, with the code depending on it, the bastards ...)

So, that's my $.02... I'm no design guru but I play one on TV.

In reply to Re: maintaining newlines in file by Hercynium
in thread maintaining newlines in file by szabgab

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others browsing the Monastery: (2)
As of 2024-04-25 06:03 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found