mIRC Home    About    Download    Register    News    Help

Print Thread
aligning text #132508 11/10/05 05:53 AM
Joined: May 2005
Posts: 3
S
Steven8604 Offline OP
Self-satisified door
OP Offline
Self-satisified door
S
Joined: May 2005
Posts: 3
I'm having difficulties aligning text on input and on text


e.g.

<nickname1> sjflksjflkjaflkajsdlfkajfdlkjaldfkjalkdjflaksjdflkjasdfj
...................fdjglkdjgsljglskdjlgksdjlkfjg

<nickname2> lkdjglksjdglkjsdljgslkjfglksjdlkgjsldkjgflksjdkgjsdjgg
...................gjlkjglksjdlkgsjdlkgjs

Without the ......................... on the second line tho...

can anyone help ? thanks laugh

Re: aligning text #132509 11/10/05 06:45 AM
Joined: Aug 2005
Posts: 1,052
L
Lpfix5 Offline
Hoopy frood
Offline
Hoopy frood
L
Joined: Aug 2005
Posts: 1,052
Well you cant really seperate or align the text for others to view unless a chr command is entered other wise.. no go

for the char command just add $chr(416) << i believe this is empty space im about 95% sure

so use or do this has an example to your channel..

//say $chr(416) $chr(416) $chr(416) $chr(416) $chr(416) $chr(416) $chr(416) hi

make sure to include both slashes before say otherwise youll be pasting the text itself in channel rather the performing the $chr command action

use more $chr(416) has you go hope this is what your sorta looking for..

it will create a large space as much as you need between text not only through your eyes but others too

im almost sure though your requesting more along the lines of actually aligning all like from here to here and there to there..

IM not sure if the post will allow to show you what i think you mean but here it goes

<dave> hi I love to do fishing
and I love to golf.

instead of <dave> hi I love to do fishing and I love to golf.

or <dave> hi I love to do fishing
and I love to play golf

Re: aligning text #132510 11/10/05 07:54 AM
Joined: Aug 2004
Posts: 21
S
sCHuTt Offline
Ameglian cow
Offline
Ameglian cow
S
Joined: Aug 2004
Posts: 21
TBH, i'd like to see this script when it's finished plz, started many times on something similar but always managed to get it upside down. So I gave up lmfao.

- sChutt

Re: aligning text #132511 11/10/05 07:56 AM
Joined: Sep 2005
Posts: 2,876
H
hixxy Offline
Hoopy frood
Offline
Hoopy frood
H
Joined: Sep 2005
Posts: 2,876
There's only 255 characters available through $chr(), so 456 is NOT a space. $chr(160) is in many fonts.

Original poster: use the /echo -i switch or use $wrap.

Re: aligning text #132512 11/10/05 08:11 AM
Joined: Feb 2004
Posts: 2,019
FiberOPtics Offline
Hoopy frood
Offline
Hoopy frood
Joined: Feb 2004
Posts: 2,019
$chr can be referenced with any number really, it'll always start again with ascii 1 at 256, at 511 etc.

So $chr(416) = $chr(160)

But anyway as you said, it's not a hard space on all fonts, and is the least preferred method.


Gone.
Re: aligning text #132513 11/10/05 09:20 AM
Joined: Apr 2004
Posts: 759
M
Mpdreamz Offline
Hoopy frood
Offline
Hoopy frood
M
Joined: Apr 2004
Posts: 759
also be sure to use a monospaced font this ensures correct alignment.


$maybe
Re: aligning text #132514 11/10/05 09:23 AM
Joined: Sep 2005
Posts: 2,876
H
hixxy Offline
Hoopy frood
Offline
Hoopy frood
H
Joined: Sep 2005
Posts: 2,876
Ah I see. Well it seems pretty pointless to use a number above 255 to me.

Re: aligning text #132515 11/10/05 11:23 AM
Joined: Apr 2003
Posts: 701
K
Kelder Offline
Hoopy frood
Offline
Hoopy frood
K
Joined: Apr 2003
Posts: 701
$chr(256) would be $chr(0) but it doesn't really output much... Normal range is be 0-255, but 256-511, 512-767, etc give same letters.

For OP: as said before, haltdef the default text and use /echo -i to display your own
This should get you started:
Code:
on ^*:TEXT:*:#:{
  haltdef
  var %len = $len($timestamp &lt;&gt; $nick)
  echo -mbflri $+ %len $timestamp $+(&lt;,$nick,&gt;) $1-
}

Re: aligning text #132516 11/10/05 04:26 PM
Joined: Aug 2005
Posts: 1,052
L
Lpfix5 Offline
Hoopy frood
Offline
Hoopy frood
L
Joined: Aug 2005
Posts: 1,052
not only is there those ranges for chr ascii but theres a forgotten range

982-1300 < $chr(1293) is like saying /RAW

so $CHR(1293) quit would be /raw quit


Code:
if $reality > $fiction { set %sanity Sane }
Else { echo -a *voices* }
Re: aligning text #132517 11/10/05 04:42 PM
Joined: Feb 2004
Posts: 2,019
FiberOPtics Offline
Hoopy frood
Offline
Hoopy frood
Joined: Feb 2004
Posts: 2,019
Um no.

$CHR(1293) = $crlf = $chr(13)

You can check out this social engineering exploit thread to see how $crlf (or $lf, which is $chr(10)) is used to send multiple commands to the server at once.

As an example:

//raw privmsg # :bla $+ $crlf $+ notice # :hehe


Gone.
Re: aligning text #132518 11/10/05 06:28 PM
Joined: Aug 2005
Posts: 1,052
L
Lpfix5 Offline
Hoopy frood
Offline
Hoopy frood
L
Joined: Aug 2005
Posts: 1,052
oops your right sorry about that it is crlf


Code:
if $reality > $fiction { set %sanity Sane }
Else { echo -a *voices* }
Re: aligning text #132519 12/10/05 01:28 AM
Joined: Jul 2003
Posts: 655
Om3n Offline
Fjord artisan
Offline
Fjord artisan
Joined: Jul 2003
Posts: 655
I posted an example of how to do this Here, however my example is limited only to on text event.
Somebody else also wrote a similar script to include other events and such, check out Message Extentions


"Allen is having a small problem and needs help adjusting his attitude" - Flutterby