mIRC Home    About    Download    Register    News    Help

Print Thread
#148308 03/05/06 05:06 PM
Joined: Apr 2006
Posts: 6
P
phs3 Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
P
Joined: Apr 2006
Posts: 6
1) If I paste a line that's too long, it would be nice if mIRC at least warned me that it was cut off (preferably indicating where: "Your message was cut of after '...this is very'"). I often paste long error messages and then get told "I only saw it up to..."

2) I'd like an option to keep mIRC from EVER sending lines pasted, without first prompting (if > 1 line) or just leaving the data on the input line.

What happens is this: I'm pasting something and it may or may not end in a CR. If it does, it's gone, sent, over, done. If not, then I can add closing punctuation etc.

Or I'm pasting multiple lines and sometimes it prompts (if it's more than some number -- maybe this is configurable already, but if so, I haven't found it) and sometimes it doesn't.

The reason behind this is that in most (?) other IM clients, nothing goes until you hit ENTER or click SEND. And I use several, and often wind up pasting stuff in IRC, not expecting it to go. Yeah, if I were trainable, this wouldn't matter ;-)

Anyway, what this would add is a scan for CR in the data (after stripping trailing blanks). If there is only one, at the end of the data, it would be stripped; if there are > 1, then that count would be compared to the count specified as an option (or I'd be satisfied if the option was "always ask before sending multiple lines").

#148309 03/05/06 06:02 PM
Joined: Jan 2005
Posts: 192
Vogon poet
Offline
Vogon poet
Joined: Jan 2005
Posts: 192
Options > Other > Confirm...
[x] Confirm when pasting [__] or more lines of text


echo -a $signature
#148310 03/05/06 06:06 PM
Joined: Dec 2002
Posts: 3,547
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
Do you mean:

mIRC Options (Alt + O) > Other > Confirm > Confirm when pasting [color:blue]N or more lines of text.[/color]

Edit: Brax beat me to it. laugh

#148311 03/05/06 09:13 PM
Joined: Apr 2006
Posts: 6
P
phs3 Offline OP
Nutrimatic drinks dispenser
OP Offline
Nutrimatic drinks dispenser
P
Joined: Apr 2006
Posts: 6
Well, yeah, that's exactly what I mean...! Well, 99% of it. I'd actually like to be able to paste a SINGLE line and *see* it before it goes.

IOW, if:
1) I have 2 lines copied, and I paste, my newly set "Confirm when pasting 0 or more lines of text" will kick in and I'm happy.

2) I have one line copied *with CR" and I have "Confirm when pasting 1 or more lines of text" set: mIRC strips the trailing <cr> and puts the text on the input line, for me to edit/etc.

3) I have one line copied *without CR": same behavior as (2).

#148312 04/05/06 02:00 PM
Joined: Jan 2005
Posts: 192
Vogon poet
Offline
Vogon poet
Joined: Jan 2005
Posts: 192
Use multi-line editboxes then smile

Options > Display > Options [x] Multi-line editboxes


echo -a $signature
#148313 08/05/06 03:47 AM
Joined: Sep 2003
Posts: 149
S
Vogon poet
Offline
Vogon poet
S
Joined: Sep 2003
Posts: 149
Quote:
1) If I paste a line that's too long, it would be nice if mIRC at least warned me that it was cut off (preferably indicating where: "Your message was cut of after '...this is very'"). I often paste long error messages and then get told "I only saw it up to..."
This is something that mIRC doesn't know. The server is what cuts off the lines, and every server uses a different legnth. The way I have solved this, was to make a script that automatically splits my lines into 2 or more lines if they are too long.

Quote:
2) I'd like an option to keep mIRC from EVER sending lines pasted, without first prompting (if > 1 line) or just leaving the data on the input line.
Done with the "confirm paste" feature


mIRC 6.21 - Win XP Pro (SP2) - 2.4 Ghz - 1 GB Mem
irc.x-tab.org
#148314 08/05/06 02:20 PM
Joined: Oct 2005
Posts: 1,741
G
Hoopy frood
Offline
Hoopy frood
G
Joined: Oct 2005
Posts: 1,741
Here is a scripted solution. It may not be perfect, but it should do most of what you wanted.

Code:
on *:CONNECT:.msg $me $+(MLT-,$str(º,512))
on me:^*:NICK:.msg $newnick $+(MLT-,$str(º,512))
on me:^*:TEXT:MLT-º*:?:{ set $+(%,MCL.,$cid) $len($gettok($rawmsg,3-,32)) | haltdef }
on *:DISCONNECT:unset $+(%,MCL.,$cid)
alias maxchars return $iif($($+(%,MCL.,$cid),2),$ifmatch,512)

on *:INPUT:#:{
  if (($inpaste) &amp;&amp; (!$input(Warning: Do you want to display this line?,y))) halt
  if ((/* iswm $1) &amp;&amp; (!$ctrlenter)) return
  var %mcllines = $ceil($calc($len($1-) / $maxchars))
  var %mcllen = $floor($calc(($len($1-) + $len($str($target $+ ..,%mcllines))) / %mcllines)))
  var %mclpre = $calc(%mcllen - $len($target $+ $chr(32)))
  while ($left($1,%mclpre)) {
    msg $target $v1
    tokenize 32 $right($1,$+(-,%mclpre))
  }
  halt
}


-genius_at_work


Link Copied to Clipboard