mirror of
https://github.com/weechat/weechat.git
synced 2026-06-17 08:34:46 +02:00
Compare commits
548 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| d13e2328b1 | |||
| 1838637f24 | |||
| 6beb0f1cb0 | |||
| b0260b6494 | |||
| fe2bb8516b | |||
| 9eb6643f63 | |||
| d2f855b7ee | |||
| 586e89b191 | |||
| f6bb78a3b2 | |||
| 1c9456f2a7 | |||
| 545fa4c332 | |||
| ec9da8cc85 | |||
| 2322eb0625 | |||
| 0eea93bba3 | |||
| 1bc71392c4 | |||
| 94a5c72590 | |||
| 15f75d157c | |||
| 7e802070ca | |||
| c2dd7e4ffb | |||
| 524fbba036 | |||
| 87aa03b2cf | |||
| a47e4a9567 | |||
| 88fd88373d | |||
| ed5f70aa6a | |||
| 8659d94965 | |||
| 949c4f72e0 | |||
| a4650a7f92 | |||
| 127edfb0fe | |||
| 631eab3c66 | |||
| 1418897108 | |||
| f4ab9dcc33 | |||
| d88ad92c72 | |||
| 01aa8472c0 | |||
| c1ce18e2f6 | |||
| bdaaa6182f | |||
| c7a8d68f70 | |||
| 78ca78855e | |||
| 293bf5988b | |||
| 65b4c157d1 | |||
| e36b53bf74 | |||
| 59cddf7a40 | |||
| dce5e4fa18 | |||
| 5d08d5e27c | |||
| 93e69f5b3e | |||
| beb846884c | |||
| 343e7fe59d | |||
| 057cffe9f0 | |||
| 86c2fb3031 | |||
| b7ba64c744 | |||
| 7d944ceca4 | |||
| 6172338bb7 | |||
| 27f45cdc6a | |||
| 9761177a2c | |||
| 3352658af4 | |||
| b314ee0f43 | |||
| 758f7f0103 | |||
| b33e8c6482 | |||
| 23f3622f2c | |||
| 6021ee85cb | |||
| bcee678a56 | |||
| 40ffeb9e0c | |||
| fb0e3a4e95 | |||
| daf2087164 | |||
| a17a5337dc | |||
| a56d65a7c0 | |||
| 5af8e4f6e7 | |||
| a065de071c | |||
| 22d8c1017b | |||
| 9481ec0c9c | |||
| f80489f469 | |||
| 2fd53dcc37 | |||
| b34bb801dc | |||
| 14fdcc5157 | |||
| 0b523df418 | |||
| b81b747b96 | |||
| 0da4487a11 | |||
| f2258884d9 | |||
| 1bee0ba0b2 | |||
| 69730a21dd | |||
| d6459aa638 | |||
| 58a1fc72db | |||
| 1bc997b238 | |||
| 1f03444a6b | |||
| c525b231e4 | |||
| 6963ca7b65 | |||
| 99d86d64ab | |||
| 94face39a6 | |||
| 2a34684bc1 | |||
| 5068f4d365 | |||
| 212ec7a76d | |||
| 08b0272a9b | |||
| d01081241a | |||
| 8ef6192b49 | |||
| f98d66a842 | |||
| 6175a89580 | |||
| 23bfafed6a | |||
| fccefcdf04 | |||
| d86af240fa | |||
| c803419616 | |||
| cc324abb75 | |||
| 8c8a4104f0 | |||
| 83bdd97916 | |||
| 56af0e3284 | |||
| 9abddbb7e9 | |||
| c0b6a23959 | |||
| 173c7f7f2e | |||
| eaa33bfb8e | |||
| fcd3809326 | |||
| 8d4497a764 | |||
| d9c032fee3 | |||
| 9fb1176b1b | |||
| 9ed873ed94 | |||
| 27fd4beca7 | |||
| 6a55ee4f79 | |||
| 4a13abcc9b | |||
| e499c1cb32 | |||
| 12b0742668 | |||
| 04e9677405 | |||
| 3ff8d488e7 | |||
| a4ee390737 | |||
| 2b99338176 | |||
| 1314c8e78e | |||
| 0277a1eb62 | |||
| c4bafd3eef | |||
| d006811b8e | |||
| 2c894b89e7 | |||
| 02d4287ad0 | |||
| 7fa3dcbb2e | |||
| 031fab21b0 | |||
| ea06fca69c | |||
| 4181fa3f74 | |||
| b9e247794e | |||
| d6e562ed7e | |||
| 227c05447f | |||
| 1005890db2 | |||
| 8f714033ac | |||
| 1a510e1598 | |||
| 650805f204 | |||
| 919800c37c | |||
| 92db79989e | |||
| 5d32ac0d57 | |||
| bd1685a8fe | |||
| 312ad619ae | |||
| e4cc182105 | |||
| 8c662f69f9 | |||
| 5c29def9d9 | |||
| c0a1673060 | |||
| 3a79e32dbb | |||
| 349d9d1028 | |||
| 13ddcc3adc | |||
| 9373a7a47e | |||
| e0c97562a5 | |||
| 3a213f38ec | |||
| 484274d65f | |||
| 4f81254e40 | |||
| da3f8ade08 | |||
| 271d1c905f | |||
| ae0e17cfe2 | |||
| d69c634d2f | |||
| 14c9afb990 | |||
| c491b39388 | |||
| 8855d39f44 | |||
| 91af3fe728 | |||
| a62a002522 | |||
| f79653db8e | |||
| 0538215157 | |||
| fa02f128ec | |||
| 06ecdfdd35 | |||
| 00eef1c1bc | |||
| e7fd1a0cb7 | |||
| 321a8a65ad | |||
| e7f730387f | |||
| e4eeaaf1dd | |||
| 4c34ac5d8f | |||
| 73990d8caa | |||
| d4e755a641 | |||
| 4a4daf6931 | |||
| 8ddc5afb21 | |||
| a5cef6abde | |||
| 13a6d5b833 | |||
| 47b7b1d578 | |||
| c0a7e4445c | |||
| 80d6b1d952 | |||
| 75eb47ee9e | |||
| 6013e43292 | |||
| 9150cff430 | |||
| 480974b8de | |||
| abeb5a2f48 | |||
| 4aac135244 | |||
| f222a6ad7a | |||
| fe5731dc84 | |||
| 70ad116c0f | |||
| 99a3434733 | |||
| 0e91f0c208 | |||
| 7711d548c0 | |||
| a7479272f0 | |||
| 2e1c6023d7 | |||
| 464fc8abdf | |||
| 1e4c1a7073 | |||
| 1607c44e75 | |||
| 364d774ded | |||
| 6972b057d9 | |||
| 8cd8410448 | |||
| 1cbdbffa40 | |||
| 3c16d49d2d | |||
| 083ede73fd | |||
| 5aeb7921fe | |||
| e907b3b7a5 | |||
| be6594afb7 | |||
| f6d46b8792 | |||
| 83852ca3ab | |||
| a4695f5ba2 | |||
| 8c54d55611 | |||
| 8b5137ddeb | |||
| b3b1ab104b | |||
| 05992a34f3 | |||
| 224cd3ff59 | |||
| b1f83dce8a | |||
| dd39ac2432 | |||
| 05456cc54e | |||
| 3fd569a83e | |||
| 978efc0d4f | |||
| b409b42470 | |||
| 0369660c0e | |||
| 457c786fbe | |||
| 4d62625894 | |||
| d875b52124 | |||
| 1704595452 | |||
| d06e847efe | |||
| b10b53c689 | |||
| 96a9a1df90 | |||
| 70e0f05ff2 | |||
| 43093b13fa | |||
| c771db23fe | |||
| 18e47000f4 | |||
| ac8c68bd68 | |||
| 4f0dc2984b | |||
| 88ee7addbc | |||
| d3bfff3d65 | |||
| b0d10367d3 | |||
| 63d728a6a1 | |||
| 503350f46b | |||
| 7c1c8cd874 | |||
| d280bf2a92 | |||
| f4513bbadd | |||
| 77b504cd3f | |||
| 04fda8a314 | |||
| d5b58ff068 | |||
| 6eabc3aa61 | |||
| c08c40a1c6 | |||
| 1c4056a3b6 | |||
| 756f7354e9 | |||
| ceaf9fa287 | |||
| 54baad1848 | |||
| 11da868d70 | |||
| acb40634b0 | |||
| 290c603321 | |||
| 77e00d0381 | |||
| b8662d79c2 | |||
| f9a4a0dd01 | |||
| 59f6997cf0 | |||
| 76891f9037 | |||
| b7286b7e9f | |||
| c1b4ccace4 | |||
| 1984e7f0f5 | |||
| 7a80558d0f | |||
| 0ef010d211 | |||
| 6c7a71976b | |||
| 74b84ae163 | |||
| 81224d9397 | |||
| a114b7adc3 | |||
| 8e696af49a | |||
| 4f1e90f68f | |||
| 6efb8e4439 | |||
| c005d8c4d3 | |||
| 816fac5084 | |||
| b821783bbf | |||
| 62bc46cb1d | |||
| a477f29cf8 | |||
| ea3d7c278d | |||
| 6cfb01f363 | |||
| f035f768ad | |||
| b38f7b6d17 | |||
| 163ded5658 | |||
| 80ed16c3c0 | |||
| 1b7f628457 | |||
| 578a57812f | |||
| 83b82e1d7d | |||
| 4ea27db1d7 | |||
| 470e8a0296 | |||
| 9f0aedd319 | |||
| c71f869106 | |||
| e750eaecfa | |||
| 5a970dffbb | |||
| d5affecc23 | |||
| 967d436a1d | |||
| ef0e468415 | |||
| 2229d34110 | |||
| f29a08bc47 | |||
| 6d931f27c3 | |||
| 3eaf388bce | |||
| cea353d34d | |||
| 85f20851d8 | |||
| f2402d4be2 | |||
| 0cf9d16bb9 | |||
| fd7d98134d | |||
| 8cab953c6f | |||
| b81fa36a5c | |||
| e63da66644 | |||
| 3a2fdde999 | |||
| 4df45530c3 | |||
| d73597d69f | |||
| 47c3266952 | |||
| b081d831e6 | |||
| 9b371e9ae7 | |||
| 483d4670e1 | |||
| 92a2a0774c | |||
| f5a20d282e | |||
| ed76104d42 | |||
| 04206f8032 | |||
| 54a5f181b5 | |||
| dd735af7f8 | |||
| 87fb462f35 | |||
| b3018f8ae7 | |||
| 1f363eeb24 | |||
| f5ecafd6a8 | |||
| c8361419b8 | |||
| 10161cd16c | |||
| a83507eb77 | |||
| 159371cbd9 | |||
| 78c110ace2 | |||
| 83b7741ef2 | |||
| 64c1dbba0e | |||
| 6eb449b370 | |||
| 2bbc2d53eb | |||
| 68cf327088 | |||
| bf3f696830 | |||
| 3bca573d49 | |||
| ba98dca08a | |||
| 4812123dc5 | |||
| ed1755eacc | |||
| bd80891676 | |||
| 8a2a0ec0ae | |||
| e49b4131f2 | |||
| a164b85e3a | |||
| b0758b6fac | |||
| 5830b0ab40 | |||
| d94a7d05ea | |||
| bea5769a05 | |||
| fd562722d0 | |||
| 639d8b3ba9 | |||
| b536a8a491 | |||
| 51cacc0fdb | |||
| e07859395f | |||
| 7cf7e5b9ff | |||
| 87e934766b | |||
| e4b59681b2 | |||
| dd8ce32004 | |||
| b575a4f578 | |||
| 6b1f5a4a92 | |||
| dd3977367f | |||
| 8a9e8ecc88 | |||
| 5dfab7643d | |||
| cea0851071 | |||
| 6919005d74 | |||
| 8497d25d34 | |||
| 4ea734a376 | |||
| 3369a00959 | |||
| a6d93cf432 | |||
| e6a1bb4694 | |||
| 6b6def5890 | |||
| be1c9be925 | |||
| e5754e1fe6 | |||
| c0e4ba60d7 | |||
| 5f101c3833 | |||
| 079e4a4028 | |||
| 24ceb3bb95 | |||
| dec92aeba6 | |||
| 5551542566 | |||
| 9411a2fad0 | |||
| ee4f5716d3 | |||
| e26772dcdb | |||
| 232b5684ca | |||
| 93b2be7a41 | |||
| b86c95e7dc | |||
| 9d52621c44 | |||
| 0e6b0a3b0c | |||
| e081a6af17 | |||
| 3f3a202739 | |||
| 0f055b087a | |||
| 0e531f5e6a | |||
| c2f4bdd0fc | |||
| 32a7fbb767 | |||
| b7484eeea7 | |||
| f7872a9dd8 | |||
| cde66456fb | |||
| 6beb8b6465 | |||
| 1a140ab8b5 | |||
| e148a40ae1 | |||
| ee2951bf11 | |||
| 73359fcc05 | |||
| 0bc32f561b | |||
| d179625e52 | |||
| bd9cdeec5c | |||
| a9f04c5fd9 | |||
| 1e382ab9bd | |||
| 2855b71520 | |||
| 7b4453a507 | |||
| aeb7170024 | |||
| 357d7c5a2f | |||
| b2ec60110c | |||
| 9eb142036e | |||
| fa54807ef6 | |||
| 11d77e6168 | |||
| 2ca5b4f651 | |||
| 38e2003a17 | |||
| 7bb815a540 | |||
| 5a3976d6a5 | |||
| cdc33d08b0 | |||
| 5130b1dc4f | |||
| cdfc5b6c5a | |||
| 50ef2b0306 | |||
| b25824eb4f | |||
| 97a1d0e79d | |||
| 219e9d443a | |||
| 77d50aef98 | |||
| eea49832ea | |||
| 16389e0728 | |||
| 4a7b3436ae | |||
| 799bb14928 | |||
| 75c58c423c | |||
| 63e73b30ad | |||
| 29006d8cec | |||
| 85b1702077 | |||
| caff3dd011 | |||
| 9d4300c0d7 | |||
| 8aa7e3e3e6 | |||
| 150c5e9749 | |||
| 6bec96cd4d | |||
| 068284dd19 | |||
| 38a8c321c0 | |||
| 0094d143b3 | |||
| 530dc9fb67 | |||
| 96a69fd7f3 | |||
| 938915d387 | |||
| 25bbe3d284 | |||
| 9c7d05f605 | |||
| c953db4d64 | |||
| 9d6ca20478 | |||
| 7f4a213239 | |||
| e18f14e5d3 | |||
| 8f3455d0a9 | |||
| dfbea2850a | |||
| 8a299adb3b | |||
| a29416e352 | |||
| c346216e34 | |||
| da7df57b1a | |||
| 61fac4d49e | |||
| 4f5c1b6e09 | |||
| 2962a8e6c8 | |||
| 76263dc7cf | |||
| 554fa728ae | |||
| 5881048405 | |||
| c517253a72 | |||
| fe16f6d48f | |||
| f276fd9494 | |||
| 517de7ab94 | |||
| 06463e5937 | |||
| d80c8e9e57 | |||
| f74b280a1f | |||
| cd4f50c136 | |||
| 767e378c53 | |||
| 60503d9383 | |||
| 11321acb96 | |||
| 84b1a27265 | |||
| 51322e7917 | |||
| d256d72eef | |||
| 8a61b0eee0 | |||
| d4ecb032d4 | |||
| 3f946e304d | |||
| 97b6bbcb9e | |||
| 357edc193e | |||
| ace03b808d | |||
| 428cfbc297 | |||
| 02cd829c4c | |||
| 17973de52a | |||
| 364667f788 | |||
| 10d7c6c34a | |||
| 38fa7c93ac | |||
| 9e328d3fef | |||
| 312d8015f5 | |||
| 110aa59ca8 | |||
| 89b955c79e | |||
| 3d724fb634 | |||
| 29d0225e4a | |||
| 8416212077 | |||
| c36f08d7d7 | |||
| 1230735c5f | |||
| 77d7b703de | |||
| 60db73c19a | |||
| a9ca2987bb | |||
| 220308e1fa | |||
| 8166d15235 | |||
| 575525d965 | |||
| 6271304832 | |||
| bdf9eadf43 | |||
| 15ea11b57b | |||
| f3390da5e3 | |||
| eeff957278 | |||
| 1eac6d8fdd | |||
| 23696b44da | |||
| 63ffae72af | |||
| 376c8a29d6 | |||
| 8b1e3b9890 | |||
| 1b2c5571e6 | |||
| 4c6c367557 | |||
| 99ad719ab9 | |||
| a68a1f8192 | |||
| 930c40eae1 | |||
| 9238a37351 | |||
| a7c4c7237c | |||
| a9912cd266 | |||
| 1d07964d17 | |||
| 06bd0f9f0e | |||
| 4b1679900a | |||
| 99f03cd2a3 | |||
| 3d41a3fa2f | |||
| 089b167573 | |||
| fc2d9732e5 | |||
| 94a3b5e1ae | |||
| 6b12f19083 | |||
| 8a6d35cf12 | |||
| d286f3922c | |||
| 505b43d15b | |||
| 07a820ced6 | |||
| df6a41566b | |||
| 263606fffb | |||
| d4d065253e | |||
| 673e7680af | |||
| ad1120c84c | |||
| f2a78ebc16 | |||
| fef0932c1d | |||
| 96bd473887 | |||
| 89d107c1a9 | |||
| 54d4fc12a6 | |||
| 55125beee4 | |||
| a724278215 | |||
| e3799797ef |
@@ -14,34 +14,34 @@ Developers:
|
||||
AIM : FlashCode AIM
|
||||
Yahoo : FlashCode_Y
|
||||
|
||||
* Python plugin
|
||||
* Scripts plugins
|
||||
|
||||
Kolter <kolter@free.fr>
|
||||
Kolter <kolter@openics.org>
|
||||
Web : http://kolter.free.fr
|
||||
IRC : nick is "kolter" @ irc.freenode.net
|
||||
Jabber: kolter@jabber.org
|
||||
Jabber: kolter@im.openics.org
|
||||
|
||||
|
||||
Debian packager:
|
||||
---------------
|
||||
|
||||
Julien Louis <ptitlouis@sysif.net>
|
||||
IRC : nicks are "ptitlouis" or "tioui" @ irc.freenode.net
|
||||
IRC : nick is "ptitlouis" @ irc.freenode.net
|
||||
Jabber: ptitlouis@amessage.info
|
||||
|
||||
|
||||
Testers:
|
||||
-------
|
||||
Contributors:
|
||||
------------
|
||||
|
||||
Bounga <bounga@altern.org>
|
||||
Web : http://bounga.ath.cx
|
||||
IRC : nick is "Bounga" @ irc.freenode.net
|
||||
Jabber: Bounga@jabber.org
|
||||
ICQ : 178297842
|
||||
|
||||
Xahlexx <xahlexx@weeland.org>
|
||||
Web : http://www.weeland.org
|
||||
IRC : nick is "xahlexx" @ irc.freenode.net
|
||||
Rudolf Polzer <rpolzer-rp@durchnull.de>, IRC: "divVerent"
|
||||
Jiri Golembiovsky <golemj@gmail.com>, IRC: "GolemJ"
|
||||
Jim Ramsay <i.am@jimramsay.com>, IRC: "lack"
|
||||
Odin <odin@dtdm.org>, IRC: "Odin"
|
||||
Pistos, IRC: "pistos"
|
||||
Gwenn, IRC: "gwenn"
|
||||
Voroskoi, IRC: "voroskoi"
|
||||
Frank Zacharias
|
||||
Pavel Shevchuk, IRC: "Stalwart"
|
||||
|
||||
|
||||
=====
|
||||
|
||||
@@ -1,12 +1,5 @@
|
||||
WeeChat - Wee Enhanced Environment for Chat
|
||||
===========================================
|
||||
|
||||
WeeChat known bugs, 2005-05-21
|
||||
|
||||
- ./configure does not check that Gtk 2.0 libraries are installed
|
||||
- when quitting WeeChat term title is not restored (if look_set_title is ON)
|
||||
- command name for /server can not contain spaces
|
||||
- wrong alias is not created and not saved when quitting WeeChat
|
||||
- when many WeeChat are launched, log file is not properly written (cleared by
|
||||
each WeeChat at startup)
|
||||
- display problems with old Konsole versions (Kde terminal) (???)
|
||||
WeeChat known bugs:
|
||||
please look at https://savannah.nongnu.org/bugs/?group=weechat
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
Version 2, June 1991
|
||||
|
||||
Copyright (C) 1989, 1991 Free Software Foundation, Inc.
|
||||
59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
Everyone is permitted to copy and distribute verbatim copies
|
||||
of this license document, but changing it is not allowed.
|
||||
|
||||
@@ -305,7 +305,7 @@ the "copyright" line and a pointer to where the full notice is found.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
|
||||
|
||||
Also add information on how to contact you by electronic and paper mail.
|
||||
|
||||
@@ -1,8 +1,201 @@
|
||||
WeeChat - Wee Enhanced Environment for Chat
|
||||
===========================================
|
||||
|
||||
ChangeLog - 2005-06-30
|
||||
ChangeLog - 2006-05-25
|
||||
|
||||
Version 0.1.9 (2006-05-25):
|
||||
* fixed /squery command (message sent to server, now ok with # args > 2)
|
||||
* fixed /alias command (with an alias name, display content)
|
||||
* improved lua plugin detection (bug #16574)
|
||||
* added backtrace when WeeChat crashes, log file automatically renamed
|
||||
* added lock for log file (~/.weechat/weechat.log), only one WeeChat
|
||||
process can use this file (bug #16382)
|
||||
* fixed crash with malformed UTF-8 strings
|
||||
* fixed crash with ncurses color when too many colors defined in ncurses
|
||||
(bug #16556)
|
||||
* added new key to find previous completion (shift-tab by default)
|
||||
* fixed bug with long outgoing IRC messages (> 512 bytes) (bug #16358)
|
||||
* fixed Ruby crash when handler does not return OK or KO (bug #16552)
|
||||
* fixed UTF-8 display bug with chars using more than one cell on screen
|
||||
(bug #16356)
|
||||
* fixed display bug with DCC file size when > 1 Gb
|
||||
* fixed refresh bug (deadlock in curses) when terminal is resized
|
||||
(bug #16542)
|
||||
* fixed nicklist sort bug
|
||||
* added russian translations (thanks to Pavel Shevchuk)
|
||||
* added german doc (thanks to Frank Zacharias)
|
||||
* added missing IRC commands (006, 007, 290, 292, 310, 379, 437, 974)
|
||||
* fixed crash when multiple pv have same name: now it's forbidden
|
||||
and pv buffer is not renamed (when a nick changes) if another
|
||||
exists with same name (bug #16369)
|
||||
* command /clear [-all] now clears hotlist
|
||||
* fixed crash after /upgrade if a line in history is empty (bug #16379)
|
||||
* fixed many crashes with DCC chat (bug #16416)
|
||||
* added new option to customize input prompt
|
||||
* added nick modes
|
||||
* fixed commands 332, 333 (/topic now ok when channel is not opened)
|
||||
* removed color encoding and charset conversion for commands (only
|
||||
allowed in text sent to channel/private)
|
||||
* added hostnames associeted to nicks (available for /ban completion)
|
||||
* added "+p" mode for channels, fixed mode display in status bar
|
||||
* added nick alignment options
|
||||
* fixed /names command: now displays result when not on a channel
|
||||
* fixed refresh bug (too many refresh) when terminal is resized
|
||||
* fixed nicklist display bugs when on top or bottom of chat window
|
||||
* added keyboard handler to plugin API
|
||||
* improved script plugin loader
|
||||
* added hostname/IP option for connection to server
|
||||
* fixed --disable-plugins option in configure script
|
||||
* added /setp command (set plugin options)
|
||||
* fixed high CPU usage when running under a screen that has been killed
|
||||
* aliases are executed before WeeChat/IRC commands, /builtin command added
|
||||
* added /cycle command, /part command does close buffer any more (use
|
||||
/buffer close (or alias /close) to part and close buffer
|
||||
|
||||
Version 0.1.8 (2006-03-18):
|
||||
* improved Ruby plugin
|
||||
* fixed /set command when internal server name contains one or many dots
|
||||
* fixed get_info plugin API function when no server at all is opened
|
||||
* fixed display bug when top of buffer is displayed and first line is
|
||||
removed (according to "history_max_lines" setting)
|
||||
* fixed /mode command output
|
||||
* improved alias completion (now uses target command for completion)
|
||||
* fixed completion problem in private with nicks
|
||||
* added missing IRC command (487)
|
||||
* added inactivity time, available for plugins via get_info("inactivity")
|
||||
* keys alt-{home|end} to scroll top/bottom, alt-{f11-f12} to scroll
|
||||
nicklist top/bottom
|
||||
* added special names for plugin message handlers: weechat_pv,
|
||||
weechat_highlight, weechat_ctcp, weechat_dcc
|
||||
* script plugins now load scripts in WeeChat system share directory
|
||||
* /msg command does not open any buffer any more
|
||||
* fixed crash when using global history (when older entry is removed)
|
||||
* added IRC raw data buffer (new key: alt-J + alt-R)
|
||||
* fixed display bug with /kill command
|
||||
* added new plugins functions: add_timer_handler, remove_timer_handler,
|
||||
remove_infobar
|
||||
* plugin messages handlers now called when message is ignored (by /ignore)
|
||||
* new behaviour for messages ignored by a message handler: now WeeChat
|
||||
executes standard handler, treating message as "ignored"
|
||||
* many commands allowed for aliases
|
||||
* many commands allowed when connecting to server
|
||||
* added Lua script plugin
|
||||
* added functions in plugins API: get_server_info, free_server_info,
|
||||
get_channel_info, free_channel_info, get_nick_info, free_nick_info
|
||||
* added option "look_nick_complete_first" (patch from Gwenn)
|
||||
* added option "look_open_near_server" (patch from Gwenn)
|
||||
* fixed bug with /upgrade and servers buffer
|
||||
* fixed bug with "get_dcc_info" plugin interface function
|
||||
* added new scroll keys for a few lines up/down (default: meta-pgup/pgdn)
|
||||
(patch from Pistos)
|
||||
* added new option "irc_away_check_max_nicks" to disable away check on
|
||||
channels with high number of nicks (patch from Gwenn)
|
||||
* added new command line argument for setting WeeChat homedir (-d or --dir)
|
||||
(patch from Gwenn)
|
||||
* fixed bug with charset in infobar highlights
|
||||
* fixed bug with buffer detection in plugins/scripts commands
|
||||
* fixed bug with /history command
|
||||
* added option "irc_show_away_once", to show away message only once in pv
|
||||
* added partial hungarian translation
|
||||
|
||||
Version 0.1.7 (2006-01-14):
|
||||
* fixed msg command (now allowed in private buffer with "*" as target)
|
||||
* removed "irc_default_msg_away" setting, for RFC 2812 conformity
|
||||
(/away command wihtout argument only removes away status),
|
||||
new values for "irc_display_away" (off, local, channel)
|
||||
* fixed refresh bug with Solaris when term size is changed
|
||||
* replaced Texinfo doc by XML Docbook
|
||||
* added color for window separators (when splited)
|
||||
* added completion system for plugins/scripts commands
|
||||
* fixed plugins autoload
|
||||
* added charset by server and channel, new command: /charset
|
||||
* added Ruby script plugin
|
||||
* added /upgrade command
|
||||
* added ETA (Estimated Time of Arrival) for DCC files
|
||||
* /nick command is now allowed when not connected to server
|
||||
* added server/channel arg to /buffer command for jumping to buffer
|
||||
* fixed display bug in chat window when a message length equals to window
|
||||
width
|
||||
* added new keys for switching to other windows: alt-W followed by
|
||||
alt-{arrow}
|
||||
* added new keys for scrolling to previous/next highlight: alt-P / alt-N
|
||||
* added "read marker": an indicator for first unread line in a
|
||||
server or channel buffer (new key alt-U to scroll to marker)
|
||||
* new window maganement: custom size for windows, auto resize when
|
||||
terminal is resized
|
||||
* fixed infinite loop when resizing term to small size
|
||||
* added /history command
|
||||
|
||||
Version 0.1.6 (2005-11-11):
|
||||
* new color management system, IRC colors are now correctly
|
||||
displayed and can be removed by new options irc_colors_receive
|
||||
and irc_colors_send
|
||||
* fixed scroll problem when one line is bigger than screen size
|
||||
* added setting for having one server buffer for all servers
|
||||
(look_one_server_buffer)
|
||||
* added setting for ignoring some chars when completing nicks
|
||||
* fixed IRC message parser bug
|
||||
* signal SIGPIPE is now ignored
|
||||
* added partial match for highlights
|
||||
* added dcc_own_ip and dcc_port_range settings
|
||||
* full UTF-8 support, auto-detection of UTF-8 usage (locale)
|
||||
* added "Day changed to [date]" message when day changes
|
||||
* new plugin interface, rewritten from scratch: now loads dynamic C
|
||||
library, and perl/python are script plugins
|
||||
* log options (for server/channel/private) can now be set while
|
||||
WeeChat is running
|
||||
* added channel modes +e and +f
|
||||
* added some missing IRC commands, fixed command 367
|
||||
* added colors for input buffer and current channel of status bar
|
||||
* added online help for config options (with /set full_option_name)
|
||||
* enhanced "smart" hotlist, with names (new options:
|
||||
look_hotlist_names_{count|level|length})
|
||||
|
||||
Version 0.1.5 (2005-09-24):
|
||||
* added /ame command (send CTCP action to all channels of all
|
||||
connected servers)
|
||||
* added setting "irc_notice_as_pv" to see notices as pv
|
||||
* added nicks colors in setup file
|
||||
* fixed DCC bug: delete failed file only if really empty (on disk)
|
||||
* fixed IRC message parser bug
|
||||
* fixed scroll problem (screen moving when scrolling and new line
|
||||
displayed)
|
||||
* fixed infinite loop when scrolling back and displaying long lines
|
||||
* fixed crash when closing a buffer used by more than one window
|
||||
* added some missing IRC commands
|
||||
* fixed DCC display bug (now decodes string according to charset)
|
||||
* added /ignore and /unignore commands
|
||||
* fixed bug with strings comparison (str[n]casecmp) and some locales
|
||||
(like turkish), now using ASCII comparison (thanks to roktas)
|
||||
* signal SIGQUIT is now ignored
|
||||
* fixed refresh bug when one line is bigger than screen size
|
||||
* fixed look_nicklist_min_size and look_nicklist_max_size options
|
||||
* fixed refresh bug when changing channel modes
|
||||
* jump to next server now saves current channel buffer for each server
|
||||
* ctrl-up/ctrl-down keys added to call previous/next command in global
|
||||
history (common to all buffers)
|
||||
|
||||
Version 0.1.4 (2005-07-30):
|
||||
* join and part/quit prefixes (arrows) now displayed with different colors
|
||||
* added "irc_highlight" setting, to get highlight with any word
|
||||
* fixed auto-rejoin for channels with key
|
||||
* fixed /ctcp command (now any command/data allowed)
|
||||
* added /amsg command (send text to all channels of all connected servers)
|
||||
* fixed SIGSEGV handler (now write a core file by aborting program)
|
||||
* fixed statusbar & infobar background refresh problem with some systems
|
||||
* added color for private in hotlist (different than color for highlight)
|
||||
* added DCC resume and timeout
|
||||
* added function for Perl/Python to get DCC list
|
||||
* fixed FIFO pipe (command now authorized on a buffer not connected
|
||||
to an IRC server)
|
||||
* topic completion now decodes UTF-8 string
|
||||
* fixed bug with IRC URL on command line (irc://)
|
||||
* new keyboard management: keys are setup in config file, new command
|
||||
/key was added and some new default keys were added, alt-K key is
|
||||
used to grab key (useful for /key command)
|
||||
* added seconds in infobar time (optional thanks to new setting)
|
||||
* fixed some curses refreshs
|
||||
* channels auto-prefixed by "#" (if no prefix found) for /join command
|
||||
|
||||
Version 0.1.3 (2005-07-02):
|
||||
* proxy support (http, socks4, socks5) with authentification (http, socks5)
|
||||
@@ -24,14 +217,14 @@ Version 0.1.3 (2005-07-02):
|
||||
* fixed plugins "print" and "prnt" functions: now ok for writing on server
|
||||
buffers
|
||||
* fixed color problem with new libcurses version
|
||||
* fixed crash when using Alt-S or Alt-X on DCC buffer (Alt-D)
|
||||
* fixed crash when using alt-S or alt-X on DCC buffer (alt-D)
|
||||
* fixed startup crash when config file (~/.weechat/weechat.rc) is not found
|
||||
* improved Perl/Python libs detection for ./configure script
|
||||
|
||||
Version 0.1.2 (2005-05-21):
|
||||
* added Python plugin support, improved Perl interface (and now Perl/Python
|
||||
libraries are checked by configure script)
|
||||
* added nicklist scroll keys (Alt+{home/end/pgup/pgdn} or F11/F12)
|
||||
* added nicklist scroll keys (alt+{home/end/pgup/pgdn} or F11/F12)
|
||||
* added transfer rate for DCC files
|
||||
* added "-all" option for /nick command
|
||||
* buffers timestamp can now be changed (new option in config file)
|
||||
@@ -100,8 +293,8 @@ Version 0.0.9 (2005-01-01):
|
||||
* fixed display of nick mode changes
|
||||
* new command "/buffer close" (close any server/channel/private buffer)
|
||||
* /notice command fixed (and display when received from server)
|
||||
* new keys: Ctrl+A (=home), Ctrl+E (=end), Ctrl+W (=Ctrl+Backspace),
|
||||
Alt-S (switch to server buffer), Alt-X (switch to first channel of next
|
||||
* new keys: ctrl+A (=home), ctrl+E (=end), ctrl+W (= ctrl+Backspace),
|
||||
alt-S (switch to server buffer), alt-X (switch to first channel of next
|
||||
server)
|
||||
* added new config option: "server_command_delay" (delay in seconds after
|
||||
startup command for each server)
|
||||
@@ -118,15 +311,15 @@ Version 0.0.8 (2004-10-30):
|
||||
to enable/disable this feature
|
||||
* Fixed crash when resizing terminal to very small size
|
||||
* "-MORE-" message is now erased when switching to another buffer
|
||||
* DCC file receive ok (Alt-D for DCC view)
|
||||
* DCC file receive ok (alt-D for DCC view)
|
||||
* /query command now reopens private buffer if already opened
|
||||
* added key for redrawing terminal (Ctrl-L)
|
||||
* added key for clearing hotlist (Alt-R)
|
||||
* added key for redrawing terminal (ctrl-L)
|
||||
* added key for clearing hotlist (alt-R)
|
||||
|
||||
Version 0.0.7 (2004-08-08):
|
||||
* new "col_status_delimiters" config option
|
||||
* /buffer command added, buffers ordered by number, auto-jump to active
|
||||
buffers (alt-a), jump to buffers by number (alt-number)
|
||||
buffers (alt-A), jump to buffers by number (alt-number)
|
||||
* /window command added, split terminal horizontally/vertically
|
||||
* unique color for each nick (based on nickname)
|
||||
* action messages are now considered as messages, not crappy joins/parts
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
WeeChat FAQ, 2005-05-21
|
||||
WeeChat FAQ, 2006-05-25
|
||||
=======================
|
||||
|
||||
Intended audience:
|
||||
@@ -50,8 +50,13 @@ Q: Why using WeeChat ? X-Chat and Irssi are so good...
|
||||
|
||||
A: Because WeeChat is very light and has new features.
|
||||
Some new features:
|
||||
* many GUI (Curses, Gtk, wxWidgets, Qt),
|
||||
* extensible with scripts (Perl, Python, Ruby),
|
||||
* many GUI (Curses, Gtk, wxWidgets, Qt)
|
||||
* available in many languages
|
||||
* nicklist available in all GUI
|
||||
* extensible with plugins (C, Perl, Python, Ruby, Lua)
|
||||
* horizontal and vertical window split
|
||||
* infobar highlight
|
||||
* FIFO pipe for remote control
|
||||
* developed from scratch (not based on any other IRC client)
|
||||
* multi-platform
|
||||
* 100% GPL and free
|
||||
@@ -72,58 +77,75 @@ A: For help you can type /help. For help about a command, type /help command.
|
||||
================================================================================
|
||||
Q: I don't see come chars with accents, what can I do?
|
||||
|
||||
A: You have to setup charset used for decoding, encoding, and internal WeeChat
|
||||
charset.
|
||||
Change value of option "look_charset_decode" to "UTF-8".
|
||||
Option "look_charset_internal" should not be changed (default is
|
||||
"ISO-8859-1").
|
||||
A: You have to setup charset used for decoding (ISO and UTF), encoding, and
|
||||
internal WeeChat charset.
|
||||
Internal charset should be empty value, except if WeeChat failed to
|
||||
detect your locale (WeeChat looks for "UTF-8" in your locale name).
|
||||
|
||||
|
||||
2.4
|
||||
================================================================================
|
||||
Q: How can I customize key bindings?
|
||||
|
||||
A: Today you can't do that. This is planed for a future version.
|
||||
A: Key bindings are customizable with /key command.
|
||||
Default key Meta-k (usually Alt-k) lets you grab key code and insert it
|
||||
in input zone.
|
||||
|
||||
|
||||
2.5
|
||||
================================================================================
|
||||
Q: How can I load Perl scripts?
|
||||
Are Perl scripts compatible with X-chat or/and Irssi ?
|
||||
Are Perl scripts compatible with other IRC clients ?
|
||||
|
||||
A: You can use /perl command to load scripts (default path is
|
||||
~/.weechat/perl).
|
||||
Note that scripts in ~/.weechat/perl/autoload are automatically loaded
|
||||
when WeeChat is starting up.
|
||||
WeeChat Perl scripts are 80% compatible with X-Chat, but not with Irssi.
|
||||
Perl scripts are not compatible with other IRC clients.
|
||||
|
||||
|
||||
2.6
|
||||
================================================================================
|
||||
Q: How can I load Python scripts?
|
||||
Are Python scripts compatible with X-chat or/and Irssi ?
|
||||
Are Python scripts compatible with other IRC clients ?
|
||||
|
||||
A: You can use /python command to load scripts (default path is
|
||||
A: You can use /python command to load scripts (default path is
|
||||
~/.weechat/python).
|
||||
Note that scripts in ~/.weechat/python/autoload are automatically loaded
|
||||
when WeeChat is starting up.
|
||||
WeeChat Python scripts are 80% compatible with X-Chat, but not with Irssi.
|
||||
Python scripts are not compatible with other IRC clients.
|
||||
|
||||
|
||||
2.7
|
||||
================================================================================
|
||||
Q: How can I load Ruby scripts?
|
||||
Are Ruby scripts compatible with other IRC clients ?
|
||||
|
||||
A: Today Ruby interface is not developed, so you can't load any Ruby script.
|
||||
A: You can use /ruby command to load scripts (default path is
|
||||
~/.weechat/ruby).
|
||||
Note that scripts in ~/.weechat/ruby/autoload are automatically loaded
|
||||
when WeeChat is starting up.
|
||||
Ruby scripts are not compatible with other IRC clients.
|
||||
|
||||
|
||||
2.8
|
||||
================================================================================
|
||||
Q: How can I load Lua scripts?
|
||||
Are Lua scripts compatible with other IRC clients ?
|
||||
|
||||
A: You can use /lua command to load scripts (default path is
|
||||
~/.weechat/lua).
|
||||
Note that scripts in ~/.weechat/lua/autoload are automatically loaded
|
||||
when WeeChat is starting up.
|
||||
Lua scripts are not compatible with other IRC clients.
|
||||
|
||||
3.1
|
||||
================================================================================
|
||||
Q: How should I report bugs?
|
||||
|
||||
A: There is 3 ways to report bugs:
|
||||
1. you can join us on IRC: irc.freenode.net, channel #weechat
|
||||
2. you can submit your bug at this url:
|
||||
2. you can submit your bug at this URL:
|
||||
http://savannah.nongnu.org/bugs/?func=addbug&group=weechat
|
||||
3. you can mail your problem, look at support page for developer's mails:
|
||||
http://weechat.flashtux.org/support.php
|
||||
@@ -136,7 +158,7 @@ Q: How should I submit patches?
|
||||
|
||||
A: There is 3 ways to submit patches:
|
||||
1. you can join us on IRC: irc.freenode.net, channel #weechat
|
||||
2. you can submit your patch at this url:
|
||||
2. you can submit your patch at this URL:
|
||||
http://savannah.nongnu.org/patch/?func=addpatch&group=weechat
|
||||
3. you can mail your patch, look at support page for developer's mails:
|
||||
http://weechat.flashtux.org/support.php
|
||||
@@ -159,13 +181,8 @@ A: There is 2 ways to submit your feature request:
|
||||
================================================================================
|
||||
Q: What is the list of supported platforms for WeeChat?
|
||||
|
||||
A: Today WeeChat was succesfully tested on these platforms:
|
||||
- GNU/Linux (any distribution / i386, AMD64, Sparc)
|
||||
- FreeBSD
|
||||
- NetBSD
|
||||
- OpenBSD
|
||||
- Mac OS X
|
||||
- Microsoft Windows (with Cygwin and some code changes)
|
||||
A: Full list is on this page:
|
||||
http://weechat.flashtux.org/download.php?lang=en&view=supported_os
|
||||
|
||||
|
||||
3.5
|
||||
@@ -189,5 +206,5 @@ A: There's many tasks to do (code, documentation, ...)
|
||||
================================================================================
|
||||
Q: Can I give money or other things to WeeChat developers?
|
||||
|
||||
A: Beer is welcome :)
|
||||
Otherwise Paypal account is: flashcode@free.fr (no limit for gifts :)
|
||||
A: You can give us money to help development.
|
||||
Details on http://weechat.flashtux.org/donate.php?lang=en
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
WeeChat FAQ, 2005-05-21
|
||||
WeeChat FAQ, 2006-05-25
|
||||
=======================
|
||||
|
||||
Public concerné :
|
||||
@@ -53,8 +53,13 @@ Q: Pourquoi utiliser WeeChat ? X-Chat et Irssi sont si bien...
|
||||
|
||||
R: Parce que WeeChat est très léger et a de nouvelles fonctionnalités.
|
||||
Quelques nouvelles fonctionnalités :
|
||||
* plusieurs interfaces (Curses, Gtk, wxWidgets, Qt),
|
||||
* extensible par des scripts (Perl, Python, Ruby),
|
||||
* plusieurs interfaces (Curses, Gtk, wxWidgets, Qt)
|
||||
* disponible en plusieurs langues
|
||||
* liste des pseudos disponible dans toutes les interfaces
|
||||
* extensible par des extensions (C, Perl, Python, Ruby, Lua)
|
||||
* découpage de la fenêtre horizontalement et verticalement
|
||||
* highlight dans la barre d'infos
|
||||
* tube FIFO pour contrĂ´le Ă distance
|
||||
* développé à partir de zéro (non basé sur un quelconque client IRC)
|
||||
* multi-platformes
|
||||
* 100% GPL et libre
|
||||
@@ -76,51 +81,68 @@ R: Pour obtenir de l'aide tapez /help. Pour de l'aide sur une commande,
|
||||
================================================================================
|
||||
Q: Je ne vois pas bien certains accents dans WeeChat, que faire ?
|
||||
|
||||
R: Il faut configurer le charset utilisé pour le décodage, l'encodage ainsi que
|
||||
le charset interne Ă WeeChat.
|
||||
Modifiez la valeur de l'option "look_charset_decode" en "UTF-8".
|
||||
L'option "look_charset_internal" ne devrait pas être modifiée (par défaut
|
||||
"ISO-8859-1").
|
||||
R: Il faut configurer le charset utilisé pour le décodage (ISO et UTF),
|
||||
l'encodage ainsi que le charset interne Ă WeeChat.
|
||||
Le charset interne Ă WeeChat doit ĂŞtre une valeur vide, sauf si WeeChat
|
||||
n'arrive pas à déterminer votre locale (WeeChat recherche "UTF-8" dans
|
||||
le nom de la locale).
|
||||
|
||||
|
||||
2.4
|
||||
================================================================================
|
||||
Q: Comment puis-je configurer les raccourcis clavier ?
|
||||
|
||||
R: Aujourd'hui vous ne pouvez pas le faire. Ce sera possible dans une
|
||||
version future.
|
||||
R: Les raccourcis clavier sont modifiables avec la commande /key.
|
||||
La touche par défaut Meta-k (souvent Alt-k) permet de capturer le code
|
||||
d'une touche et de l'inclure dans la zone de saisie.
|
||||
|
||||
|
||||
2.5
|
||||
================================================================================
|
||||
Q: Comment puis-je charger des scripts Perl ?
|
||||
Les scripts Perl sont-ils compatibles avec X-chat et/ou Irssi ?
|
||||
Les scripts Perl sont-ils compatibles avec d'autres clients IRC ?
|
||||
|
||||
R: La commande /perl permet de charger les scripts Perl (le chemin par défaut
|
||||
est ~/.weechat/perl).
|
||||
Notez que les scripts dans ~/.weechat/perl/autoload sont automatiquement
|
||||
chargés par WeeChat lorsqu'il démarre.
|
||||
Les scripts Perl WeeChat sont 80% compatibles avec X-Chat, mais pas Irssi.
|
||||
Les scripts Perl ne sont pas compatibles avec d'autres clients IRC.
|
||||
|
||||
|
||||
2.6
|
||||
================================================================================
|
||||
Q: Comment puis-je charger les scripts Python ?
|
||||
Les scripts Python sont-ils compatibles avec X-chat et/ou Irssi ?
|
||||
Les scripts Python sont-ils compatibles avec d'autres clients IRC ?
|
||||
|
||||
R: La commande /python permet de charger les scripts Python (le chemin par
|
||||
défaut est ~/.weechat/python).
|
||||
Notez que les scripts dans ~/.weechat/python/autoload sont automatiquement
|
||||
chargés par WeeChat lorsqu'il démarre.
|
||||
Les scripts Python WeeChat sont 80% compatibles avec X-Chat, mais pas Irssi.
|
||||
Les scripts Python ne sont pas compatibles avec d'autres clients IRC.
|
||||
|
||||
|
||||
2.7
|
||||
================================================================================
|
||||
Q: Comment puis-je charger des scripts Ruby ?
|
||||
Les scripts Ruby sont-ils compatibles avec d'autres clients IRC ?
|
||||
|
||||
R: Aujourd'hui l'interface Ruby n'est pas développée.
|
||||
Vous ne pouvez donc charger aucun script Ruby.
|
||||
R: La commande /ruby permet de charger les scripts Ruby (le chemin par
|
||||
défaut est ~/.weechat/ruby).
|
||||
Notez que les scripts dans ~/.weechat/ruby/autoload sont automatiquement
|
||||
chargés par WeeChat lorsqu'il démarre.
|
||||
Les scripts Ruby ne sont pas compatibles avec d'autres clients IRC.
|
||||
|
||||
|
||||
2.8
|
||||
================================================================================
|
||||
Q: Comment puis-je charger des scripts Lua ?
|
||||
Les scripts Lua sont-ils compatibles avec d'autres clients IRC ?
|
||||
|
||||
R: La commande /lua permet de charger les scripts Lua (le chemin par
|
||||
défaut est ~/.weechat/lua).
|
||||
Notez que les scripts dans ~/.weechat/lua/autoload sont automatiquement
|
||||
chargés par WeeChat lorsqu'il démarre.
|
||||
Les scripts Lua ne sont pas compatibles avec d'autres clients IRC.
|
||||
|
||||
|
||||
3.1
|
||||
@@ -131,7 +153,7 @@ R: Il y a 3 mani
|
||||
1. vous pouvez nous joindre sur IRC: irc.freenode.net, canal #weechat
|
||||
2. vous pouvez soumettre votre bug Ă cette adresse :
|
||||
http://savannah.nongnu.org/bugs/?func=addbug&group=weechat
|
||||
3. vous pouvez envoyer votre problem par mail, consultez la page
|
||||
3. vous pouvez envoyer votre problème par mail, consultez la page
|
||||
support pour les mails des développeurs :
|
||||
http://weechat.flashtux.org/support.php
|
||||
(vous pouvez souscrire et envoyer Ă la liste de diffusion
|
||||
@@ -170,13 +192,8 @@ R: Il y a 2 mani
|
||||
================================================================================
|
||||
Q: Quelle est la liste des plate-formes supportées par WeeChat ?
|
||||
|
||||
R: Aujourd'hui WeeChat a été testé avec succès sur ces plate-formes :
|
||||
- GNU/Linux (toute distribution / i386, AMD64, Sparc)
|
||||
- FreeBSD
|
||||
- NetBSD
|
||||
- OpenBSD
|
||||
- Mac OS X
|
||||
- Microsoft Windows (avec Cygwin et quelques modifications de code)
|
||||
R: La liste complète est sur cette page :
|
||||
http://weechat.flashtux.org/download.php?lang=fr&view=supported_os
|
||||
|
||||
|
||||
3.5
|
||||
@@ -201,6 +218,5 @@ R: Il y a plusieurs choses
|
||||
================================================================================
|
||||
Q: Puis-je donner de l'argent ou d'autres choses aux développeurs WeeChat ?
|
||||
|
||||
R: La bière est la bienvenue :)
|
||||
Sinon le compte Paypal est: flashcode@free.fr (il n'y a pas de limite pour
|
||||
les dons :)
|
||||
R: Vous pouvez donner de l'argent pour aider le développement.
|
||||
Plus de détails sur http://weechat.flashtux.org/donate.php
|
||||
|
||||
@@ -2,11 +2,7 @@ WeeChat - Installation instructions
|
||||
===================================
|
||||
|
||||
1) Run './configure'
|
||||
options: --enable-perl : enable Perl scripts
|
||||
--disable-curses : do not build Curses interface
|
||||
--enable-gtk : build Gtk+ interface (under development!)
|
||||
--enable-qt : build Qt interface (not developed!)
|
||||
--with-debug=X : X=1 for debug compilation, 2 for debug messages
|
||||
(./configure --help so see options)
|
||||
|
||||
2) Run 'make'
|
||||
|
||||
@@ -14,4 +10,4 @@ WeeChat - Installation instructions
|
||||
|
||||
4) Enjoy ! :-)
|
||||
|
||||
See AUTHORS for support, feel free to contact us for any problem ;)
|
||||
See AUTHORS for support, feel free to contact us for any problem.
|
||||
|
||||
+8
-9
@@ -1,4 +1,4 @@
|
||||
# Copyright (c) 2003-2005 FlashCode <flashcode@flashtux.org>
|
||||
# Copyright (c) 2003-2006 FlashCode <flashcode@flashtux.org>
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
@@ -12,19 +12,18 @@
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
#
|
||||
|
||||
SUBDIRS = po intl src
|
||||
SUBDIRS = po doc intl src
|
||||
|
||||
EXTRA_DIST = config.rpath weechat-curses.1 BUGS FAQ FAQ.fr \
|
||||
EXTRA_DIST = config.rpath BUGS FAQ FAQ.fr \
|
||||
debian/changelog debian/control \
|
||||
debian/copyright \
|
||||
debian/copyright debian/compat \
|
||||
debian/rules debian/weechat-common.docs \
|
||||
debian/weechat-common.install debian/weechat-curses.dirs \
|
||||
debian/weechat-curses.install debian/weechat-gtk.dirs \
|
||||
debian/weechat-gtk.install
|
||||
|
||||
man_MANS = weechat-curses.1
|
||||
debian/weechat-curses.install debian/weechat-plugins.install \
|
||||
debian/weechat-curses.menu debian/NEWS \
|
||||
weechat.spec weechat_icon_32.png
|
||||
|
||||
ACLOCAL_AMFLAGS = -I m4
|
||||
|
||||
@@ -1,6 +1,78 @@
|
||||
WeeChat - Wee Enhanced Environment for Chat
|
||||
===========================================
|
||||
|
||||
* FlashCode, 2006-05-25
|
||||
|
||||
WeeChat 0.1.9 released.
|
||||
|
||||
Important release notes:
|
||||
|
||||
- please close all DCC chat buffers before using /upgrade command,
|
||||
otherwise you may experience problems with DCC chats.
|
||||
- some changes in script API: now timer handlers functions takes exactly
|
||||
0 (zero) argument (in version 0.1.8, two arguments were mandatory but
|
||||
not used: server and args)
|
||||
|
||||
* FlashCode, 2006-03-18
|
||||
|
||||
WeeChat 0.1.8 released.
|
||||
|
||||
Important release notes:
|
||||
|
||||
- it is recommended for users of version 0.1.7 (or any older), to
|
||||
replace values in setup file (~/.weechat/weechat.rc) :
|
||||
- option: log_path: replace "~/.weechat/logs" by "%h/logs"
|
||||
- option: plugins_path: replace "~/.weechat/plugins" by "%h/plugins"
|
||||
"%h" is replaced by WeeChat home (default: ~/.weechat, may be overriden
|
||||
by new command line arg --dir)
|
||||
- after installing 0.1.8 (or with /upgrade), issue both commands (if you
|
||||
didn't redefined these keys (alt-home/end):
|
||||
/key unbind meta-meta2-1~
|
||||
/key unbind meta-meta2-4~
|
||||
then launch again WeeChat (or issue /upgrade).
|
||||
Alt-home/end were used for nicklist scroll, they're now replaced by
|
||||
Alt-F11/F12.
|
||||
|
||||
* FlashCode, 2006-01-14
|
||||
|
||||
WeeChat 0.1.7 released.
|
||||
|
||||
Important release notes:
|
||||
|
||||
- Ruby script plugin has been added but is experimental in this release.
|
||||
You're warned!
|
||||
|
||||
- "/away" command was changed to be RFC 2812 compliant.
|
||||
Now argument is required to set away, and no argument means
|
||||
remove away ("back"). Setting "irc_default_msg_away" has been removed.
|
||||
|
||||
* FlashCode, 2005-11-11
|
||||
|
||||
WeeChat 0.1.6 released.
|
||||
|
||||
Important release notes:
|
||||
|
||||
- incompatibility with some old scripts: now all handlers have to return
|
||||
a code for completion, and to do some actions about message to ignore
|
||||
(please look at documentation for detail)
|
||||
|
||||
- on OpenBSD, the new option "plugins_extension" should be set to ".so.0.0"
|
||||
since the plugins names are ending by ".so.0.0" and not ".so"
|
||||
|
||||
- with new and full UTF-8 support, the option "look_charset_internal"
|
||||
should be set to blank for most cases. Forces it only if your locale is
|
||||
not properly detected by WeeChat (you can set "UTF-8" or "ISO-8859-15"
|
||||
for example, depending on your locale). WeeChat is looking for "UTF-8" in
|
||||
your locale name at startup.
|
||||
|
||||
* FlashCode, 2005-09-24
|
||||
|
||||
WeeChat 0.1.5 released.
|
||||
|
||||
* FlashCode, 2005-07-30
|
||||
|
||||
WeeChat 0.1.4 released.
|
||||
|
||||
* FlashCode, 2005-07-02
|
||||
|
||||
WeeChat 0.1.3 released.
|
||||
|
||||
@@ -12,17 +12,17 @@ Features
|
||||
* IRC chat client with multi-server connection
|
||||
* many GUI (curses, Gtk, Qt) (1)
|
||||
* small, fast and very light
|
||||
* customizable and extensible with scripts (Perl, Python, Ruby) (2)
|
||||
* customizable and extensible with plugins (C, Perl, Python, Ruby, Lua)
|
||||
* compliant with RFC 1459,2810,2811,2812,2813
|
||||
* developed from scratch
|
||||
* multi-platform (GNU/Linux, *BSD, Windows & other) (3)
|
||||
* multi-platform (GNU/Linux, *BSD, Mac OS X, QNX, Windows & other) (2)
|
||||
* 100% GPL & free
|
||||
|
||||
|
||||
Copyright
|
||||
---------
|
||||
|
||||
WeeChat (c) Copyright 2003-2005 by FlashCode <flashcode@flashtux.org>
|
||||
WeeChat (c) Copyright 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
(see AUTHORS file if you want to contact authors)
|
||||
|
||||
WeeChat is distributed under GPL licence (see COPYING file for complete license):
|
||||
@@ -39,10 +39,9 @@ GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
|
||||
|
||||
---
|
||||
(1) only Curses interface is available today
|
||||
(2) only Perl and Python interfaces are available today
|
||||
(3) only GNU/Linux and *BSD versions are available today
|
||||
(2) Windows version is under construction
|
||||
|
||||
@@ -1,66 +1,5 @@
|
||||
WeeChat - Wee Enhanced Environment for Chat
|
||||
===========================================
|
||||
|
||||
TODO - 2005-07-02
|
||||
|
||||
Legend:
|
||||
# done
|
||||
+ currently in development
|
||||
- pending
|
||||
? is this really necessary?
|
||||
|
||||
|
||||
v0.1.3:
|
||||
------
|
||||
|
||||
* General:
|
||||
+ Windows version
|
||||
+ Solaris version
|
||||
|
||||
* Interface:
|
||||
+ Gtk GUI
|
||||
+ internationalization (traduce WeeChat in many languages)
|
||||
|
||||
* TCP/IP communication:
|
||||
# SSL support
|
||||
# IPv6 protocol implementation
|
||||
# proxy support (http, socks4, socks5) with authentification
|
||||
(http, socks5) and ipv6 support (client to proxy)
|
||||
|
||||
* Configuration:
|
||||
# save buffer notify levels
|
||||
|
||||
|
||||
Future versions:
|
||||
---------------
|
||||
|
||||
* IRC protocol:
|
||||
- customizable CTCP version reply
|
||||
- complete "/list" command: add regexp search, display only channels that
|
||||
match regexp
|
||||
- "/ignore" and "/unignore" commands: hide all that is write by a given
|
||||
nick/host
|
||||
- when we're away, WeeChat should log all the lines begenning by our nick.
|
||||
When we come back from our away it should print it to the current window
|
||||
- "/notify" and "/unnotify" command to be warn by WeeChat when a given
|
||||
nick/host connect to the given irc network
|
||||
|
||||
* WeeChat commands:
|
||||
- "/highlight" command: highlight a given word when it appears on
|
||||
channels/privates
|
||||
- "/completion" command: do shortcuts (for example when we type "u"
|
||||
in the text bar it send it to the server as "you")
|
||||
- "/last": command to look for text in previous messages
|
||||
|
||||
* Interface:
|
||||
- color for nicks (except own nick) when nick colors are disabled
|
||||
- interpret special chars in messages (color & bold for example)
|
||||
- understand incomplete commands if unambigous (for example: /he for /help is ok)
|
||||
? Qt GUI
|
||||
|
||||
* Plugins:
|
||||
- Ruby plugin
|
||||
- "/ruby load" and "/ruby unload" commands to (un)load Ruby scripts
|
||||
|
||||
* Configuration:
|
||||
- add key bindings to config file
|
||||
WeeChat TODO:
|
||||
please look at https://savannah.nongnu.org/task/?group=weechat
|
||||
|
||||
+9
-4
@@ -3,13 +3,18 @@
|
||||
# gettextize updates Makefile.am, configure.in
|
||||
cp configure.in configure.in.old
|
||||
cp Makefile.am Makefile.am.old
|
||||
gettextize --copy --force --intl --no-changelog &&
|
||||
if test "$1" = "--auto" ; then
|
||||
grep -v 'read dummy < /dev/tty' $(which gettextize) | /bin/sh -s -- --copy --force --intl --no-changelog
|
||||
else
|
||||
gettextize --copy --force --intl --no-changelog
|
||||
fi
|
||||
mv Makefile.am.old Makefile.am
|
||||
mv configure.in.old configure.in
|
||||
aclocal &&
|
||||
libtoolize --automake --force --copy
|
||||
aclocal
|
||||
# autoheader creates config.h.in needed by autoconf
|
||||
autoheader &&
|
||||
autoheader
|
||||
# autoconf creates configure
|
||||
autoconf &&
|
||||
autoconf
|
||||
# automake creates Makefile.in
|
||||
automake --add-missing --copy --gnu
|
||||
|
||||
+535
-164
@@ -1,4 +1,4 @@
|
||||
# Copyright (c) 2003-2005 FlashCode <flashcode@flashtux.org>
|
||||
# Copyright (c) 2003-2006 FlashCode <flashcode@flashtux.org>
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
@@ -12,35 +12,58 @@
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
#
|
||||
|
||||
# -*- Autoconf -*-
|
||||
# Process this file with autoconf to produce a configure script.
|
||||
|
||||
AC_PREREQ(2.56)
|
||||
AC_INIT(WeeChat, 0.1.3, flashcode@flashtux.org)
|
||||
AC_INIT(WeeChat, 0.1.9, flashcode@flashtux.org)
|
||||
AC_CONFIG_SRCDIR([src/common/weechat.c])
|
||||
AM_CONFIG_HEADER(config.h)
|
||||
AM_INIT_AUTOMAKE([weechat], [0.1.3])
|
||||
AM_INIT_AUTOMAKE([weechat], [0.1.9])
|
||||
|
||||
# Checks for programs.
|
||||
# Checks for programs
|
||||
AC_PROG_CC
|
||||
AC_PROG_MAKE_SET
|
||||
AC_PROG_RANLIB
|
||||
AM_PROG_LIBTOOL
|
||||
|
||||
# Add some flags for some OS
|
||||
case "$host_os" in
|
||||
freebsd* | openbsd*)
|
||||
CFLAGS="$CFLAGS -I/usr/local/include"
|
||||
LDFLAGS="$LDFLAGS -L/usr/local/lib"
|
||||
;;
|
||||
netbsd*)
|
||||
CFLAGS="$CFLAGS -I/usr/pkg/include"
|
||||
LDFLAGS="$LDFLAGS -L/usr/pkg/lib"
|
||||
;;
|
||||
solaris*)
|
||||
LDFLAGS="$LDFLAGS -lsocket -lxnet"
|
||||
;;
|
||||
*)
|
||||
;;
|
||||
esac
|
||||
|
||||
# Gettext
|
||||
ALL_LINGUAS="fr es"
|
||||
ALL_LINGUAS="fr es cs hu de ru"
|
||||
AM_GNU_GETTEXT
|
||||
|
||||
# Checks for libraries.
|
||||
AC_CHECK_LIB([ncurses], [initscr], LIBNCURSES_FOUND=1, LIBNCURSES_FOUND=0)
|
||||
# Checks for libraries
|
||||
AC_CHECK_LIB(ncurses, initscr, LIBNCURSES_FOUND=1, LIBNCURSES_FOUND=0)
|
||||
AC_CHECK_LIB(ncursesw, initscr, LIBNCURSESW_FOUND=1, LIBNCURSESW_FOUND=0)
|
||||
|
||||
# Checks for header files.
|
||||
# Checks for header files
|
||||
AC_HEADER_STDC
|
||||
AC_CHECK_HEADERS([arpa/inet.h libintl.h limits.h locale.h netdb.h netinet/in.h stdlib.h string.h sys/socket.h sys/time.h sys/types.h unistd.h pwd.h errno.h])
|
||||
AC_CHECK_HEADERS([arpa/inet.h libintl.h limits.h locale.h netdb.h netinet/in.h stdlib.h string.h sys/socket.h sys/time.h sys/types.h unistd.h pwd.h errno.h regex.h wchar.h sys/file.h])
|
||||
|
||||
# Checks for typedefs, structures, and compiler characteristics.
|
||||
if echo "$host_os" | grep "^openbsd" 1>/dev/null 2>&1 ; then
|
||||
AC_CHECK_HEADER(utf8/wchar.h, LDFLAGS="$LDFLAGS -lutf8", [AC_MSG_ERROR([
|
||||
*** on OpenBSD systems, package libutf8 must be installed to compile WeeChat])])
|
||||
fi
|
||||
|
||||
# Checks for typedefs, structures, and compiler characteristics
|
||||
AC_HEADER_TIME
|
||||
AC_STRUCT_TM
|
||||
|
||||
@@ -61,190 +84,480 @@ AC_MSG_RESULT($ac_cv_type_socklen_t)
|
||||
# Checks for library functions.
|
||||
AC_FUNC_SELECT_ARGTYPES
|
||||
AC_TYPE_SIGNAL
|
||||
AC_CHECK_FUNCS([gethostbyname gethostname getsockname gettimeofday inet_ntoa memset mkdir select setlocale socket strcasecmp strchr strdup strncasecmp strpbrk strrchr strstr uname])
|
||||
AC_CHECK_FUNCS([gethostbyname gethostname getsockname gettimeofday inet_ntoa memset mkdir select setlocale socket strcasecmp strchr strdup strncasecmp strpbrk strrchr strstr uname regexec])
|
||||
|
||||
# Variables in config.h
|
||||
|
||||
AH_VERBATIM([PREFIX], [#undef PREFIX])
|
||||
AH_VERBATIM([WEECHAT_LIBDIR], [#undef WEECHAT_LIBDIR])
|
||||
AH_VERBATIM([WEECHAT_SHAREDIR], [#undef WEECHAT_SHAREDIR])
|
||||
AH_VERBATIM([PLUGINS], [#undef PLUGINS])
|
||||
AH_VERBATIM([PLUGIN_PERL], [#undef PLUGIN_PERL])
|
||||
AH_VERBATIM([PLUGIN_PYTHON], [#undef PLUGIN_PYTHON])
|
||||
AH_VERBATIM([PLUGIN_RUBY], [#undef PLUGIN_RUBY])
|
||||
AH_VERBATIM([PLUGIN_LUA], [#undef PLUGIN_LUA])
|
||||
AH_VERBATIM([HAVE_GNUTLS], [#undef HAVE_GNUTLS])
|
||||
AH_VERBATIM([HAVE_FLOCK], [#undef HAVE_FLOCK])
|
||||
AH_VERBATIM([DEBUG], [#undef DEBUG])
|
||||
|
||||
AC_ARG_ENABLE(ncurses, [ --disable-ncurses Turn off ncurses interface (default=auto)],enable_ncurses=$enableval,enable_ncurses=yes)
|
||||
AC_ARG_ENABLE(wxwidgets,[ --enable-wxwidgets Turn on WxWidgets interface (default=no)],enable_wxwidgets=$enableval,enable_wxwidgets=no)
|
||||
AC_ARG_ENABLE(gtk, [ --enable-gtk Turn on Gtk+ interface (default=no)],enable_gtk=$enableval,enable_gtk=no)
|
||||
AC_ARG_ENABLE(qt, [ --enable-qt Turn on Qt interface (default=no)],enable_qt=$enableval,enable_qt=no)
|
||||
AC_ARG_ENABLE(perl, [ --enable-perl Turn on Perl plugins (default=no)],enable_perl=$enableval,enable_perl=no)
|
||||
AC_ARG_ENABLE(python, [ --enable-python Turn on Python plugins (default=no)],enable_python=$enableval,enable_python=no)
|
||||
AC_ARG_ENABLE(gnutls, [ --disable-gnutls Turn off gnutls support (default=auto)],enable_gnutls=$enableval,enable_gnutls=yes)
|
||||
AC_ARG_WITH(debug, [ --with-debug Debugging: 0=no debug, 1=debug compilation, 2=debug compilation + verbose msgs (default=0)],debug=$withval,debug=0)
|
||||
# Arguments for ./configure
|
||||
|
||||
enable_plugins="no"
|
||||
enable_ruby="no"
|
||||
RUBY_CFLAGS=
|
||||
AC_ARG_ENABLE(ncurses, [ --disable-ncurses Turn off ncurses interface (default=compiled if found)],enable_ncurses=$enableval,enable_ncurses=yes)
|
||||
AC_ARG_ENABLE(wxwidgets, [ --enable-wxwidgets Turn on WxWidgets interface (default=no wxwidgets)],enable_wxwidgets=$enableval,enable_wxwidgets=no)
|
||||
AC_ARG_ENABLE(gtk, [ --enable-gtk Turn on Gtk interface (default=no Gtk)],enable_gtk=$enableval,enable_gtk=no)
|
||||
AC_ARG_ENABLE(qt, [ --enable-qt Turn on Qt interface (default=no Qt)],enable_qt=$enableval,enable_qt=no)
|
||||
AC_ARG_ENABLE(plugins, [ --disable-plugins Turn off plugins support (default=plugins enabled)],enable_plugins=$enableval,enable_plugins=yes)
|
||||
AC_ARG_ENABLE(perl, [ --disable-perl Turn off Perl script plugin (default=compiled if found)],enable_perl=$enableval,enable_perl=yes)
|
||||
AC_ARG_ENABLE(python, [ --disable-python Turn off Python script plugin (default=compiled if found)],enable_python=$enableval,enable_python=yes)
|
||||
AC_ARG_ENABLE(ruby, [ --disable-ruby Turn off Ruby script plugin (default=compiled if found)],enable_ruby=$enableval,enable_ruby=yes)
|
||||
AC_ARG_ENABLE(lua, [ --disable-lua Turn off Lua script plugin (default=compiled if found)],enable_lua=$enableval,enable_lua=yes)
|
||||
AC_ARG_WITH(lua-inc, [ --with-lua-inc=DIR, Lua include files are in DIR (default=autodetect)],lua_inc=$withval,lua_inc='')
|
||||
AC_ARG_WITH(lua-lib, [ --with-lua-lib=DIR, Lua library files are in DIR (default=autodetect)],lua_lib=$withval,lua_lib='')
|
||||
AC_ARG_WITH(lua-suffix, [ --with-lua-suffix=ARG Lua is suffixed with ARG (default=autodetect)],lua_suffix=$withval,lua_suffix='')
|
||||
AC_ARG_ENABLE(gnutls, [ --disable-gnutls Turn off gnutls support (default=compiled if found)],enable_gnutls=$enableval,enable_gnutls=yes)
|
||||
AC_ARG_WITH(debug, [ --with-debug Debugging: 0=no debug, 1=debug compilation, 2=debug compilation + verbose msgs (default=1)],debug=$withval,debug=1)
|
||||
|
||||
AM_CONDITIONAL(GUI_NCURSES, test "$enable_ncurses" = "yes")
|
||||
AM_CONDITIONAL(GUI_WXWIDGETS, test "$enable_wxwidgets" = "yes")
|
||||
AM_CONDITIONAL(GUI_GTK, test "$enable_gtk" = "yes")
|
||||
AM_CONDITIONAL(GUI_QT, test "$enable_qt" = "yes")
|
||||
AM_CONDITIONAL(PLUGIN_PERL, test "$enable_perl" = "yes")
|
||||
AM_CONDITIONAL(PLUGIN_PYTHON, test "$enable_python" = "yes")
|
||||
# AM_CONDITIONAL(PLUGIN_RUBY, test "$enable_ruby" = "yes")
|
||||
AM_CONDITIONAL(HAVE_GNUTLS, test "$enable_gnutls" = "yes")
|
||||
not_found=""
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# GUI
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
if test "x$enable_ncurses" = "xyes" ; then
|
||||
if test "$LIBNCURSES_FOUND" = "0" ; then
|
||||
AC_MSG_ERROR([
|
||||
if test "$LIBNCURSESW_FOUND" = "0" ; then
|
||||
if test "$LIBNCURSES_FOUND" = "0" ; then
|
||||
AC_MSG_WARN([
|
||||
*** ncurses library not found!
|
||||
*** Please install ncurses library or run ./configure with --disable-ncurses parameter.])
|
||||
*** WeeChat will be built without ncurses support.])
|
||||
enable_ncurses="no"
|
||||
not_found="$not_found ncurses"
|
||||
else
|
||||
AC_MSG_WARN([
|
||||
*** ncursesw library not found! Falling back to "ncurses"
|
||||
*** Be careful, UTF-8 display may not work properly if your locale is UTF-8.])
|
||||
NCURSES_LIBS="-lncurses"
|
||||
fi
|
||||
else
|
||||
NCURSES_LIBS="-lncursesw"
|
||||
AC_CHECK_HEADERS(ncursesw/curses.h)
|
||||
fi
|
||||
NCURSES_LIBS="-lncurses"
|
||||
AC_SUBST(NCURSES_LIBS)
|
||||
fi
|
||||
|
||||
if test "x$enable_wxwidgets" = "xyes" ; then
|
||||
AM_OPTIONS_WXCONFIG
|
||||
AM_PATH_WXCONFIG(2.3.4, wxWin=1)
|
||||
|
||||
if test "$wxWin" != 1; then
|
||||
AC_MSG_ERROR([
|
||||
*** wxWindows must be installed on your system
|
||||
*** but wx-config script couldn't be found.
|
||||
|
||||
*** Please check that wx-config is in path, the directory
|
||||
*** where wxWindows libraries are installed (returned by
|
||||
*** 'wx-config --libs' command) is in LD_LIBRARY_PATH or
|
||||
*** equivalent variable and wxWindows version is 2.3.4 or above.
|
||||
])
|
||||
fi
|
||||
|
||||
CPPFLAGS="$CPPFLAGS $WX_CPPFLAGS"
|
||||
CXXFLAGS="$CXXFLAGS $WX_CXXFLAGS_ONLY"
|
||||
CFLAGS="$CFLAGS $WX_CFLAGS_ONLY"
|
||||
LDFLAGS="$LDFLAGS $WX_LIBS"
|
||||
|
||||
WXWIDGETS_CFLAGS=""
|
||||
WXWIDGETS_LIBS=""
|
||||
fi
|
||||
#if test "x$enable_wxwidgets" = "xyes" ; then
|
||||
# AM_OPTIONS_WXCONFIG
|
||||
# AM_PATH_WXCONFIG(2.3.4, wxWin=1)
|
||||
#
|
||||
# if test "$wxWin" != 1; then
|
||||
# AC_MSG_ERROR([
|
||||
#*** wxWindows must be installed on your system
|
||||
#*** but wx-config script couldn't be found.
|
||||
#
|
||||
#*** Please check that wx-config is in path, the directory
|
||||
#*** where wxWindows libraries are installed (returned by
|
||||
#*** 'wx-config --libs' command) is in LD_LIBRARY_PATH or
|
||||
#*** equivalent variable and wxWindows version is 2.3.4 or above.
|
||||
# ])
|
||||
# fi
|
||||
#
|
||||
# CPPFLAGS="$CPPFLAGS $WX_CPPFLAGS"
|
||||
# CXXFLAGS="$CXXFLAGS $WX_CXXFLAGS_ONLY"
|
||||
# CFLAGS="$CFLAGS $WX_CFLAGS_ONLY"
|
||||
# LDFLAGS="$LDFLAGS $WX_LIBS"
|
||||
#
|
||||
# WXWIDGETS_CFLAGS=""
|
||||
# WXWIDGETS_LIBS=""
|
||||
#fi
|
||||
|
||||
if test "x$enable_gtk" = "xyes" ; then
|
||||
#if test "$LIBGTK_FOUND" = "0" ; then
|
||||
# AC_MSG_ERROR([Gtk+ library not found! Install Gtk+ (2.0 or higher) library or run ./configure without --enable-gtk parameter.])
|
||||
#fi
|
||||
GTK_CFLAGS=`pkg-config --cflags gtk+-2.0`
|
||||
GTK_LIBS=`pkg-config --libs gtk+-2.0`
|
||||
AC_SUBST(GTK_CFLAGS)
|
||||
AC_SUBST(GTK_LIBS)
|
||||
AM_PATH_GTK_2_0(2.4.0, LIBGTK_FOUND=1, LIBGTK_FOUND=0)
|
||||
if test "$LIBGTK_FOUND" = "0" ; then
|
||||
AC_MSG_WARN([
|
||||
*** Gtk library not found!
|
||||
*** WeeChat will be built without Gtk support.])
|
||||
enable_gtk="no"
|
||||
not_found="$not_found gtk"
|
||||
else
|
||||
GTK_CFLAGS=`pkg-config --cflags gtk+-2.0`
|
||||
GTK_LIBS=`pkg-config --libs gtk+-2.0`
|
||||
AC_SUBST(GTK_CFLAGS)
|
||||
AC_SUBST(GTK_LIBS)
|
||||
fi
|
||||
fi
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# plugins
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
PLUGINS_LIBS=
|
||||
|
||||
if test "x$enable_plugins" != "xyes" ; then
|
||||
enable_plugins="no"
|
||||
enable_perl="no"
|
||||
enable_python="no"
|
||||
enable_ruby="no"
|
||||
enable_lua="no"
|
||||
fi
|
||||
|
||||
# ---------------------------------- perl --------------------------------------
|
||||
|
||||
if test "x$enable_perl" = "xyes" ; then
|
||||
enable_plugins="yes"
|
||||
|
||||
AC_PATH_PROG(PERL, perl perl5)
|
||||
AC_PATH_PROGS(PERL, perl perl5)
|
||||
if test -z $PERL ; then
|
||||
AC_MSG_ERROR([
|
||||
*** Perl must be installed on your system
|
||||
*** but perl interpreter couldn't be found in path.
|
||||
|
||||
Please check that perl is in path, or install
|
||||
it with your software package manager.])
|
||||
fi
|
||||
|
||||
AC_MSG_CHECKING(for Perl headers files)
|
||||
|
||||
PERL_HEADER_TEST=`PT=perltest.c ; echo "#include <EXTERN.h>" > $PT; echo "#include <perl.h>" >> $PT; echo "#include <XSUB.h>" >> $PT ; echo "int main() { return 0; }" >> $PT ; $CC -Wall $PT -o $PT.out $($PERL -MExtUtils::Embed -e ccopts) 1>/dev/null 2>&1; echo $?; rm -f $PT $PT.out 1>/dev/null 2>&1`
|
||||
|
||||
if test "x$PERL_HEADER_TEST" = "x0" ; then
|
||||
PERL_CFLAGS=`$PERL -MExtUtils::Embed -e ccopts`
|
||||
AC_MSG_WARN([
|
||||
*** Perl must be installed on your system but perl interpreter couldn't be found in path.
|
||||
*** Please check that perl is in path, or install it with your software package manager.
|
||||
*** WeeChat will be built without Perl support.])
|
||||
enable_perl="no"
|
||||
not_found="$not_found perl"
|
||||
else
|
||||
AC_MSG_ERROR([
|
||||
*** Perl headers couldn't be found in your system.
|
||||
*** Try to install it with your software package manager.])
|
||||
fi
|
||||
AC_MSG_RESULT(found)
|
||||
|
||||
AC_MSG_CHECKING(for Perl library)
|
||||
|
||||
PERL_LIB_TEST=`PT=perltest.c ; echo "int main() { return 0; }" > $PT ; $CC -Wall $PT -o $PT.out $($PERL -MExtUtils::Embed -e ldopts) 1>/dev/null 2>&1; echo $?; rm -f $PT $PT.out 1>/dev/null 2>&1`
|
||||
|
||||
if test "x$PERL_LIB_TEST" = "x0" ; then
|
||||
PLUGINS_LIBS="$PLUGINS_LIBS ../../plugins/perl/lib_weechat_perl.a `$PERL -MExtUtils::Embed -e ldopts`"
|
||||
else
|
||||
AC_MSG_ERROR([
|
||||
AC_MSG_CHECKING(for Perl headers files)
|
||||
|
||||
PERL_HEADER_TEST=`PT=perltest.c ; echo "#include <EXTERN.h>" > $PT; echo "#include <perl.h>" >> $PT; echo "#include <XSUB.h>" >> $PT ; echo "int main() { return 0; }" >> $PT ; $CC -Wall $PT -o $PT.out $($PERL -MExtUtils::Embed -e ccopts) 1>/dev/null 2>&1; echo $?; rm -f $PT $PT.out 1>/dev/null 2>&1`
|
||||
|
||||
if test "x$PERL_HEADER_TEST" = "x0" ; then
|
||||
PERL_CFLAGS=`$PERL -MExtUtils::Embed -e ccopts`
|
||||
AC_MSG_RESULT(found)
|
||||
AC_MSG_CHECKING(for Perl library)
|
||||
PERL_LIB_TEST=`PT=perltest.c ; echo "int main() { return 0; }" > $PT ; $CC -Wall $PT -o $PT.out $($PERL -MExtUtils::Embed -e ldopts) 1>/dev/null 2>&1; echo $?; rm -f $PT $PT.out 1>/dev/null 2>&1`
|
||||
if test "x$PERL_LIB_TEST" = "x0" ; then
|
||||
PERL_LFLAGS=`$PERL -MExtUtils::Embed -e ldopts`
|
||||
AC_MSG_RESULT(found)
|
||||
else
|
||||
AC_MSG_WARN([
|
||||
*** Perl library couldn't be found in your system.
|
||||
*** Try to install it with your software package manager.])
|
||||
*** Try to install it with your software package manager.
|
||||
*** WeeChat will be built without Perl support.])
|
||||
enable_perl="no"
|
||||
not_found="$not_found perl"
|
||||
fi
|
||||
else
|
||||
AC_MSG_WARN([
|
||||
*** Perl headers couldn't be found in your system.
|
||||
*** Try to install it with your software package manager.
|
||||
*** WeeChat will be built without Perl support.])
|
||||
enable_perl="no"
|
||||
not_found="$not_found perl"
|
||||
fi
|
||||
fi
|
||||
AC_MSG_RESULT(found)
|
||||
|
||||
fi
|
||||
|
||||
if test "x$enable_perl" = "xyes" ; then
|
||||
AC_SUBST(PERL_CFLAGS)
|
||||
AC_SUBST(PERL_LFLAGS)
|
||||
AC_DEFINE(PLUGIN_PERL)
|
||||
fi
|
||||
|
||||
# --------------------------------- python -------------------------------------
|
||||
|
||||
if test "x$enable_python" = "xyes" ; then
|
||||
enable_plugins="yes"
|
||||
|
||||
AC_PATH_PROG(PYTHON, python python2.4 python2.3 python2.2)
|
||||
AC_PATH_PROGS(PYTHON, python python2.4 python2.3 python2.2)
|
||||
if test -z $PYTHON ; then
|
||||
AC_MSG_ERROR([
|
||||
*** Python must be installed on your system
|
||||
*** but python interpreter couldn't be found in path.
|
||||
|
||||
*** Please check that python is in path, or install
|
||||
*** it with your software package manager.])
|
||||
fi
|
||||
|
||||
PYTHON_SYSPREFIX=`$PYTHON -c 'import sys; print "%s" % sys.prefix'`
|
||||
PYTHON_VERSION=`$PYTHON -c 'import sys ; print sys.version[[:3]]'`
|
||||
PYTHON_INCLUDE="$PYTHON_SYSPREFIX/include/python$PYTHON_VERSION"
|
||||
|
||||
AC_MSG_CHECKING(for Python header files)
|
||||
if test -r "$PYTHON_INCLUDE/Python.h"; then
|
||||
PYTHON_CFLAGS=-I`$PYTHON -c "import distutils.sysconfig,string; print distutils.sysconfig.get_config_var('CONFINCLUDEPY')"`
|
||||
AC_MSG_WARN([
|
||||
*** Python must be installed on your system but python interpreter couldn't be found in path.
|
||||
*** Please check that python is in path, or install it with your software package manager.
|
||||
*** WeeChat will be built without Python support.])
|
||||
enable_python="no"
|
||||
not_found="$not_found python"
|
||||
else
|
||||
AC_MSG_ERROR([
|
||||
*** Python header files couldn't be found in your system.
|
||||
*** Try to install them with your software package manager.])
|
||||
fi
|
||||
AC_MSG_RESULT(found)
|
||||
|
||||
PYTHON_LIB="$PYTHON_SYSPREFIX/lib/python$PYTHON_VERSION/config"
|
||||
|
||||
AC_MSG_CHECKING(for Python library)
|
||||
if test -r "$PYTHON_LIB/libpython$PYTHON_VERSION.so" -o -r "$PYTHON_SYSPREFIX/lib/libpython$PYTHON_VERSION.so"; then
|
||||
PYTHON_LFLAGS="-lpython$PYTHON_VERSION -lpthread -lutil"
|
||||
else
|
||||
AC_MSG_ERROR([
|
||||
PYTHON_SYSPREFIX=`$PYTHON -c 'import sys; print "%s" % sys.prefix'`
|
||||
PYTHON_VERSION=`$PYTHON -c 'import sys ; print sys.version[[:3]]'`
|
||||
PYTHON_INCLUDE=`$PYTHON -c "import distutils.sysconfig,string; print distutils.sysconfig.get_config_var('CONFINCLUDEPY')"`
|
||||
|
||||
AC_MSG_CHECKING(for Python header files)
|
||||
if test -r "$PYTHON_INCLUDE/Python.h"; then
|
||||
PYTHON_CFLAGS="-I$PYTHON_INCLUDE"
|
||||
AC_MSG_RESULT(found)
|
||||
PYTHON_LIB=`$PYTHON -c "import distutils.sysconfig; print distutils.sysconfig.get_config_var('LIBPL')"`
|
||||
PYTHON_LFLAGS="-lpython$PYTHON_VERSION "`$PYTHON -c "import distutils.sysconfig; print distutils.sysconfig.get_config_var('LIBS')+' '+distutils.sysconfig.get_config_var('SYSLIBS')+' '+distutils.sysconfig.get_config_var('LINKFORSHARED')"`
|
||||
AC_MSG_CHECKING(for Python library)
|
||||
if test -r "$PYTHON_LIB/libpython$PYTHON_VERSION.so"; then
|
||||
PYTHON_LFLAGS="-L$PYTHON_LIB $PYTHON_LFLAGS"
|
||||
AC_MSG_RESULT(found)
|
||||
elif test -r "$PYTHON_LIB/libpython$PYTHON_VERSION.a"; then
|
||||
PYTHON_LFLAGS="-L$PYTHON_LIB $PYTHON_LFLAGS"
|
||||
AC_MSG_RESULT(found)
|
||||
elif test -r "$PYTHON_SYSPREFIX/lib/libpython$PYTHON_VERSION.so"; then
|
||||
PYTHON_LFLAGS="-L$PYTHON_SYSPREFIX/lib/ $PYTHON_LFLAGS"
|
||||
AC_MSG_RESULT(found)
|
||||
else
|
||||
AC_MSG_WARN([
|
||||
*** Python library couldn't be found in your system.
|
||||
*** Try to install it with your software package manager.])
|
||||
*** Try to install it with your software package manager.
|
||||
*** WeeChat will be built without Python support.])
|
||||
enable_python="no"
|
||||
not_found="$not_found python"
|
||||
fi
|
||||
else
|
||||
AC_MSG_WARN([
|
||||
*** Python header files couldn't be found in your system.
|
||||
*** Try to install them with your software package manager.
|
||||
*** WeeChat will be built without Python support.])
|
||||
enable_python="no"
|
||||
not_found="$not_found python"
|
||||
fi
|
||||
fi
|
||||
AC_MSG_RESULT(found)
|
||||
|
||||
PLUGINS_LIBS="$PLUGINS_LIBS ../../plugins/python/lib_weechat_python.a $PYTHON_LFLAGS"
|
||||
fi
|
||||
|
||||
if test "x$enable_python" = "xyes" ; then
|
||||
AC_SUBST(PYTHON_CFLAGS)
|
||||
AC_SUBST(PYTHON_LFLAGS)
|
||||
AC_DEFINE(PLUGIN_PYTHON)
|
||||
fi
|
||||
|
||||
if test "x$enable_plugins" = "xyes" ; then
|
||||
AC_DEFINE(PLUGINS)
|
||||
# ---------------------------------- ruby --------------------------------------
|
||||
|
||||
if test "x$enable_ruby" = "xyes" ; then
|
||||
enable_plugins="yes"
|
||||
|
||||
AC_PATH_PROGS(RUBY, ruby ruby1.8 ruby1.9)
|
||||
if test -z $RUBY ; then
|
||||
AC_MSG_WARN([
|
||||
*** Ruby must be installed on your system but ruby interpreter couldn't be found in path.
|
||||
*** Please check that ruby is in path, or install it with your software package manager.
|
||||
*** WeeChat will be built without Ruby support.])
|
||||
enable_ruby="no"
|
||||
not_found="$not_found ruby"
|
||||
else
|
||||
RUBY_INCLUDE=`$RUBY -rrbconfig -e "puts Config::CONFIG[['archdir']]"`
|
||||
AC_MSG_CHECKING(for Ruby header files)
|
||||
if test -r "$RUBY_INCLUDE/ruby.h"; then
|
||||
RUBY_CFLAGS="-I$RUBY_INCLUDE"
|
||||
else
|
||||
AC_MSG_WARN([
|
||||
*** Ruby header files couldn't be found in your system.
|
||||
*** Try to install them with your software package manager.
|
||||
*** WeeChat will be built without Ruby support.])
|
||||
enable_ruby="no"
|
||||
not_found="$not_found ruby"
|
||||
fi
|
||||
AC_MSG_RESULT(found)
|
||||
RUBY_LFLAGS=`$RUBY -rrbconfig -e "puts Config::CONFIG[['LIBRUBYARG_SHARED']]"`
|
||||
fi
|
||||
fi
|
||||
|
||||
AC_SUBST(PLUGINS_LIBS)
|
||||
if test "x$enable_ruby" = "xyes" ; then
|
||||
AC_SUBST(RUBY_CFLAGS)
|
||||
AC_SUBST(RUBY_LFLAGS)
|
||||
AC_DEFINE(PLUGIN_RUBY)
|
||||
fi
|
||||
|
||||
# ---------------------------------- lua --------------------------------------
|
||||
|
||||
if test "x$enable_lua" = "xyes" ; then
|
||||
enable_plugins="yes"
|
||||
|
||||
ac_save_CPPFLAGS="$CPPFLAGS"
|
||||
ac_save_CFLAGS="$CFLAGS"
|
||||
ac_save_LDFLAGS="$LDFLAGS"
|
||||
|
||||
LUA_CFLAGS=""
|
||||
LUA_LFLAGS=""
|
||||
|
||||
if test -n "$lua_inc"; then
|
||||
CFLAGS="$CFLAGS -I$lua_inc"
|
||||
CPPFLAGS="$CPPFLAGS -I$lua_inc"
|
||||
fi
|
||||
if test -n "$lua_lib"; then
|
||||
LDFLAGS="$LDFLAGS -L$lua_lib"
|
||||
fi
|
||||
|
||||
if test "x$LUA_CFLAGS" = "x" -o "x$LUA_LFLAGS" = "x" ; then
|
||||
PKGCONFIG=""
|
||||
AC_CHECK_PROGS(PKGCONFIG, pkg-config)
|
||||
if test "x$PKGCONFIG" != "x"; then
|
||||
AC_MSG_CHECKING(for Lua headers and librairies with pkg-config)
|
||||
echo
|
||||
for l in "$lua_suffix" "" "50" "5.0" "51" "5.1" ; do
|
||||
pkgconfig_lua_found=`$PKGCONFIG --exists lua$l 2>/dev/null && $PKGCONFIG --exists lualib$l 2>/dev/null`
|
||||
if test "x$?" = "x0" ; then
|
||||
LUA_CFLAGS="$LUA_CFLAGS "`$PKGCONFIG --cflags lua$l`
|
||||
LUA_CFLAGS="$LUA_CFLAGS "`$PKGCONFIG --cflags lualib$l`
|
||||
LUA_LFLAGS="$LUA_LFLAGS "`$PKGCONFIG --libs lua$l`
|
||||
LUA_LFLAGS="$LUA_LFLAGS "`$PKGCONFIG --libs lualib$l`
|
||||
break
|
||||
fi
|
||||
done
|
||||
fi
|
||||
fi
|
||||
|
||||
if test "x$LUA_CFLAGS" = "x" -o "x$LUA_LFLAGS" = "x" ; then
|
||||
LUACONFIG=""
|
||||
AC_CHECK_PROGS(LUACONFIG, lua-config lua-config50 lua-config5.0 lua-config51 lua-config5.1)
|
||||
if test "x$LUACONFIG" != "x" ; then
|
||||
AC_MSG_CHECKING(for Lua headers and librairies with lua-config)
|
||||
echo
|
||||
LUA_CFLAGS=`$LUACONFIG --include`
|
||||
LUA_LFLAGS=`$LUACONFIG --libs`
|
||||
fi
|
||||
fi
|
||||
|
||||
if test "x$LUA_CFLAGS" = "x" -o "x$LUA_LFLAGS" = "x" ; then
|
||||
AC_MSG_CHECKING(for Lua headers and librairies)
|
||||
echo
|
||||
AC_CHECK_HEADER(lua.h,ac_found_lua_header="yes",ac_found_lua_header="no")
|
||||
AC_CHECK_HEADER(lualib.h,ac_found_liblua_header="yes",ac_found_liblua_header="no")
|
||||
if test "x$ac_found_lua_header" = "xyes" -a "x$ac_found_liblua_header" = "xyes"; then
|
||||
LUA_CFLAGS="$CFLAGS"
|
||||
fi
|
||||
for l in "$lua_suffix" "" "50" "5.0" "51" "5.1" ; do
|
||||
AC_CHECK_LIB(lua$l,lua_call,ac_found_lua_lib="yes",ac_found_lua_lib="no")
|
||||
if test "x$ac_found_lua_lib" = "xyes" ; then
|
||||
LUA_LFLAGS="$LDFLAGS -llua$l -lm"
|
||||
|
||||
ac2_save_LDFLAGS="$LDFLAGS"
|
||||
LDFLAGS="$LDFLAGS -llua$l -lm"
|
||||
|
||||
if echo "$host_os" | grep "^linux" 1>/dev/null 2>&1 ; then
|
||||
LDFLAGS="$LDFLAGS -ldl"
|
||||
fi
|
||||
|
||||
AC_CHECK_LIB(lualib$l,luaL_openlib,ac_found_liblua_lib="yes",ac_found_liblua_lib="no")
|
||||
if test "x$ac_found_liblua_lib" = "xyes" ; then
|
||||
LUA_LFLAGS="$LUA_LFLAGS -llualib$l"
|
||||
|
||||
if echo "$host_os" | grep "^linux" 1>/dev/null 2>&1 ; then
|
||||
LUA_LFLAGS="$LUA_LFLAGS -ldl"
|
||||
fi
|
||||
fi
|
||||
|
||||
LDFLAGS="$ac2_save_LDFLAGS"
|
||||
break
|
||||
fi
|
||||
done
|
||||
fi
|
||||
|
||||
AC_MSG_CHECKING(for Lua compiling and linking)
|
||||
LUA_TEST=`LT=luatest.c ; echo "#include <lua.h>" > $LT; echo "#include <lualib.h>" >> $LT; echo "int main() { luaopen_base((lua_State *)lua_open()); return 0; }" >> $LT ; $CC -Wall $LT -o $LT.out $LUA_CFLAGS $LUA_LFLAGS $CFLAGS $LDFLAGS 1>/dev/null 2>&1 ; echo $?; rm -f $LT $LT.out 1>/dev/null 2>&1`
|
||||
if test "x$LUA_TEST" != "x0" ; then
|
||||
AC_MSG_RESULT(no)
|
||||
AC_MSG_WARN([
|
||||
*** Lua (>=5.0) headers and/or librairies couldn't be found in your system.
|
||||
*** Try to install liblua, liblualib and liblua-dev with your software package manager.
|
||||
*** WeeChat will be built without Lua support.])
|
||||
enable_lua="no"
|
||||
not_found="$not_found lua"
|
||||
else
|
||||
AC_MSG_RESULT(yes)
|
||||
fi
|
||||
|
||||
CFLAGS="$ac_save_CFLAGS"
|
||||
CPPFLAGS="$ac_save_CPPFLAGS"
|
||||
LDFLAGS="$ac_save_LDFLAGS"
|
||||
fi
|
||||
|
||||
if test "x$enable_lua" = "xyes" ; then
|
||||
AC_SUBST(LUA_CFLAGS)
|
||||
AC_SUBST(LUA_LFLAGS)
|
||||
AC_DEFINE(PLUGIN_LUA)
|
||||
fi
|
||||
|
||||
if test "x$enable_plugins" = "xyes" ; then
|
||||
AC_CHECK_FUNCS(dlopen, LIBDL_FOUND=yes, LIBDL_FOUND=no)
|
||||
if test "$LIBDL_FOUND" != "yes"; then
|
||||
AC_CHECK_LIB(dl, dlopen, [LIBDL_FOUND=yes; PLUGINS_LIBS=-ldl], LIBDL_FOUND=no)
|
||||
fi
|
||||
if test "$LIBDL_FOUND" = "yes"; then
|
||||
AC_DEFINE(PLUGINS)
|
||||
AC_SUBST(PLUGINS_LIBS)
|
||||
else
|
||||
AC_MSG_WARN([
|
||||
*** "dl" library (dynamic library loader) couldn't be found in your system.
|
||||
*** Try to install it with your software package manager or disable plugins.
|
||||
*** WeeChat will be built without any plugin.])
|
||||
enable_plugins="no"
|
||||
enable_perl="no"
|
||||
enable_python="no"
|
||||
enable_ruby="no"
|
||||
enable_lua="no"
|
||||
not_found="$not_found plugins"
|
||||
fi
|
||||
fi
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# gnutls
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
if test "x$enable_gnutls" = "xyes" ; then
|
||||
found_gnutls="no"
|
||||
AM_PATH_LIBGNUTLS( 1.0.0, found_gnutls=yes, AC_MSG_WARN([[
|
||||
*** libgnutls was not found. You may want to get it from
|
||||
*** ftp://ftp.gnutls.org/pub/gnutls/
|
||||
*** libgnutls was not found. You may want to get it from ftp://ftp.gnutls.org/pub/gnutls/
|
||||
*** WeeChat will be built without GnuTLS support.]]))
|
||||
if test "x$found_gnutls" = "xyes" ; then
|
||||
GNUTLS_LIBS="-lgnutls"
|
||||
AC_SUBST(GNUTLS_LIBS)
|
||||
GNUTLS_CFLAGS=`libgnutls-config --cflags`
|
||||
GNUTLS_LFLAGS=`libgnutls-config --libs`
|
||||
AC_SUBST(GNUTLS_CFLAGS)
|
||||
AC_SUBST(GNUTLS_LFLAGS)
|
||||
AC_DEFINE(HAVE_GNUTLS)
|
||||
else
|
||||
enable_gnutls="no"
|
||||
not_found="$not_found gnutls"
|
||||
fi
|
||||
fi
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# flock
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
enable_flock="no"
|
||||
AC_CACHE_CHECK([for flock() support], ac_have_flock, [
|
||||
AC_TRY_COMPILE(
|
||||
[ #include <sys/file.h>
|
||||
],
|
||||
[ flock(0, LOCK_SH); ],
|
||||
[ ac_have_flock="yes" ],
|
||||
[ ac_have_flock="no" ])])
|
||||
|
||||
if test "x$ac_have_flock" = "xyes"; then
|
||||
enable_flock="yes"
|
||||
AC_DEFINE(HAVE_FLOCK)
|
||||
fi
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# backtrace
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
enable_backtrace="no"
|
||||
if test "x$debug" != "x0" ; then
|
||||
AC_CACHE_CHECK([for execinfo.h and backtrace], ac_have_backtrace, [
|
||||
AC_TRY_COMPILE(
|
||||
[ #include <execinfo.h>
|
||||
],
|
||||
[ void *trace[128]; int n = backtrace(trace, 128); ],
|
||||
[ ac_have_backtrace="yes" ],
|
||||
[ ac_have_backtrace="no" ])])
|
||||
if test "x$ac_have_backtrace" = "xyes"; then
|
||||
enable_backtrace="yes"
|
||||
AC_DEFINE(HAVE_BACKTRACE,1,[glibc backtrace function])
|
||||
fi
|
||||
fi
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# general vars
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
if test "x$prefix" = "xNONE" ; then
|
||||
prefix="$ac_default_prefix"
|
||||
fi
|
||||
|
||||
if test "x$exec_prefix" = "xNONE" ; then
|
||||
exec_prefix="$prefix"
|
||||
fi
|
||||
|
||||
AC_DEFINE_UNQUOTED(PREFIX, "${prefix}")
|
||||
|
||||
WEECHAT_LIBDIR=`eval echo ${libdir}/weechat`
|
||||
AC_DEFINE_UNQUOTED(WEECHAT_LIBDIR, "$WEECHAT_LIBDIR")
|
||||
|
||||
WEECHAT_SHAREDIR=`eval echo ${datadir}/weechat`
|
||||
AC_DEFINE_UNQUOTED(WEECHAT_SHAREDIR, "$WEECHAT_SHAREDIR")
|
||||
|
||||
weechat_libdir=${libdir}/weechat
|
||||
AC_SUBST(weechat_libdir)
|
||||
|
||||
CFLAGS=`echo $CFLAGS | sed s/-g//g`
|
||||
if test "x$CFLAGS" = "x" ; then
|
||||
@@ -260,17 +573,67 @@ if test "x$debug" = "x2" ; then
|
||||
AC_DEFINE(DEBUG)
|
||||
fi
|
||||
|
||||
dnl For FreeBSD
|
||||
LIBS="$LIBS $INTLLIBS"
|
||||
CFLAGS="$CFLAGS $CPPFLAGS"
|
||||
|
||||
case "$host_os" in
|
||||
freebsd*)
|
||||
if test "x$enable_perl" = "xyes" -o "x$enable_python" = "xyes" ; then
|
||||
CFLAGS="$CFLAGS -pthread"
|
||||
fi
|
||||
CFLAGS="$CFLAGS $CPPFLAGS"
|
||||
;;
|
||||
openbsd*)
|
||||
if test "x$enable_python" = "xyes" ; then
|
||||
CFLAGS="$CFLAGS -pthread"
|
||||
fi
|
||||
;;
|
||||
netbsd*)
|
||||
if test "x$enable_perl" = "xyes" -o "x$enable_python" = "xyes" ; then
|
||||
CFLAGS="$CFLAGS -pthread"
|
||||
fi
|
||||
CFLAGS="$CFLAGS $CPPFLAGS"
|
||||
# bad hack
|
||||
LDFLAGS="$LDFLAGS -liconv"
|
||||
;;
|
||||
gnu*)
|
||||
if test "x$enable_plugins" = "xyes" ; then
|
||||
LDFLAGS="$LDFLAGS -lpthread"
|
||||
fi
|
||||
;;
|
||||
*)
|
||||
;;
|
||||
esac
|
||||
|
||||
# ------------------------------------------------------------------------------
|
||||
# output Makefiles
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
AM_CONDITIONAL(GUI_NCURSES, test "$enable_ncurses" = "yes")
|
||||
AM_CONDITIONAL(GUI_WXWIDGETS, test "$enable_wxwidgets" = "yes")
|
||||
AM_CONDITIONAL(GUI_GTK, test "$enable_gtk" = "yes")
|
||||
AM_CONDITIONAL(GUI_QT, test "$enable_qt" = "yes")
|
||||
AM_CONDITIONAL(PLUGINS, test "$enable_plugins" = "yes")
|
||||
AM_CONDITIONAL(PLUGIN_PERL, test "$enable_perl" = "yes")
|
||||
AM_CONDITIONAL(PLUGIN_PYTHON, test "$enable_python" = "yes")
|
||||
AM_CONDITIONAL(PLUGIN_RUBY, test "$enable_ruby" = "yes")
|
||||
AM_CONDITIONAL(PLUGIN_LUA, test "$enable_lua" = "yes")
|
||||
AM_CONDITIONAL(HAVE_GNUTLS, test "$enable_gnutls" = "yes")
|
||||
AM_CONDITIONAL(HAVE_FLOCK, test "$enable_flock" = "yes")
|
||||
|
||||
AC_OUTPUT([Makefile
|
||||
doc/Makefile
|
||||
doc/en/Makefile
|
||||
doc/fr/Makefile
|
||||
doc/de/Makefile
|
||||
src/Makefile
|
||||
src/common/Makefile
|
||||
src/irc/Makefile
|
||||
src/plugins/Makefile
|
||||
src/plugins/perl/Makefile
|
||||
src/plugins/python/Makefile
|
||||
src/plugins/scripts/Makefile
|
||||
src/plugins/scripts/perl/Makefile
|
||||
src/plugins/scripts/python/Makefile
|
||||
src/plugins/scripts/ruby/Makefile
|
||||
src/plugins/scripts/lua/Makefile
|
||||
src/gui/Makefile
|
||||
src/gui/curses/Makefile
|
||||
src/gui/wxwidgets/Makefile
|
||||
@@ -279,10 +642,11 @@ AC_OUTPUT([Makefile
|
||||
intl/Makefile
|
||||
po/Makefile.in])
|
||||
|
||||
echo
|
||||
echo $PACKAGE $VERSION
|
||||
# ------------------------------------------------------------------------------
|
||||
# end message
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
listgui=
|
||||
listgui=""
|
||||
if test "x$enable_ncurses" = "xyes" ; then
|
||||
listgui="$listgui ncurses"
|
||||
fi
|
||||
@@ -290,7 +654,7 @@ if test "x$enable_wxwidgets" = "xyes"; then
|
||||
listgui="$listgui WxWidgets"
|
||||
fi
|
||||
if test "x$enable_gtk" = "xyes" ; then
|
||||
listgui="$listgui Gtk+"
|
||||
listgui="$listgui Gtk"
|
||||
fi
|
||||
if test "x$enable_qt" = "xyes" ; then
|
||||
listgui="$listgui Qt"
|
||||
@@ -299,7 +663,13 @@ fi
|
||||
if test "x$listgui" = "x" ; then
|
||||
AC_MSG_ERROR([
|
||||
*** No interface specified...
|
||||
*** Please specify at least ncurses, WxWidgets, Gtk or Qt.])
|
||||
*** Please enable at least ncurses, WxWidgets, Gtk or Qt.])
|
||||
fi
|
||||
|
||||
if test "x$not_found" != "x" ; then
|
||||
echo ""
|
||||
echo "Following components were asked but not found, they will not be built:"
|
||||
echo "$not_found"
|
||||
fi
|
||||
|
||||
msg_debug_compiler="no"
|
||||
@@ -311,19 +681,20 @@ if test "x$debug" = "x2" ; then
|
||||
msg_debug_verbose="yes"
|
||||
fi
|
||||
|
||||
echo
|
||||
echo Interfaces.................... :$listgui
|
||||
echo
|
||||
echo Build with Plugin support..... : $enable_plugins
|
||||
echo Build with Perl support....... : $enable_perl
|
||||
echo Build with Python support..... : $enable_python
|
||||
echo Build with Ruby support....... : $enable_ruby
|
||||
echo Build with GNUtls support..... : $enable_gnutls
|
||||
echo
|
||||
echo Compile with debug info....... : $msg_debug_compiler
|
||||
echo Print debugging messages...... : $msg_debug_verbose
|
||||
echo
|
||||
eval eval echo WeeChat will be installed in $bindir.
|
||||
echo
|
||||
echo configure complete, now type \'make\' to build WeeChat
|
||||
echo
|
||||
echo ""
|
||||
echo "Interfaces........................ :$listgui"
|
||||
echo "Build with GNUtls support......... : $enable_gnutls"
|
||||
echo "Build with flock support.......... : $enable_flock"
|
||||
echo "Build with Plugin support......... : $enable_plugins"
|
||||
echo " Perl plugin......... : $enable_perl"
|
||||
echo " Python plugin....... : $enable_python"
|
||||
echo " Ruby plugin......... : $enable_ruby"
|
||||
echo " Lua plugin.......... : $enable_lua"
|
||||
echo "Compile with debug info........... : $msg_debug_compiler"
|
||||
echo " Backtrace........... : $enable_backtrace"
|
||||
echo "Print debugging messages.......... : $msg_debug_verbose"
|
||||
echo ""
|
||||
eval echo "WeeChat will be installed in $bindir."
|
||||
echo ""
|
||||
echo "configure complete, now type 'make' to build WeeChat $VERSION"
|
||||
echo ""
|
||||
|
||||
Vendored
+6
@@ -0,0 +1,6 @@
|
||||
weechat (0.1.6-1) unstable; urgency=low
|
||||
|
||||
This release introduces some incompatible changes with old scripts and locale
|
||||
support, you can read the upstream NEWS file for more information.
|
||||
|
||||
-- Julien Louis <ptitlouis@sysif.net> Fri, 11 Nov 2005 20:45:46 +0100
|
||||
Vendored
+210
@@ -1,3 +1,213 @@
|
||||
weechat (0.1.8-2) unstable; urgency=low
|
||||
|
||||
* Switch to cdbs
|
||||
* update debhelper compatibility to 5
|
||||
* update Build-Depends
|
||||
* update debian/copyright
|
||||
* Bump Standards-Version, no changes needed
|
||||
|
||||
-- Julien Louis <ptitlouis@sysif.net> Fri, 21 Apr 2006 22:39:00 +0200
|
||||
|
||||
weechat (0.1.8-1) unstable; urgency=low
|
||||
|
||||
* New upstream release
|
||||
* Add liblualib50-dev and docbook-xml to Build-Depends
|
||||
|
||||
-- Julien Louis <ptitlouis@sysif.net> Sat, 18 Mar 2006 11:32:52 +0100
|
||||
|
||||
weechat (0.1.7-2) unstable; urgency=low
|
||||
|
||||
* force linking against libpthread on GNU/Hurd (Closes: #350487)
|
||||
|
||||
-- Julien Louis <ptitlouis@sysif.net> Sun, 5 Feb 2006 18:23:24 +0100
|
||||
|
||||
weechat (0.1.7-1) unstable; urgency=low
|
||||
|
||||
* New upstream release
|
||||
|
||||
-- Julien Louis <ptitlouis@sysif.net> Sat, 14 Jan 2006 14:14:29 +0100
|
||||
|
||||
weechat (0.1.6-2) unstable; urgency=low
|
||||
|
||||
* Apply path to fix segfault when removing server.
|
||||
* Move plugins in a separate package
|
||||
|
||||
-- Julien Louis <ptitlouis@sysif.net> Tue, 22 Nov 2005 08:33:09 +0100
|
||||
|
||||
weechat (0.1.6-1) unstable; urgency=low
|
||||
|
||||
* New upstream release
|
||||
* Add menu entry
|
||||
* Move libperl5.8 and python2.3 from Depends to Recommends
|
||||
|
||||
-- Julien Louis <ptitlouis@sysif.net> Fri, 11 Nov 2005 22:21:08 +0100
|
||||
|
||||
weechat (0.1.5-1) unstable; urgency=low
|
||||
|
||||
* New upstream release
|
||||
|
||||
-- Julien Louis <ptitlouis@sysif.net> Sat, 24 Sep 2005 14:08:55 +0200
|
||||
|
||||
weechat (0.1.4-2) unstable; urgency=low
|
||||
|
||||
* Add autotools-dev to Build-Depends.
|
||||
* update autotools stuff automatically to always
|
||||
have up-to-date config.{guess,sub}
|
||||
* Update Build-Depends: libgnutls11-dev -> libgnutls-dev
|
||||
|
||||
-- Julien Louis <ptitlouis@sysif.net> Mon, 1 Aug 2005 11:46:39 +0200
|
||||
|
||||
weechat (0.1.4-1) unstable; urgency=low
|
||||
|
||||
* New upstream release.
|
||||
|
||||
-- Julien Louis <ptitlouis@sysif.net> Sat, 30 Jul 2005 16:26:55 +0200
|
||||
|
||||
weechat (0.1.3-2) unstable; urgency=low
|
||||
|
||||
* Update config.{guess,sub} to fix FTBFS on k*BSD (Closes: #316791)
|
||||
|
||||
-- Julien Louis <ptitlouis@sysif.net> Fri, 8 Jul 2005 21:30:38 +0200
|
||||
|
||||
weechat (0.1.3-1) unstable; urgency=low
|
||||
|
||||
* New upstream release.
|
||||
|
||||
-- Julien Louis <ptitlouis@sysif.net> Sat, 2 Jul 2005 20:06:29 +0200
|
||||
|
||||
weechat (0.1.2-3) unstable; urgency=low
|
||||
|
||||
* Apply patch against gui-display.c to fix curses color bug.
|
||||
* remove dh_install --sourcedir to allow builds on woody.
|
||||
|
||||
-- Julien Louis <ptitlouis@sysif.net> Sun, 19 Jun 2005 22:37:11 +0200
|
||||
|
||||
weechat (0.1.2-2) unstable; urgency=low
|
||||
|
||||
* Patch src/gui/curse/gui-display.c to fix segfault
|
||||
when config file does not exists (Closes: #310589).
|
||||
|
||||
-- Julien Louis <ptitlouis@sysif.net> Tue, 24 May 2005 20:55:02 +0200
|
||||
|
||||
weechat (0.1.2-1) unstable; urgency=low
|
||||
|
||||
* WeeChat version 0.1.2, see ChangeLog for detail.
|
||||
|
||||
-- Sebastien Helleu <flashcode@flashtux.org> Sat, 21 May 2005 08:00:00 +0200
|
||||
|
||||
weechat (0.1.1-2) unstable; urgency=low
|
||||
|
||||
* debian/control:
|
||||
- Add myself to uploaders.
|
||||
- Remove unecessary dependency on weechat-gtk (Closes: #308287).
|
||||
|
||||
-- Julien Louis <ptitlouis@sysif.net> Tue, 10 May 2005 22:38:52 +0200
|
||||
|
||||
weechat (0.1.1-1) unstable; urgency=low
|
||||
|
||||
* WeeChat version 0.1.1, see ChangeLog for detail (closes: #306492)
|
||||
|
||||
-- Sebastien Helleu <flashcode@flashtux.org> Sat, 20 Mar 2005 08:00:00 +0200
|
||||
|
||||
weechat (0.1.0-1) unstable; urgency=low
|
||||
|
||||
* WeeChat version 0.1.0, see ChangeLog for detail.
|
||||
|
||||
-- Sebastien Helleu <flashcode@flashtux.org> Sat, 12 Feb 2005 12:00:00 +0200
|
||||
|
||||
weechat (0.0.9-1) unstable; urgency=low
|
||||
|
||||
* WeeChat version 0.0.9, see ChangeLog for detail.
|
||||
|
||||
-- FlashCode <flashcode@flashtux.org> Sat, 01 Jan 2005 13:00:00 +0200
|
||||
|
||||
weechat (0.0.8-1) unstable; urgency=low
|
||||
|
||||
* WeeChat version 0.0.8, see ChangeLog for detail.
|
||||
|
||||
-- FlashCode <flashcode@flashtux.org> Sat, 30 Oct 2004 11:40:00 +0200
|
||||
|
||||
weechat (0.0.7-1) unstable; urgency=low
|
||||
|
||||
* WeeChat version 0.0.7, see ChangeLog for detail.
|
||||
|
||||
-- FlashCode <flashcode@flashtux.org> Sat, 08 Aug 2004 21:00:00 +0200
|
||||
|
||||
weechat (0.0.6-1) unstable; urgency=low
|
||||
|
||||
* WeeChat version 0.0.6, see ChangeLog for detail.
|
||||
|
||||
-- FlashCode <flashcode@flashtux.org> Sat, 05 Jun 2004 11:30:00 +0200
|
||||
|
||||
weechat (0.0.5-1) unstable; urgency=low
|
||||
|
||||
* WeeChat version 0.0.5, see ChangeLog for detail.
|
||||
|
||||
-- FlashCode <flashcode@flashtux.org> Sat, 07 Feb 2004 20:30:00 +0200
|
||||
|
||||
weechat (0.0.4-1) unstable; urgency=low
|
||||
|
||||
* WeeChat version 0.0.4, see ChangeLog for detail.
|
||||
|
||||
-- FlashCode <flashcode@flashtux.org> Thu, 01 Jan 2004 13:00:00 +0200
|
||||
|
||||
weechat (0.0.3-1) unstable; urgency=low
|
||||
|
||||
* WeeChat version 0.0.3, see ChangeLog for detail.
|
||||
|
||||
-- FlashCode <flashcode@flashtux.org> Mon, 03 Nov 2003 23:15:00 +0200
|
||||
|
||||
weechat (0.0.2-1) unstable; urgency=low
|
||||
|
||||
* WeeChat version 0.0.2, see ChangeLog for detail.
|
||||
|
||||
-- FlashCode <flashcode@flashtux.org> Sun, 05 Oct 2003 12:00:00 +0200
|
||||
|
||||
weechat (0.0.1-1) unstable; urgency=low
|
||||
|
||||
* First version.
|
||||
|
||||
-- FlashCode <flashcode@flashtux.org> Sat, 27 Sep 2003 12:00:00 +0200
|
||||
weechat (0.1.5-1) unstable; urgency=low
|
||||
|
||||
* New upstream release
|
||||
|
||||
-- Julien Louis <ptitlouis@sysif.net> Sat, 24 Sep 2005 14:08:55 +0200
|
||||
|
||||
weechat (0.1.4-2) unstable; urgency=low
|
||||
|
||||
* Add autotools-dev to Build-Depends.
|
||||
* update autotools stuff automatically to always
|
||||
have up-to-date config.{guess,sub}
|
||||
* Update Build-Depends: libgnutls11-dev -> libgnutls-dev
|
||||
|
||||
-- Julien Louis <ptitlouis@sysif.net> Mon, 1 Aug 2005 11:46:39 +0200
|
||||
|
||||
weechat (0.1.4-1) unstable; urgency=low
|
||||
|
||||
* New upstream release.
|
||||
|
||||
-- Julien Louis <ptitlouis@sysif.net> Sat, 30 Jul 2005 16:26:55 +0200
|
||||
|
||||
weechat (0.1.3-2) unstable; urgency=low
|
||||
|
||||
* Update config.{guess,sub} to fix FTBFS on k*BSD (Closes: #316791)
|
||||
|
||||
-- Julien Louis <ptitlouis@sysif.net> Fri, 8 Jul 2005 21:30:38 +0200
|
||||
|
||||
weechat (0.1.3-1) unstable; urgency=low
|
||||
|
||||
* New upstream release.
|
||||
|
||||
-- Julien Louis <ptitlouis@sysif.net> Sat, 2 Jul 2005 20:06:29 +0200
|
||||
|
||||
weechat (0.1.2-3) unstable; urgency=low
|
||||
|
||||
* Apply patch against gui-display.c to fix curses color bug.
|
||||
* remove dh_install --sourcedir to allow builds on woody.
|
||||
|
||||
-- Julien Louis <ptitlouis@sysif.net> Sun, 19 Jun 2005 22:37:11 +0200
|
||||
|
||||
weechat (0.1.2-2) unstable; urgency=low
|
||||
|
||||
* Patch src/gui/curse/gui-display.c to fix segfault
|
||||
|
||||
Vendored
+1
-1
@@ -1 +1 @@
|
||||
4
|
||||
5
|
||||
|
||||
Vendored
+32
-6
@@ -3,8 +3,8 @@ Section: net
|
||||
Priority: optional
|
||||
Maintainer: Sebastien Helleu <flashcode@flashtux.org>
|
||||
Uploaders: Julien Louis <ptitlouis@sysif.net>
|
||||
Build-Depends: debhelper (>> 4.0.4), libncurses5-dev (>= 5.2.20020112a-7), libperl-dev, python-dev
|
||||
Standards-Version: 3.6.1
|
||||
Build-Depends: cdbs, debhelper (>= 5), libncursesw5-dev, ruby, ruby1.8-dev, libperl-dev, python-dev, liblualib50-dev, libgnutls-dev, libtool, xsltproc, docbook-xsl, docbook-xml
|
||||
Standards-Version: 3.7.2
|
||||
|
||||
Package: weechat
|
||||
Architecture: all
|
||||
@@ -12,20 +12,46 @@ Depends: weechat-common (= ${Source-Version}), weechat-curses (= ${Source-Versio
|
||||
Description: Fast, light and extensible IRC client
|
||||
WeeChat (Wee Enhanced Environment for Chat) is a fast and light IRC client
|
||||
for many operating systems. Everything can be done with a keyboard.
|
||||
It is customizable and extensible with scripts.
|
||||
It is customizable and extensible with plugins/scripts, and includes:
|
||||
- nicklist
|
||||
- smart hotlist
|
||||
- infobar with highlight notification
|
||||
- horizontal and vertical split
|
||||
- double charset support (decode/encode)
|
||||
- FIFO pipe for remote control
|
||||
- and much more!
|
||||
.
|
||||
Homepage: http://weechat.flashtux.org/
|
||||
|
||||
Package: weechat-curses
|
||||
Architecture: any
|
||||
Depends: ${shlibs:Depends}, weechat-common (= ${Source-Version})
|
||||
Recommends: weechat-plugins (= ${Source-Version})
|
||||
Description: Fast, light and extensible IRC client
|
||||
WeeChat (Wee Enhanced Environment for Chat) is a fast and light IRC client
|
||||
for many operating systems. Everything can be done with a keyboard.
|
||||
It is customizable and extensible with scripts.
|
||||
It is customizable and extensible with plugins/scripts, and includes:
|
||||
- nicklist
|
||||
- smart hotlist
|
||||
- infobar with highlight notification
|
||||
- horizontal and vertical split
|
||||
- double charset support (decode/encode)
|
||||
- FIFO pipe for remote control
|
||||
- and much more!
|
||||
.
|
||||
Homepage: http://weechat.flashtux.org/
|
||||
|
||||
Package: weechat-common
|
||||
Architecture: all
|
||||
Replaces: weechat
|
||||
Recommends: weechat-curses | weechat-gtk
|
||||
Recommends: weechat-curses
|
||||
Description: Common files for WeeChat
|
||||
Documentation, examples, and locale files for WeeChat - fast, light and
|
||||
extensible IRC client. It is useless without weechat-curses or weechat-gtk.
|
||||
extensible IRC client. It is useless without weechat-curses.
|
||||
|
||||
Package: weechat-plugins
|
||||
Architecture: any
|
||||
Depends: ${shlibs:Depends}
|
||||
Description: Plugins for WeeChat
|
||||
This package provides some plugins to enhance weechat with scripting languages
|
||||
such as perl python or ruby.
|
||||
|
||||
Vendored
+3
-1
@@ -3,7 +3,9 @@ Sat, 21 May 2005 08:00:00 +0200.
|
||||
|
||||
It was downloaded from http://weechat.flashtux.org/download
|
||||
|
||||
Upstream Author: FlashCode <flashcode@flashtux.org>
|
||||
Upstream Authors:
|
||||
- FlashCode <flashcode@flashtux.org>
|
||||
- kolter <kolter@free.fr>
|
||||
|
||||
Copyright:
|
||||
|
||||
|
||||
Vendored
+23
-70
@@ -1,81 +1,34 @@
|
||||
#!/usr/bin/make -f
|
||||
# Sample debian/rules that uses cdbs. Originaly written by Robert Millan.
|
||||
# This file is public domain.
|
||||
|
||||
#export DH_VERBOSE=1
|
||||
DEB_AUTO_CLEANUP_RCS := yes
|
||||
|
||||
# Add here any variable or target overrides you need
|
||||
|
||||
DEB_CONFIGURE_USER_FLAGS := --with-debug=0
|
||||
DEB_STRIP_EXCLUDE := libperl.a
|
||||
DEB_DH_INSTALL_SOURCEDIR := $(CURDIR)/debian/tmp
|
||||
DEB_INSTALL_DOCS_weechat-common := FAQ FAQ.fr
|
||||
DEB_DH_MAKESHLIBS_ARGS_weechat-plugins := -n
|
||||
|
||||
DEB_HOST_ARCH_OS := $(shell dpkg-architecture -qDEB_HOST_ARCH_OS)
|
||||
|
||||
ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
|
||||
CFLAGS += -O0
|
||||
CFLAGS += -O0
|
||||
else
|
||||
CFLAGS += -O2
|
||||
CFLAGS += -O2
|
||||
endif
|
||||
ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
|
||||
INSTALL_PROGRAM += -s
|
||||
INSTALL_PROGRAM += -s
|
||||
endif
|
||||
|
||||
configure: configure-stamp
|
||||
configure-stamp:
|
||||
dh_testdir
|
||||
./configure --prefix=/usr --sysconfdir=/etc --mandir=\$${prefix}/share/man \
|
||||
--enable-perl --enable-python
|
||||
touch configure-stamp
|
||||
ifeq ($(DEB_HOST_ARCH_OS),hurd)
|
||||
DEB_CONFIGURE_SCRIPT_ENV += LDFLAGS="-lpthread"
|
||||
endif
|
||||
|
||||
include /usr/share/cdbs/1/class/autotools.mk
|
||||
include /usr/share/cdbs/1/rules/debhelper.mk
|
||||
|
||||
build: build-stamp
|
||||
|
||||
build-stamp: configure-stamp
|
||||
dh_testdir
|
||||
$(MAKE)
|
||||
touch build-stamp
|
||||
|
||||
clean:
|
||||
dh_testdir
|
||||
dh_testroot
|
||||
rm -f build-stamp configure-stamp
|
||||
-$(MAKE) distclean
|
||||
dh_clean
|
||||
|
||||
install: build
|
||||
dh_testdir
|
||||
dh_testroot
|
||||
dh_clean -k
|
||||
dh_installdirs
|
||||
$(MAKE) install DESTDIR=$(CURDIR)/debian/weechat
|
||||
dh_install --sourcedir=debian/weechat
|
||||
install -o root -g root -m 755 src/gui/curses/weechat-curses $(CURDIR)/debian/weechat-curses/usr/bin
|
||||
# install -o root -g root -m 755 src/gui/gtk/weechat-gtk $(CURDIR)/debian/weechat-gtk/usr/bin
|
||||
|
||||
|
||||
# Build architecture-independent files here.
|
||||
binary-indep: build install
|
||||
dh_testdir -pweechat-common -pweechat
|
||||
dh_testroot -pweechat-common -pweechat
|
||||
dh_installchangelogs ChangeLog -pweechat-common
|
||||
dh_installdocs -pweechat-common
|
||||
dh_installexamples -pweechat-common
|
||||
dh_compress -pweechat-common -pweechat
|
||||
dh_link -pweechat usr/share/doc/weechat-common usr/share/doc/weechat
|
||||
dh_fixperms -pweechat-common -pweechat
|
||||
dh_installdeb -pweechat-common -pweechat
|
||||
dh_shlibdeps -pweechat-common -pweechat
|
||||
dh_gencontrol -pweechat-common -pweechat
|
||||
dh_md5sums -pweechat-common -pweechat
|
||||
dh_builddeb -pweechat-common -pweechat
|
||||
|
||||
# Build architecture-dependent files here.
|
||||
binary-arch: build install
|
||||
dh_testdir -a
|
||||
dh_testroot -a
|
||||
# dh_installchangelogs -a
|
||||
# dh_installdocs -a
|
||||
dh_installman weechat-curses.1 -pweechat-curses
|
||||
dh_link -a usr/share/doc/weechat-common usr/share/doc/weechat-curses
|
||||
dh_strip -a
|
||||
dh_compress -a
|
||||
dh_fixperms -a
|
||||
dh_installdeb -a
|
||||
dh_shlibdeps -a
|
||||
dh_gencontrol -a
|
||||
dh_md5sums -a
|
||||
dh_builddeb -a
|
||||
|
||||
binary: binary-indep binary-arch
|
||||
.PHONY: build clean binary-indep binary-arch binary install configure
|
||||
install/weechat-common::
|
||||
install -D -o root -g root -m 644 weechat_icon_32.png $(CURDIR)/debian/weechat-common/usr/share/pixmaps/weechat_icon_32.png
|
||||
|
||||
Vendored
+2
@@ -0,0 +1,2 @@
|
||||
version=2
|
||||
http://weechat.flashtux.org/download/weechat-(\d.*)\.tar\.bz2
|
||||
Vendored
+2
-1
@@ -1 +1,2 @@
|
||||
usr/share/locale
|
||||
usr/share/locale/
|
||||
usr/share/doc/weechat/html usr/share/doc/weechat-common
|
||||
|
||||
Vendored
+4
@@ -0,0 +1,4 @@
|
||||
?package(weechat-curses):needs="text" section="Apps/Net" \
|
||||
title="weechat-curses" \
|
||||
icon="/usr/share/pixmaps/weechat_icon_32.png" \
|
||||
command="/usr/bin/weechat-curses"
|
||||
Vendored
+1
@@ -0,0 +1 @@
|
||||
usr/lib
|
||||
Vendored
+1
@@ -0,0 +1 @@
|
||||
usr/lib/weechat/plugins/*so*
|
||||
@@ -1,36 +0,0 @@
|
||||
# Copyright (c) 2003-2005 FlashCode <flashcode@flashtux.org>
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; either version 2 of the License, or
|
||||
# (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
#
|
||||
|
||||
all: weechat_doc_fr.texi weechat_doc_en.texi weechat_doc_pt.texi weechat_doc_es.texi
|
||||
export LANG=fr_FR && makeinfo --html --no-split --number-sections weechat_doc_fr.texi
|
||||
export LANG=fr_FR && makeinfo --no-headers --no-warn --no-split --number-sections weechat_doc_fr.texi >weechat_doc_fr.txt
|
||||
export LANG=en_EN && makeinfo --html --no-split --number-sections weechat_doc_en.texi
|
||||
export LANG=en_EN && makeinfo --no-headers --no-warn --no-split --number-sections weechat_doc_en.texi >weechat_doc_en.txt
|
||||
export LANG=es_ES && makeinfo --html --no-split --number-sections weechat_doc_es.texi
|
||||
export LANG=es_ES && makeinfo --no-headers --no-warn --no-split --number-sections weechat_doc_es.texi >weechat_doc_es.txt
|
||||
export LANG=pt_PT && makeinfo --html --no-split --number-sections weechat_doc_pt.texi
|
||||
export LANG=pt_PT && makeinfo --no-headers --no-warn --no-split --number-sections weechat_doc_pt.texi >weechat_doc_pt.txt
|
||||
export LANG=fr_FR && texi2pdf weechat_doc_fr.texi
|
||||
export LANG=en_EN && texi2pdf weechat_doc_en.texi
|
||||
export LANG=es_ES && texi2pdf weechat_doc_es.texi
|
||||
export LANG=pt_PT && texi2pdf weechat_doc_pt.texi
|
||||
|
||||
clean:
|
||||
rm -rf weechat_doc_*.aux weechat_doc_*.cp weechat_doc_*.fn \
|
||||
weechat_doc_*.html weechat_doc_*.ky weechat_doc_*.log \
|
||||
weechat_doc_*.pdf weechat_doc_*.pg weechat_doc_*.toc \
|
||||
weechat_doc_*.tp weechat_doc_*.txt weechat_doc_*.vr
|
||||
@@ -0,0 +1,22 @@
|
||||
# Copyright (c) 2003-2006 FlashCode <flashcode@flashtux.org>
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; either version 2 of the License, or
|
||||
# (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
#
|
||||
|
||||
SUBDIRS = en fr de
|
||||
|
||||
man_MANS = weechat-curses.1
|
||||
|
||||
EXTRA_DIST = $(man_MANS) weechat-doc.css weechat-html-one.xsl weechat-html.xsl
|
||||
Executable
+189
@@ -0,0 +1,189 @@
|
||||
#!/usr/bin/perl
|
||||
#
|
||||
# Copyright (c) 2003-2006 FlashCode <flashcode@flashtux.org>
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; either version 2 of the License, or
|
||||
# (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
#
|
||||
|
||||
#
|
||||
# Build some XML code for WeeChat doc
|
||||
# with weechat-curses command
|
||||
#
|
||||
|
||||
@all_lang = ("fr_FR", "en_US", "de_DE");
|
||||
%all_encodings = ("fr_FR" => "iso-8859-1",
|
||||
"en_US" => "iso-8859-1",
|
||||
"de_DE" => "iso-8859-1");
|
||||
%all_types = ("fr_FR" => "type",
|
||||
"en_US" => "type",
|
||||
"de_DE" => "Typ",
|
||||
"es_ES" => "tipo");
|
||||
%all_values = ("fr_FR" => "valeurs",
|
||||
"en_US" => "values",
|
||||
"de_DE" => "Werte",
|
||||
"es_ES" => "valores");
|
||||
%all_default = ("fr_FR" => "valeur par défaut",
|
||||
"en_US" => "default value",
|
||||
"de_DE" => "Standardwert",
|
||||
"es_ES" => "valor por defecto");
|
||||
%all_desc = ("fr_FR" => "description",
|
||||
"en_US" => "description",
|
||||
"de_DE" => "Beschreibung",
|
||||
"es_ES" => "descripciĂłn");
|
||||
$warning_do_not_edit = "\n<!-- ********* WARNING! *********\n\n"
|
||||
." This file is automatically built with a Perl script. DO NOT EDIT!\n"
|
||||
."-->\n\n";
|
||||
|
||||
foreach $lng (@all_lang)
|
||||
{
|
||||
create_commands ($lng, $all_encodings{$lng},
|
||||
"weechat-curses -w | tail +3", "weechat_commands");
|
||||
create_commands ($lng, $all_encodings{$lng},
|
||||
"weechat-curses -i | tail +3", "irc_commands");
|
||||
create_key_func ($lng, $all_encodings{$lng},
|
||||
"weechat-curses -f | tail +3", "key_functions");
|
||||
create_config ($lng, $all_encodings{$lng},
|
||||
"weechat-curses -c | tail +3", "config");
|
||||
print "\n";
|
||||
}
|
||||
|
||||
sub toxml
|
||||
{
|
||||
$_ = $_[0];
|
||||
$_ =~ s/&/&/g;
|
||||
$_ =~ s/</</g;
|
||||
$_ =~ s/>/>/g;
|
||||
return $_;
|
||||
}
|
||||
|
||||
sub create_commands
|
||||
{
|
||||
$lang = $_[0];
|
||||
$lang2 = substr ($lang, 0, 2);
|
||||
$encoding = $_[1];
|
||||
$command = $_[2];
|
||||
$file = $_[3];
|
||||
print "Creating $lang2/$file.xml ($lang)...\n";
|
||||
open XML, ">$lang2/$file.xml" or die "Error: can't write file!";
|
||||
print XML "<?xml version=\"1.0\" encoding=\"$encoding\"?>\n";
|
||||
print XML $warning_do_not_edit;
|
||||
|
||||
$started = 0;
|
||||
$ENV{"LANG"} = $lang;
|
||||
foreach (`$command`)
|
||||
{
|
||||
if (/\* (.*)/)
|
||||
{
|
||||
print XML "</programlisting>\n" if ($started == 1);
|
||||
$started = 1;
|
||||
print XML "<command>".toxml($1)."</command>\n";
|
||||
print XML "<programlisting>";
|
||||
}
|
||||
else
|
||||
{
|
||||
chomp ($_);
|
||||
print XML toxml($_)."\n";
|
||||
}
|
||||
}
|
||||
print XML "</programlisting>\n";
|
||||
close XML;
|
||||
iconv_file ($lang2."/".$file, $encoding);
|
||||
}
|
||||
|
||||
sub create_key_func
|
||||
{
|
||||
$lang = $_[0];
|
||||
$lang2 = substr ($lang, 0, 2);
|
||||
$encoding = $_[1];
|
||||
$command = $_[2];
|
||||
$file = $_[3];
|
||||
print "Creating $lang2/$file.xml ($lang)...\n";
|
||||
open XML, ">$lang2/$file.xml" or die "Error: can't write file!";
|
||||
print XML "<?xml version=\"1.0\" encoding=\"$encoding\"?>\n";
|
||||
print XML $warning_do_not_edit;
|
||||
|
||||
$ENV{"LANG"} = $lang;
|
||||
foreach (`$command`)
|
||||
{
|
||||
if (/\* (.*): (.*)/)
|
||||
{
|
||||
print XML "<row>\n";
|
||||
print XML " <entry><literal>$1</literal></entry>\n";
|
||||
print XML " <entry>$2</entry>\n";
|
||||
print XML "</row>\n";
|
||||
}
|
||||
}
|
||||
close XML;
|
||||
iconv_file ($lang2."/".$file, $encoding);
|
||||
}
|
||||
|
||||
sub create_config
|
||||
{
|
||||
$lang = $_[0];
|
||||
$lang2 = substr ($lang, 0, 2);
|
||||
$encoding = $_[1];
|
||||
$command = $_[2];
|
||||
$file = $_[3];
|
||||
print "Creating $lang2/$file.xml ($lang)...\n";
|
||||
open XML, ">$lang2/$file.xml" or die "Error: can't write file!";
|
||||
print XML "<?xml version=\"1.0\" encoding=\"$encoding\"?>\n";
|
||||
print XML $warning_do_not_edit;
|
||||
$type = "";
|
||||
$values = "";
|
||||
$default = "";
|
||||
$desc = "";
|
||||
|
||||
$ENV{"LANG"} = $lang;
|
||||
foreach (`weechat-curses -c`)
|
||||
{
|
||||
if (/\* (.*):/)
|
||||
{
|
||||
print XML "<row>\n";
|
||||
print XML " <entry><option>$1</option></entry>\n";
|
||||
}
|
||||
elsif (/ \. $all_types{$lang}: (.*)/)
|
||||
{
|
||||
$type = $1;
|
||||
}
|
||||
elsif (/ \. $all_values{$lang}: (.*)/)
|
||||
{
|
||||
$values = $1;
|
||||
}
|
||||
elsif (/ \. $all_default{$lang}: (.*)/)
|
||||
{
|
||||
$default = $1;
|
||||
}
|
||||
elsif (/ \. $all_desc{$lang}: (.*)/)
|
||||
{
|
||||
$_ = $1;
|
||||
s/(.*)/\u$1/;
|
||||
$desc = $_;
|
||||
print XML " <entry>".toxml($type)."</entry>\n";
|
||||
print XML " <entry>".toxml($values)."</entry>\n";
|
||||
print XML " <entry>".toxml($default)."</entry>\n";
|
||||
print XML " <entry>".toxml($desc)."</entry>\n";
|
||||
print XML "</row>\n";
|
||||
}
|
||||
}
|
||||
close XML;
|
||||
iconv_file ($lang2."/".$file, $encoding);
|
||||
}
|
||||
|
||||
sub iconv_file
|
||||
{
|
||||
print "Converting $_[0].xml to $_[1]...\n";
|
||||
system ("iconv -t $encoding -o $_[0].xml.$_[1] $_[0].xml");
|
||||
system ("mv $_[0].xml.$_[1] $_[0].xml");
|
||||
}
|
||||
@@ -0,0 +1,61 @@
|
||||
# Copyright (c) 2003-2006 FlashCode <flashcode@flashtux.org>
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; either version 2 of the License, or
|
||||
# (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
#
|
||||
|
||||
LANGCODE = de
|
||||
BOOK = weechat.$(LANGCODE)
|
||||
BOOK_INCLUDE = weechat_commands.xml irc_commands.xml key_functions.xml config.xml
|
||||
|
||||
EXTRA_DIST = $(BOOK).xml $(BOOK_INCLUDE)
|
||||
|
||||
docdir = $(datadir)/doc/$(PACKAGE)
|
||||
|
||||
all-local: html-stamp
|
||||
|
||||
# HTML output with chunks (many pages)
|
||||
|
||||
html: html-stamp
|
||||
|
||||
html-stamp: $(BOOK).xml $(BOOK_INCLUDE) ../weechat-html.xsl ../weechat-doc.css
|
||||
echo "<pubdate>`date -R`</pubdate>" >date.xml
|
||||
mkdir -p html/
|
||||
xsltproc -o html/ ../weechat-html.xsl $(BOOK).xml || true
|
||||
cp ../weechat-doc.css html/
|
||||
touch html-stamp
|
||||
|
||||
# HTML output, all in one page
|
||||
|
||||
html1: html1-stamp
|
||||
|
||||
html1-stamp: $(BOOK).xml $(BOOK_INCLUDE) ../weechat-html-one.xsl ../weechat-doc.css
|
||||
echo "<pubdate>`date -R`</pubdate>" >date.xml
|
||||
mkdir -p html1/
|
||||
xsltproc -o html1/$(BOOK).html ../weechat-html-one.xsl $(BOOK).xml || true
|
||||
cp ../weechat-doc.css html1/
|
||||
touch html1-stamp
|
||||
|
||||
# install docs
|
||||
|
||||
install-data-hook:
|
||||
$(mkinstalldirs) $(DESTDIR)$(docdir)/html/$(LANGCODE)/
|
||||
$(INSTALL_DATA) html/* $(DESTDIR)$(docdir)/html/$(LANGCODE)/
|
||||
|
||||
# clean
|
||||
|
||||
clean-local:
|
||||
-rm -f *.html *.pdf *.txt date.xml
|
||||
-rm -rf html/ html1/
|
||||
-rm -f html-stamp html1-stamp
|
||||
+1246
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,443 @@
|
||||
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||
|
||||
<!-- ********* WARNING! *********
|
||||
|
||||
This file is automatically built with a Perl script. DO NOT EDIT!
|
||||
-->
|
||||
|
||||
<command>admin [Ziel]</command>
|
||||
<programlisting>
|
||||
Information ĂĽber den Server-Administrator abfragen
|
||||
|
||||
Ziel: Server
|
||||
|
||||
</programlisting>
|
||||
<command>ame Nachricht</command>
|
||||
<programlisting>
|
||||
Nachricht an alle Channels aller verbundenen Server schicken
|
||||
|
||||
zu sendende Nachricht
|
||||
|
||||
</programlisting>
|
||||
<command>amsg Text</command>
|
||||
<programlisting>
|
||||
Nachricht an alle Channels aller verbundener Server schicken
|
||||
|
||||
Text: zu sendender Text
|
||||
|
||||
</programlisting>
|
||||
<command>away [-all] [Nachricht]</command>
|
||||
<programlisting>
|
||||
Abwesenheitsnachricht ein/ausschalten
|
||||
|
||||
-all: Abwesenheitszustand auf allen Servern ändern
|
||||
Nachricht: Abwesenheitsnachricht (bzw. keine, um den Abwesenheitszustand zu deaktivieren)
|
||||
|
||||
</programlisting>
|
||||
<command>ban [Channel] [Nickname [Nickname ...]]</command>
|
||||
<programlisting>
|
||||
Nicknames oder Hosts sperren/verbannen
|
||||
|
||||
Channel: Channel fĂĽr die Sperre
|
||||
Nickname: zu sperrender User oder Host
|
||||
|
||||
</programlisting>
|
||||
<command>ctcp Nickname Typ [Argumente]</command>
|
||||
<programlisting>
|
||||
CTCP-Nachricht verschicken
|
||||
|
||||
Nickname: User, an den die CTCP-Nachricht geschickt werden soll
|
||||
Typ: Typ der CTCP-Nachricht (z.B. "version", "ping", ...)
|
||||
Argumente: Argumente fĂĽr CTCP
|
||||
|
||||
</programlisting>
|
||||
<command>cycle [Channel[,Channel]] [Abschiedsnachricht]</command>
|
||||
<programlisting>
|
||||
einen Channel verlassen und wieder betreten
|
||||
|
||||
Channel: zu verlassender Channel
|
||||
Abschiedsnachricht: Abschiedsnachricht (die den anderen Usern angezeigt wird)
|
||||
|
||||
</programlisting>
|
||||
<command>dehalfop Nickname [Nickname]</command>
|
||||
<programlisting>
|
||||
Halb-Operatorstatus aberkennen
|
||||
|
||||
</programlisting>
|
||||
<command>deop Nickname [Nickname]</command>
|
||||
<programlisting>
|
||||
Operatorstatus aberkennen
|
||||
|
||||
</programlisting>
|
||||
<command>devoice Nickname [Nickname]</command>
|
||||
<programlisting>
|
||||
Voice wegnehmen
|
||||
|
||||
</programlisting>
|
||||
<command>die</command>
|
||||
<programlisting>
|
||||
Server herunterfahren
|
||||
|
||||
</programlisting>
|
||||
<command>halfop Nickname [Nickname]</command>
|
||||
<programlisting>
|
||||
Halb-Operatorstatus verleihen
|
||||
|
||||
</programlisting>
|
||||
<command>info [Ziel]</command>
|
||||
<programlisting>
|
||||
Information ĂĽber den Server abfragen
|
||||
|
||||
Ziel: Servername
|
||||
|
||||
</programlisting>
|
||||
<command>invite Nickname Channel</command>
|
||||
<programlisting>
|
||||
jemanden in einen Channel einladen
|
||||
|
||||
Nickname: Chatname des Einzuladenden
|
||||
Channel: Channel, in den er eingeladen werden soll
|
||||
|
||||
</programlisting>
|
||||
<command>ison Nickname [Nickname ...]</command>
|
||||
<programlisting>
|
||||
ĂĽberprĂĽfen, ob jemand zur Zeit im IRC ist
|
||||
|
||||
Nickname: Nickname
|
||||
|
||||
</programlisting>
|
||||
<command>join Channel[,Channel] [Passwort[,Passwort]]</command>
|
||||
<programlisting>
|
||||
einen Channel betreten
|
||||
|
||||
Channel: zu betretender Channel
|
||||
Passwort: Channelpasswort (+k-Mode)
|
||||
|
||||
</programlisting>
|
||||
<command>kick [Channel] Nickname [Kommentar]</command>
|
||||
<programlisting>
|
||||
einen User aus einem Channel herauskicken
|
||||
|
||||
Channel: Channel des Benutzers
|
||||
Nickname: Nickname des Benutzers
|
||||
Kommentar: BegrĂĽndung fĂĽr den Kick
|
||||
|
||||
</programlisting>
|
||||
<command>kickban [Channel] Nickname [Kommentar]</command>
|
||||
<programlisting>
|
||||
kickt und verbannt jemanden von einem Channel
|
||||
|
||||
Channel: Channel des Benutzers
|
||||
Nickname: Nickname des Benutzers
|
||||
Kommentar: BegrĂĽndung fĂĽr den Kickban
|
||||
|
||||
</programlisting>
|
||||
<command>kill Nickname Kommentar</command>
|
||||
<programlisting>
|
||||
Jemanden vom Server werfen
|
||||
|
||||
Nickname: Chatname
|
||||
Kommentar: BegrĂĽndung
|
||||
|
||||
</programlisting>
|
||||
<command>links [[Server] Servermaske]</command>
|
||||
<programlisting>
|
||||
Alle dem antwortenden Server bekannten Servernamen auflisten
|
||||
|
||||
Server: dieser Server soll die Anfrage beantworten
|
||||
Servermaske: die aufzulistenden Server sollen diesem Muster entsprechen
|
||||
|
||||
</programlisting>
|
||||
<command>list [Channel[,Channel] [Server]]</command>
|
||||
<programlisting>
|
||||
Channels mit ihren Topics auflisten
|
||||
|
||||
Channel: aufzulistender Channel (reguläre Ausdrücke sind möglich)
|
||||
Server: Servername
|
||||
|
||||
</programlisting>
|
||||
<command>lusers [Maske [Ziel]]</command>
|
||||
<programlisting>
|
||||
Statistik über die Größe dieses IRC-Netzwerks abfragen
|
||||
|
||||
Maske: Nur Server, die diesem Muster entsprechen
|
||||
Ziel: Server, der die Anfrage weiterleiten soll
|
||||
|
||||
</programlisting>
|
||||
<command>me Nachricht</command>
|
||||
<programlisting>
|
||||
eine CTCP ACTION an den aktuellen Channel senden
|
||||
|
||||
zu sendende Nachricht
|
||||
|
||||
</programlisting>
|
||||
<command>mode { Channel {[+|-]|o|p|s|i|t|n|b|v} [Limit] [User] [Bannmaske] } | {Nickname {[+|-]|i|w|s|o} }</command>
|
||||
<programlisting>
|
||||
Channel- oder Usermode ändern
|
||||
|
||||
Channelmodi:
|
||||
Channel: zu ändernder Channel
|
||||
o: gib/nimm Operatorstatus
|
||||
p: privater Channel
|
||||
s: geheimer Channel
|
||||
i: geschlossener Channel (Zutritt nur mit Einladung)
|
||||
t: nur Operatoren dĂĽrfen das Topic setzen
|
||||
n: keine Channelnachrichten von auĂźerhalb des Channels
|
||||
m: moderierter Channel (schreiben nur mit Voice)
|
||||
l: maximale Anzahl an Usern im Channel festlegen
|
||||
b: Bannmaske fĂĽr zu sperrende User (in nick!ident@host-Form)
|
||||
e: lege Ausnahmemaske fest
|
||||
v: gib/nimm Voice (d.h. Schreibrecht bei moderierten Channels)
|
||||
k: Channelkey/Channelpasswort festlegen
|
||||
Usermodi:
|
||||
Nickname: zu ändernder Nickname
|
||||
i: User als unsichtbar kennzeichnen
|
||||
s: User empfängt Server-Nachrichten
|
||||
w: User empfängt WALLOPS
|
||||
o: User ist Channeloperator
|
||||
|
||||
</programlisting>
|
||||
<command>motd [Ziel]</command>
|
||||
<programlisting>
|
||||
die "Nachricht von heute" abfragen
|
||||
|
||||
Ziel: Servername
|
||||
|
||||
</programlisting>
|
||||
<command>msg Empfänger[,Empfänger] Text</command>
|
||||
<programlisting>
|
||||
Nachricht an Nick/Channel verschicken
|
||||
|
||||
Empfänger: Nick/Channel (darf eine Maske sein, '*' = aktueller Channel)
|
||||
Text: zu sendender Text
|
||||
|
||||
</programlisting>
|
||||
<command>names [Channel[,Channel]]</command>
|
||||
<programlisting>
|
||||
Nicknames in Channels auflisten
|
||||
|
||||
Channel: Channelname
|
||||
|
||||
</programlisting>
|
||||
<command>nick [-all] Nickname</command>
|
||||
<programlisting>
|
||||
aktuellen Nickname wechseln
|
||||
|
||||
-all: Nickname auf allen verbundenen Servern ändern
|
||||
Nickname: neuer Nickname
|
||||
|
||||
</programlisting>
|
||||
<command>notice Nickname Text</command>
|
||||
<programlisting>
|
||||
NOTICE an einen User verschicken
|
||||
|
||||
Nickname: Empfänger der Nachricht
|
||||
Text: zu sendender Text
|
||||
|
||||
</programlisting>
|
||||
<command>op Nickname [Nickname]</command>
|
||||
<programlisting>
|
||||
Channeloperatorstatus verleihen
|
||||
|
||||
</programlisting>
|
||||
<command>oper Benutzername Passwort</command>
|
||||
<programlisting>
|
||||
Serveroperatorprivilegien anfordern
|
||||
|
||||
Benutzername/Passwort: Account im IRC-Server
|
||||
|
||||
</programlisting>
|
||||
<command>part [Channel[,Channel]] [Abschiedsnachricht]</command>
|
||||
<programlisting>
|
||||
einen Channel verlassen
|
||||
|
||||
Channel: zu verlassender Channel
|
||||
Abschiedsnachricht: Abschiedsnachricht, die den anderen Usern angezeigt wird
|
||||
|
||||
</programlisting>
|
||||
<command>ping Server1 [Server2]</command>
|
||||
<programlisting>
|
||||
Server anpingen
|
||||
|
||||
Server1: Anzupingender Server
|
||||
Server2: Ping an diesen Server weiterleiten
|
||||
|
||||
</programlisting>
|
||||
<command>pong Daemon [Daemon2]</command>
|
||||
<programlisting>
|
||||
auf Ping antworten
|
||||
|
||||
Daemon: Daemon, der auf die Ping-Nachricht geantwortet hat
|
||||
Daemon2: Nachricht an diesen Daemon weiterleiten
|
||||
|
||||
</programlisting>
|
||||
<command>query Nickname [Text]</command>
|
||||
<programlisting>
|
||||
private Nachricht an jemanden schicken
|
||||
|
||||
Nickname: Nickname fĂĽr privaten Chat
|
||||
Text: zu sendender Text
|
||||
|
||||
</programlisting>
|
||||
<command>quit [Abschiedsnachricht]</command>
|
||||
<programlisting>
|
||||
alle Verbindungen trennen und Programm beenden
|
||||
|
||||
Abschiednachricht: anderen Usern zu zeigende Nachricht
|
||||
|
||||
</programlisting>
|
||||
<command>quote Daten</command>
|
||||
<programlisting>
|
||||
Daten direkt an Server senden (siehe RFC 2812)
|
||||
|
||||
Daten: zu sendende Rohdaten
|
||||
|
||||
</programlisting>
|
||||
<command>rehash</command>
|
||||
<programlisting>
|
||||
den Server dazu bringen, seine Konfigurationsdatei neu zu laden
|
||||
|
||||
</programlisting>
|
||||
<command>restart</command>
|
||||
<programlisting>
|
||||
den Server dazu bringen, sich selbst neu zu starten
|
||||
|
||||
</programlisting>
|
||||
<command>service Nickname reserviert Distribution Typ reserviert Info</command>
|
||||
<programlisting>
|
||||
einen neuen Service eintragen
|
||||
|
||||
Distribution: Sichtbarkeit des Services
|
||||
Typ: für spätere Verwendung reserviert
|
||||
|
||||
</programlisting>
|
||||
<command>servlist [Maske [Typ]]</command>
|
||||
<programlisting>
|
||||
zur Zeit verbundene Services auflisten
|
||||
|
||||
Maske: nur zutreffende Services auflisten
|
||||
Typ: nur Services von diesem Typ auflisten
|
||||
|
||||
</programlisting>
|
||||
<command>squery Service Text</command>
|
||||
<programlisting>
|
||||
Nachricht an einen Service senden
|
||||
|
||||
Service: Name des Service
|
||||
Text: zu sendender Text
|
||||
|
||||
</programlisting>
|
||||
<command>squit Server Kommentar</command>
|
||||
<programlisting>
|
||||
Serververbindungen trennen
|
||||
|
||||
Server: Servername
|
||||
Kommentar: Trennungsgrund
|
||||
|
||||
</programlisting>
|
||||
<command>stats [Anfrage [Server]]</command>
|
||||
<programlisting>
|
||||
Serverstatistik abfragen
|
||||
|
||||
Anfrage: c/h/i/k/l/m/o/y/u (siehe RFC1459)
|
||||
Server: zu befragender Server
|
||||
|
||||
</programlisting>
|
||||
<command>summon User [Ziel [Channel]]</command>
|
||||
<programlisting>
|
||||
Nutzer, die auf dem IRC-Server arbeiten, darum bitten, auf den IRC-Server zu kommen
|
||||
|
||||
User: Benutzername
|
||||
Ziel: Servername
|
||||
Channel: Channelname
|
||||
|
||||
</programlisting>
|
||||
<command>time [Ziel]</command>
|
||||
<programlisting>
|
||||
Ortszeit des Servers abfragen
|
||||
|
||||
Ziel: der zu fragende Server
|
||||
|
||||
</programlisting>
|
||||
<command>topic [Channel] [Topic]</command>
|
||||
<programlisting>
|
||||
Channeltopic abfragen/setzen
|
||||
|
||||
Channel: Channelname
|
||||
Topic: neues Topic (oder "-delete" zum Entfernen des Topics)
|
||||
|
||||
</programlisting>
|
||||
<command>trace [Ziel]</command>
|
||||
<programlisting>
|
||||
Route zum angegebenen Server ermitteln
|
||||
|
||||
Ziel: Server
|
||||
|
||||
</programlisting>
|
||||
<command>unban [Channel] nickname [nickname ...]</command>
|
||||
<programlisting>
|
||||
Bann aufheben
|
||||
|
||||
Channel: Channel, in dem der Bann aufzuheben ist
|
||||
Nickname: User, fĂĽr den der Bann aufzuheben ist
|
||||
|
||||
</programlisting>
|
||||
<command>userhost Nickname [Nickname ...]</command>
|
||||
<programlisting>
|
||||
liste von Nickname-Informationen ermitteln
|
||||
|
||||
Nickname: Nickname
|
||||
|
||||
</programlisting>
|
||||
<command>users [Ziel]</command>
|
||||
<programlisting>
|
||||
auf dem Server eingeloggte User auflisten
|
||||
|
||||
Ziel: Server
|
||||
|
||||
</programlisting>
|
||||
<command>version [Server | Nickname]</command>
|
||||
<programlisting>
|
||||
Versionsinformationen von Nickname oder Server ermitteln
|
||||
|
||||
Server: Servername
|
||||
Nickname: Nickname
|
||||
|
||||
</programlisting>
|
||||
<command>voice Nickname [Nickname]</command>
|
||||
<programlisting>
|
||||
Voice vergeben
|
||||
|
||||
</programlisting>
|
||||
<command>wallops Text</command>
|
||||
<programlisting>
|
||||
Nachricht an alle User schicken, die den 'w'-Mode gesetzt haben
|
||||
|
||||
zu sendender Text
|
||||
|
||||
</programlisting>
|
||||
<command>who [Maske ["o"]]</command>
|
||||
<programlisting>
|
||||
erweiterte Nicknameliste
|
||||
|
||||
Maske: nur Information ĂĽber betreffende Nicknames abfragen
|
||||
o: nur Operatoren ausgeben, die dem Filter entsprechen
|
||||
|
||||
</programlisting>
|
||||
<command>whois [Server] Nickname[,Nickname]</command>
|
||||
<programlisting>
|
||||
Information ĂĽber User abfragen
|
||||
|
||||
Server: Servername
|
||||
Nickname: Nickname (oder eine Maske)
|
||||
|
||||
</programlisting>
|
||||
<command>whowas Nickname [,Nickname [,Nickname ...]] [Anzahl [Ziel]]</command>
|
||||
<programlisting>
|
||||
Information ĂĽber die Vergangenheit eines Nicknames erfragen
|
||||
|
||||
Nickname: abzufragende Nicknames
|
||||
Anzahl: maximale Anzahl an Antworten (negative Zahl für eine vollständige Liste)
|
||||
Ziel: zu suchende Hostmaske
|
||||
|
||||
</programlisting>
|
||||
@@ -0,0 +1,191 @@
|
||||
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||
|
||||
<!-- ********* WARNING! *********
|
||||
|
||||
This file is automatically built with a Perl script. DO NOT EDIT!
|
||||
-->
|
||||
|
||||
<row>
|
||||
<entry><literal>return</literal></entry>
|
||||
<entry>Zeile terminieren</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>tab</literal></entry>
|
||||
<entry>Wort vervollständigen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>tab_previous</literal></entry>
|
||||
<entry>finde letzte Wortvervollständigung</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>backspace</literal></entry>
|
||||
<entry>vorheriges Zeichen löschen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>delete</literal></entry>
|
||||
<entry>nächstes Zeichen löschen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>delete_end_line</literal></entry>
|
||||
<entry>bis zum Zeilenende löschen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>delete_beginning_line</literal></entry>
|
||||
<entry>bis zum Zeilenanfang löschen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>delete_line</literal></entry>
|
||||
<entry>ganze Zeile löschen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>delete_previous_word</literal></entry>
|
||||
<entry>vorheriges Wort löschen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>delete_next_word</literal></entry>
|
||||
<entry>nächstes Wort löschen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>clipboard_paste</literal></entry>
|
||||
<entry>einfĂĽgen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>transpose_chars</literal></entry>
|
||||
<entry>Zeichen vertauschen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>home</literal></entry>
|
||||
<entry>zum Zeilenanfang gehen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>end</literal></entry>
|
||||
<entry>zum Zeilenende gehen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>left</literal></entry>
|
||||
<entry>ein Zeichen nach links gehen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>previous_word</literal></entry>
|
||||
<entry>ein Wort nach links gehen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>right</literal></entry>
|
||||
<entry>ein Zeichen nach rechts gehen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>next_word</literal></entry>
|
||||
<entry>ein Wort nach rechts gehen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>up</literal></entry>
|
||||
<entry>vorherigen Befehl aus dem Verlauf abfragen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>up_global</literal></entry>
|
||||
<entry>vorherigen Befehl aus dem globalen Verlauf abfragen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>down</literal></entry>
|
||||
<entry>nächsten Befehl aus dem Verlauf abfragen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>down_global</literal></entry>
|
||||
<entry>nächsten Befehl aus dem globalen Verlauf abfragen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>page_up</literal></entry>
|
||||
<entry>eine Seite hochscrollen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>page_down</literal></entry>
|
||||
<entry>eine Seite herunterscrollen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>scroll_up</literal></entry>
|
||||
<entry>einige Zeilen hochscrollen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>scroll_down</literal></entry>
|
||||
<entry>einige Zeilen herunterscrollen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>scroll_top</literal></entry>
|
||||
<entry>nach ganz oben scrollen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>scroll_bottom</literal></entry>
|
||||
<entry>nach ganz unten scrollen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>nick_beginning</literal></entry>
|
||||
<entry>zum Anfang der Nicklist gehen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>nick_end</literal></entry>
|
||||
<entry>zum Ende der Nicklist gehen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>nick_page_up</literal></entry>
|
||||
<entry>Nickliste eine Seite hochscrollen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>nick_page_down</literal></entry>
|
||||
<entry>Nickliste eine Seite herunterscrollen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>jump_smart</literal></entry>
|
||||
<entry>zu nächstem aktiven Puffer springen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>jump_dcc</literal></entry>
|
||||
<entry>zum DCC-Puffer springen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>jump_raw_data</literal></entry>
|
||||
<entry>gehe zum IRC-Rohdaten-Puffer</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>jump_last_buffer</literal></entry>
|
||||
<entry>zum letzten Puffer springen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>jump_server</literal></entry>
|
||||
<entry>zum Serverpuffer springen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>jump_next_server</literal></entry>
|
||||
<entry>zum nächsten Server springen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>switch_server</literal></entry>
|
||||
<entry>wechsel den aktiven Server im Server-Puffer</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>scroll_previous_highlight</literal></entry>
|
||||
<entry>scrolle zur vorherigen hervorhebung im Puffer</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>scroll_next_highlight</literal></entry>
|
||||
<entry>scrolle zur nächsten Hervorhebung im Puffer</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>scroll_unread</literal></entry>
|
||||
<entry>scrolle zur ersten, ungelesenen Zeile im Puffer</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>hotlist_clear</literal></entry>
|
||||
<entry>Hotlist leeren</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>infobar_clear</literal></entry>
|
||||
<entry>Infobar leeren</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>refresh</literal></entry>
|
||||
<entry>Bild neu aufbauen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>grab_key</literal></entry>
|
||||
<entry>Tastencode ermitteln und einfĂĽgen</entry>
|
||||
</row>
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,235 @@
|
||||
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||
|
||||
<!-- ********* WARNING! *********
|
||||
|
||||
This file is automatically built with a Perl script. DO NOT EDIT!
|
||||
-->
|
||||
|
||||
<command>alias [Aliasname [Befehl [Argumente]]]</command>
|
||||
<programlisting>
|
||||
einen Alias fĂĽr einen Befehl anlegen
|
||||
|
||||
Aliasname: Name des Alias
|
||||
Befehl: Befehlsname (WeeChat- oder IRC-Befehl ohne führenden '/', mehrere Befehle können durch Semikola getrennt werden)
|
||||
Argumente: Argumente fĂĽr den Befehl
|
||||
|
||||
</programlisting>
|
||||
<command>buffer [Aktion [Argumente] | Nummer | [[Server] [Channel]]]</command>
|
||||
<programlisting>
|
||||
Puffer verwalten
|
||||
|
||||
Aktion: Pufferaktion:
|
||||
move: Puffer in der Liste bewegen (kann auch relativ sein, wie -1)
|
||||
close: Puffer schlieĂźen (und Channel ohne Meldung verlassen)
|
||||
list: alle offenen Puffer auflisten (Standardaktion)
|
||||
notify: Notify-Level fĂĽr Puffer festlegen (0=nie, 1=highlighten, 2=1+Nachricht, 3=2+join/part)
|
||||
Server
|
||||
Channel: gehe zum Puffer mit Servernamen oder Channelnamen
|
||||
Nummer: gehe zu Puffer mit dieser Nummer
|
||||
|
||||
</programlisting>
|
||||
<command>builtin Befehl</command>
|
||||
<programlisting>
|
||||
starte eingebauten WeeChat/IRC-Befehl (ohne Plugin-Handler oder Aliase)
|
||||
|
||||
Befehl: auszufĂĽhrender Befehl (falls nicht vorhanden wird automatisch ein '/' vorangestellt)
|
||||
|
||||
|
||||
</programlisting>
|
||||
<command>charset [(decode_iso | decode_utf | encode) Zeichensatz]</command>
|
||||
<programlisting>
|
||||
ändere Zeichensatz für den Server oder Channel
|
||||
|
||||
decode_iso: Zeichensatz um ISO zu decoden
|
||||
decode_utf: Zeichensatz um UTF zu decoden
|
||||
encode: der zum encoden benutzte Zeichensatz
|
||||
Zeichensatz: Zeichensatz, der benutzt werden soll (zum Beispiel: ISO-8859-15, UTF-8,..)
|
||||
|
||||
</programlisting>
|
||||
<command>clear [-all]</command>
|
||||
<programlisting>
|
||||
Fenster leeren
|
||||
|
||||
-all: alle Fenster leeren
|
||||
|
||||
</programlisting>
|
||||
<command>connect [Servername]</command>
|
||||
<programlisting>
|
||||
mit einem Server verbinden
|
||||
|
||||
Servername: Zielserver
|
||||
|
||||
</programlisting>
|
||||
<command>disconnect [Servername]</command>
|
||||
<programlisting>
|
||||
Serververbindung trennen
|
||||
|
||||
Servername: Name des zu trennenden Servers
|
||||
|
||||
</programlisting>
|
||||
<command>dcc Aktion [Nickname [Datei]]</command>
|
||||
<programlisting>
|
||||
DCC (Filetransfer oder Chat) starten oder Chat beenden
|
||||
|
||||
Aktion: 'send' (Datei) oder 'chat' oder 'close' (Chat)
|
||||
Nickname: Empfänger der Datei bzw. Chatpartner
|
||||
Datei: zu versendende (lokal vorliegende) Datei
|
||||
|
||||
</programlisting>
|
||||
<command>debug dump | windows</command>
|
||||
<programlisting>
|
||||
Debugging-Nachricht ausgeben
|
||||
|
||||
dump: Speicherabbild im WeeChat-Logfile ablegen (wie nach einem Programmabsturz)
|
||||
windows: zeigt Fensterdaten an
|
||||
|
||||
</programlisting>
|
||||
<command>help [Befehl]</command>
|
||||
<programlisting>
|
||||
Hilfe zu Befehlen abfragen
|
||||
|
||||
Befehl: Name eines WeeChat- oder IRC-Befehls
|
||||
|
||||
</programlisting>
|
||||
<command>history [clear | Anzahl]</command>
|
||||
<programlisting>
|
||||
zeigt Befehlsverlauf des Puffers
|
||||
|
||||
clear: Löscht Verlauf
|
||||
Anzahl: zeigt die gewünschte Anzahl an Verlaufseinträgen
|
||||
|
||||
</programlisting>
|
||||
<command>ignore [Maske [[Typ | Befehl] [Channel [Server]]]]</command>
|
||||
<programlisting>
|
||||
IRC-Nachrichten und/oder Hosts ignorieren
|
||||
|
||||
Nummer: Nummer des zu entfernenden Eintrags (siehe Liste)
|
||||
Maske: Nickname oder Hostmaske, die ignoriert werden soll
|
||||
Typ: Typ der Nachrichten, die ignoriert werden sollen (action, ctcp, dcc, pv)
|
||||
Befehl: IRC-Befehl
|
||||
Channel: Channel, in dem ignoriert werden soll
|
||||
Server: Server, auf dem ignoriert werden soll
|
||||
|
||||
Bei jedem Argument steht '*' fĂĽr 'alle'.
|
||||
Ohne Argumente listet /ignore alle definierten /ignore-Regeln auf.
|
||||
|
||||
</programlisting>
|
||||
<command>key [Taste Funktion/Befehl] [unbind Taste] [functions] [reset -yes]</command>
|
||||
<programlisting>
|
||||
belegen/freigeben von Tasten
|
||||
|
||||
Taste: diese Taste mit einer internen Funktion oder einem Befehl, beginnend mit "/", belegen
|
||||
unbind: Tastenbelegung aufheben
|
||||
functions: interne Funktionen fĂĽr Tastenbelegungen auflisten
|
||||
reset: Standardbelegung wiederherstellen und entferne alle eigenen Belegungen (Vorsicht!)
|
||||
|
||||
</programlisting>
|
||||
<command>plugin [load Dateiname] | [autoload] | [reload] | [unload]</command>
|
||||
<programlisting>
|
||||
auflisten/laden/entladen von Plugins
|
||||
|
||||
Dateiname: zu ladendes Plugin
|
||||
|
||||
Ohne Argumente werden alle geladenen Plugins aufgelistet.
|
||||
|
||||
</programlisting>
|
||||
<command>server [Servername] | [Servername Hostname Port [-auto | -noauto] [-ipv6] [-ssl] [-pwd Passwort] [-nicks Nick1 Nick2 Nick3] [-username Benutzername] [-realname Name] [-command Befehl] [-autojoin Channel[,Channel]] ] | [del Servername]</command>
|
||||
<programlisting>
|
||||
Auflisten, HinzufĂĽgen oder Entfernen von Servern
|
||||
|
||||
Servername: anzuzeigender Servername
|
||||
Hostname: Name oder IP-Adresse des Servers
|
||||
Port: Port des Servers
|
||||
ipv6: IPv6 benutzen
|
||||
ssl: SSL benutzen
|
||||
Passwort: Serverpasswort
|
||||
Nick1: erster Nickname
|
||||
Nick2: zweiter Nickname
|
||||
Nick3: dritter Nicname
|
||||
Benutzername: Benutzername
|
||||
Realname: voller Name des Benutzers
|
||||
|
||||
</programlisting>
|
||||
<command>save [Datei]</command>
|
||||
<programlisting>
|
||||
Konfiguration abspeichern
|
||||
|
||||
Datei: Name der zu speichernden Konfigurationsdatei
|
||||
|
||||
</programlisting>
|
||||
<command>set [Option [ = Wert]]</command>
|
||||
<programlisting>
|
||||
Konfigurationsparameter setzen
|
||||
|
||||
Option: Name einer Option (wenn der Name vorhanden ist, aber kein Wert, dann wird eine Hilfe zur Option ausgegeben
|
||||
Wert: Wert der Option
|
||||
|
||||
Option kann Servername.server_xxx lauten, wobei "Servername" der interne Servername ist und "xxx" eine Option fĂĽr diesen Server.
|
||||
|
||||
</programlisting>
|
||||
<command>setp [Option [ = Wert]]</command>
|
||||
<programlisting>
|
||||
Konfigurationsparameter fĂĽr Plugin setzen
|
||||
|
||||
Option: Name einer Plugin-Option
|
||||
Wert: Wert fĂĽr Option
|
||||
|
||||
Option wird wie folgt formatiert: Plugin.Option, z.B. perl.myscript.item1
|
||||
|
||||
</programlisting>
|
||||
<command>unalias Aliasname</command>
|
||||
<programlisting>
|
||||
einen Alias entfernen
|
||||
|
||||
Aliasname: Name des zu löschenden Aliases
|
||||
|
||||
</programlisting>
|
||||
<command>unignore [Nummer | [Maske [[Typ | Befehl] [Channel [Server]]]]</command>
|
||||
<programlisting>
|
||||
/ignore-Regel entfernen
|
||||
|
||||
Nummer: Nummer des zu entfernenden Eintrags (siehe Liste)
|
||||
Maske: Nickname oder Hostmaske, die ignoriert werden soll
|
||||
Typ: Typ der Nachrichten, die ignoriert werden sollen (action, ctcp, dcc, pv)
|
||||
Befehl: IRC-Befehl
|
||||
Channel: Channel, in dem ignoriert werden soll
|
||||
Server: Server, auf dem ignoriert werden soll
|
||||
|
||||
Bei jedem Argument steht '*' fĂĽr 'alle'.
|
||||
Ohne Argumente listet /unignore alle definierten /ignore-Regeln auf.
|
||||
|
||||
</programlisting>
|
||||
<command>upgrade</command>
|
||||
<programlisting>
|
||||
aktualisiert WeeChat ohne die Verbindung zum Server zu trennen
|
||||
|
||||
Dieser Befehl wird auf dem Weechat-Binary ausgefĂĽhrt, daher sollte dieses kompiliert oder mit einem Paketmanager installiert sein, bevor der Befehl ausgefĂĽhrt wird.
|
||||
|
||||
</programlisting>
|
||||
<command>uptime [-o]</command>
|
||||
<programlisting>
|
||||
zeigt die Uptime von Weechat an
|
||||
|
||||
-o: sendet die Weechat-Uptime als IRC-Nachricht in den aktuellen Channel
|
||||
|
||||
</programlisting>
|
||||
<command>window [list | -1 | +1 | b# | up | down | left | right | splith [pct] | splitv [pct] | resize pct | merge [all]]</command>
|
||||
<programlisting>
|
||||
Fenster verwalten
|
||||
|
||||
list: listet die geöffneten Fenster (Default, kann auch weggelassen werden)
|
||||
-1: springt zum vorherigen Fenster
|
||||
+1: springt zum nächsten Fenster
|
||||
b#: springt zum nächsten Fenster, dass Puffer Nummer # anzeigt
|
||||
up: wechselt zum Fenster ĂĽber dem aktuellen
|
||||
down: wechselt zum Fenster unter dem aktuellen
|
||||
left: wechselt zum linken Fenster
|
||||
right: wechselt zum rechten Fenster
|
||||
splith: teilt das aktuelle Fenster horizontal
|
||||
splitv: teilt das aktuelle Fenster vertikal
|
||||
resize: verändert die Größe des aktuellen Fensters, die neue Größe wird in Prozent des Elternfensters angegeben
|
||||
merge: vereinigt Fenster miteinander (all = alle Fenster vereinigen)
|
||||
|
||||
Bei splith und splitv gibt pct die neue Größe des Fensters im verhältnis zur aktuellen Größe an. Zum Beispiel würde 25 bedeuten, dass das neue Fenster nur noch ein Viertel der Größe des alten Fensters hätte.
|
||||
|
||||
</programlisting>
|
||||
@@ -0,0 +1,61 @@
|
||||
# Copyright (c) 2003-2006 FlashCode <flashcode@flashtux.org>
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; either version 2 of the License, or
|
||||
# (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
#
|
||||
|
||||
LANGCODE = en
|
||||
BOOK = weechat.$(LANGCODE)
|
||||
BOOK_INCLUDE = weechat_commands.xml irc_commands.xml key_functions.xml config.xml
|
||||
|
||||
EXTRA_DIST = $(BOOK).xml $(BOOK_INCLUDE)
|
||||
|
||||
docdir = $(datadir)/doc/$(PACKAGE)
|
||||
|
||||
all-local: html-stamp
|
||||
|
||||
# HTML output with chunks (many pages)
|
||||
|
||||
html: html-stamp
|
||||
|
||||
html-stamp: $(BOOK).xml $(BOOK_INCLUDE) ../weechat-html.xsl ../weechat-doc.css
|
||||
echo "<pubdate>`date -R`</pubdate>" >date.xml
|
||||
mkdir -p html/
|
||||
xsltproc -o html/ ../weechat-html.xsl $(BOOK).xml || true
|
||||
cp ../weechat-doc.css html/
|
||||
touch html-stamp
|
||||
|
||||
# HTML output, all in one page
|
||||
|
||||
html1: html1-stamp
|
||||
|
||||
html1-stamp: $(BOOK).xml $(BOOK_INCLUDE) ../weechat-html-one.xsl ../weechat-doc.css
|
||||
echo "<pubdate>`date -R`</pubdate>" >date.xml
|
||||
mkdir -p html1/
|
||||
xsltproc -o html1/$(BOOK).html ../weechat-html-one.xsl $(BOOK).xml || true
|
||||
cp ../weechat-doc.css html1/
|
||||
touch html1-stamp
|
||||
|
||||
# install docs
|
||||
|
||||
install-data-hook:
|
||||
$(mkinstalldirs) $(DESTDIR)$(docdir)/html/$(LANGCODE)/
|
||||
$(INSTALL_DATA) html/* $(DESTDIR)$(docdir)/html/$(LANGCODE)/
|
||||
|
||||
# clean
|
||||
|
||||
clean-local:
|
||||
-rm -f *.html *.pdf *.txt date.xml
|
||||
-rm -rf html/ html1/
|
||||
-rm -f html-stamp html1-stamp
|
||||
+1246
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,443 @@
|
||||
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||
|
||||
<!-- ********* WARNING! *********
|
||||
|
||||
This file is automatically built with a Perl script. DO NOT EDIT!
|
||||
-->
|
||||
|
||||
<command>admin [target]</command>
|
||||
<programlisting>
|
||||
find information about the administrator of the server
|
||||
|
||||
target: server
|
||||
|
||||
</programlisting>
|
||||
<command>ame message</command>
|
||||
<programlisting>
|
||||
send a CTCP action to all channels of all connected servers
|
||||
|
||||
message: message to send
|
||||
|
||||
</programlisting>
|
||||
<command>amsg text</command>
|
||||
<programlisting>
|
||||
send message to all channels of all connected servers
|
||||
|
||||
text: text to send
|
||||
|
||||
</programlisting>
|
||||
<command>away [-all] [message]</command>
|
||||
<programlisting>
|
||||
toggle away status
|
||||
|
||||
-all: toggle away status on all connected servers
|
||||
message: message for away (if no message is given, away status is removed)
|
||||
|
||||
</programlisting>
|
||||
<command>ban [channel] [nickname [nickname ...]]</command>
|
||||
<programlisting>
|
||||
bans nicks or hosts
|
||||
|
||||
channel: channel for ban
|
||||
nickname: user or host to ban
|
||||
|
||||
</programlisting>
|
||||
<command>ctcp nickname type [arguments]</command>
|
||||
<programlisting>
|
||||
send a CTCP message (Client-To-Client Protocol)
|
||||
|
||||
nickname: user to send CTCP to
|
||||
type: CTCP type (examples: "version", "ping", ..)
|
||||
arguments: arguments for CTCP
|
||||
|
||||
</programlisting>
|
||||
<command>cycle [channel[,channel]] [part_message]</command>
|
||||
<programlisting>
|
||||
leave and rejoin a channel
|
||||
|
||||
channel: channel name for cycle
|
||||
part_message: part message (displayed to other users)
|
||||
|
||||
</programlisting>
|
||||
<command>dehalfop [nickname [nickname]]</command>
|
||||
<programlisting>
|
||||
removes half channel operator status from nickname(s)
|
||||
|
||||
</programlisting>
|
||||
<command>deop [nickname [nickname]]</command>
|
||||
<programlisting>
|
||||
removes channel operator status from nickname(s)
|
||||
|
||||
</programlisting>
|
||||
<command>devoice [nickname [nickname]]</command>
|
||||
<programlisting>
|
||||
removes voice from nickname(s)
|
||||
|
||||
</programlisting>
|
||||
<command>die</command>
|
||||
<programlisting>
|
||||
shutdown the server
|
||||
|
||||
</programlisting>
|
||||
<command>halfop [nickname [nickname]]</command>
|
||||
<programlisting>
|
||||
gives half channel operator status to nickname(s)
|
||||
|
||||
</programlisting>
|
||||
<command>info [target]</command>
|
||||
<programlisting>
|
||||
get information describing the server
|
||||
|
||||
target: server name
|
||||
|
||||
</programlisting>
|
||||
<command>invite nickname channel</command>
|
||||
<programlisting>
|
||||
invite a nick on a channel
|
||||
|
||||
nickname: nick to invite
|
||||
channel: channel to invite
|
||||
|
||||
</programlisting>
|
||||
<command>ison nickname [nickname ...]</command>
|
||||
<programlisting>
|
||||
check if a nickname is currently on IRC
|
||||
|
||||
nickname: nickname
|
||||
|
||||
</programlisting>
|
||||
<command>join channel[,channel] [key[,key]]</command>
|
||||
<programlisting>
|
||||
join a channel
|
||||
|
||||
channel: channel name to join
|
||||
key: key to join the channel
|
||||
|
||||
</programlisting>
|
||||
<command>kick [channel] nickname [comment]</command>
|
||||
<programlisting>
|
||||
forcibly remove a user from a channel
|
||||
|
||||
channel: channel where user is
|
||||
nickname: nickname to kick
|
||||
comment: comment for kick
|
||||
|
||||
</programlisting>
|
||||
<command>kickban [channel] nickname [comment]</command>
|
||||
<programlisting>
|
||||
kicks and bans a nick from a channel
|
||||
|
||||
channel: channel where user is
|
||||
nickname: nickname to kick and ban
|
||||
comment: comment for kick
|
||||
|
||||
</programlisting>
|
||||
<command>kill nickname comment</command>
|
||||
<programlisting>
|
||||
close client-server connection
|
||||
|
||||
nickname: nickname
|
||||
comment: comment for kill
|
||||
|
||||
</programlisting>
|
||||
<command>links [[server] server_mask]</command>
|
||||
<programlisting>
|
||||
list all servernames which are known by the server answering the query
|
||||
|
||||
server: this server should answer the query
|
||||
server_mask: list of servers must match this mask
|
||||
|
||||
</programlisting>
|
||||
<command>list [channel[,channel] [server]]</command>
|
||||
<programlisting>
|
||||
list channels and their topic
|
||||
|
||||
channel: channel to list (a regexp is allowed)
|
||||
server: server name
|
||||
|
||||
</programlisting>
|
||||
<command>lusers [mask [target]]</command>
|
||||
<programlisting>
|
||||
get statistics about the size of the IRC network
|
||||
|
||||
mask: servers matching the mask only
|
||||
target: server for forwarding request
|
||||
|
||||
</programlisting>
|
||||
<command>me message</command>
|
||||
<programlisting>
|
||||
send a CTCP action to the current channel
|
||||
|
||||
message: message to send
|
||||
|
||||
</programlisting>
|
||||
<command>mode { channel {[+|-]|o|p|s|i|t|n|b|v} [limit] [user] [ban mask] } | { nickname {[+|-]|i|w|s|o} }</command>
|
||||
<programlisting>
|
||||
change channel or user mode
|
||||
|
||||
channel modes:
|
||||
channel: channel name to modify
|
||||
o: give/take channel operator privileges
|
||||
p: private channel flag
|
||||
s: secret channel flag
|
||||
i: invite-only channel flag
|
||||
t: topic settable by channel operator only flag
|
||||
n: no messages to channel from clients on the outside
|
||||
m: moderated channel
|
||||
l: set the user limit to channel
|
||||
b: set a ban mask to keep users out
|
||||
e: set exception mask
|
||||
v: give/take the ability to speak on a moderated channel
|
||||
k: set a channel key (password)
|
||||
user modes:
|
||||
nickname: nickname to modify
|
||||
i: mark a user as invisible
|
||||
s: mark a user for receive server notices
|
||||
w: user receives wallops
|
||||
o: operator flag
|
||||
|
||||
</programlisting>
|
||||
<command>motd [target]</command>
|
||||
<programlisting>
|
||||
get the "Message Of The Day"
|
||||
|
||||
target: server name
|
||||
|
||||
</programlisting>
|
||||
<command>msg receiver[,receiver] text</command>
|
||||
<programlisting>
|
||||
send message to a nick or channel
|
||||
|
||||
receiver: nick or channel (may be mask, '*' = current channel)
|
||||
text: text to send
|
||||
|
||||
</programlisting>
|
||||
<command>names [channel[,channel]]</command>
|
||||
<programlisting>
|
||||
list nicknames on channels
|
||||
|
||||
channel: channel name
|
||||
|
||||
</programlisting>
|
||||
<command>nick [-all] nickname</command>
|
||||
<programlisting>
|
||||
change current nickname
|
||||
|
||||
-all: set new nickname for all connected servers
|
||||
nickname: new nickname
|
||||
|
||||
</programlisting>
|
||||
<command>notice nickname text</command>
|
||||
<programlisting>
|
||||
send notice message to user
|
||||
|
||||
nickname: user to send notice to
|
||||
text: text to send
|
||||
|
||||
</programlisting>
|
||||
<command>op nickname [nickname]</command>
|
||||
<programlisting>
|
||||
gives channel operator status to nickname(s)
|
||||
|
||||
</programlisting>
|
||||
<command>oper user password</command>
|
||||
<programlisting>
|
||||
get operator privileges
|
||||
|
||||
user/password: used to get privileges on current IRC server
|
||||
|
||||
</programlisting>
|
||||
<command>part [channel[,channel]] [part_message]</command>
|
||||
<programlisting>
|
||||
leave a channel
|
||||
|
||||
channel: channel name to leave
|
||||
part_message: part message (displayed to other users)
|
||||
|
||||
</programlisting>
|
||||
<command>ping server1 [server2]</command>
|
||||
<programlisting>
|
||||
ping server
|
||||
|
||||
server1: server to ping
|
||||
server2: forward ping to this server
|
||||
|
||||
</programlisting>
|
||||
<command>pong daemon [daemon2]</command>
|
||||
<programlisting>
|
||||
answer to a ping message
|
||||
|
||||
daemon: daemon who has responded to Ping message
|
||||
daemon2: forward message to this daemon
|
||||
|
||||
</programlisting>
|
||||
<command>query nickname [text]</command>
|
||||
<programlisting>
|
||||
send a private message to a nick
|
||||
|
||||
nickname: nickname for private conversation
|
||||
text: text to send
|
||||
|
||||
</programlisting>
|
||||
<command>quit [quit_message]</command>
|
||||
<programlisting>
|
||||
close all connections and quit
|
||||
|
||||
quit_message: quit message (displayed to other users)
|
||||
|
||||
</programlisting>
|
||||
<command>quote data</command>
|
||||
<programlisting>
|
||||
send raw data to server without parsing
|
||||
|
||||
data: raw data to send
|
||||
|
||||
</programlisting>
|
||||
<command>rehash</command>
|
||||
<programlisting>
|
||||
tell the server to reload its config file
|
||||
|
||||
</programlisting>
|
||||
<command>restart</command>
|
||||
<programlisting>
|
||||
tell the server to restart itself
|
||||
|
||||
</programlisting>
|
||||
<command>service nickname reserved distribution type reserved info</command>
|
||||
<programlisting>
|
||||
register a new service
|
||||
|
||||
distribution: visibility of service
|
||||
type: reserved for future usage
|
||||
|
||||
</programlisting>
|
||||
<command>servlist [mask [type]]</command>
|
||||
<programlisting>
|
||||
list services currently connected to the network
|
||||
|
||||
mask: list only services matching this mask
|
||||
type: list only services of this type
|
||||
|
||||
</programlisting>
|
||||
<command>squery service text</command>
|
||||
<programlisting>
|
||||
deliver a message to a service
|
||||
|
||||
service: name of service
|
||||
text: text to send
|
||||
|
||||
</programlisting>
|
||||
<command>squit server comment</command>
|
||||
<programlisting>
|
||||
disconnect server links
|
||||
|
||||
server: server name
|
||||
comment: comment for quit
|
||||
|
||||
</programlisting>
|
||||
<command>stats [query [server]]</command>
|
||||
<programlisting>
|
||||
query statistics about server
|
||||
|
||||
query: c/h/i/k/l/m/o/y/u (see RFC1459)
|
||||
server: server name
|
||||
|
||||
</programlisting>
|
||||
<command>summon user [target [channel]]</command>
|
||||
<programlisting>
|
||||
give users who are on a host running an IRC server a message asking them to please join IRC
|
||||
|
||||
user: username
|
||||
target: server name
|
||||
channel: channel name
|
||||
|
||||
</programlisting>
|
||||
<command>time [target]</command>
|
||||
<programlisting>
|
||||
query local time from server
|
||||
|
||||
target: query time from specified server
|
||||
|
||||
</programlisting>
|
||||
<command>topic [channel] [topic]</command>
|
||||
<programlisting>
|
||||
get/set channel topic
|
||||
|
||||
channel: channel name
|
||||
topic: new topic for channel (if topic is "-delete" then topic is deleted)
|
||||
|
||||
</programlisting>
|
||||
<command>trace [target]</command>
|
||||
<programlisting>
|
||||
find the route to specific server
|
||||
|
||||
target: server
|
||||
|
||||
</programlisting>
|
||||
<command>unban [channel] nickname [nickname ...]</command>
|
||||
<programlisting>
|
||||
unbans nicks or hosts
|
||||
|
||||
channel: channel for unban
|
||||
nickname: user or host to unban
|
||||
|
||||
</programlisting>
|
||||
<command>userhost nickname [nickname ...]</command>
|
||||
<programlisting>
|
||||
return a list of information about nicknames
|
||||
|
||||
nickname: nickname
|
||||
|
||||
</programlisting>
|
||||
<command>users [target]</command>
|
||||
<programlisting>
|
||||
list of users logged into the server
|
||||
|
||||
target: server
|
||||
|
||||
</programlisting>
|
||||
<command>version [server | nickname]</command>
|
||||
<programlisting>
|
||||
gives the version info of nick or server (current or specified)
|
||||
|
||||
server: server name
|
||||
nickname: nickname
|
||||
|
||||
</programlisting>
|
||||
<command>voice [nickname [nickname]]</command>
|
||||
<programlisting>
|
||||
gives voice to nickname(s)
|
||||
|
||||
</programlisting>
|
||||
<command>wallops text</command>
|
||||
<programlisting>
|
||||
send a message to all currently connected users who have set the 'w' user mode for themselves
|
||||
|
||||
text to send
|
||||
|
||||
</programlisting>
|
||||
<command>who [mask ["o"]]</command>
|
||||
<programlisting>
|
||||
generate a query which returns a list of information
|
||||
|
||||
mask: only information which match this mask
|
||||
o: only operators are returned according to the mask supplied
|
||||
|
||||
</programlisting>
|
||||
<command>whois [server] nickname[,nickname]</command>
|
||||
<programlisting>
|
||||
query information about user(s)
|
||||
|
||||
server: server name
|
||||
nickname: nickname (may be a mask)
|
||||
|
||||
</programlisting>
|
||||
<command>whowas nickname [,nickname [,nickname ...]] [count [target]]</command>
|
||||
<programlisting>
|
||||
ask for information about a nickname which no longer exists
|
||||
|
||||
nickname: nickname to search
|
||||
count: number of replies to return (full search if negative number)
|
||||
target: reply should match this mask
|
||||
|
||||
</programlisting>
|
||||
@@ -0,0 +1,191 @@
|
||||
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||
|
||||
<!-- ********* WARNING! *********
|
||||
|
||||
This file is automatically built with a Perl script. DO NOT EDIT!
|
||||
-->
|
||||
|
||||
<row>
|
||||
<entry><literal>return</literal></entry>
|
||||
<entry>terminate line</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>tab</literal></entry>
|
||||
<entry>complete word</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>tab_previous</literal></entry>
|
||||
<entry>find previous completion for word</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>backspace</literal></entry>
|
||||
<entry>delete previous char</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>delete</literal></entry>
|
||||
<entry>delete next char</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>delete_end_line</literal></entry>
|
||||
<entry>delete until end of line</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>delete_beginning_line</literal></entry>
|
||||
<entry>delete until beginning of line</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>delete_line</literal></entry>
|
||||
<entry>delete entire line</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>delete_previous_word</literal></entry>
|
||||
<entry>delete previous word</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>delete_next_word</literal></entry>
|
||||
<entry>delete next word</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>clipboard_paste</literal></entry>
|
||||
<entry>paste current clipboard content</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>transpose_chars</literal></entry>
|
||||
<entry>transpose chars</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>home</literal></entry>
|
||||
<entry>go to beginning of line</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>end</literal></entry>
|
||||
<entry>go to end of line</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>left</literal></entry>
|
||||
<entry>move one char left</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>previous_word</literal></entry>
|
||||
<entry>move to previous word</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>right</literal></entry>
|
||||
<entry>move one char right</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>next_word</literal></entry>
|
||||
<entry>move to next word</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>up</literal></entry>
|
||||
<entry>call previous command in history</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>up_global</literal></entry>
|
||||
<entry>call previous command in global history</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>down</literal></entry>
|
||||
<entry>call next command in history</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>down_global</literal></entry>
|
||||
<entry>call next command in global history</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>page_up</literal></entry>
|
||||
<entry>scroll one page up</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>page_down</literal></entry>
|
||||
<entry>scroll one page down</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>scroll_up</literal></entry>
|
||||
<entry>scroll a few lines up</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>scroll_down</literal></entry>
|
||||
<entry>scroll a few lines down</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>scroll_top</literal></entry>
|
||||
<entry>scroll to top of buffer</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>scroll_bottom</literal></entry>
|
||||
<entry>scroll to bottom of buffer</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>nick_beginning</literal></entry>
|
||||
<entry>display beginning of nicklist</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>nick_end</literal></entry>
|
||||
<entry>display end of nicklist</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>nick_page_up</literal></entry>
|
||||
<entry>scroll nicklist one page up</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>nick_page_down</literal></entry>
|
||||
<entry>scroll nicklist one page down</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>jump_smart</literal></entry>
|
||||
<entry>jump to buffer with activity</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>jump_dcc</literal></entry>
|
||||
<entry>jump to DCC buffer</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>jump_raw_data</literal></entry>
|
||||
<entry>jump to raw IRC data buffer</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>jump_last_buffer</literal></entry>
|
||||
<entry>jump to last buffer</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>jump_server</literal></entry>
|
||||
<entry>jump to server buffer</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>jump_next_server</literal></entry>
|
||||
<entry>jump to next server</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>switch_server</literal></entry>
|
||||
<entry>switch active server on servers buffer</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>scroll_previous_highlight</literal></entry>
|
||||
<entry>scroll to previous highlight in buffer</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>scroll_next_highlight</literal></entry>
|
||||
<entry>scroll to next highlight in buffer</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>scroll_unread</literal></entry>
|
||||
<entry>scroll to first unread line in buffer</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>hotlist_clear</literal></entry>
|
||||
<entry>clear hotlist</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>infobar_clear</literal></entry>
|
||||
<entry>clear infobar</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>refresh</literal></entry>
|
||||
<entry>refresh screen</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>grab_key</literal></entry>
|
||||
<entry>grab a key</entry>
|
||||
</row>
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,234 @@
|
||||
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||
|
||||
<!-- ********* WARNING! *********
|
||||
|
||||
This file is automatically built with a Perl script. DO NOT EDIT!
|
||||
-->
|
||||
|
||||
<command>alias [alias_name [command [arguments]]]</command>
|
||||
<programlisting>
|
||||
create an alias for a command
|
||||
|
||||
alias_name: name of alias
|
||||
command: command name (WeeChat or IRC command, many commands can be separated by semicolons)
|
||||
arguments: arguments for command
|
||||
|
||||
</programlisting>
|
||||
<command>buffer [action [args] | number | [[server] [channel]]]</command>
|
||||
<programlisting>
|
||||
manage buffers
|
||||
|
||||
action: action to do:
|
||||
move: move buffer in the list (may be relative, for example -1)
|
||||
close: close buffer (optional arg is part message, for a channel)
|
||||
list: list opened buffers (no parameter implies this list)
|
||||
notify: set notify level for buffer (0=never, 1=highlight, 2=1+msg, 3=2+join/part)
|
||||
server
|
||||
channel: jump to buffer by server and/or channel name
|
||||
number: jump to buffer by number
|
||||
|
||||
</programlisting>
|
||||
<command>builtin command</command>
|
||||
<programlisting>
|
||||
launch WeeChat/IRC builtin command (do not look at plugins handlers or aliases)
|
||||
|
||||
command: command to execute (a '/' is automatically added if not found at beginning of command)
|
||||
|
||||
|
||||
</programlisting>
|
||||
<command>charset [(decode_iso | decode_utf | encode) charset]</command>
|
||||
<programlisting>
|
||||
change charset for server or channel
|
||||
|
||||
decode_iso: charset used for decoding ISO
|
||||
decode_utf: charset used for decoding UTF
|
||||
encode: charset used for encoding messages
|
||||
charset: charset to use (for example: ISO-8859-15, UTF-8,..)
|
||||
|
||||
</programlisting>
|
||||
<command>clear [-all]</command>
|
||||
<programlisting>
|
||||
clear window(s)
|
||||
|
||||
-all: clear all windows
|
||||
|
||||
</programlisting>
|
||||
<command>connect [servername]</command>
|
||||
<programlisting>
|
||||
connect to a server
|
||||
|
||||
servername: server name to connect
|
||||
|
||||
</programlisting>
|
||||
<command>disconnect [servername]</command>
|
||||
<programlisting>
|
||||
disconnect from a server
|
||||
|
||||
servername: server name to disconnect
|
||||
|
||||
</programlisting>
|
||||
<command>dcc action [nickname [file]]</command>
|
||||
<programlisting>
|
||||
starts DCC (file or chat) or close chat
|
||||
|
||||
action: 'send' (file) or 'chat' or 'close' (chat)
|
||||
nickname: nickname to send file or chat
|
||||
file: filename (on local host)
|
||||
|
||||
</programlisting>
|
||||
<command>debug dump | windows</command>
|
||||
<programlisting>
|
||||
print debug messages
|
||||
|
||||
dump: save memory dump in WeeChat log file (same dump is written when WeeChat crashes)
|
||||
windows: display windows tree
|
||||
|
||||
</programlisting>
|
||||
<command>help [command]</command>
|
||||
<programlisting>
|
||||
display help about commands
|
||||
|
||||
command: name of a WeeChat or IRC command
|
||||
|
||||
</programlisting>
|
||||
<command>history [clear | value]</command>
|
||||
<programlisting>
|
||||
show buffer command history
|
||||
|
||||
clear: clear history
|
||||
value: number of history entries to show
|
||||
|
||||
</programlisting>
|
||||
<command>ignore [mask [[type | command] [channel [server]]]]</command>
|
||||
<programlisting>
|
||||
ignore IRC messages and/or hosts
|
||||
|
||||
mask: nick or host mask to ignore
|
||||
type: type of message to ignore (action, ctcp, dcc, pv)
|
||||
command: IRC command
|
||||
channel: name of channel for ignore
|
||||
server: name of server for ignore
|
||||
|
||||
For each argument, '*' means all.
|
||||
Without argument, /ignore command lists all defined ignore.
|
||||
|
||||
</programlisting>
|
||||
<command>key [key function/command] [unbind key] [functions] [reset -yes]</command>
|
||||
<programlisting>
|
||||
bind/unbind keys
|
||||
|
||||
key: bind this key to an internal function or a command (beginning by "/")
|
||||
unbind: unbind a key
|
||||
functions: list internal functions for key bindings
|
||||
reset: restore bindings to the default values and delete ALL personal bindings (use carefully!)
|
||||
|
||||
</programlisting>
|
||||
<command>plugin [load filename] | [autoload] | [reload] | [unload]</command>
|
||||
<programlisting>
|
||||
list/load/unload plugins
|
||||
|
||||
filename: WeeChat plugin (file) to load
|
||||
|
||||
Without argument, /plugin command lists all loaded plugins.
|
||||
|
||||
</programlisting>
|
||||
<command>server [servername] | [servername hostname port [-auto | -noauto] [-ipv6] [-ssl] [-pwd password] [-nicks nick1 nick2 nick3] [-username username] [-realname realname] [-command command] [-autojoin channel[,channel]] ] | [del servername]</command>
|
||||
<programlisting>
|
||||
list, add or remove servers
|
||||
|
||||
servername: server name, for internal and display use
|
||||
hostname: name or IP address of server
|
||||
port: port for server (integer)
|
||||
ipv6: use IPv6 protocol
|
||||
ssl: use SSL protocol
|
||||
password: password for server
|
||||
nick1: first nick for server
|
||||
nick2: alternate nick for server
|
||||
nick3: second alternate nick for server
|
||||
username: user name
|
||||
realname: real name of user
|
||||
|
||||
</programlisting>
|
||||
<command>save [file]</command>
|
||||
<programlisting>
|
||||
save config to disk
|
||||
|
||||
file: filename for writing config
|
||||
|
||||
</programlisting>
|
||||
<command>set [option [ = value]]</command>
|
||||
<programlisting>
|
||||
set config options
|
||||
|
||||
option: name of an option (if name is full and no value is given, then help is displayed on option)
|
||||
value: value for option
|
||||
|
||||
Option may be: servername.server_xxx where "servername" is an internal server name and "xxx" an option for this server.
|
||||
|
||||
</programlisting>
|
||||
<command>setp [option [ = value]]</command>
|
||||
<programlisting>
|
||||
set plugin config options
|
||||
|
||||
option: name of a plugin option
|
||||
value: value for option
|
||||
|
||||
Option is format: plugin.option, example: perl.myscript.item1
|
||||
|
||||
</programlisting>
|
||||
<command>unalias alias_name</command>
|
||||
<programlisting>
|
||||
remove an alias
|
||||
|
||||
alias_name: name of alias to remove
|
||||
|
||||
</programlisting>
|
||||
<command>unignore [number | [mask [[type | command] [channel [server]]]]]</command>
|
||||
<programlisting>
|
||||
unignore IRC messages and/or hosts
|
||||
|
||||
number: # of ignore to unignore (number is displayed by list of ignore)
|
||||
mask: nick or host mask to unignore
|
||||
type: type of message to unignore (action, ctcp, dcc, pv)
|
||||
command: IRC command
|
||||
channel: name of channel for unignore
|
||||
server: name of server for unignore
|
||||
|
||||
For each argument, '*' means all.
|
||||
Without argument, /unignore command lists all defined ignore.
|
||||
|
||||
</programlisting>
|
||||
<command>upgrade</command>
|
||||
<programlisting>
|
||||
upgrade WeeChat without disconnecting from servers
|
||||
|
||||
This command run again WeeChat binary, so it should have been compiled or installed with a package manager before running this command.
|
||||
|
||||
</programlisting>
|
||||
<command>uptime [-o]</command>
|
||||
<programlisting>
|
||||
show WeeChat uptime
|
||||
|
||||
-o: send uptime on current channel as an IRC message
|
||||
|
||||
</programlisting>
|
||||
<command>window [list | -1 | +1 | b# | up | down | left | right | splith [pct] | splitv [pct] | resize pct | merge [all]]</command>
|
||||
<programlisting>
|
||||
manage windows
|
||||
|
||||
list: list opened windows (no parameter implies this list)
|
||||
-1: jump to previous window
|
||||
+1: jump to next window
|
||||
b#: jump to next window displaying buffer number #
|
||||
up: switch to window above current one
|
||||
down: switch to window below current one
|
||||
left: switch to window on the left
|
||||
right: switch to window on the right
|
||||
splith: split current window horizontally
|
||||
splitv: split current window vertically
|
||||
resize: resize window size, new size is <pct> pourcentage of parent window
|
||||
merge: merge window with another (all = keep only one window)
|
||||
|
||||
For splith and splitv, pct is a pourcentage which represents size of new window, computed with current window as size reference. For example 25 means create a new window with size = current_size / 4
|
||||
|
||||
</programlisting>
|
||||
@@ -0,0 +1,61 @@
|
||||
# Copyright (c) 2003-2006 FlashCode <flashcode@flashtux.org>
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; either version 2 of the License, or
|
||||
# (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
#
|
||||
|
||||
LANGCODE = fr
|
||||
BOOK = weechat.$(LANGCODE)
|
||||
BOOK_INCLUDE = weechat_commands.xml irc_commands.xml key_functions.xml config.xml
|
||||
|
||||
EXTRA_DIST = $(BOOK).xml $(BOOK_INCLUDE)
|
||||
|
||||
docdir = $(datadir)/doc/$(PACKAGE)
|
||||
|
||||
all-local: html-stamp
|
||||
|
||||
# HTML output with chunks (many pages)
|
||||
|
||||
html: html-stamp
|
||||
|
||||
html-stamp: $(BOOK).xml $(BOOK_INCLUDE) ../weechat-html.xsl ../weechat-doc.css
|
||||
echo "<pubdate>`date -R`</pubdate>" >date.xml
|
||||
mkdir -p html/
|
||||
xsltproc -o html/ ../weechat-html.xsl $(BOOK).xml || true
|
||||
cp ../weechat-doc.css html/
|
||||
touch html-stamp
|
||||
|
||||
# HTML output, all in one page
|
||||
|
||||
html1: html1-stamp
|
||||
|
||||
html1-stamp: $(BOOK).xml $(BOOK_INCLUDE) ../weechat-html-one.xsl ../weechat-doc.css
|
||||
echo "<pubdate>`date -R`</pubdate>" >date.xml
|
||||
mkdir -p html1/
|
||||
xsltproc -o html1/$(BOOK).html ../weechat-html-one.xsl $(BOOK).xml || true
|
||||
cp ../weechat-doc.css html1/
|
||||
touch html1-stamp
|
||||
|
||||
# install docs
|
||||
|
||||
install-data-hook:
|
||||
$(mkinstalldirs) $(DESTDIR)$(docdir)/html/$(LANGCODE)/
|
||||
$(INSTALL_DATA) html/* $(DESTDIR)$(docdir)/html/$(LANGCODE)/
|
||||
|
||||
# clean
|
||||
|
||||
clean-local:
|
||||
-rm -f *.html *.pdf *.txt date.xml
|
||||
-rm -rf html/ html1/
|
||||
-rm -f html-stamp html1-stamp
|
||||
+1246
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,443 @@
|
||||
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||
|
||||
<!-- ********* WARNING! *********
|
||||
|
||||
This file is automatically built with a Perl script. DO NOT EDIT!
|
||||
-->
|
||||
|
||||
<command>admin [cible]</command>
|
||||
<programlisting>
|
||||
trouver les informations sur l'administrateur du serveur
|
||||
|
||||
cible: serveur
|
||||
|
||||
</programlisting>
|
||||
<command>ame message</command>
|
||||
<programlisting>
|
||||
envoyer une action CTCP à tous les canaux de tous les serveurs connectés
|
||||
|
||||
message: message Ă envoyer
|
||||
|
||||
</programlisting>
|
||||
<command>amsg texte</command>
|
||||
<programlisting>
|
||||
envoyer un message à tous les canaux de tous les serveurs connectés
|
||||
|
||||
texte: texte Ă envoyer
|
||||
|
||||
</programlisting>
|
||||
<command>away [-all] [message]</command>
|
||||
<programlisting>
|
||||
basculer le statut absent
|
||||
|
||||
-all: basculer le statut absent sur tous les serveurs connectés
|
||||
message: message pour l'absence (si pas de message donné, le statut d'absence est supprimé)
|
||||
|
||||
</programlisting>
|
||||
<command>ban [canal] [pseudo [pseudo ...]]</command>
|
||||
<programlisting>
|
||||
bannit des pseudos ou masques
|
||||
|
||||
canal: nom du canal pour le bannissement
|
||||
pseudo: pseudo ou masque pour le bannissement
|
||||
|
||||
</programlisting>
|
||||
<command>ctcp pseudo type [arguments]</command>
|
||||
<programlisting>
|
||||
envoyer un message CTCP (Client-To-Client Protocol)
|
||||
|
||||
pseudo: utilisateur Ă qui envoyer le CTCP
|
||||
type: type de CTCP (exemples: "version", "ping", etc...)
|
||||
arguments: arguments pour le CTCP
|
||||
|
||||
</programlisting>
|
||||
<command>cycle [canal[,canal]] [message_de_fin]</command>
|
||||
<programlisting>
|
||||
quitter et rejoindre un canal
|
||||
|
||||
canal: canal pour le cycle
|
||||
message_de_fin: message de fin (affiché aux autres utilisateurs)
|
||||
|
||||
</programlisting>
|
||||
<command>dehalfop [pseudo [pseudo]]</command>
|
||||
<programlisting>
|
||||
retire le statut de demi-opérateur du canal à /aux nick(s)
|
||||
|
||||
</programlisting>
|
||||
<command>deop [pseudo [pseudo]]</command>
|
||||
<programlisting>
|
||||
retire le statut d'opérateur du canal à /aux nick(s)
|
||||
|
||||
</programlisting>
|
||||
<command>devoice [pseudo [pseudo]]</command>
|
||||
<programlisting>
|
||||
retire la voix du/des pseudo(s)
|
||||
|
||||
</programlisting>
|
||||
<command>die</command>
|
||||
<programlisting>
|
||||
arrĂŞter le serveur
|
||||
|
||||
</programlisting>
|
||||
<command>halfop [pseudo [pseudo]]</command>
|
||||
<programlisting>
|
||||
donner le statut de demi-opérateur à un/des utilisateur(s)
|
||||
|
||||
</programlisting>
|
||||
<command>info [cible]</command>
|
||||
<programlisting>
|
||||
voir les informations décrivant le serveur
|
||||
|
||||
cible: nom du serveur
|
||||
|
||||
</programlisting>
|
||||
<command>invite pseudo canal</command>
|
||||
<programlisting>
|
||||
inviter un utilisateur sur un canal
|
||||
|
||||
pseudo: utilisateur Ă inviter
|
||||
channel: canal pour l'invitation
|
||||
|
||||
</programlisting>
|
||||
<command>ison pseudo [pseudo ...]</command>
|
||||
<programlisting>
|
||||
vérifier si un utilisateur est actuellement sur IRC
|
||||
|
||||
pseudo: pseudo
|
||||
|
||||
</programlisting>
|
||||
<command>join canal[,canal] [clé[,clé]]</command>
|
||||
<programlisting>
|
||||
joindre un canal
|
||||
|
||||
canal: nom du canal Ă rejoindre
|
||||
clé: clé pour rejoindre le canal
|
||||
|
||||
</programlisting>
|
||||
<command>kick [canal] pseudo [commentaire]</command>
|
||||
<programlisting>
|
||||
retirer par la force un utilisateur d'un canal
|
||||
|
||||
canal: canal oĂą l'utilisateur se trouve
|
||||
pseudo: utilisateur à éliminer
|
||||
commentaire: commentaire pour l'élimination
|
||||
|
||||
</programlisting>
|
||||
<command>kickban [canal] pseudo [commentaire]</command>
|
||||
<programlisting>
|
||||
retirer par la force un utilisateur d'un canal et le bannir
|
||||
|
||||
canal: canal oĂą l'utilisateur se trouve
|
||||
pseudo: utilisateur à éliminer et bannir
|
||||
commentaire: commentaire pour l'élimination
|
||||
|
||||
</programlisting>
|
||||
<command>kill pseudo commentaire</command>
|
||||
<programlisting>
|
||||
fermer la connexion client-serveur
|
||||
|
||||
pseudo: utilisateur
|
||||
commentaire: commentaire pour la mort
|
||||
|
||||
</programlisting>
|
||||
<command>links [[serveur] masque_serveur]</command>
|
||||
<programlisting>
|
||||
lister tous les noms de serveurs connus du serveur qui répondent à la requête
|
||||
|
||||
serveur: ce serveur doit répondre à la requête
|
||||
masque_serveur: liste des serveurs correspondant au masque
|
||||
|
||||
</programlisting>
|
||||
<command>list [canal[,canal] [serveur]]</command>
|
||||
<programlisting>
|
||||
lister les canaux et leur sujet
|
||||
|
||||
canal: canal à lister (une expression régulière est acceptée)
|
||||
serveur: nom du serveur
|
||||
|
||||
</programlisting>
|
||||
<command>lusers [masque [cible]]</command>
|
||||
<programlisting>
|
||||
obtenir des statistiques sur la taille du réseau IRC
|
||||
|
||||
masque: serveurs qui correspondent au masque seulement
|
||||
cible: serveur pour faire suivre la requĂŞte
|
||||
|
||||
</programlisting>
|
||||
<command>me message</command>
|
||||
<programlisting>
|
||||
envoyer une action CTCP au canal courant
|
||||
|
||||
message: message Ă envoyer
|
||||
|
||||
</programlisting>
|
||||
<command>mode { canal {[+|-]|o|p|s|i|t|n|b|v} [limite] [utilisateur] [masque de banissement] } | { nick {[+|-]|i|w|s|o} }</command>
|
||||
<programlisting>
|
||||
changer le mode du canal ou de l'utilisateur
|
||||
|
||||
modes de canaux :
|
||||
canal: nom du canal Ă modifier
|
||||
o: donner/reprendre le statut privilégié d'opérateur
|
||||
p: indicateur de canal privé
|
||||
s: indicateur de canal secret
|
||||
i: indicateur de canal avec invitation seulement
|
||||
t: le titre est modifiable seulement par un opérateur du canal
|
||||
n: aucun message au canal depuis l'extérieur
|
||||
m: canal modéré
|
||||
l: fixer la limite d'utilisateurs pour le canal
|
||||
b: paramétrer un masque de banissement pour garder des utilisateurs dehors
|
||||
e: paramétrer un masque d'exception
|
||||
v: donner/reprendre la possibilité de parler sur un canal modéré
|
||||
k: définir une clé (mot de passe) pour accéder au canal
|
||||
modes utilisateur :
|
||||
pseudo: utilisateur Ă modifier
|
||||
i: marquer un utilisateur comme invisible
|
||||
s: marquer un utilisateur pour recevoir les notices du serveur
|
||||
w: l'utilisateur reçoit les wallops
|
||||
o: drapeau opérateur
|
||||
|
||||
</programlisting>
|
||||
<command>motd [cible]</command>
|
||||
<programlisting>
|
||||
obtenir le message du jour
|
||||
|
||||
cible: nom du serveur
|
||||
|
||||
</programlisting>
|
||||
<command>msg cible[,cible] texte</command>
|
||||
<programlisting>
|
||||
envoyer un message Ă un utilisateur ou canal
|
||||
|
||||
cible: utilisateur ou canal (peut-ĂŞtre un masque, '*' = canal courant)
|
||||
texte: texte Ă envoyer
|
||||
|
||||
</programlisting>
|
||||
<command>names [canal[,canal]]</command>
|
||||
<programlisting>
|
||||
lister les utilisateurs sur des canaux
|
||||
|
||||
canal: nom du canal
|
||||
|
||||
</programlisting>
|
||||
<command>nick [-all] pseudo</command>
|
||||
<programlisting>
|
||||
changer le pseudo courant
|
||||
|
||||
-all: définir le nouveau pseudo sur tous les serveurs connectés
|
||||
pseudo: nouveau pseudo
|
||||
|
||||
</programlisting>
|
||||
<command>notice pseudo texte</command>
|
||||
<programlisting>
|
||||
envoyer un message notice Ă un utilisateur
|
||||
|
||||
pseudo: utilisateur cible pour la notice
|
||||
texte: texte Ă envoyer
|
||||
|
||||
</programlisting>
|
||||
<command>op pseudo [pseudo]</command>
|
||||
<programlisting>
|
||||
donner le statut opérateur à un/des utilisateur(s)
|
||||
|
||||
</programlisting>
|
||||
<command>oper utilisateur mot_de_passe</command>
|
||||
<programlisting>
|
||||
obtenir le statut d'opérateur
|
||||
|
||||
utilisateur/mot_de_passe: utilisé pour obtenir les privilèges sur le serveur IRC courant
|
||||
|
||||
</programlisting>
|
||||
<command>part [canal[,canal]] [message_de_fin]</command>
|
||||
<programlisting>
|
||||
quitter un canal
|
||||
|
||||
canal: canal Ă quitter
|
||||
message_de_fin: message de fin (affiché aux autres utilisateurs)
|
||||
|
||||
</programlisting>
|
||||
<command>ping serveur1 [serveur2]</command>
|
||||
<programlisting>
|
||||
pinguer un serveur
|
||||
|
||||
serveur1: serveur Ă pinguer
|
||||
serveur2: faire suivre le ping Ă ce serveur
|
||||
|
||||
</programlisting>
|
||||
<command>pong démon [démon2]</command>
|
||||
<programlisting>
|
||||
répondre à un message ping
|
||||
|
||||
démon: démon qui a répondu au message Ping
|
||||
démon2: faire suivre le message à ce démon
|
||||
|
||||
</programlisting>
|
||||
<command>query pseudo [texte]</command>
|
||||
<programlisting>
|
||||
envoyer un message privé à un utilisateur
|
||||
|
||||
pseudo: utilisateur pour la conversation privée
|
||||
texte: texte Ă envoyer
|
||||
|
||||
</programlisting>
|
||||
<command>quit [message_de_fin]</command>
|
||||
<programlisting>
|
||||
fermer toutes les connexions et quitter
|
||||
|
||||
message_de_fin: message de fin (affiché aux autres utilisateurs)
|
||||
|
||||
</programlisting>
|
||||
<command>quote données</command>
|
||||
<programlisting>
|
||||
envoyer des données brutes au serveur sans analyse
|
||||
|
||||
données: données brutes à envoyer
|
||||
|
||||
</programlisting>
|
||||
<command>rehash</command>
|
||||
<programlisting>
|
||||
demander au serveur de recharger son fichier de configuration
|
||||
|
||||
</programlisting>
|
||||
<command>restart</command>
|
||||
<programlisting>
|
||||
demander au serveur de redémarrer
|
||||
|
||||
</programlisting>
|
||||
<command>service pseudo réservé distribution type réservé info</command>
|
||||
<programlisting>
|
||||
enregister un nouveau service
|
||||
|
||||
distribution: visibilité du service
|
||||
type: réservé pour une utilisation future
|
||||
|
||||
</programlisting>
|
||||
<command>servlist [masque [type]]</command>
|
||||
<programlisting>
|
||||
lister les services actuellement connectés au réseau
|
||||
|
||||
masque: lister seulement les services qui correspondent Ă ce masque
|
||||
type: lister seulement les services de ce type
|
||||
|
||||
</programlisting>
|
||||
<command>squery service texte</command>
|
||||
<programlisting>
|
||||
envoyer un message Ă un service
|
||||
|
||||
service: nom du service
|
||||
texte: texte Ă envoyer
|
||||
|
||||
</programlisting>
|
||||
<command>squit serveur commentaire</command>
|
||||
<programlisting>
|
||||
déconnecter les liens vers un serveur
|
||||
|
||||
serveur: nom du serveur
|
||||
commentaire: commentaire pour quitter
|
||||
|
||||
</programlisting>
|
||||
<command>stats [requĂŞte [serveur]]</command>
|
||||
<programlisting>
|
||||
demander des statistiques sur le serveur
|
||||
|
||||
requĂŞte: c/h/i/k/l/m/o/y/u (voir la RFC1459)
|
||||
serveur: nom du serveur
|
||||
|
||||
</programlisting>
|
||||
<command>summon utilisateur [cible [canal]]</command>
|
||||
<programlisting>
|
||||
envoyer aux utilisateurs d'un serveur IRC un message leur demandant de rejoindre IRC
|
||||
|
||||
utilisateur: nom d'utilisateur
|
||||
cible: nom du serveur
|
||||
canal: nom du canal
|
||||
|
||||
</programlisting>
|
||||
<command>time [cible]</command>
|
||||
<programlisting>
|
||||
demander l'heure locale de serveur
|
||||
|
||||
cible: demander l'heure de ce serveur
|
||||
|
||||
</programlisting>
|
||||
<command>topic [canal] [titre]</command>
|
||||
<programlisting>
|
||||
recevoir/définir le titre du canal
|
||||
|
||||
canal: nom du canal
|
||||
titre: nouveau titre pour le canal (si le titre est "-delete" alors le titre est supprimé)
|
||||
|
||||
</programlisting>
|
||||
<command>trace [cible]</command>
|
||||
<programlisting>
|
||||
trouver le chemin jusqu'à un serveur spécifique
|
||||
|
||||
cible: serveur
|
||||
|
||||
</programlisting>
|
||||
<command>unban [canal] pseudo [pseudo ...]</command>
|
||||
<programlisting>
|
||||
supprime le bannissement sur des pseudos ou masques
|
||||
|
||||
canal: nom du canal pour supprimer le bannissement
|
||||
pseudo: pseudo ou masque pour supprimer le bannissement
|
||||
|
||||
</programlisting>
|
||||
<command>userhost pseudo [pseudo ...]</command>
|
||||
<programlisting>
|
||||
retourne une liste d'informations sur des utilisateurs
|
||||
|
||||
pseudo: pseudo
|
||||
|
||||
</programlisting>
|
||||
<command>users [cible]</command>
|
||||
<programlisting>
|
||||
liste des utilisateurs connectés au serveur
|
||||
|
||||
cible: serveur
|
||||
|
||||
</programlisting>
|
||||
<command>version [serveur | pseudo]</command>
|
||||
<programlisting>
|
||||
retourne la version de l'utilisateur ou du serveur (courant ou spécifié)
|
||||
|
||||
serveur: nom du serveur
|
||||
pseudo: utilisateur
|
||||
|
||||
</programlisting>
|
||||
<command>voice [pseudo [pseudo]]</command>
|
||||
<programlisting>
|
||||
donne la voix Ă /aux utilisateur(s)
|
||||
|
||||
</programlisting>
|
||||
<command>wallops texte</command>
|
||||
<programlisting>
|
||||
envoyer un message à tous les utilisateurs connectés qui ont activé le mode utilisateur 'w' pour eux-mêmes
|
||||
|
||||
texte Ă envoyer
|
||||
|
||||
</programlisting>
|
||||
<command>who [masque ["o"]]</command>
|
||||
<programlisting>
|
||||
génère une requête qui retourne une liste d'information
|
||||
|
||||
masque: information qui correspond Ă ce masque uniquement
|
||||
o: seul les opérateurs sont retournés correspondant au masque fourni
|
||||
|
||||
</programlisting>
|
||||
<command>whois [serveur] pseudo[,pseudo]</command>
|
||||
<programlisting>
|
||||
demande les informations sur le(s) utilisateur(s)
|
||||
|
||||
serveur: nom du serveur
|
||||
pseudo: utilisateur (peut ĂŞtre un masque)
|
||||
|
||||
</programlisting>
|
||||
<command>whowas pseudo [,pseudo [,pseudo ...]] [nombre [cible]]</command>
|
||||
<programlisting>
|
||||
demander de l'information sur un nick qui n'existe plus
|
||||
|
||||
pseudo: pseudo Ă chercher
|
||||
nombre: nombre de réponses à retourner (recherche complète si nombre négatif)
|
||||
cible: la réponse doit correspondre à ce masque
|
||||
|
||||
</programlisting>
|
||||
@@ -0,0 +1,191 @@
|
||||
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||
|
||||
<!-- ********* WARNING! *********
|
||||
|
||||
This file is automatically built with a Perl script. DO NOT EDIT!
|
||||
-->
|
||||
|
||||
<row>
|
||||
<entry><literal>return</literal></entry>
|
||||
<entry>terminer la ligne</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>tab</literal></entry>
|
||||
<entry>compléter le mot</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>tab_previous</literal></entry>
|
||||
<entry>trouver le mot complété précédent</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>backspace</literal></entry>
|
||||
<entry>effacer le caractère précédent</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>delete</literal></entry>
|
||||
<entry>effacer le caractère suivant</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>delete_end_line</literal></entry>
|
||||
<entry>effacer jusqu'Ă la fin de la ligne</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>delete_beginning_line</literal></entry>
|
||||
<entry>effacer jusqu'au début de la ligne</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>delete_line</literal></entry>
|
||||
<entry>effacer la ligne entière</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>delete_previous_word</literal></entry>
|
||||
<entry>effacer le mot précédent</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>delete_next_word</literal></entry>
|
||||
<entry>effacer le mot suivant</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>clipboard_paste</literal></entry>
|
||||
<entry>coller le contenu du presse-papier</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>transpose_chars</literal></entry>
|
||||
<entry>inverser les caractères</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>home</literal></entry>
|
||||
<entry>aller au début de la ligne</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>end</literal></entry>
|
||||
<entry>aller Ă la fin de la ligne</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>left</literal></entry>
|
||||
<entry>se déplacer d'un caractère à gauche</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>previous_word</literal></entry>
|
||||
<entry>se déplacer au mot précédent</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>right</literal></entry>
|
||||
<entry>se déplacer d'un caractère à droite</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>next_word</literal></entry>
|
||||
<entry>se déplacer au mot suivant</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>up</literal></entry>
|
||||
<entry>appeler la commande précédente dans l'historique</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>up_global</literal></entry>
|
||||
<entry>appeler la commande précédente dans l'historique global</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>down</literal></entry>
|
||||
<entry>appeler la commande suivante dans l'historique</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>down_global</literal></entry>
|
||||
<entry>appeler la commande suivante dans l'historique global</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>page_up</literal></entry>
|
||||
<entry>faire défiler d'une page vers le haut</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>page_down</literal></entry>
|
||||
<entry>faire défiler d'une page vers le bas</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>scroll_up</literal></entry>
|
||||
<entry>faire défiler de quelques lignes vers le haut</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>scroll_down</literal></entry>
|
||||
<entry>faire défiler de quelques lignes vers le bas</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>scroll_top</literal></entry>
|
||||
<entry>faire défiler jusqu'au début du tampon</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>scroll_bottom</literal></entry>
|
||||
<entry>faire défiler jusqu'à la fin du tampon</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>nick_beginning</literal></entry>
|
||||
<entry>afficher le début de la liste des pseudos</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>nick_end</literal></entry>
|
||||
<entry>afficher la fin de la liste des pseudos</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>nick_page_up</literal></entry>
|
||||
<entry>faire défiler la liste des pseudos d'une page vers le haut</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>nick_page_down</literal></entry>
|
||||
<entry>faire défiler la liste des pseudos d'une page vers le bas</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>jump_smart</literal></entry>
|
||||
<entry>sauter au tampon avec de l'activité</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>jump_dcc</literal></entry>
|
||||
<entry>sauter au tampon DCC</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>jump_raw_data</literal></entry>
|
||||
<entry>sauter au tampon IRC brut</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>jump_last_buffer</literal></entry>
|
||||
<entry>sauter au dernier tampon</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>jump_server</literal></entry>
|
||||
<entry>sauter au tampon du serveur</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>jump_next_server</literal></entry>
|
||||
<entry>sauter au prochain serveur</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>switch_server</literal></entry>
|
||||
<entry>bascule de serveur actif sur le tampon des serveurs</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>scroll_previous_highlight</literal></entry>
|
||||
<entry>scroller jusqu'au highlight précédent du tampon</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>scroll_next_highlight</literal></entry>
|
||||
<entry>scroller jusqu'au highlight suivant du tampon</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>scroll_unread</literal></entry>
|
||||
<entry>scroller jusqu'à la première ligne non lue du tampon</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>hotlist_clear</literal></entry>
|
||||
<entry>effacer la liste d'activité</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>infobar_clear</literal></entry>
|
||||
<entry>effacer la barre d'infos</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>refresh</literal></entry>
|
||||
<entry>rafraîchir l'écran</entry>
|
||||
</row>
|
||||
<row>
|
||||
<entry><literal>grab_key</literal></entry>
|
||||
<entry>capturer une touche</entry>
|
||||
</row>
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,234 @@
|
||||
<?xml version="1.0" encoding="iso-8859-1"?>
|
||||
|
||||
<!-- ********* WARNING! *********
|
||||
|
||||
This file is automatically built with a Perl script. DO NOT EDIT!
|
||||
-->
|
||||
|
||||
<command>alias [nom_alias [commande [paramètres]]]</command>
|
||||
<programlisting>
|
||||
créer un alias pour une commande
|
||||
|
||||
nom_alias: nom de l'alias
|
||||
commande: nom de la commande (commande WeeChat ou IRC, plusieurs commandes peuvent être séparées par des point-virgules)
|
||||
paramètres: paramètres pour la commande
|
||||
|
||||
</programlisting>
|
||||
<command>buffer [action [args] | nombre | [[serveur] [canal]]]</command>
|
||||
<programlisting>
|
||||
gestion des tampons
|
||||
|
||||
action: action Ă effectuer:
|
||||
move: déplacer le tampon dans la liste (peut être relatif, par exemple -1)
|
||||
close: fermer le tampon (le paramètre optionnel est le message de fin, pour un canal)
|
||||
list: liste les tampons ouverts (pas de paramètre affiche cette liste)
|
||||
notify: fixer le niveau de notification (0=jamais, 1=highlight, 2=1+msg, 3=2+join/part)
|
||||
serveur
|
||||
canal: sauter au tampon par serveur et/ou nom de canal
|
||||
nombre: sauter au tampon qui a ce numéro
|
||||
|
||||
</programlisting>
|
||||
<command>builtin commande</command>
|
||||
<programlisting>
|
||||
lance une commande WeeChat/IRC interne (sans regarder les gestionnaires de commandes et les alias)
|
||||
|
||||
commande: commande à exécuter (un '/' est automatiquement ajouté s'il n'est pas trouvé au début de la commande)
|
||||
|
||||
|
||||
</programlisting>
|
||||
<command>charset [(decode_iso | decode_utf | encode) charset]</command>
|
||||
<programlisting>
|
||||
changer le jeu de caractères pour le serveur ou le canal
|
||||
|
||||
decode_iso: jeu de caractères utilisé pour décoder l'ISO
|
||||
decode_utf: jeu de caractères utilisé pour décoder l'UTF
|
||||
encode: jeu de caractères utilisé pour encoder les messages
|
||||
charset: jeu de caractères à utiliser (par exemple: ISO-8859-15, UTF-8,..)
|
||||
|
||||
</programlisting>
|
||||
<command>clear [-all]</command>
|
||||
<programlisting>
|
||||
effacer la/les fenĂŞtre(s)
|
||||
|
||||
-all: effacer toutes les fenĂŞtres
|
||||
|
||||
</programlisting>
|
||||
<command>connect [nom_serveur]</command>
|
||||
<programlisting>
|
||||
se connecter Ă un serveur
|
||||
|
||||
nom_serveur: nom du serveur pour se connecter
|
||||
|
||||
</programlisting>
|
||||
<command>disconnect [nom_serveur]</command>
|
||||
<programlisting>
|
||||
se déconnecter d'un serveur
|
||||
|
||||
nom_serveur: nom du serveur pour se déconnecter
|
||||
|
||||
</programlisting>
|
||||
<command>dcc action [pseudo [fichier]]</command>
|
||||
<programlisting>
|
||||
démarre le DCC (fichier ou discussion) ou ferme une discussion
|
||||
|
||||
action: 'send' (envoi de fichier) ou 'chat' (discussion) ou 'close' (fermeture discussion)
|
||||
pseudo: pseudo pour envoyer le fichier ou discuter
|
||||
fichier: nom du fichier (sur la machine locale)
|
||||
|
||||
</programlisting>
|
||||
<command>debug dump | windows</command>
|
||||
<programlisting>
|
||||
affiche des messages de debogage
|
||||
|
||||
dump: affiche les variables mémoire WeeChat dans le fichier log (les mêmes messages sont affichés lorsque WeeChat plante)
|
||||
windows: affiche l'arbre des fenĂŞtres
|
||||
|
||||
</programlisting>
|
||||
<command>help [commande]</command>
|
||||
<programlisting>
|
||||
afficher l'aide sur les commandes
|
||||
|
||||
commande: nom d'une commande WeeChat ou IRC
|
||||
|
||||
</programlisting>
|
||||
<command>history [clear | valeur]</command>
|
||||
<programlisting>
|
||||
affiche l'historique des commandes du tampon
|
||||
|
||||
clear: effacer l'historique
|
||||
valeur: nombre d'entrées dans l'historique à afficher
|
||||
|
||||
</programlisting>
|
||||
<command>ignore [masque [[type | commande] [canal [serveur]]]]</command>
|
||||
<programlisting>
|
||||
ignorer des messages IRC et/ou des masques
|
||||
|
||||
masque: pseudo ou masque Ă ignorer
|
||||
type: type de message Ă ignorer (action, ctcp, dcc, pv)
|
||||
commande: commande IRC
|
||||
canal: nom du canal pour le ignore
|
||||
serveur: nom du serveur pour le ignore
|
||||
|
||||
Pour chaque paramètre, '*' signifie tou(te)s.
|
||||
Sans paramètres, la commande /ignore liste les ignore définis.
|
||||
|
||||
</programlisting>
|
||||
<command>key [touche fonction/commande] [unbind touche] [functions] [reset -yes]</command>
|
||||
<programlisting>
|
||||
associer/libérer des touches
|
||||
|
||||
touche: associer cette touche à une fonction interne ou une commande (commençant par "/")
|
||||
unbind: supprimer l'association Ă une touche
|
||||
functions: lister la liste des fonctions internes pour les associations de touches
|
||||
reset: restaure les touches aux valeurs par défaut et supprime TOUTES les touches personnelles (utiliser avec précaution !)
|
||||
|
||||
</programlisting>
|
||||
<command>plugin [load fichier] | [autoload] | [reload] | [unload]</command>
|
||||
<programlisting>
|
||||
liste/charge/décharge des extensions
|
||||
|
||||
fichier: extension WeeChat (fichier) Ă charger
|
||||
|
||||
Sans paramètre, la commande /plugin liste toutes les extensions chargées.
|
||||
|
||||
</programlisting>
|
||||
<command>server [nom_serveur] | [nom_serveur nom/IP port [-auto | -noauto] [-ipv6] [-ssl] [-pwd mot_de_passe] [-nicks pseudo1 pseudo2 pseudo3] [-username nom_utilisateur] [-realname nom_réel] [-command commande] [-autojoin canal[,canal]] ] | [del nom_serveur]</command>
|
||||
<programlisting>
|
||||
liste, ajoute ou retire des serveurs
|
||||
|
||||
nom_serveur: nom du serveur, pour usage interne et affichage
|
||||
nom/IP: nom ou adresse IP du serveur
|
||||
port: port pour le serveur (nombre entier)
|
||||
ipv6: utiliser le protocole IPv6
|
||||
ssl: utiliser le protocole SSL
|
||||
mot_de_passe: mot de passe pour le serveur
|
||||
pseudo1: premier pseudo pour le serveur
|
||||
pseudo2: pseudo alternatif pour le serveur
|
||||
pseudo3: second pseudo alternatif pour le serveur
|
||||
nom_utilisateur: nom d'utilisateur
|
||||
nom_réel: nom réel de l'utilisateur
|
||||
|
||||
</programlisting>
|
||||
<command>save [fichier]</command>
|
||||
<programlisting>
|
||||
sauvegarder la configuration sur disque
|
||||
|
||||
fichier: fichier pour sauvegarder la configuration
|
||||
|
||||
</programlisting>
|
||||
<command>set [option [ = valeur]]</command>
|
||||
<programlisting>
|
||||
modifier des options de configuration
|
||||
|
||||
option: nom de l'option (si le nom est complet et qu'aucune valeur n'est donnée, alors l'aide sur l'option est affichée)
|
||||
valeur: valeur pour l'option
|
||||
|
||||
L'option peut ĂŞtre: nomserveur.server_xxx oĂą "nomserveur" est le nom interne d'un serveur et "xxx" une option pour ce serveur.
|
||||
|
||||
</programlisting>
|
||||
<command>setp [option [ = valeur]]</command>
|
||||
<programlisting>
|
||||
modifier des options de configuration des extensions
|
||||
|
||||
option: nom d'une option d'extension
|
||||
valeur: valeur pour l'option
|
||||
|
||||
L'option est au format: extension.option, par exemple: perl.monscript.variable1
|
||||
|
||||
</programlisting>
|
||||
<command>unalias nom_alias</command>
|
||||
<programlisting>
|
||||
supprimer un alias
|
||||
|
||||
nom_alias: nom de l'alias Ă supprimer
|
||||
|
||||
</programlisting>
|
||||
<command>unignore [nombre | [masque [[type | commande] [canal [serveur]]]]]</command>
|
||||
<programlisting>
|
||||
supprimer le ignore des messages IRC et/ou des masques
|
||||
|
||||
nombre: numéro de ignore à supprimer (le nombre est affiché sur la liste des ignore)
|
||||
masque: pseudo ou masque Ă ignorer
|
||||
type: type de message Ă ignorer (action, ctcp, dcc, pv)
|
||||
commande: commande IRC
|
||||
canal: nom du canal pour le ignore
|
||||
serveur: nom du serveur pour le ignore
|
||||
|
||||
Pour chaque paramètre, '*' signifie tou(te)s.
|
||||
Sans paramètre, /ignore liste les ignore définis.
|
||||
|
||||
</programlisting>
|
||||
<command>upgrade</command>
|
||||
<programlisting>
|
||||
mettre à jour WeeChat sans se déconnecter des serveurs
|
||||
|
||||
Cette commande lance à nouveau le binaire WeeChat, il doit donc avoir été compilé ou installé via un gestionnaire de paquet avant de lancer cette commande.
|
||||
|
||||
</programlisting>
|
||||
<command>uptime [-o]</command>
|
||||
<programlisting>
|
||||
montrer l'uptime de WeeChat
|
||||
|
||||
-o: envoyer l'uptime sur le canal courant en tant que message IRC
|
||||
|
||||
</programlisting>
|
||||
<command>window [list | -1 | +1 | b# | up | down | left | right | splith [pct] | splitv [ptc] | resize pct | merge [all]]</command>
|
||||
<programlisting>
|
||||
gestion des fenĂŞtres
|
||||
|
||||
list: liste les fenêtres ouvertes (pas de paramètre affiche cette liste)
|
||||
-1: saute à la fenêtre précédente
|
||||
+1: saute Ă la fenĂŞtre suivante
|
||||
b#: saute à la fenêtre affichant le tampon n°#
|
||||
up: saute Ă la fenĂŞtre au dessus
|
||||
down: saute Ă la fenĂŞtre au dessous
|
||||
left: saute Ă la fenĂŞtre Ă gauche
|
||||
right: saute Ă la fenĂŞtre Ă droite
|
||||
splith: éclate la fenêtre en deux horizontalement
|
||||
splitv: éclate la fenêtre en deux verticalement
|
||||
resize: redimensionne une fenĂŞtre, la nouvelle taille est <pct> pourcentage de la fenĂŞtre parent
|
||||
merge: fusionne la fenĂŞtre avec une autre
|
||||
|
||||
Pour splith et splitv, pct est un pourcentage qui représente la taille de la nouvelle fenêtre, calculée par rapport à la taille de la fenêtre courante. Par exemple 25 signifie créer une fenêtre qui a pour taille: taille_courante / 4
|
||||
|
||||
</programlisting>
|
||||
@@ -1,4 +1,4 @@
|
||||
.TH WEECHAT 1 "July 2005" "FlashCode"
|
||||
.TH WEECHAT 1 "May 2006" "FlashCode"
|
||||
|
||||
.SH NAME
|
||||
weechat-curses \- Wee Enhanced Environment for Chat (Curses version)
|
||||
@@ -19,10 +19,22 @@ It is compliant with RFCs 1459, 2810, 2811, 2812, and 2813.
|
||||
|
||||
.SH OPTIONS
|
||||
.TP
|
||||
.B \-a, \-\-no\-connect
|
||||
.br
|
||||
disable auto-connect to servers at startup
|
||||
.TP
|
||||
.B \-c, \-\-config
|
||||
.br
|
||||
display config file help (list of options)
|
||||
.TP
|
||||
.B \-d, \-\-dir <dir>
|
||||
.br
|
||||
set WeeChat home dir
|
||||
.TP
|
||||
.B \-f, \-\-key\-functions
|
||||
.br
|
||||
display internal functions for keys
|
||||
.TP
|
||||
.B \-h, \-\-help
|
||||
.br
|
||||
display summary of options
|
||||
@@ -31,10 +43,18 @@ display summary of options
|
||||
.br
|
||||
display IRC commands
|
||||
.TP
|
||||
.B \-k, \-\-keys
|
||||
.br
|
||||
display default keys
|
||||
.TP
|
||||
.B \-l, \-\-license
|
||||
.br
|
||||
display program license
|
||||
.TP
|
||||
.B \-p, \-\-no\-plugin
|
||||
.br
|
||||
don't load any plugin at startup
|
||||
.TP
|
||||
.B \-v, \-\-version
|
||||
.br
|
||||
display WeeChat version
|
||||
@@ -0,0 +1,86 @@
|
||||
/*
|
||||
* WeeChat doc CSS
|
||||
* (c) 2006 by FlashCode <flashcode@flashtux.org>
|
||||
*/
|
||||
|
||||
body {
|
||||
font-family: Verdana, Tahoma, Arial, Helvetica, sans-serif;
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
table {
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
a {
|
||||
color: #000099;
|
||||
}
|
||||
|
||||
a:visited {
|
||||
color: #770077;
|
||||
}
|
||||
|
||||
a:hover {
|
||||
background-color: #FFCCCC;
|
||||
}
|
||||
|
||||
.navheader {
|
||||
background-color: #E8E8FF;
|
||||
border: solid 1px #B5B5CC;
|
||||
}
|
||||
|
||||
.navheader hr {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.navfooter {
|
||||
background-color: #E8E8FF;
|
||||
border: solid 1px #B5B5CC;
|
||||
}
|
||||
|
||||
.navfooter hr {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.title {
|
||||
background-color: #E5FFE5;
|
||||
border: solid 1px #CCDDCC;
|
||||
padding: 3px;
|
||||
}
|
||||
|
||||
.informaltable table {
|
||||
font-size: 11px;
|
||||
font-family: Verdana;
|
||||
border-collapse: collapse;
|
||||
}
|
||||
|
||||
.informaltable table th {
|
||||
padding: 2px 5px 2px 5px;
|
||||
border: solid 1px #AAAAAA;
|
||||
background-color: #DDDDFF;
|
||||
}
|
||||
|
||||
.informaltable table td {
|
||||
padding: 2px 5px 2px 5px;
|
||||
border: solid 1px #AAAAAA;
|
||||
}
|
||||
|
||||
.oddrow {
|
||||
background-color: #F0F0F0;
|
||||
}
|
||||
|
||||
.synopsis {
|
||||
font-size: 11px;
|
||||
}
|
||||
|
||||
.programlisting {
|
||||
font-size: 11px;
|
||||
}
|
||||
|
||||
pre.screen {
|
||||
font-size: 11px;
|
||||
background-color: #F5F5F5;
|
||||
border: solid 1px #CCCCCC;
|
||||
padding: 4px;
|
||||
margin: 0 40px 0 40px;
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
|
||||
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
|
||||
|
||||
<xsl:import href="/usr/share/xml/docbook/stylesheet/nwalsh/html/docbook.xsl"/>
|
||||
|
||||
<xsl:output indent="yes"/>
|
||||
|
||||
<xsl:param name="chunk.section.depth" select="2"/>
|
||||
<xsl:param name="chunk.quietly" select="1"/>
|
||||
<xsl:param name="chunk.first.sections" select="1"/>
|
||||
<xsl:param name="generate.section.toc.level" select="3"/>
|
||||
|
||||
<xsl:param name="html.stylesheet">weechat-doc.css</xsl:param>
|
||||
|
||||
<xsl:template name="tr.attributes">
|
||||
<xsl:param name="row" select="."/>
|
||||
<xsl:param name="rownum" select="0"/>
|
||||
|
||||
<xsl:if test="not(ancestor::table/@tabstyle = 'unstriped')">
|
||||
<xsl:if test="$rownum mod 2 = 0">
|
||||
<xsl:attribute name="class">oddrow</xsl:attribute>
|
||||
</xsl:if>
|
||||
</xsl:if>
|
||||
</xsl:template>
|
||||
|
||||
</xsl:stylesheet>
|
||||
@@ -0,0 +1,27 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
|
||||
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
|
||||
|
||||
<xsl:import href="/usr/share/xml/docbook/stylesheet/nwalsh/html/chunk.xsl"/>
|
||||
|
||||
<xsl:output indent="yes"/>
|
||||
|
||||
<xsl:param name="chunk.section.depth" select="2"/>
|
||||
<xsl:param name="chunk.quietly" select="1"/>
|
||||
<xsl:param name="chunk.first.sections" select="1"/>
|
||||
<xsl:param name="generate.section.toc.level" select="3"/>
|
||||
|
||||
<xsl:param name="html.stylesheet">weechat-doc.css</xsl:param>
|
||||
|
||||
<xsl:template name="tr.attributes">
|
||||
<xsl:param name="row" select="."/>
|
||||
<xsl:param name="rownum" select="0"/>
|
||||
|
||||
<xsl:if test="not(ancestor::table/@tabstyle = 'unstriped')">
|
||||
<xsl:if test="$rownum mod 2 = 0">
|
||||
<xsl:attribute name="class">oddrow</xsl:attribute>
|
||||
</xsl:if>
|
||||
</xsl:if>
|
||||
</xsl:template>
|
||||
|
||||
</xsl:stylesheet>
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Binary file not shown.
+44
-8
@@ -6,19 +6,51 @@
|
||||
./src/irc/irc-send.c
|
||||
./src/irc/irc-recv.c
|
||||
./src/irc/irc-dcc.c
|
||||
./src/irc/irc-ignore.c
|
||||
./src/irc/irc.h
|
||||
./src/plugins/perl/wee-perl.c
|
||||
./src/plugins/perl/wee-perl.h
|
||||
./src/plugins/python/wee-python.c
|
||||
./src/plugins/python/wee-python.h
|
||||
./src/plugins/plugins.c
|
||||
./src/plugins/plugins.h
|
||||
./src/gui/curses/gui-input.c
|
||||
./src/gui/curses/gui-display.c
|
||||
./src/gui/gtk/gui-display.c
|
||||
./src/gui/gtk/gui-input.c
|
||||
./src/plugins/plugins-config.c
|
||||
./src/plugins/plugins-config.h
|
||||
./src/plugins/plugins-interface.c
|
||||
./src/plugins/weechat-plugin.h
|
||||
./src/gui/curses/gui-curses-chat.c
|
||||
./src/gui/curses/gui-curses-color.c
|
||||
./src/gui/curses/gui-curses-infobar.c
|
||||
./src/gui/curses/gui-curses-input.c
|
||||
./src/gui/curses/gui-curses-keyboard.c
|
||||
./src/gui/curses/gui-curses-main.c
|
||||
./src/gui/curses/gui-curses-nicklist.c
|
||||
./src/gui/curses/gui-curses-panel.c
|
||||
./src/gui/curses/gui-curses-status.c
|
||||
./src/gui/curses/gui-curses-window.c
|
||||
./src/gui/curses/gui-curses.h
|
||||
./src/gui/gtk/gui-gtk-chat.c
|
||||
./src/gui/gtk/gui-gtk-color.c
|
||||
./src/gui/gtk/gui-gtk-infobar.c
|
||||
./src/gui/gtk/gui-gtk-input.c
|
||||
./src/gui/gtk/gui-gtk-keyboard.c
|
||||
./src/gui/gtk/gui-gtk-main.c
|
||||
./src/gui/gtk/gui-gtk-nicklist.c
|
||||
./src/gui/gtk/gui-gtk-panel.c
|
||||
./src/gui/gtk/gui-gtk-status.c
|
||||
./src/gui/gtk/gui-gtk-window.c
|
||||
./src/gui/gtk/gui-gtk.h
|
||||
./src/gui/gui-action.c
|
||||
./src/gui/gui-buffer.c
|
||||
./src/gui/gui-common.c
|
||||
./src/gui/gui-keyboard.c
|
||||
./src/gui/gui-log.c
|
||||
./src/gui/gui-panel.c
|
||||
./src/gui/gui-window.c
|
||||
./src/gui/gui.h
|
||||
./src/gui/gui-buffer.h
|
||||
./src/gui/gui-color.h
|
||||
./src/gui/gui-keyboard.h
|
||||
./src/gui/gui-panel.h
|
||||
./src/gui/gui-window.h
|
||||
./src/common/backtrace.c
|
||||
./src/common/backtrace.h
|
||||
./src/common/command.c
|
||||
./src/common/command.h
|
||||
./src/common/completion.c
|
||||
@@ -31,6 +63,10 @@
|
||||
./src/common/hotlist.h
|
||||
./src/common/log.c
|
||||
./src/common/log.h
|
||||
./src/common/session.c
|
||||
./src/common/session.h
|
||||
./src/common/utf8.c
|
||||
./src/common/utf8.h
|
||||
./src/common/weechat.c
|
||||
./src/common/weechat.h
|
||||
./src/common/weeconfig.c
|
||||
|
||||
+3134
-1546
File diff suppressed because it is too large
Load Diff
+2
-2
@@ -1,4 +1,4 @@
|
||||
# Copyright (c) 2003-2005 FlashCode <flashcode@flashtux.org>
|
||||
# Copyright (c) 2003-2006 FlashCode <flashcode@flashtux.org>
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
@@ -12,7 +12,7 @@
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
#
|
||||
|
||||
SUBDIRS = common irc plugins gui
|
||||
|
||||
+10
-4
@@ -1,4 +1,4 @@
|
||||
# Copyright (c) 2003-2005 FlashCode <flashcode@flashtux.org>
|
||||
# Copyright (c) 2003-2006 FlashCode <flashcode@flashtux.org>
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
@@ -12,15 +12,17 @@
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
#
|
||||
|
||||
INCLUDES = -DLOCALEDIR=\"$(datadir)/locale\"
|
||||
INCLUDES = -DLOCALEDIR=\"$(datadir)/locale\" $(GNUTLS_CFLAGS)
|
||||
|
||||
noinst_LIBRARIES = lib_weechat_main.a
|
||||
|
||||
lib_weechat_main_a_SOURCES = weechat.c \
|
||||
weechat.h \
|
||||
backtrace.c \
|
||||
backtrace.h \
|
||||
command.c \
|
||||
command.h \
|
||||
completion.c \
|
||||
@@ -36,4 +38,8 @@ lib_weechat_main_a_SOURCES = weechat.c \
|
||||
log.c \
|
||||
log.h \
|
||||
fifo.c \
|
||||
fifo.h
|
||||
fifo.h \
|
||||
session.c \
|
||||
session.h \
|
||||
utf8.c \
|
||||
utf8.h
|
||||
|
||||
@@ -0,0 +1,163 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
/* backtrace.c: display backtrace after a segfault */
|
||||
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#include <stdarg.h>
|
||||
#define __USE_GNU
|
||||
#include <dlfcn.h>
|
||||
|
||||
#ifdef HAVE_BACKTRACE
|
||||
#include <execinfo.h>
|
||||
#endif
|
||||
|
||||
#include "weechat.h"
|
||||
#include "backtrace.h"
|
||||
#include "log.h"
|
||||
|
||||
|
||||
/*
|
||||
* weechat_backtrace_printf: display a backtrage line (on stderr and in WeeChat log)
|
||||
*/
|
||||
|
||||
void
|
||||
weechat_backtrace_printf (char *message, ...)
|
||||
{
|
||||
static char buffer[4096];
|
||||
va_list argptr;
|
||||
|
||||
va_start (argptr, message);
|
||||
vsnprintf (buffer, sizeof (buffer) - 1, message, argptr);
|
||||
va_end (argptr);
|
||||
|
||||
fprintf (stderr, "%s", buffer);
|
||||
weechat_log_printf ("%s", buffer);
|
||||
}
|
||||
|
||||
/*
|
||||
* weechat_backtrace_addr2line: display function name and line with a backtrace address
|
||||
*/
|
||||
|
||||
void
|
||||
weechat_backtrace_addr2line (int number, void *address, char *symbol)
|
||||
{
|
||||
int rc;
|
||||
Dl_info info;
|
||||
const void *addr;
|
||||
FILE *output;
|
||||
char cmd_line[1024];
|
||||
char line[1024], *ptr_line, *pos;
|
||||
char function_name[1024];
|
||||
int file_line;
|
||||
|
||||
rc = dladdr (address, &info);
|
||||
if ((rc == 0) || !info.dli_fname || !info.dli_fname[0])
|
||||
{
|
||||
weechat_backtrace_printf ("%03d %s\n", number, symbol);
|
||||
return;
|
||||
}
|
||||
|
||||
addr = address;
|
||||
if (info.dli_fbase >= (const void *) 0x40000000)
|
||||
addr = (const char *) addr - (unsigned int) info.dli_fbase;
|
||||
|
||||
snprintf (cmd_line, sizeof (cmd_line),
|
||||
"addr2line --functions --demangle -e $(which %s) %p",
|
||||
info.dli_fname, addr);
|
||||
output = popen (cmd_line, "r");
|
||||
if (!output)
|
||||
{
|
||||
weechat_backtrace_printf ("%03d %s\n", number, symbol);
|
||||
return;
|
||||
}
|
||||
function_name[0] = '\0';
|
||||
file_line = 0;
|
||||
while (!feof (output))
|
||||
{
|
||||
ptr_line = fgets (line, sizeof (line) - 1, output);
|
||||
if (ptr_line && ptr_line[0])
|
||||
{
|
||||
pos = strchr (ptr_line, '\n');
|
||||
if (pos)
|
||||
pos[0] = '\0';
|
||||
if (strchr (ptr_line, ':'))
|
||||
{
|
||||
file_line = 1;
|
||||
weechat_backtrace_printf ("%03d %s%s%s%s\n",
|
||||
number,
|
||||
ptr_line,
|
||||
(function_name[0]) ? " [function " : "",
|
||||
function_name,
|
||||
(function_name[0]) ? "]" : "");
|
||||
function_name[0] = '\0';
|
||||
}
|
||||
else
|
||||
{
|
||||
if (function_name[0])
|
||||
weechat_backtrace_printf ("%03d %s",
|
||||
number, function_name);
|
||||
snprintf (function_name, sizeof (function_name),
|
||||
"%s", ptr_line);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (function_name[0])
|
||||
weechat_backtrace_printf ("%03d %s\n",
|
||||
number, function_name);
|
||||
pclose (output);
|
||||
}
|
||||
|
||||
/*
|
||||
* weechat_backtrace: display backtrace (called when a SIGSEGV is received)
|
||||
*/
|
||||
|
||||
void
|
||||
weechat_backtrace ()
|
||||
{
|
||||
#ifdef HAVE_BACKTRACE
|
||||
void *trace[BACKTRACE_MAX];
|
||||
int trace_size, i;
|
||||
char **symbols;
|
||||
#endif
|
||||
|
||||
weechat_backtrace_printf ("======= WeeChat backtrace =======\n");
|
||||
|
||||
#ifdef HAVE_BACKTRACE
|
||||
trace_size = backtrace (trace, BACKTRACE_MAX);
|
||||
symbols = backtrace_symbols (trace, trace_size);
|
||||
|
||||
for (i = 0; i < trace_size; i++)
|
||||
{
|
||||
weechat_backtrace_addr2line (i + 1, trace[i], symbols[i]);
|
||||
}
|
||||
#else
|
||||
weechat_backtrace_printf (" No backtrace info (no debug info available "
|
||||
"or no backtrace possible on your system).\n");
|
||||
#endif
|
||||
|
||||
weechat_backtrace_printf ("======= End of backtrace =======\n");
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2005 by FlashCode <flashcode@flashtux.org>
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@@ -14,21 +14,15 @@
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
|
||||
#ifndef __WEECHAT_PERL_H
|
||||
#define __WEECHAT_PERL_H 1
|
||||
#ifndef __WEECHAT_BACKTACE_H
|
||||
#define __WEECHAT_BACKTACE_H 1
|
||||
|
||||
#include "../plugins.h"
|
||||
#define BACKTRACE_MAX 128
|
||||
|
||||
extern void wee_perl_init ();
|
||||
extern t_plugin_script *wee_perl_search (char *);
|
||||
extern int wee_perl_exec (char *, char *, char *);
|
||||
extern int wee_perl_load (char *);
|
||||
extern void wee_perl_unload (t_plugin_script *);
|
||||
extern void wee_perl_unload_all ();
|
||||
extern void wee_perl_end ();
|
||||
extern void weechat_backtrace ();
|
||||
|
||||
#endif /* wee-perl.h */
|
||||
#endif /* backtrace.h */
|
||||
+2743
-937
File diff suppressed because it is too large
Load Diff
+48
-26
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2005 by FlashCode <flashcode@flashtux.org>
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@@ -14,7 +14,7 @@
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
|
||||
@@ -31,13 +31,19 @@ typedef struct t_weechat_command t_weechat_command;
|
||||
|
||||
struct t_weechat_command
|
||||
{
|
||||
char *command_name;
|
||||
char *command_description;
|
||||
char *arguments;
|
||||
char *arguments_description;
|
||||
int min_arg, max_arg;
|
||||
int (*cmd_function_args)(int, char **);
|
||||
int (*cmd_function_1arg)(char *);
|
||||
char *command_name; /* WeeChat (internal) command name */
|
||||
char *command_description; /* command description (for /help) */
|
||||
char *arguments; /* command arguments (for /help) */
|
||||
char *arguments_description; /* arguments description (for /help) */
|
||||
char *completion_template; /* template for completion */
|
||||
/* NULL=no completion, ""=default (nick) */
|
||||
int min_arg, max_arg; /* min & max number of arguments */
|
||||
int charset_conversion; /* = 1 if cmd args are converted before */
|
||||
/* they're executed */
|
||||
int (*cmd_function_args)(t_irc_server *, t_irc_channel *, int, char **);
|
||||
/* function called when user enters cmd */
|
||||
int (*cmd_function_1arg)(t_irc_server *, t_irc_channel *, char *);
|
||||
/* function called when user enters cmd */
|
||||
};
|
||||
|
||||
typedef struct t_weechat_alias t_weechat_alias;
|
||||
@@ -46,6 +52,7 @@ struct t_weechat_alias
|
||||
{
|
||||
char *alias_name;
|
||||
char *alias_command;
|
||||
int running;
|
||||
t_weechat_alias *prev_alias;
|
||||
t_weechat_alias *next_alias;
|
||||
};
|
||||
@@ -58,24 +65,39 @@ extern t_weelist *last_index_command;
|
||||
|
||||
extern void command_index_build ();
|
||||
extern void command_index_free ();
|
||||
extern t_weechat_alias *alias_search (char *);
|
||||
extern t_weechat_alias *alias_new (char *, char *);
|
||||
extern char *alias_get_final_command (t_weechat_alias *);
|
||||
extern void alias_free_all ();
|
||||
extern int exec_weechat_command (t_irc_server *, char *);
|
||||
extern void user_command (t_irc_server *, t_gui_buffer *, char *);
|
||||
extern int weechat_cmd_alias (char *);
|
||||
extern int weechat_cmd_buffer (int, char **);
|
||||
extern int weechat_cmd_clear (int, char **);
|
||||
extern int weechat_cmd_connect (int, char **);
|
||||
extern int weechat_cmd_debug (int, char **);
|
||||
extern int weechat_cmd_disconnect (int, char **);
|
||||
extern int weechat_cmd_help (int, char **);
|
||||
extern int weechat_cmd_perl (int, char **);
|
||||
extern int weechat_cmd_python (int, char **);
|
||||
extern int weechat_cmd_save (int, char **);
|
||||
extern int weechat_cmd_server (int, char **);
|
||||
extern int weechat_cmd_set (char *);
|
||||
extern int weechat_cmd_unalias (char *);
|
||||
extern int weechat_cmd_unset (char *);
|
||||
extern int weechat_cmd_window (int, char **);
|
||||
extern char **explode_string (char *, char *, int, int *);
|
||||
extern void free_exploded_string (char **);
|
||||
extern char **split_multi_command (char *, char);
|
||||
extern void free_multi_command (char **);
|
||||
extern int exec_weechat_command (t_irc_server *, t_irc_channel *, char *, int);
|
||||
extern void user_command (t_irc_server *, t_irc_channel *, char *, int);
|
||||
extern int weechat_cmd_alias (t_irc_server *, t_irc_channel *, char *);
|
||||
extern int weechat_cmd_buffer (t_irc_server *, t_irc_channel *, char *);
|
||||
extern int weechat_cmd_builtin (t_irc_server *, t_irc_channel *, char *);
|
||||
extern int weechat_cmd_charset (t_irc_server *, t_irc_channel *, int, char **);
|
||||
extern int weechat_cmd_clear (t_irc_server *, t_irc_channel *, int, char **);
|
||||
extern int weechat_cmd_connect (t_irc_server *, t_irc_channel *, int, char **);
|
||||
extern int weechat_cmd_dcc (t_irc_server *, t_irc_channel *, char *);
|
||||
extern int weechat_cmd_debug (t_irc_server *, t_irc_channel *, int, char **);
|
||||
extern int weechat_cmd_disconnect (t_irc_server *, t_irc_channel *, int, char **);
|
||||
extern int weechat_cmd_help (t_irc_server *, t_irc_channel *, int, char **);
|
||||
extern int weechat_cmd_history (t_irc_server *, t_irc_channel *, int, char **);
|
||||
extern void weechat_cmd_ignore_display (char *, t_irc_ignore *);
|
||||
extern int weechat_cmd_ignore (t_irc_server *, t_irc_channel *, int, char **);
|
||||
extern int weechat_cmd_key (t_irc_server *, t_irc_channel *, char *);
|
||||
extern int weechat_cmd_plugin (t_irc_server *, t_irc_channel *, int, char **);
|
||||
extern int weechat_cmd_save (t_irc_server *, t_irc_channel *, int, char **);
|
||||
extern int weechat_cmd_server (t_irc_server *, t_irc_channel *, int, char **);
|
||||
extern int weechat_cmd_set (t_irc_server *, t_irc_channel *, char *);
|
||||
extern int weechat_cmd_setp (t_irc_server *, t_irc_channel *, char *);
|
||||
extern int weechat_cmd_unalias (t_irc_server *, t_irc_channel *, char *);
|
||||
extern int weechat_cmd_unignore (t_irc_server *, t_irc_channel *, int, char **);
|
||||
extern int weechat_cmd_upgrade (t_irc_server *, t_irc_channel *, int, char **);
|
||||
extern int weechat_cmd_uptime (t_irc_server *, t_irc_channel *, int, char **);
|
||||
extern int weechat_cmd_window (t_irc_server *, t_irc_channel *, int, char **);
|
||||
|
||||
#endif /* command.h */
|
||||
|
||||
+912
-428
File diff suppressed because it is too large
Load Diff
+21
-16
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2005 by FlashCode <flashcode@flashtux.org>
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@@ -14,7 +14,7 @@
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
|
||||
@@ -33,26 +33,31 @@ typedef struct t_completion t_completion;
|
||||
struct t_completion
|
||||
{
|
||||
/* completion context */
|
||||
int context; /* context: null, nick, command, cmd arg */
|
||||
char *base_command; /* command with arg to complete (can be NULL) */
|
||||
int base_command_arg; /* # arg to complete (if context is cmd arg) */
|
||||
char *base_word; /* word to complete (when Tab was pressed) */
|
||||
int base_word_pos; /* beggining of base word */
|
||||
int position; /* position where Tab was pressed */
|
||||
char *args; /* command line args (including base word) */
|
||||
void *server; /* server pointer */
|
||||
void *channel; /* channel pointer */
|
||||
int context; /* context: null, nick, command, cmd arg */
|
||||
char *base_command; /* command with arg to complete (can be NULL) */
|
||||
int base_command_arg; /* # arg to complete (if context is cmd arg) */
|
||||
int arg_is_nick; /* argument is nick */
|
||||
char *base_word; /* word to complete (when Tab was pressed) */
|
||||
int base_word_pos; /* beggining of base word */
|
||||
int position; /* position where Tab was pressed */
|
||||
char *args; /* command line args (including base word) */
|
||||
int direction; /* +1 = search next word, -1 = previous word */
|
||||
|
||||
/* for command argument completion */
|
||||
t_weelist *completion_list; /* data list for completion */
|
||||
t_weelist *last_completion; /* last data element for completion */
|
||||
t_weelist *completion_list; /* data list for completion */
|
||||
t_weelist *last_completion; /* last data element for completion */
|
||||
|
||||
/* completion found */
|
||||
char *word_found; /* word found (to replace base word) */
|
||||
int position_replace; /* position where word has to be replaced */
|
||||
int diff_size; /* size difference (< 0 = char(s) deleted) */
|
||||
char *word_found; /* word found (to replace base word) */
|
||||
int position_replace; /* position where word has to be replaced */
|
||||
int diff_size; /* size difference (< 0 = char(s) deleted) */
|
||||
int diff_length; /* length difference (<= diff_size) */
|
||||
};
|
||||
|
||||
extern void completion_init (t_completion *);
|
||||
extern void completion_init (t_completion *, void *, void *);
|
||||
extern void completion_free (t_completion *);
|
||||
extern void completion_search (t_completion *, void *, char *, int, int);
|
||||
extern void completion_search (t_completion *, int, char *, int, int);
|
||||
|
||||
#endif /* completion.h */
|
||||
|
||||
+32
-50
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2005 by FlashCode <flashcode@flashtux.org>
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@@ -14,7 +14,7 @@
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
/* fifo.c: FIFO pipe for WeeChat remote control */
|
||||
@@ -34,6 +34,7 @@
|
||||
#include "weechat.h"
|
||||
#include "fifo.h"
|
||||
#include "command.h"
|
||||
#include "log.h"
|
||||
#include "weeconfig.h"
|
||||
#include "../gui/gui.h"
|
||||
|
||||
@@ -54,7 +55,7 @@ fifo_create ()
|
||||
|
||||
if (cfg_irc_fifo_pipe)
|
||||
{
|
||||
/* build FIFO filename: "~/.weechat/weechat_fifo_" + process PID */
|
||||
/* build FIFO filename: "<weechat_home>/weechat_fifo_" + process PID */
|
||||
if (!weechat_fifo_filename)
|
||||
{
|
||||
filename_length = strlen (weechat_home) + 64;
|
||||
@@ -70,8 +71,9 @@ fifo_create ()
|
||||
gui_printf (NULL,
|
||||
_("%s unable to create FIFO pipe for remote control (%s)\n"),
|
||||
WEECHAT_ERROR, weechat_fifo_filename);
|
||||
wee_log_printf (_("%s unable to create FIFO pipe for remote control (%s)\n"),
|
||||
WEECHAT_ERROR, weechat_fifo_filename);
|
||||
weechat_log_printf (_("%s unable to create FIFO pipe for "
|
||||
"remote control (%s)\n"),
|
||||
WEECHAT_ERROR, weechat_fifo_filename);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -81,12 +83,12 @@ fifo_create ()
|
||||
gui_printf (NULL,
|
||||
_("%s unable to open FIFO pipe (%s) for reading\n"),
|
||||
WEECHAT_ERROR, weechat_fifo_filename);
|
||||
wee_log_printf (_("%s unable to open FIFO pipe (%s) for reading\n"),
|
||||
WEECHAT_ERROR, weechat_fifo_filename);
|
||||
weechat_log_printf (_("%s unable to open FIFO pipe (%s) for reading\n"),
|
||||
WEECHAT_ERROR, weechat_fifo_filename);
|
||||
return;
|
||||
}
|
||||
|
||||
wee_log_printf (_("FIFO pipe is open\n"));
|
||||
weechat_log_printf (_("FIFO pipe is open\n"));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -100,27 +102,25 @@ fifo_exec (char *text)
|
||||
char *pos_msg, *pos;
|
||||
t_irc_server *ptr_server;
|
||||
t_irc_channel *ptr_channel;
|
||||
t_gui_buffer *ptr_buffer;
|
||||
|
||||
pos = NULL;
|
||||
ptr_server = NULL;
|
||||
ptr_channel = NULL;
|
||||
ptr_buffer = NULL;
|
||||
|
||||
/* look for server/channel at beginning of text */
|
||||
/* text may be: "server,channel *text" or "server *text" or "*text" */
|
||||
if (text[0] == '*')
|
||||
{
|
||||
pos_msg = text + 1;
|
||||
ptr_server = SERVER(gui_current_window->buffer);
|
||||
ptr_buffer = gui_current_window->buffer;
|
||||
|
||||
if (!ptr_server)
|
||||
if (gui_current_window->buffer->has_input)
|
||||
{
|
||||
irc_display_prefix (NULL, PREFIX_ERROR);
|
||||
gui_printf (NULL, _("%s invalid buffer for displaying text via FIFO pipe\n"),
|
||||
WEECHAT_WARNING);
|
||||
return;
|
||||
ptr_server = SERVER(gui_current_window->buffer);
|
||||
ptr_channel = CHANNEL(gui_current_window->buffer);
|
||||
}
|
||||
else
|
||||
{
|
||||
ptr_server = SERVER(gui_buffers);
|
||||
ptr_channel = NULL;
|
||||
}
|
||||
}
|
||||
else
|
||||
@@ -128,7 +128,7 @@ fifo_exec (char *text)
|
||||
pos_msg = strstr (text, " *");
|
||||
if (!pos_msg)
|
||||
{
|
||||
irc_display_prefix (NULL, PREFIX_ERROR);
|
||||
irc_display_prefix (NULL, NULL, PREFIX_ERROR);
|
||||
gui_printf (NULL, _("%s invalid text received on FIFO pipe\n"),
|
||||
WEECHAT_WARNING);
|
||||
return;
|
||||
@@ -150,45 +150,27 @@ fifo_exec (char *text)
|
||||
ptr_server = server_search (text);
|
||||
if (!ptr_server || !ptr_server->buffer)
|
||||
{
|
||||
irc_display_prefix (NULL, PREFIX_ERROR);
|
||||
irc_display_prefix (NULL, NULL, PREFIX_ERROR);
|
||||
gui_printf (NULL, _("%s server \"%s\" not found (FIFO pipe data)\n"),
|
||||
WEECHAT_WARNING, text);
|
||||
return;
|
||||
}
|
||||
if (ptr_server)
|
||||
if (ptr_server && pos)
|
||||
{
|
||||
if (pos)
|
||||
ptr_channel = channel_search_any (ptr_server, pos + 1);
|
||||
if (!ptr_channel)
|
||||
{
|
||||
ptr_channel = channel_search (ptr_server, pos + 1);
|
||||
if (!ptr_channel)
|
||||
{
|
||||
irc_display_prefix (NULL, PREFIX_ERROR);
|
||||
gui_printf (NULL, _("%s channel \"%s\" not found (FIFO pipe data)\n"),
|
||||
WEECHAT_WARNING, pos + 1);
|
||||
return;
|
||||
}
|
||||
irc_display_prefix (NULL, NULL, PREFIX_ERROR);
|
||||
gui_printf (NULL,
|
||||
_("%s channel \"%s\" not found (FIFO pipe data)\n"),
|
||||
WEECHAT_WARNING, pos + 1);
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (!ptr_server)
|
||||
{
|
||||
irc_display_prefix (NULL, PREFIX_ERROR);
|
||||
gui_printf (NULL, _("%s invalid text received on FIFO pipe\n"),
|
||||
WEECHAT_WARNING);
|
||||
return;
|
||||
}
|
||||
|
||||
if (!ptr_buffer)
|
||||
{
|
||||
if (ptr_channel)
|
||||
ptr_buffer = ptr_channel->buffer;
|
||||
else
|
||||
ptr_buffer = ptr_server->buffer;
|
||||
}
|
||||
|
||||
user_command (ptr_server, ptr_buffer, pos_msg);
|
||||
user_command (ptr_server, ptr_channel, pos_msg, 0);
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -264,8 +246,8 @@ fifo_read ()
|
||||
gui_printf (NULL,
|
||||
_("%s error reading FIFO pipe, closing it\n"),
|
||||
WEECHAT_ERROR);
|
||||
wee_log_printf (_("%s error reading FIFO pipe, closing it\n"),
|
||||
WEECHAT_ERROR);
|
||||
weechat_log_printf (_("%s error reading FIFO pipe, closing it\n"),
|
||||
WEECHAT_ERROR);
|
||||
fifo_remove ();
|
||||
}
|
||||
else
|
||||
@@ -306,5 +288,5 @@ fifo_remove ()
|
||||
weechat_fifo_filename = NULL;
|
||||
}
|
||||
|
||||
wee_log_printf (_("FIFO pipe is closed\n"));
|
||||
weechat_log_printf (_("FIFO pipe is closed\n"));
|
||||
}
|
||||
|
||||
+2
-2
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2005 by FlashCode <flashcode@flashtux.org>
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@@ -14,7 +14,7 @@
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
|
||||
|
||||
+109
-81
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2005 by FlashCode <flashcode@flashtux.org>
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@@ -14,10 +14,10 @@
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
/* history.c: memorize and call again commands or text */
|
||||
/* history.c: memorize commands or text */
|
||||
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
@@ -33,10 +33,10 @@
|
||||
#include "../gui/gui.h"
|
||||
|
||||
|
||||
t_history *history_general = NULL;
|
||||
t_history *history_general_last = NULL;
|
||||
t_history *history_general_ptr = NULL;
|
||||
int num_history_general = 0;
|
||||
t_history *history_global = NULL;
|
||||
t_history *history_global_last = NULL;
|
||||
t_history *history_global_ptr = NULL;
|
||||
int num_history_global = 0;
|
||||
|
||||
|
||||
/*
|
||||
@@ -66,98 +66,126 @@ history_hide_password (char *string)
|
||||
}
|
||||
|
||||
/*
|
||||
* history_add: add a text/command to history
|
||||
* history_buffer_add: add a text/command to buffer's history
|
||||
*/
|
||||
|
||||
void
|
||||
history_add (void *buffer, char *string)
|
||||
history_buffer_add (void *buffer, char *string)
|
||||
{
|
||||
t_history *new_history, *ptr_history;
|
||||
|
||||
if (!string)
|
||||
return;
|
||||
|
||||
/* add history to general history */
|
||||
new_history = (t_history *)malloc (sizeof (t_history));
|
||||
if (new_history)
|
||||
{
|
||||
new_history->text = strdup (string);
|
||||
if (cfg_log_hide_nickserv_pwd)
|
||||
history_hide_password (new_history->text);
|
||||
|
||||
if (history_general)
|
||||
history_general->prev_history = new_history;
|
||||
else
|
||||
history_general_last = new_history;
|
||||
new_history->next_history = history_general;
|
||||
new_history->prev_history = NULL;
|
||||
history_general = new_history;
|
||||
num_history_general++;
|
||||
|
||||
/* remove one command if necessary */
|
||||
if ((cfg_history_max_commands > 0)
|
||||
&& (num_history_general > cfg_history_max_commands))
|
||||
{
|
||||
ptr_history = history_general_last->prev_history;
|
||||
history_general_last->prev_history->next_history = NULL;
|
||||
if (history_general_last->text)
|
||||
free (history_general_last->text);
|
||||
free (history_general_last);
|
||||
history_general_last = ptr_history;
|
||||
num_history_general--;
|
||||
}
|
||||
}
|
||||
|
||||
/* add history to local history */
|
||||
new_history = (t_history *)malloc (sizeof (t_history));
|
||||
if (new_history)
|
||||
{
|
||||
new_history->text = strdup (string);
|
||||
if (cfg_log_hide_nickserv_pwd)
|
||||
history_hide_password (new_history->text);
|
||||
|
||||
if (((t_gui_buffer *)(buffer))->history)
|
||||
((t_gui_buffer *)(buffer))->history->prev_history = new_history;
|
||||
else
|
||||
((t_gui_buffer *)(buffer))->last_history = new_history;
|
||||
new_history->next_history = ((t_gui_buffer *)(buffer))->history;
|
||||
new_history->prev_history = NULL;
|
||||
((t_gui_buffer *)buffer)->history = new_history;
|
||||
((t_gui_buffer *)(buffer))->num_history++;
|
||||
|
||||
/* remove one command if necessary */
|
||||
if ((cfg_history_max_commands > 0)
|
||||
&& (((t_gui_buffer *)(buffer))->num_history > cfg_history_max_commands))
|
||||
{
|
||||
ptr_history = ((t_gui_buffer *)buffer)->last_history->prev_history;
|
||||
((t_gui_buffer *)buffer)->last_history->prev_history->next_history = NULL;
|
||||
if (((t_gui_buffer *)buffer)->last_history->text)
|
||||
free (((t_gui_buffer *)buffer)->last_history->text);
|
||||
free (((t_gui_buffer *)buffer)->last_history);
|
||||
((t_gui_buffer *)buffer)->last_history = ptr_history;
|
||||
((t_gui_buffer *)(buffer))->num_history++;
|
||||
}
|
||||
if ( !((t_gui_buffer *)(buffer))->history
|
||||
|| ( ((t_gui_buffer *)(buffer))->history
|
||||
&& ascii_strcasecmp (((t_gui_buffer *)(buffer))->history->text, string) != 0))
|
||||
{
|
||||
new_history = (t_history *)malloc (sizeof (t_history));
|
||||
if (new_history)
|
||||
{
|
||||
new_history->text = strdup (string);
|
||||
if (cfg_log_hide_nickserv_pwd)
|
||||
history_hide_password (new_history->text);
|
||||
|
||||
if (((t_gui_buffer *)(buffer))->history)
|
||||
((t_gui_buffer *)(buffer))->history->prev_history = new_history;
|
||||
else
|
||||
((t_gui_buffer *)(buffer))->last_history = new_history;
|
||||
new_history->next_history = ((t_gui_buffer *)(buffer))->history;
|
||||
new_history->prev_history = NULL;
|
||||
((t_gui_buffer *)buffer)->history = new_history;
|
||||
((t_gui_buffer *)buffer)->num_history++;
|
||||
|
||||
/* remove one command if necessary */
|
||||
if ((cfg_history_max_commands > 0)
|
||||
&& (((t_gui_buffer *)(buffer))->num_history > cfg_history_max_commands))
|
||||
{
|
||||
ptr_history = ((t_gui_buffer *)buffer)->last_history->prev_history;
|
||||
if (((t_gui_buffer *)buffer)->ptr_history == ((t_gui_buffer *)buffer)->last_history)
|
||||
((t_gui_buffer *)buffer)->ptr_history = ptr_history;
|
||||
((t_gui_buffer *)buffer)->last_history->prev_history->next_history = NULL;
|
||||
if (((t_gui_buffer *)buffer)->last_history->text)
|
||||
free (((t_gui_buffer *)buffer)->last_history->text);
|
||||
free (((t_gui_buffer *)buffer)->last_history);
|
||||
((t_gui_buffer *)buffer)->last_history = ptr_history;
|
||||
((t_gui_buffer *)(buffer))->num_history++;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* history_general_free: free general history
|
||||
* history_global_add: add a text/command to buffer's history
|
||||
*/
|
||||
|
||||
void
|
||||
history_general_free ()
|
||||
history_global_add (char *string)
|
||||
{
|
||||
t_history *new_history, *ptr_history;
|
||||
|
||||
if (!string)
|
||||
return;
|
||||
|
||||
if (!history_global
|
||||
|| (history_global
|
||||
&& ascii_strcasecmp (history_global->text, string) != 0))
|
||||
{
|
||||
new_history = (t_history *)malloc (sizeof (t_history));
|
||||
if (new_history)
|
||||
{
|
||||
new_history->text = strdup (string);
|
||||
if (cfg_log_hide_nickserv_pwd)
|
||||
history_hide_password (new_history->text);
|
||||
|
||||
if (history_global)
|
||||
history_global->prev_history = new_history;
|
||||
else
|
||||
history_global_last = new_history;
|
||||
new_history->next_history = history_global;
|
||||
new_history->prev_history = NULL;
|
||||
history_global = new_history;
|
||||
num_history_global++;
|
||||
|
||||
/* remove one command if necessary */
|
||||
if ((cfg_history_max_commands > 0)
|
||||
&& (num_history_global > cfg_history_max_commands))
|
||||
{
|
||||
ptr_history = history_global_last->prev_history;
|
||||
if (history_global_ptr == history_global_last)
|
||||
history_global_ptr = ptr_history;
|
||||
history_global_last->prev_history->next_history = NULL;
|
||||
if (history_global_last->text)
|
||||
free (history_global_last->text);
|
||||
free (history_global_last);
|
||||
history_global_last = ptr_history;
|
||||
num_history_global--;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* history_global_free: free global history
|
||||
*/
|
||||
|
||||
void
|
||||
history_global_free ()
|
||||
{
|
||||
t_history *ptr_history;
|
||||
|
||||
while (history_general)
|
||||
while (history_global)
|
||||
{
|
||||
ptr_history = history_general->next_history;
|
||||
if (history_general->text)
|
||||
free (history_general->text);
|
||||
free (history_general);
|
||||
history_general = ptr_history;
|
||||
ptr_history = history_global->next_history;
|
||||
if (history_global->text)
|
||||
free (history_global->text);
|
||||
free (history_global);
|
||||
history_global = ptr_history;
|
||||
}
|
||||
history_general = NULL;
|
||||
history_general_last = NULL;
|
||||
history_general_ptr = NULL;
|
||||
num_history_general = 0;
|
||||
history_global = NULL;
|
||||
history_global_last = NULL;
|
||||
history_global_ptr = NULL;
|
||||
num_history_global = 0;
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2005 by FlashCode <flashcode@flashtux.org>
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@@ -14,7 +14,7 @@
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
|
||||
@@ -30,8 +30,13 @@ struct t_history
|
||||
t_history *prev_history; /* link to previous text/command */
|
||||
};
|
||||
|
||||
extern void history_add (void *, char *);
|
||||
extern void history_general_free ();
|
||||
extern t_history *history_global;
|
||||
extern t_history *history_global_last;
|
||||
extern t_history *history_global_ptr;
|
||||
|
||||
extern void history_buffer_add (void *, char *);
|
||||
extern void history_global_add (char *);
|
||||
extern void history_global_free ();
|
||||
extern void history_buffer_free (void *);
|
||||
|
||||
#endif /* history.h */
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2005 by FlashCode <flashcode@flashtux.org>
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@@ -14,7 +14,7 @@
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
/* hotlist.c: WeeChat hotlist (buffers with activity) */
|
||||
@@ -76,7 +76,7 @@ hotlist_find_pos (t_weechat_hotlist *new_hotlist)
|
||||
*/
|
||||
|
||||
void
|
||||
hotlist_add (int priority, t_gui_buffer *buffer)
|
||||
hotlist_add (int priority, t_irc_server *server, t_gui_buffer *buffer)
|
||||
{
|
||||
t_weechat_hotlist *new_hotlist, *pos_hotlist;
|
||||
|
||||
@@ -104,6 +104,7 @@ hotlist_add (int priority, t_gui_buffer *buffer)
|
||||
}
|
||||
|
||||
new_hotlist->priority = priority;
|
||||
new_hotlist->server = server;
|
||||
new_hotlist->buffer = buffer;
|
||||
|
||||
if (hotlist)
|
||||
|
||||
+10
-4
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2005 by FlashCode <flashcode@flashtux.org>
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@@ -14,7 +14,7 @@
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
|
||||
@@ -23,12 +23,18 @@
|
||||
|
||||
#include "../irc/irc.h"
|
||||
|
||||
#define HOTLIST_LOW 0
|
||||
#define HOTLIST_MSG 1
|
||||
#define HOTLIST_PRIVATE 2
|
||||
#define HOTLIST_HIGHLIGHT 3
|
||||
|
||||
typedef struct t_weechat_hotlist t_weechat_hotlist;
|
||||
|
||||
struct t_weechat_hotlist
|
||||
{
|
||||
int priority; /* 0=crappy msg (join/part), 1=msg, */
|
||||
/* 2=nick highlight */
|
||||
/* 2=pv, 3=nick highlight */
|
||||
t_irc_server *server; /* associated server */
|
||||
t_gui_buffer *buffer; /* associated buffer */
|
||||
t_weechat_hotlist *prev_hotlist; /* link to previous hotlist */
|
||||
t_weechat_hotlist *next_hotlist; /* link to next hotlist */
|
||||
@@ -37,7 +43,7 @@ struct t_weechat_hotlist
|
||||
extern t_weechat_hotlist *hotlist;
|
||||
extern t_gui_buffer *hotlist_initial_buffer;
|
||||
|
||||
extern void hotlist_add (int, t_gui_buffer *);
|
||||
extern void hotlist_add (int, t_irc_server *, t_gui_buffer *);
|
||||
extern void hotlist_free (t_weechat_hotlist *);
|
||||
extern void hotlist_free_all ();
|
||||
extern void hotlist_remove_buffer (t_gui_buffer *);
|
||||
|
||||
+171
-119
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2005 by FlashCode <flashcode@flashtux.org>
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@@ -14,10 +14,10 @@
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
/* log.c: log buffers to files */
|
||||
/* log.c: WeeChat log file */
|
||||
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
@@ -27,146 +27,198 @@
|
||||
#include <stdlib.h>
|
||||
#include <unistd.h>
|
||||
#include <string.h>
|
||||
#include <stdarg.h>
|
||||
#include <sys/file.h>
|
||||
#include <sys/types.h>
|
||||
#include <time.h>
|
||||
|
||||
#include "weechat.h"
|
||||
#include "log.h"
|
||||
#include "weeconfig.h"
|
||||
#include "../gui/gui.h"
|
||||
|
||||
|
||||
char *weechat_log_filename = NULL; /* log name (~/.weechat/weechat.log) */
|
||||
FILE *weechat_log_file = NULL; /* WeeChat log file */
|
||||
|
||||
|
||||
/*
|
||||
* log_write_date: writes date to log file
|
||||
* weechat_log_open: initialize log file
|
||||
*/
|
||||
|
||||
int
|
||||
weechat_log_open (char *filename, char *mode)
|
||||
{
|
||||
int filename_length;
|
||||
|
||||
/* exit if log already opened */
|
||||
if (weechat_log_file)
|
||||
return 0;
|
||||
|
||||
if (filename)
|
||||
weechat_log_filename = strdup (filename);
|
||||
else
|
||||
{
|
||||
filename_length = strlen (weechat_home) + 64;
|
||||
weechat_log_filename =
|
||||
(char *) malloc (filename_length * sizeof (char));
|
||||
snprintf (weechat_log_filename, filename_length,
|
||||
"%s/%s", weechat_home, WEECHAT_LOG_NAME);
|
||||
}
|
||||
|
||||
weechat_log_file = fopen (weechat_log_filename, mode);
|
||||
if (!weechat_log_file)
|
||||
{
|
||||
free (weechat_log_filename);
|
||||
weechat_log_filename = NULL;
|
||||
return 0;
|
||||
}
|
||||
|
||||
#ifdef HAVE_FLOCK
|
||||
if ((flock (fileno (weechat_log_file), LOCK_EX | LOCK_NB) != 0))
|
||||
{
|
||||
fclose (weechat_log_file);
|
||||
weechat_log_file = NULL;
|
||||
free (weechat_log_filename);
|
||||
weechat_log_filename = NULL;
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
/*
|
||||
* weechat_log_init: initialize log file
|
||||
*/
|
||||
|
||||
void
|
||||
log_write_date (t_gui_buffer *buffer)
|
||||
weechat_log_init ()
|
||||
{
|
||||
static char buf_time[256];
|
||||
if (!weechat_log_open (NULL, "w"))
|
||||
{
|
||||
fprintf (stderr,
|
||||
_("%s unable to create/append to log file\n"
|
||||
"If another WeeChat process is using this file, try to run WeeChat\n"
|
||||
"with another home using \"--dir\" command line option.\n"),
|
||||
WEECHAT_ERROR);
|
||||
exit (1);
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* weechat_log_printf: write a message in WeeChat log (<weechat_home>/weechat.log)
|
||||
*/
|
||||
|
||||
void
|
||||
weechat_log_printf (char *message, ...)
|
||||
{
|
||||
static char buffer[4096];
|
||||
char *ptr_buffer;
|
||||
va_list argptr;
|
||||
static time_t seconds;
|
||||
struct tm *date_tmp;
|
||||
|
||||
if (buffer->log_file)
|
||||
{
|
||||
seconds = time (NULL);
|
||||
date_tmp = localtime (&seconds);
|
||||
if (date_tmp)
|
||||
{
|
||||
strftime (buf_time, sizeof (buf_time) - 1, cfg_log_timestamp, date_tmp);
|
||||
fprintf (buffer->log_file, "%s ", buf_time);
|
||||
fflush (buffer->log_file);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* log_write: writes a message to log file
|
||||
*/
|
||||
|
||||
void
|
||||
log_write (t_gui_buffer *buffer, char *message)
|
||||
{
|
||||
if (buffer->log_file)
|
||||
{
|
||||
fprintf (buffer->log_file, "%s", message);
|
||||
fflush (buffer->log_file);
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* log_write_line: writes a WeeChat line to log file
|
||||
*/
|
||||
|
||||
void
|
||||
log_write_line (t_gui_buffer *buffer, t_gui_line *line)
|
||||
{
|
||||
t_gui_message *ptr_msg;
|
||||
|
||||
if (buffer->log_file)
|
||||
{
|
||||
log_write_date (buffer);
|
||||
for (ptr_msg = line->messages; ptr_msg; ptr_msg = ptr_msg->next_message)
|
||||
{
|
||||
if (ptr_msg->type != MSG_TYPE_TIME)
|
||||
fprintf (buffer->log_file, "%s", ptr_msg->message);
|
||||
}
|
||||
fprintf (buffer->log_file, "\n");
|
||||
fflush (buffer->log_file);
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* log_start: starts a log
|
||||
*/
|
||||
|
||||
void
|
||||
log_start (t_gui_buffer *buffer)
|
||||
{
|
||||
int length;
|
||||
char *ptr_home;
|
||||
|
||||
ptr_home = getenv ("HOME");
|
||||
length = strlen (cfg_log_path) +
|
||||
((cfg_log_path[0] == '~') ? strlen (ptr_home) : 0) +
|
||||
64;
|
||||
if (SERVER(buffer))
|
||||
length += strlen (SERVER(buffer)->name);
|
||||
if (CHANNEL(buffer))
|
||||
length += strlen (CHANNEL(buffer)->name);
|
||||
buffer->log_filename = (char *) malloc (length);
|
||||
if (!buffer->log_filename)
|
||||
{
|
||||
wee_log_printf (_("Not enough memory to write log file for a buffer\n"));
|
||||
if (!weechat_log_file)
|
||||
return;
|
||||
}
|
||||
if (cfg_log_path[0] == '~')
|
||||
|
||||
va_start (argptr, message);
|
||||
vsnprintf (buffer, sizeof (buffer) - 1, message, argptr);
|
||||
va_end (argptr);
|
||||
|
||||
/* keep only valid chars */
|
||||
ptr_buffer = buffer;
|
||||
while (ptr_buffer[0])
|
||||
{
|
||||
strcpy (buffer->log_filename, ptr_home);
|
||||
strcat (buffer->log_filename, cfg_log_path + 1);
|
||||
if ((ptr_buffer[0] != '\n')
|
||||
&& (ptr_buffer[0] != '\r')
|
||||
&& ((unsigned char)(ptr_buffer[0]) < 32))
|
||||
ptr_buffer[0] = '.';
|
||||
ptr_buffer++;
|
||||
}
|
||||
|
||||
seconds = time (NULL);
|
||||
date_tmp = localtime (&seconds);
|
||||
if (date_tmp)
|
||||
fprintf (weechat_log_file, "[%04d-%02d-%02d %02d:%02d:%02d] %s",
|
||||
date_tmp->tm_year + 1900, date_tmp->tm_mon + 1, date_tmp->tm_mday,
|
||||
date_tmp->tm_hour, date_tmp->tm_min, date_tmp->tm_sec,
|
||||
buffer);
|
||||
else
|
||||
strcpy (buffer->log_filename, cfg_log_path);
|
||||
if (buffer->log_filename[strlen (buffer->log_filename) - 1] != DIR_SEPARATOR_CHAR)
|
||||
strcat (buffer->log_filename, DIR_SEPARATOR);
|
||||
|
||||
if (SERVER(buffer))
|
||||
{
|
||||
strcat (buffer->log_filename, SERVER(buffer)->name);
|
||||
strcat (buffer->log_filename, ".");
|
||||
}
|
||||
if (CHANNEL(buffer))
|
||||
{
|
||||
strcat (buffer->log_filename, CHANNEL(buffer)->name);
|
||||
strcat (buffer->log_filename, ".");
|
||||
}
|
||||
strcat (buffer->log_filename, "weechatlog");
|
||||
|
||||
buffer->log_file = fopen (buffer->log_filename, "a");
|
||||
if (!buffer->log_file)
|
||||
{
|
||||
wee_log_printf (_("Unable to write log file for a buffer\n"));
|
||||
free (buffer->log_filename);
|
||||
return;
|
||||
}
|
||||
log_write (buffer, _("**** Beginning of log "));
|
||||
log_write_date (buffer);
|
||||
log_write (buffer, "****\n");
|
||||
fprintf (weechat_log_file, "%s", buffer);
|
||||
fflush (weechat_log_file);
|
||||
}
|
||||
|
||||
/*
|
||||
* log_end: ends a log
|
||||
* weechat_log_close: close log file
|
||||
*/
|
||||
|
||||
void
|
||||
log_end (t_gui_buffer *buffer)
|
||||
weechat_log_close ()
|
||||
{
|
||||
if (buffer->log_file)
|
||||
/* close log file */
|
||||
if (weechat_log_file)
|
||||
{
|
||||
log_write (buffer, _("**** End of log "));
|
||||
log_write_date (buffer);
|
||||
log_write (buffer, "****\n");
|
||||
fclose (buffer->log_file);
|
||||
buffer->log_file = NULL;
|
||||
#ifdef HAVE_FLOCK
|
||||
flock (fileno (weechat_log_file), LOCK_UN);
|
||||
#endif
|
||||
fclose (weechat_log_file);
|
||||
weechat_log_file = NULL;
|
||||
}
|
||||
|
||||
/* free filename */
|
||||
if (weechat_log_filename)
|
||||
{
|
||||
free (weechat_log_filename);
|
||||
weechat_log_filename = NULL;
|
||||
}
|
||||
if (buffer->log_filename)
|
||||
free (buffer->log_filename);
|
||||
}
|
||||
|
||||
/*
|
||||
* weechat_log_crash_rename: rename log file when crashing
|
||||
*/
|
||||
|
||||
int
|
||||
weechat_log_crash_rename ()
|
||||
{
|
||||
char *old_name, *new_name;
|
||||
int length;
|
||||
time_t time_now;
|
||||
struct tm *local_time;
|
||||
|
||||
if (!weechat_log_filename)
|
||||
return 0;
|
||||
|
||||
old_name = strdup (weechat_log_filename);
|
||||
if (!old_name)
|
||||
return 0;
|
||||
|
||||
weechat_log_close ();
|
||||
|
||||
length = strlen (weechat_home) + 128;
|
||||
new_name = (char *) malloc (length);
|
||||
if (new_name)
|
||||
{
|
||||
time_now = time (NULL);
|
||||
local_time = localtime (&time_now);
|
||||
snprintf (new_name, length,
|
||||
"%s/weechat_crash_%04d%02d%02d_%d.log",
|
||||
weechat_home,
|
||||
local_time->tm_year + 1900,
|
||||
local_time->tm_mon + 1,
|
||||
local_time->tm_mday,
|
||||
getpid());
|
||||
if (rename (old_name, new_name) == 0)
|
||||
{
|
||||
fprintf (stderr, "*** Full crash dump was saved to %s file.\n",
|
||||
new_name);
|
||||
weechat_log_open (new_name, "a");
|
||||
free (old_name);
|
||||
free (new_name);
|
||||
return 1;
|
||||
}
|
||||
free (new_name);
|
||||
}
|
||||
|
||||
free (old_name);
|
||||
weechat_log_open (NULL, "a");
|
||||
return 0;
|
||||
}
|
||||
|
||||
+8
-9
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2005 by FlashCode <flashcode@flashtux.org>
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@@ -14,20 +14,19 @@
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
|
||||
#ifndef __WEECHAT_LOG_H
|
||||
#define __WEECHAT_LOG_H 1
|
||||
|
||||
#include "../irc/irc.h"
|
||||
#include "../gui/gui.h"
|
||||
extern char *weechat_log_filename;
|
||||
extern FILE *weechat_log_file;
|
||||
|
||||
extern void log_write_date (t_gui_buffer *);
|
||||
extern void log_write (t_gui_buffer *, char *);
|
||||
extern void log_write_line (t_gui_buffer *, t_gui_line *);
|
||||
extern void log_start (t_gui_buffer *);
|
||||
extern void log_end (t_gui_buffer *);
|
||||
extern void weechat_log_init ();
|
||||
extern void weechat_log_close ();
|
||||
extern void weechat_log_printf (char *, ...);
|
||||
extern int weechat_log_crash_rename ();
|
||||
|
||||
#endif /* log.h */
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,188 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
|
||||
#ifndef __WEECHAT_SESSION_H
|
||||
#define __WEECHAT_SESSION_H 1
|
||||
|
||||
#define WEECHAT_SESSION_NAME "weechat_session.bin"
|
||||
|
||||
#define SESSION_SIGNATURE "== WeeChat Upgrade file v1.0 - binary, do not edit! =="
|
||||
|
||||
/* For developers: please add new values ONLY AT THE END of enums */
|
||||
|
||||
enum t_session_type
|
||||
{
|
||||
SESSION_TYPE_INT = 0,
|
||||
SESSION_TYPE_STR,
|
||||
SESSION_TYPE_BUF
|
||||
};
|
||||
|
||||
enum t_session_object
|
||||
{
|
||||
SESSION_OBJ_END = 0,
|
||||
SESSION_OBJ_SERVER,
|
||||
SESSION_OBJ_CHANNEL,
|
||||
SESSION_OBJ_NICK,
|
||||
SESSION_OBJ_DCC,
|
||||
SESSION_OBJ_HISTORY,
|
||||
SESSION_OBJ_BUFFER,
|
||||
SESSION_OBJ_LINE,
|
||||
SESSION_OBJ_UPTIME
|
||||
};
|
||||
|
||||
enum t_session_server
|
||||
{
|
||||
SESSION_SERV_END = 0,
|
||||
SESSION_SERV_NAME,
|
||||
SESSION_SERV_AUTOCONNECT,
|
||||
SESSION_SERV_AUTORECONNECT,
|
||||
SESSION_SERV_AUTORECONNECT_DELAY,
|
||||
SESSION_SERV_COMMAND_LINE,
|
||||
SESSION_SERV_ADDRESS,
|
||||
SESSION_SERV_PORT,
|
||||
SESSION_SERV_IPV6,
|
||||
SESSION_SERV_SSL,
|
||||
SESSION_SERV_PASSWORD,
|
||||
SESSION_SERV_NICK1,
|
||||
SESSION_SERV_NICK2,
|
||||
SESSION_SERV_NICK3,
|
||||
SESSION_SERV_USERNAME,
|
||||
SESSION_SERV_REALNAME,
|
||||
SESSION_SERV_COMMAND,
|
||||
SESSION_SERV_COMMAND_DELAY,
|
||||
SESSION_SERV_AUTOJOIN,
|
||||
SESSION_SERV_AUTOREJOIN,
|
||||
SESSION_SERV_NOTIFY_LEVELS,
|
||||
SESSION_SERV_CHILD_PID,
|
||||
SESSION_SERV_CHILD_READ,
|
||||
SESSION_SERV_CHILD_WRITE,
|
||||
SESSION_SERV_SOCK,
|
||||
SESSION_SERV_IS_CONNECTED,
|
||||
SESSION_SERV_SSL_CONNECTED,
|
||||
SESSION_SERV_GNUTLS_SESS,
|
||||
SESSION_SERV_UNTERMINATED_MESSAGE,
|
||||
SESSION_SERV_NICK,
|
||||
SESSION_SERV_RECONNECT_START,
|
||||
SESSION_SERV_RECONNECT_JOIN,
|
||||
SESSION_SERV_IS_AWAY,
|
||||
SESSION_SERV_AWAY_TIME,
|
||||
SESSION_SERV_LAG,
|
||||
SESSION_SERV_LAG_CHECK_TIME,
|
||||
SESSION_SERV_LAG_NEXT_CHECK,
|
||||
SESSION_SERV_CHARSET_DECODE_ISO,
|
||||
SESSION_SERV_CHARSET_DECODE_UTF,
|
||||
SESSION_SERV_CHARSET_ENCODE,
|
||||
SESSION_SERV_HOSTNAME,
|
||||
SESSION_SERV_NICK_MODES
|
||||
};
|
||||
|
||||
enum t_session_channel
|
||||
{
|
||||
SESSION_CHAN_END = 0,
|
||||
SESSION_CHAN_TYPE,
|
||||
SESSION_CHAN_NAME,
|
||||
SESSION_CHAN_TOPIC,
|
||||
SESSION_CHAN_MODES,
|
||||
SESSION_CHAN_LIMIT,
|
||||
SESSION_CHAN_KEY,
|
||||
SESSION_CHAN_NICKS_COUNT,
|
||||
SESSION_CHAN_CHECKING_AWAY,
|
||||
SESSION_CHAN_AWAY_MESSAGE,
|
||||
SESSION_CHAN_CYCLE,
|
||||
SESSION_CHAN_CLOSE
|
||||
};
|
||||
|
||||
enum t_session_nick
|
||||
{
|
||||
SESSION_NICK_END = 0,
|
||||
SESSION_NICK_NICK,
|
||||
SESSION_NICK_FLAGS,
|
||||
SESSION_NICK_COLOR,
|
||||
SESSION_NICK_HOST
|
||||
};
|
||||
|
||||
enum t_session_dcc
|
||||
{
|
||||
SESSION_DCC_END = 0,
|
||||
SESSION_DCC_SERVER,
|
||||
SESSION_DCC_CHANNEL,
|
||||
SESSION_DCC_TYPE,
|
||||
SESSION_DCC_STATUS,
|
||||
SESSION_DCC_START_TIME,
|
||||
SESSION_DCC_START_TRANSFER,
|
||||
SESSION_DCC_ADDR,
|
||||
SESSION_DCC_PORT,
|
||||
SESSION_DCC_NICK,
|
||||
SESSION_DCC_SOCK,
|
||||
SESSION_DCC_UNTERMINATED_MESSAGE,
|
||||
SESSION_DCC_FILE,
|
||||
SESSION_DCC_FILENAME,
|
||||
SESSION_DCC_LOCAL_FILENAME,
|
||||
SESSION_DCC_FILENAME_SUFFIX,
|
||||
SESSION_DCC_SIZE,
|
||||
SESSION_DCC_POS,
|
||||
SESSION_DCC_ACK,
|
||||
SESSION_DCC_START_RESUME,
|
||||
SESSION_DCC_LAST_CHECK_TIME,
|
||||
SESSION_DCC_LAST_CHECK_POS,
|
||||
SESSION_DCC_LAST_ACTIVITY,
|
||||
SESSION_DCC_BYTES_PER_SEC,
|
||||
SESSION_DCC_ETA
|
||||
};
|
||||
|
||||
enum t_session_history
|
||||
{
|
||||
SESSION_HIST_END = 0,
|
||||
SESSION_HIST_TEXT
|
||||
};
|
||||
|
||||
enum t_session_buffer
|
||||
{
|
||||
SESSION_BUFF_END = 0,
|
||||
SESSION_BUFF_SERVER,
|
||||
SESSION_BUFF_CHANNEL,
|
||||
SESSION_BUFF_TYPE,
|
||||
SESSION_BUFF_ALL_SERVERS
|
||||
};
|
||||
|
||||
enum t_session_line
|
||||
{
|
||||
SESSION_LINE_END = 0,
|
||||
SESSION_LINE_LENGTH,
|
||||
SESSION_LINE_LENGTH_ALIGN,
|
||||
SESSION_LINE_LOG_WRITE,
|
||||
SESSION_LINE_WITH_MESSAGE,
|
||||
SESSION_LINE_WITH_HIGHLIGHT,
|
||||
SESSION_LINE_DATA,
|
||||
SESSION_LINE_OFS_AFTER_DATE,
|
||||
SESSION_LINE_OFS_START_MESSAGE,
|
||||
SESSION_LINE_NICK
|
||||
};
|
||||
|
||||
enum t_session_uptime
|
||||
{
|
||||
SESSION_UPT_END = 0,
|
||||
SESSION_UPT_START_TIME
|
||||
};
|
||||
|
||||
int session_save (char *filename);
|
||||
int session_load (char *filename);
|
||||
|
||||
#endif /* session.h */
|
||||
@@ -0,0 +1,370 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
/* utf8.c: UTF-8 string functions for WeeChat */
|
||||
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#define __USE_XOPEN
|
||||
|
||||
#if defined(__OpenBSD__)
|
||||
#include <utf8/wchar.h>
|
||||
#else
|
||||
#include <wchar.h>
|
||||
#endif
|
||||
|
||||
#include "weechat.h"
|
||||
#include "utf8.h"
|
||||
#include "weeconfig.h"
|
||||
|
||||
|
||||
int local_utf8 = 0;
|
||||
|
||||
|
||||
/*
|
||||
* utf8_init: initializes UTF-8 in WeeChat
|
||||
*/
|
||||
|
||||
void
|
||||
utf8_init ()
|
||||
{
|
||||
local_utf8 = 0;
|
||||
|
||||
if (cfg_look_charset_internal && cfg_look_charset_internal[0])
|
||||
{
|
||||
if (strstr (cfg_look_charset_internal, "UTF-8")
|
||||
|| strstr (cfg_look_charset_internal, "utf-8"))
|
||||
local_utf8 = 1;
|
||||
}
|
||||
else if ((local_charset)
|
||||
&& ((strstr (local_charset, "UTF-8")
|
||||
|| strstr (local_charset, "utf-8"))))
|
||||
local_utf8 = 1;
|
||||
}
|
||||
|
||||
/*
|
||||
* utf8_is_valid: return 1 if UTF-8 string is valid, 0 otherwise
|
||||
*/
|
||||
|
||||
int
|
||||
utf8_is_valid (char *string)
|
||||
{
|
||||
while (string && string[0])
|
||||
{
|
||||
/* UTF-8, 2 bytes, should be: 110vvvvv 10vvvvvv */
|
||||
if (((unsigned char)(string[0]) & 0xE0) == 0xC0)
|
||||
{
|
||||
if (!string[1] || (((unsigned char)(string[1]) & 0xC0) != 0x80))
|
||||
return 0;
|
||||
string += 2;
|
||||
}
|
||||
/* UTF-8, 3 bytes, should be: 1110vvvv 10vvvvvv 10vvvvvv */
|
||||
else if (((unsigned char)(string[0]) & 0xF0) == 0xE0)
|
||||
{
|
||||
if (!string[1] || !string[2]
|
||||
|| (((unsigned char)(string[1]) & 0xC0) != 0x80)
|
||||
|| (((unsigned char)(string[2]) & 0xC0) != 0x80))
|
||||
return 0;
|
||||
string += 3;
|
||||
}
|
||||
/* UTF-8, 4 bytes, should be: 11110vvv 10vvvvvv 10vvvvvv 10vvvvvv */
|
||||
else if (((unsigned char)(string[0]) & 0xF8) == 0xF0)
|
||||
{
|
||||
if (!string[1] || !string[2] || !string[3]
|
||||
|| (((unsigned char)(string[1]) & 0xC0) != 0x80)
|
||||
|| (((unsigned char)(string[2]) & 0xC0) != 0x80)
|
||||
|| (((unsigned char)(string[3]) & 0xC0) != 0x80))
|
||||
return 0;
|
||||
string += 4;
|
||||
}
|
||||
/* UTF-8, 1 byte, should be: 0vvvvvvv */
|
||||
else if ((unsigned char)(string[0]) >= 0x80)
|
||||
return 0;
|
||||
else
|
||||
string++;
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
|
||||
/*
|
||||
* utf8_prev_char: return previous UTF-8 char in a string
|
||||
*/
|
||||
|
||||
char *
|
||||
utf8_prev_char (char *string_start, char *string)
|
||||
{
|
||||
if (!string || (string <= string_start))
|
||||
return NULL;
|
||||
|
||||
string--;
|
||||
|
||||
if (!local_utf8)
|
||||
return string;
|
||||
|
||||
if (((unsigned char)(string[0]) & 0xC0) == 0x80)
|
||||
{
|
||||
/* UTF-8, at least 2 bytes */
|
||||
string--;
|
||||
if (string < string_start)
|
||||
return string + 1;
|
||||
if (((unsigned char)(string[0]) & 0xC0) == 0x80)
|
||||
{
|
||||
/* UTF-8, at least 3 bytes */
|
||||
string--;
|
||||
if (string < string_start)
|
||||
return string + 1;
|
||||
if (((unsigned char)(string[0]) & 0xC0) == 0x80)
|
||||
{
|
||||
/* UTF-8, 4 bytes */
|
||||
string--;
|
||||
if (string < string_start)
|
||||
return string + 1;
|
||||
return string;
|
||||
}
|
||||
else
|
||||
return string;
|
||||
}
|
||||
else
|
||||
return string;
|
||||
}
|
||||
return string;
|
||||
}
|
||||
|
||||
/*
|
||||
* utf8_next_char: return next UTF-8 char in a string
|
||||
*/
|
||||
|
||||
char *
|
||||
utf8_next_char (char *string)
|
||||
{
|
||||
if (!string)
|
||||
return NULL;
|
||||
|
||||
if (!local_utf8)
|
||||
return string + 1;
|
||||
|
||||
/* UTF-8, 2 bytes: 110vvvvv 10vvvvvv */
|
||||
if (((unsigned char)(string[0]) & 0xE0) == 0xC0)
|
||||
{
|
||||
if (!string[1])
|
||||
return string + 1;
|
||||
return string + 2;
|
||||
}
|
||||
/* UTF-8, 3 bytes: 1110vvvv 10vvvvvv 10vvvvvv */
|
||||
else if (((unsigned char)(string[0]) & 0xF0) == 0xE0)
|
||||
{
|
||||
if (!string[1])
|
||||
return string + 1;
|
||||
if (!string[2])
|
||||
return string + 2;
|
||||
return string + 3;
|
||||
}
|
||||
/* UTF-8, 4 bytes: 11110vvv 10vvvvvv 10vvvvvv 10vvvvvv */
|
||||
else if (((unsigned char)(string[0]) & 0xF8) == 0xF0)
|
||||
{
|
||||
if (!string[1])
|
||||
return string + 1;
|
||||
if (!string[2])
|
||||
return string + 2;
|
||||
if (!string[3])
|
||||
return string + 3;
|
||||
return string + 4;
|
||||
}
|
||||
/* UTF-8, 1 byte: 0vvvvvvv */
|
||||
return string + 1;
|
||||
}
|
||||
|
||||
/*
|
||||
* utf8_char_size: return UTF-8 char size
|
||||
*/
|
||||
|
||||
int
|
||||
utf8_char_size (char *string)
|
||||
{
|
||||
if (!string)
|
||||
return 0;
|
||||
|
||||
return utf8_next_char (string) - string;
|
||||
}
|
||||
|
||||
/*
|
||||
* utf8_strlen: return length of an UTF-8 string (<= strlen(string))
|
||||
*/
|
||||
|
||||
int
|
||||
utf8_strlen (char *string)
|
||||
{
|
||||
int length;
|
||||
|
||||
if (!string)
|
||||
return 0;
|
||||
|
||||
if (!local_utf8)
|
||||
return strlen (string);
|
||||
|
||||
length = 0;
|
||||
while (string && string[0])
|
||||
{
|
||||
string = utf8_next_char (string);
|
||||
length++;
|
||||
}
|
||||
return length;
|
||||
}
|
||||
|
||||
/*
|
||||
* utf8_strnlen: return length of an UTF-8 string, for N bytes
|
||||
*/
|
||||
|
||||
int
|
||||
utf8_strnlen (char *string, int bytes)
|
||||
{
|
||||
char *start;
|
||||
int length;
|
||||
|
||||
if (!string)
|
||||
return 0;
|
||||
|
||||
if (!local_utf8)
|
||||
{
|
||||
length = strlen (string);
|
||||
if (bytes > length)
|
||||
return length;
|
||||
return bytes;
|
||||
}
|
||||
|
||||
start = string;
|
||||
length = 0;
|
||||
while (string && string[0] && (string - start < bytes))
|
||||
{
|
||||
string = utf8_next_char (string);
|
||||
length++;
|
||||
}
|
||||
return length;
|
||||
}
|
||||
|
||||
/*
|
||||
* utf8_width_screen: return number of chars needed on screen to display UTF-8 string
|
||||
*/
|
||||
|
||||
int
|
||||
utf8_width_screen (char *string)
|
||||
{
|
||||
int length, num_char;
|
||||
wchar_t *wstring;
|
||||
|
||||
if (!string)
|
||||
return 0;
|
||||
|
||||
if (!local_utf8)
|
||||
return strlen (string);
|
||||
|
||||
num_char = mbstowcs (NULL, string, 0) + 1;
|
||||
wstring = (wchar_t *) malloc ((num_char + 1) * sizeof (wchar_t));
|
||||
if (!wstring)
|
||||
return utf8_strlen (string);
|
||||
|
||||
if (mbstowcs (wstring, string, num_char) == (size_t)(-1))
|
||||
{
|
||||
free (wstring);
|
||||
return utf8_strlen (string);
|
||||
}
|
||||
|
||||
length = wcswidth (wstring, num_char);
|
||||
free (wstring);
|
||||
return length;
|
||||
}
|
||||
|
||||
/*
|
||||
* utf8_add_offset: moves forward N chars in an UTF-8 string
|
||||
*/
|
||||
|
||||
char *
|
||||
utf8_add_offset (char *string, int offset)
|
||||
{
|
||||
int count;
|
||||
|
||||
if (!string)
|
||||
return string;
|
||||
|
||||
if (!local_utf8)
|
||||
return string + offset;
|
||||
|
||||
count = 0;
|
||||
while (string && string[0] && (count < offset))
|
||||
{
|
||||
string = utf8_next_char (string);
|
||||
count++;
|
||||
}
|
||||
return string;
|
||||
}
|
||||
|
||||
/*
|
||||
* utf8_real_pos: get real position in UTF-8
|
||||
* for example: ("aébc", 2) returns 3
|
||||
*/
|
||||
|
||||
int
|
||||
utf8_real_pos (char *string, int pos)
|
||||
{
|
||||
int count, real_pos;
|
||||
char *next_char;
|
||||
|
||||
if (!string || !local_utf8)
|
||||
return pos;
|
||||
|
||||
count = 0;
|
||||
real_pos = 0;
|
||||
while (string && string[0] && (count < pos))
|
||||
{
|
||||
next_char = utf8_next_char (string);
|
||||
real_pos += (next_char - string);
|
||||
string = next_char;
|
||||
count++;
|
||||
}
|
||||
return real_pos;
|
||||
}
|
||||
|
||||
/*
|
||||
* utf8_pos: get position in UTF-8
|
||||
* for example: ("aébc", 3) returns 2
|
||||
*/
|
||||
|
||||
int
|
||||
utf8_pos (char *string, int real_pos)
|
||||
{
|
||||
int count;
|
||||
char *limit;
|
||||
|
||||
if (!string || !local_charset)
|
||||
return real_pos;
|
||||
|
||||
count = 0;
|
||||
limit = string + real_pos;
|
||||
while (string && string[0] && (string < limit))
|
||||
{
|
||||
string = utf8_next_char (string);
|
||||
count++;
|
||||
}
|
||||
return count;
|
||||
}
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2005 by FlashCode <flashcode@flashtux.org>
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@@ -14,21 +14,25 @@
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
|
||||
#ifndef __WEECHAT_PYTHON_H
|
||||
#define __WEECHAT_PYTHON_H 1
|
||||
#ifndef __WEECHAT_UTF8_H
|
||||
#define __WEECHAT_UTF8_H 1
|
||||
|
||||
#include "../plugins.h"
|
||||
extern int local_utf8;
|
||||
|
||||
extern void wee_python_init ();
|
||||
extern t_plugin_script *wee_python_search (char *);
|
||||
extern int wee_python_exec (char *, char *, char *);
|
||||
extern int wee_python_load (char *);
|
||||
extern void wee_python_unload (t_plugin_script *);
|
||||
extern void wee_python_unload_all ();
|
||||
extern void wee_python_end ();
|
||||
extern void utf8_init ();
|
||||
extern int utf8_is_valid (char *);
|
||||
extern char *utf8_prev_char (char *, char *);
|
||||
extern char *utf8_next_char (char *);
|
||||
extern int utf8_char_size (char *);
|
||||
extern int utf8_strlen (char *);
|
||||
extern int utf8_strnlen (char *, int);
|
||||
extern int utf8_width_screen (char *);
|
||||
extern char *utf8_add_offset (char *, int);
|
||||
extern int utf8_real_pos (char *, int);
|
||||
extern int utf8_pos (char *, int);
|
||||
|
||||
#endif /* wee-python.h */
|
||||
#endif /* utf8.h */
|
||||
+587
-317
File diff suppressed because it is too large
Load Diff
+15
-23
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2005 by FlashCode <flashcode@flashtux.org>
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@@ -14,7 +14,7 @@
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
|
||||
@@ -52,7 +52,7 @@
|
||||
#endif
|
||||
|
||||
|
||||
#define WEECHAT_COPYRIGHT_DATE "(c) 2003-2005"
|
||||
#define WEECHAT_COPYRIGHT_DATE "(c) 2003-2006"
|
||||
#define WEECHAT_WEBSITE "http://weechat.flashtux.org"
|
||||
|
||||
#define WEECHAT_ERROR _("WeeChat Error:")
|
||||
@@ -65,7 +65,7 @@
|
||||
/* license */
|
||||
|
||||
#define WEE_LICENSE \
|
||||
PACKAGE_STRING " (c) Copyright 2003-2005, compiled on " __DATE__ " " __TIME__ \
|
||||
PACKAGE_STRING " (c) Copyright 2003-2006, compiled on " __DATE__ " " __TIME__ \
|
||||
"\nDeveloped by FlashCode <flashcode@flashtux.org> - " WEECHAT_WEBSITE "\n\n" \
|
||||
"This program is free software; you can redistribute it and/or modify\n" \
|
||||
"it under the terms of the GNU General Public License as published by\n" \
|
||||
@@ -80,22 +80,8 @@
|
||||
"\n" \
|
||||
"You should have received a copy of the GNU General Public License\n" \
|
||||
"along with this program; if not, write to the Free Software\n" \
|
||||
"Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA\n\n"
|
||||
"Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA\n\n"
|
||||
|
||||
#define WEE_USAGE1 \
|
||||
PACKAGE_STRING " (c) Copyright 2003-2005, compiled on " __DATE__ " " __TIME__ \
|
||||
"\nDeveloped by FlashCode <flashcode@flashtux.org> - " WEECHAT_WEBSITE "\n\n" \
|
||||
"Usage: %s [options ...]\n" \
|
||||
" or: %s [irc[6][s]://[nickname[:password]@]irc.example.org[:port][/channel][,channel[...]]\n\n"
|
||||
|
||||
#define WEE_USAGE2 \
|
||||
" -c, --config display config file options\n" \
|
||||
" -h, --help this help screen\n" \
|
||||
" -i, --irc-commands display IRC commands\n" \
|
||||
" -l, --license display WeeChat license\n" \
|
||||
" -v, --version display WeeChat version\n" \
|
||||
" -w, --weechat-commands display WeeChat commands\n\n"
|
||||
|
||||
/* directory separator, depending on OS */
|
||||
|
||||
#ifdef _WIN32
|
||||
@@ -108,6 +94,8 @@
|
||||
|
||||
/* global variables and functions */
|
||||
|
||||
extern char *weechat_argv0;
|
||||
extern time_t weechat_start_time;
|
||||
extern int quit_weechat;
|
||||
extern char *weechat_home;
|
||||
extern char *local_charset;
|
||||
@@ -116,10 +104,14 @@ extern char *local_charset;
|
||||
extern gnutls_certificate_credentials gnutls_xcred;
|
||||
#endif
|
||||
|
||||
extern void wee_log_printf (char *, ...);
|
||||
extern void wee_dump (int);
|
||||
extern char *weechat_convert_encoding (char *, char *, char *);
|
||||
extern void ascii_tolower (char *);
|
||||
extern void ascii_toupper (char *);
|
||||
extern int ascii_strcasecmp (char *, char *);
|
||||
extern int ascii_strncasecmp (char *, char *, int);
|
||||
extern char *weechat_iconv (char *, char *, char *);
|
||||
extern char *weechat_strreplace (char *, char *, char *);
|
||||
extern void weechat_dump (int);
|
||||
extern long get_timeval_diff (struct timeval *, struct timeval *);
|
||||
extern void wee_shutdown (int);
|
||||
extern void weechat_shutdown (int, int);
|
||||
|
||||
#endif /* weechat.h */
|
||||
|
||||
+915
-219
File diff suppressed because it is too large
Load Diff
+73
-10
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2005 by FlashCode <flashcode@flashtux.org>
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@@ -14,7 +14,7 @@
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
|
||||
@@ -33,9 +33,12 @@
|
||||
#define CONFIG_SECTION_IRC 4
|
||||
#define CONFIG_SECTION_DCC 5
|
||||
#define CONFIG_SECTION_PROXY 6
|
||||
#define CONFIG_SECTION_ALIAS 7
|
||||
#define CONFIG_SECTION_SERVER 8
|
||||
#define CONFIG_NUMBER_SECTIONS 9
|
||||
#define CONFIG_SECTION_PLUGINS 7
|
||||
#define CONFIG_SECTION_KEYS 8
|
||||
#define CONFIG_SECTION_ALIAS 9
|
||||
#define CONFIG_SECTION_IGNORE 10
|
||||
#define CONFIG_SECTION_SERVER 11
|
||||
#define CONFIG_NUMBER_SECTIONS 12
|
||||
|
||||
#define OPTION_TYPE_BOOLEAN 1 /* values: on/off */
|
||||
#define OPTION_TYPE_INT 2 /* values: from min to max */
|
||||
@@ -51,6 +54,14 @@
|
||||
#define CFG_LOOK_NICKLIST_TOP 2
|
||||
#define CFG_LOOK_NICKLIST_BOTTOM 3
|
||||
|
||||
#define CFG_LOOK_ALIGN_NICK_NONE 0
|
||||
#define CFG_LOOK_ALIGN_NICK_LEFT 1
|
||||
#define CFG_LOOK_ALIGN_NICK_RIGHT 2
|
||||
|
||||
#define CFG_IRC_DISPLAY_AWAY_OFF 0
|
||||
#define CFG_IRC_DISPLAY_AWAY_LOCAL 1
|
||||
#define CFG_IRC_DISPLAY_AWAY_CHANNEL 2
|
||||
|
||||
typedef struct t_config_section t_config_section;
|
||||
|
||||
struct t_config_section
|
||||
@@ -80,13 +91,16 @@ extern int cfg_look_set_title;
|
||||
extern int cfg_look_startup_logo;
|
||||
extern int cfg_look_startup_version;
|
||||
extern char *cfg_look_weechat_slogan;
|
||||
extern char *cfg_look_charset_decode;
|
||||
extern char *cfg_look_charset_decode_iso;
|
||||
extern char *cfg_look_charset_decode_utf;
|
||||
extern char *cfg_look_charset_encode;
|
||||
extern char *cfg_look_charset_internal;
|
||||
extern int cfg_look_one_server_buffer;
|
||||
extern int cfg_look_open_near_server;
|
||||
extern int cfg_look_scroll_amount;
|
||||
extern char *cfg_look_buffer_timestamp;
|
||||
extern int cfg_look_color_nicks;
|
||||
extern int cfg_look_color_nicks_number;
|
||||
extern int cfg_look_color_actions;
|
||||
extern int cfg_look_remove_colors_from_msgs;
|
||||
extern int cfg_look_nicklist;
|
||||
extern int cfg_look_nicklist_position;
|
||||
extern int cfg_look_nicklist_min_size;
|
||||
@@ -94,11 +108,29 @@ extern int cfg_look_nicklist_max_size;
|
||||
extern int cfg_look_nickmode;
|
||||
extern int cfg_look_nickmode_empty;
|
||||
extern char *cfg_look_no_nickname;
|
||||
extern char *cfg_look_completor;
|
||||
extern char *cfg_look_nick_prefix;
|
||||
extern char *cfg_look_nick_suffix;
|
||||
extern int cfg_look_align_nick;
|
||||
extern int cfg_look_align_other;
|
||||
extern int cfg_look_align_size;
|
||||
extern int cfg_look_align_size_max;
|
||||
extern char *cfg_look_nick_completor;
|
||||
extern char *cfg_look_nick_completion_ignore;
|
||||
extern int cfg_look_nick_complete_first;
|
||||
extern int cfg_look_infobar;
|
||||
extern char *cfg_look_infobar_timestamp;
|
||||
extern int cfg_look_infobar_seconds;
|
||||
extern int cfg_look_infobar_delay_highlight;
|
||||
extern int cfg_look_hotlist_names_count;
|
||||
extern int cfg_look_hotlist_names_level;
|
||||
extern int cfg_look_hotlist_names_length;
|
||||
extern int cfg_look_day_change;
|
||||
extern char *cfg_look_day_change_timestamp;
|
||||
extern char *cfg_look_read_marker;
|
||||
extern char *cfg_look_input_format;
|
||||
|
||||
extern int cfg_col_real_white;
|
||||
extern int cfg_col_separator;
|
||||
extern int cfg_col_title;
|
||||
extern int cfg_col_title_bg;
|
||||
extern int cfg_col_chat;
|
||||
@@ -106,25 +138,35 @@ extern int cfg_col_chat_time;
|
||||
extern int cfg_col_chat_time_sep;
|
||||
extern int cfg_col_chat_prefix1;
|
||||
extern int cfg_col_chat_prefix2;
|
||||
extern int cfg_col_chat_server;
|
||||
extern int cfg_col_chat_join;
|
||||
extern int cfg_col_chat_part;
|
||||
extern int cfg_col_chat_nick;
|
||||
extern int cfg_col_chat_host;
|
||||
extern int cfg_col_chat_channel;
|
||||
extern int cfg_col_chat_dark;
|
||||
extern int cfg_col_chat_highlight;
|
||||
extern int cfg_col_chat_bg;
|
||||
extern int cfg_col_chat_read_marker;
|
||||
extern int cfg_col_chat_read_marker_bg;
|
||||
extern int cfg_col_status;
|
||||
extern int cfg_col_status_delimiters;
|
||||
extern int cfg_col_status_channel;
|
||||
extern int cfg_col_status_data_msg;
|
||||
extern int cfg_col_status_data_private;
|
||||
extern int cfg_col_status_data_highlight;
|
||||
extern int cfg_col_status_data_other;
|
||||
extern int cfg_col_status_more;
|
||||
extern int cfg_col_status_bg;
|
||||
extern int cfg_col_infobar;
|
||||
extern int cfg_col_infobar_delimiters;
|
||||
extern int cfg_col_infobar_highlight;
|
||||
extern int cfg_col_infobar_bg;
|
||||
extern int cfg_col_input;
|
||||
extern int cfg_col_input_server;
|
||||
extern int cfg_col_input_channel;
|
||||
extern int cfg_col_input_nick;
|
||||
extern int cfg_col_input_delimiters;
|
||||
extern int cfg_col_input_bg;
|
||||
extern int cfg_col_nick;
|
||||
extern int cfg_col_nick_away;
|
||||
@@ -136,6 +178,7 @@ extern int cfg_col_nick_voice;
|
||||
extern int cfg_col_nick_more;
|
||||
extern int cfg_col_nick_sep;
|
||||
extern int cfg_col_nick_self;
|
||||
extern int cfg_col_nick_colors[COLOR_WIN_NICK_NUMBER];
|
||||
extern int cfg_col_nick_private;
|
||||
extern int cfg_col_nick_bg;
|
||||
extern int cfg_col_dcc_selected;
|
||||
@@ -148,6 +191,7 @@ extern int cfg_col_dcc_aborted;
|
||||
|
||||
extern int cfg_history_max_lines;
|
||||
extern int cfg_history_max_commands;
|
||||
extern int cfg_history_display_default;
|
||||
|
||||
extern int cfg_log_auto_server;
|
||||
extern int cfg_log_auto_channel;
|
||||
@@ -158,19 +202,26 @@ extern char *cfg_log_timestamp;
|
||||
extern int cfg_log_hide_nickserv_pwd;
|
||||
|
||||
extern int cfg_irc_display_away;
|
||||
extern char *cfg_irc_default_msg_away;
|
||||
extern int cfg_irc_show_away_once;
|
||||
extern char *cfg_irc_default_msg_part;
|
||||
extern char *cfg_irc_default_msg_quit;
|
||||
extern int cfg_irc_notice_as_pv;
|
||||
extern int cfg_irc_away_check;
|
||||
extern int cfg_irc_away_check_max_nicks;
|
||||
extern int cfg_irc_lag_check;
|
||||
extern int cfg_irc_lag_min_show;
|
||||
extern int cfg_irc_lag_disconnect;
|
||||
extern int cfg_irc_fifo_pipe;
|
||||
extern char *cfg_irc_highlight;
|
||||
extern int cfg_irc_colors_receive;
|
||||
extern int cfg_irc_colors_send;
|
||||
|
||||
extern int cfg_dcc_auto_accept_files;
|
||||
extern int cfg_dcc_auto_accept_chats;
|
||||
extern int cfg_dcc_timeout;
|
||||
extern int cfg_dcc_blocksize;
|
||||
extern char *cfg_dcc_port_range;
|
||||
extern char *cfg_dcc_own_ip;
|
||||
extern char *cfg_dcc_download_path;
|
||||
extern char *cfg_dcc_upload_path;
|
||||
extern int cfg_dcc_convert_spaces;
|
||||
@@ -186,6 +237,10 @@ extern int cfg_proxy_port;
|
||||
extern char *cfg_proxy_username;
|
||||
extern char *cfg_proxy_password;
|
||||
|
||||
extern char *cfg_plugins_path;
|
||||
extern char *cfg_plugins_autoload;
|
||||
extern char *cfg_plugins_extension;
|
||||
|
||||
extern t_config_section config_sections [CONFIG_NUMBER_SECTIONS];
|
||||
extern t_config_option * weechat_options [CONFIG_NUMBER_SECTIONS];
|
||||
|
||||
@@ -194,11 +249,19 @@ extern void config_change_noop ();
|
||||
extern void config_change_title ();
|
||||
extern void config_change_buffers ();
|
||||
extern void config_change_buffer_content ();
|
||||
extern void config_change_read_marker ();
|
||||
extern void config_change_charset ();
|
||||
extern void config_change_one_server_buffer ();
|
||||
extern void config_change_color ();
|
||||
extern void config_change_nicks_colors ();
|
||||
extern void config_change_away_check ();
|
||||
extern void config_change_fifo_pipe ();
|
||||
extern void config_change_notify_levels ();
|
||||
extern void config_change_log ();
|
||||
extern int config_option_set_value (t_config_option *, char *);
|
||||
extern void config_option_list_remove (char **, char *);
|
||||
extern void config_option_list_set (char **, char *, char *);
|
||||
extern void config_option_list_get_value (char **, char *, char **, int *);
|
||||
extern t_config_option *config_option_search (char *);
|
||||
extern void config_option_search_option_value (char *, t_config_option **, void **);
|
||||
extern int config_set_value (char *, char *);
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2005 by FlashCode <flashcode@flashtux.org>
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@@ -14,7 +14,7 @@
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
/* weelist.c: sorted lists management */
|
||||
@@ -42,7 +42,7 @@ weelist_search (t_weelist *weelist, char *data)
|
||||
|
||||
for (ptr_weelist = weelist; ptr_weelist; ptr_weelist = ptr_weelist->next_weelist)
|
||||
{
|
||||
if (strcasecmp (data, ptr_weelist->data) == 0)
|
||||
if (ascii_strcasecmp (data, ptr_weelist->data) == 0)
|
||||
return ptr_weelist;
|
||||
}
|
||||
/* word not found in list */
|
||||
@@ -60,7 +60,7 @@ weelist_find_pos (t_weelist *weelist, char *data)
|
||||
|
||||
for (ptr_weelist = weelist; ptr_weelist; ptr_weelist = ptr_weelist->next_weelist)
|
||||
{
|
||||
if (strcasecmp (data, ptr_weelist->data) < 0)
|
||||
if (ascii_strcasecmp (data, ptr_weelist->data) < 0)
|
||||
return ptr_weelist;
|
||||
}
|
||||
/* position not found, best position is at the end */
|
||||
@@ -140,6 +140,9 @@ weelist_remove (t_weelist **weelist, t_weelist **last_weelist, t_weelist *elemen
|
||||
{
|
||||
t_weelist *new_weelist;
|
||||
|
||||
if (!element)
|
||||
return;
|
||||
|
||||
/* remove element from list */
|
||||
if (*last_weelist == element)
|
||||
*last_weelist = element->prev_weelist;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2005 by FlashCode <flashcode@flashtux.org>
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@@ -14,7 +14,7 @@
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
|
||||
|
||||
+15
-4
@@ -1,4 +1,4 @@
|
||||
# Copyright (c) 2003-2005 FlashCode <flashcode@flashtux.org>
|
||||
# Copyright (c) 2003-2006 FlashCode <flashcode@flashtux.org>
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
@@ -12,15 +12,26 @@
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
#
|
||||
|
||||
INCLUDES = -DLOCALEDIR=\"$(datadir)/locale\"
|
||||
|
||||
noinst_LIBRARIES = lib_weechat_gui_common.a
|
||||
|
||||
lib_weechat_gui_common_a_SOURCES = gui-common.c \
|
||||
gui.h
|
||||
lib_weechat_gui_common_a_SOURCES = gui-buffer.c \
|
||||
gui-common.c \
|
||||
gui-action.c \
|
||||
gui-keyboard.c \
|
||||
gui-log.c \
|
||||
gui-window.c \
|
||||
gui-panel.c \
|
||||
gui.h \
|
||||
gui-buffer.h \
|
||||
gui-color.h \
|
||||
gui-keyboard.h \
|
||||
gui-panel.h \
|
||||
gui-window.h
|
||||
|
||||
if GUI_NCURSES
|
||||
curses_dir=curses
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# Copyright (c) 2003-2005 FlashCode <flashcode@flashtux.org>
|
||||
# Copyright (c) 2003-2006 FlashCode <flashcode@flashtux.org>
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
@@ -12,19 +12,38 @@
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
#
|
||||
|
||||
INCLUDES = -DLOCALEDIR=\"$(datadir)/locale\"
|
||||
|
||||
bin_PROGRAMS = weechat-curses
|
||||
|
||||
if PLUGINS
|
||||
weechat_curses_LDADD = ../lib_weechat_gui_common.a \
|
||||
../../common/lib_weechat_main.a \
|
||||
../../irc/lib_weechat_irc.a \
|
||||
../../plugins/lib_weechat_plugins.a \
|
||||
$(PLUGINS_LIBS) \
|
||||
$(NCURSES_LIBS) \
|
||||
../../plugins/lib_weechat_plugins.a $(PLUGINS_LIBS) \
|
||||
$(GNUTLS_LIBS)
|
||||
$(GNUTLS_LFLAGS)
|
||||
else
|
||||
weechat_curses_LDADD = ../lib_weechat_gui_common.a \
|
||||
../../common/lib_weechat_main.a \
|
||||
../../irc/lib_weechat_irc.a \
|
||||
$(PLUGINS_LIBS) \
|
||||
$(NCURSES_LIBS) \
|
||||
$(GNUTLS_LFLAGS)
|
||||
endif
|
||||
|
||||
weechat_curses_SOURCES = gui-display.c \
|
||||
gui-input.c
|
||||
weechat_curses_SOURCES = gui-curses-chat.c \
|
||||
gui-curses-color.c \
|
||||
gui-curses-infobar.c \
|
||||
gui-curses-input.c \
|
||||
gui-curses-keyboard.c \
|
||||
gui-curses-main.c \
|
||||
gui-curses-nicklist.c \
|
||||
gui-curses-status.c \
|
||||
gui-curses-window.c \
|
||||
gui-curses-panel.c \
|
||||
gui-curses.h
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,601 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
/* gui-curses-color.c: color functions for Curses GUI */
|
||||
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <ctype.h>
|
||||
|
||||
#include "../../common/weechat.h"
|
||||
#include "../gui.h"
|
||||
#include "../../common/weeconfig.h"
|
||||
#include "gui-curses.h"
|
||||
|
||||
|
||||
t_gui_color gui_weechat_colors[] =
|
||||
{ { -1, 0, 0, "default" },
|
||||
{ WEECHAT_COLOR_BLACK, 0, 0, "black" },
|
||||
{ WEECHAT_COLOR_RED, 0, 0, "red" },
|
||||
{ WEECHAT_COLOR_RED, 0, A_BOLD, "lightred" },
|
||||
{ WEECHAT_COLOR_GREEN, 0, 0, "green" },
|
||||
{ WEECHAT_COLOR_GREEN, 0, A_BOLD, "lightgreen" },
|
||||
{ WEECHAT_COLOR_YELLOW, 0, 0, "brown" },
|
||||
{ WEECHAT_COLOR_YELLOW, 0, A_BOLD, "yellow" },
|
||||
{ WEECHAT_COLOR_BLUE, 0, 0, "blue" },
|
||||
{ WEECHAT_COLOR_BLUE, 0, A_BOLD, "lightblue" },
|
||||
{ WEECHAT_COLOR_MAGENTA, 0, 0, "magenta" },
|
||||
{ WEECHAT_COLOR_MAGENTA, 0, A_BOLD, "lightmagenta" },
|
||||
{ WEECHAT_COLOR_CYAN, 0, 0, "cyan" },
|
||||
{ WEECHAT_COLOR_CYAN, 0, A_BOLD, "lightcyan" },
|
||||
{ WEECHAT_COLOR_WHITE, 0, A_BOLD, "white" },
|
||||
{ 0, 0, 0, NULL }
|
||||
};
|
||||
|
||||
int gui_irc_colors[GUI_NUM_IRC_COLORS][2] =
|
||||
{ { /* 0 */ WEECHAT_COLOR_WHITE, A_BOLD },
|
||||
{ /* 1 */ WEECHAT_COLOR_BLACK, 0 },
|
||||
{ /* 2 */ WEECHAT_COLOR_BLUE, 0 },
|
||||
{ /* 3 */ WEECHAT_COLOR_GREEN, 0 },
|
||||
{ /* 4 */ WEECHAT_COLOR_RED, A_BOLD },
|
||||
{ /* 5 */ WEECHAT_COLOR_RED, 0 },
|
||||
{ /* 6 */ WEECHAT_COLOR_MAGENTA, 0 },
|
||||
{ /* 7 */ WEECHAT_COLOR_YELLOW, 0 },
|
||||
{ /* 8 */ WEECHAT_COLOR_YELLOW, A_BOLD },
|
||||
{ /* 9 */ WEECHAT_COLOR_GREEN, A_BOLD },
|
||||
{ /* 10 */ WEECHAT_COLOR_CYAN, 0 },
|
||||
{ /* 11 */ WEECHAT_COLOR_CYAN, A_BOLD },
|
||||
{ /* 12 */ WEECHAT_COLOR_BLUE, A_BOLD },
|
||||
{ /* 13 */ WEECHAT_COLOR_MAGENTA, A_BOLD },
|
||||
{ /* 14 */ WEECHAT_COLOR_WHITE, 0 },
|
||||
{ /* 15 */ WEECHAT_COLOR_WHITE, A_BOLD }
|
||||
};
|
||||
|
||||
t_gui_color *gui_color[GUI_NUM_COLORS];
|
||||
|
||||
|
||||
/*
|
||||
* gui_color_assign: assign a WeeChat color (read from config)
|
||||
*/
|
||||
|
||||
int
|
||||
gui_color_assign (int *color, char *color_name)
|
||||
{
|
||||
int i;
|
||||
|
||||
/* look for curses colors in table */
|
||||
i = 0;
|
||||
while (gui_weechat_colors[i].string)
|
||||
{
|
||||
if (ascii_strcasecmp (gui_weechat_colors[i].string, color_name) == 0)
|
||||
{
|
||||
*color = i;
|
||||
return 1;
|
||||
}
|
||||
i++;
|
||||
}
|
||||
|
||||
/* color not found */
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*
|
||||
* gui_color_get_name: get color name
|
||||
*/
|
||||
|
||||
char *
|
||||
gui_color_get_name (int num_color)
|
||||
{
|
||||
return gui_weechat_colors[num_color].string;
|
||||
}
|
||||
|
||||
/*
|
||||
* gui_color_decode: parses a message (coming from IRC server),
|
||||
* and according:
|
||||
* - remove any color/style in message
|
||||
* or:
|
||||
* - change colors by codes to be compatible with
|
||||
* other IRC clients
|
||||
* After use, string returned has to be free()
|
||||
*/
|
||||
|
||||
unsigned char *
|
||||
gui_color_decode (unsigned char *string, int keep_colors)
|
||||
{
|
||||
unsigned char *out;
|
||||
int out_length, out_pos;
|
||||
char str_fg[3], str_bg[3];
|
||||
int fg, bg, attr;
|
||||
|
||||
out_length = (strlen ((char *)string) * 2) + 1;
|
||||
out = (unsigned char *)malloc (out_length);
|
||||
if (!out)
|
||||
return NULL;
|
||||
|
||||
out_pos = 0;
|
||||
while (string[0] && (out_pos < out_length - 1))
|
||||
{
|
||||
switch (string[0])
|
||||
{
|
||||
case GUI_ATTR_BOLD_CHAR:
|
||||
case GUI_ATTR_RESET_CHAR:
|
||||
case GUI_ATTR_FIXED_CHAR:
|
||||
case GUI_ATTR_REVERSE_CHAR:
|
||||
case GUI_ATTR_REVERSE2_CHAR:
|
||||
case GUI_ATTR_ITALIC_CHAR:
|
||||
case GUI_ATTR_UNDERLINE_CHAR:
|
||||
if (keep_colors)
|
||||
out[out_pos++] = string[0];
|
||||
string++;
|
||||
break;
|
||||
case GUI_ATTR_COLOR_CHAR:
|
||||
string++;
|
||||
str_fg[0] = '\0';
|
||||
str_bg[0] = '\0';
|
||||
if (isdigit (string[0]))
|
||||
{
|
||||
str_fg[0] = string[0];
|
||||
str_fg[1] = '\0';
|
||||
string++;
|
||||
if (isdigit (string[0]))
|
||||
{
|
||||
str_fg[1] = string[0];
|
||||
str_fg[2] = '\0';
|
||||
string++;
|
||||
}
|
||||
}
|
||||
if (string[0] == ',')
|
||||
{
|
||||
string++;
|
||||
if (isdigit (string[0]))
|
||||
{
|
||||
str_bg[0] = string[0];
|
||||
str_bg[1] = '\0';
|
||||
string++;
|
||||
if (isdigit (string[0]))
|
||||
{
|
||||
str_bg[1] = string[0];
|
||||
str_bg[2] = '\0';
|
||||
string++;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (keep_colors)
|
||||
{
|
||||
if (!str_fg[0] && !str_bg[0])
|
||||
out[out_pos++] = GUI_ATTR_COLOR_CHAR;
|
||||
else
|
||||
{
|
||||
attr = 0;
|
||||
if (str_fg[0])
|
||||
{
|
||||
sscanf (str_fg, "%d", &fg);
|
||||
fg %= GUI_NUM_IRC_COLORS;
|
||||
attr |= gui_irc_colors[fg][1];
|
||||
}
|
||||
if (str_bg[0])
|
||||
{
|
||||
sscanf (str_bg, "%d", &bg);
|
||||
bg %= GUI_NUM_IRC_COLORS;
|
||||
attr |= gui_irc_colors[bg][1];
|
||||
}
|
||||
if (attr & A_BOLD)
|
||||
{
|
||||
out[out_pos++] = GUI_ATTR_WEECHAT_SET_CHAR;
|
||||
out[out_pos++] = GUI_ATTR_BOLD_CHAR;
|
||||
}
|
||||
else
|
||||
{
|
||||
out[out_pos++] = GUI_ATTR_WEECHAT_REMOVE_CHAR;
|
||||
out[out_pos++] = GUI_ATTR_BOLD_CHAR;
|
||||
}
|
||||
out[out_pos++] = GUI_ATTR_COLOR_CHAR;
|
||||
if (str_fg[0])
|
||||
{
|
||||
out[out_pos++] = (gui_irc_colors[fg][0] / 10) + '0';
|
||||
out[out_pos++] = (gui_irc_colors[fg][0] % 10) + '0';
|
||||
}
|
||||
if (str_bg[0])
|
||||
{
|
||||
out[out_pos++] = ',';
|
||||
out[out_pos++] = (gui_irc_colors[bg][0] / 10) + '0';
|
||||
out[out_pos++] = (gui_irc_colors[bg][0] % 10) + '0';
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
case GUI_ATTR_WEECHAT_COLOR_CHAR:
|
||||
string++;
|
||||
if (isdigit (string[0]) && isdigit (string[1]))
|
||||
{
|
||||
if (keep_colors)
|
||||
{
|
||||
out[out_pos++] = string[0];
|
||||
out[out_pos++] = string[1];
|
||||
}
|
||||
string += 2;
|
||||
}
|
||||
break;
|
||||
case GUI_ATTR_WEECHAT_SET_CHAR:
|
||||
case GUI_ATTR_WEECHAT_REMOVE_CHAR:
|
||||
string++;
|
||||
if (string[0])
|
||||
{
|
||||
if (keep_colors)
|
||||
{
|
||||
out[out_pos++] = *(string - 1);
|
||||
out[out_pos++] = string[0];
|
||||
}
|
||||
string++;
|
||||
}
|
||||
break;
|
||||
default:
|
||||
out[out_pos++] = string[0];
|
||||
string++;
|
||||
}
|
||||
}
|
||||
out[out_pos] = '\0';
|
||||
return out;
|
||||
}
|
||||
|
||||
/*
|
||||
* gui_color_decode_for_user_entry: parses a message (coming from IRC server),
|
||||
* and replaces colors/bold/.. by %C, %B, ..
|
||||
* After use, string returned has to be free()
|
||||
*/
|
||||
|
||||
unsigned char *
|
||||
gui_color_decode_for_user_entry (unsigned char *string)
|
||||
{
|
||||
unsigned char *out;
|
||||
int out_length, out_pos;
|
||||
|
||||
out_length = (strlen ((char *)string) * 2) + 1;
|
||||
out = (unsigned char *)malloc (out_length);
|
||||
if (!out)
|
||||
return NULL;
|
||||
|
||||
out_pos = 0;
|
||||
while (string[0] && (out_pos < out_length - 1))
|
||||
{
|
||||
switch (string[0])
|
||||
{
|
||||
case GUI_ATTR_BOLD_CHAR:
|
||||
out[out_pos++] = '%';
|
||||
out[out_pos++] = 'B';
|
||||
string++;
|
||||
break;
|
||||
case GUI_ATTR_FIXED_CHAR:
|
||||
string++;
|
||||
break;
|
||||
case GUI_ATTR_RESET_CHAR:
|
||||
out[out_pos++] = '%';
|
||||
out[out_pos++] = 'O';
|
||||
string++;
|
||||
break;
|
||||
case GUI_ATTR_REVERSE_CHAR:
|
||||
case GUI_ATTR_REVERSE2_CHAR:
|
||||
out[out_pos++] = '%';
|
||||
out[out_pos++] = 'R';
|
||||
string++;
|
||||
break;
|
||||
case GUI_ATTR_ITALIC_CHAR:
|
||||
string++;
|
||||
break;
|
||||
case GUI_ATTR_UNDERLINE_CHAR:
|
||||
out[out_pos++] = '%';
|
||||
out[out_pos++] = 'R';
|
||||
string++;
|
||||
break;
|
||||
case GUI_ATTR_COLOR_CHAR:
|
||||
out[out_pos++] = '%';
|
||||
out[out_pos++] = 'C';
|
||||
string++;
|
||||
break;
|
||||
default:
|
||||
out[out_pos++] = string[0];
|
||||
string++;
|
||||
}
|
||||
}
|
||||
out[out_pos] = '\0';
|
||||
return out;
|
||||
}
|
||||
|
||||
/*
|
||||
* gui_color_encode: parses a message (entered by user), and
|
||||
* encode special chars (%B, %C, ..) in IRC colors
|
||||
* After use, string returned has to be free()
|
||||
*/
|
||||
|
||||
unsigned char *
|
||||
gui_color_encode (unsigned char *string)
|
||||
{
|
||||
unsigned char *out;
|
||||
int out_length, out_pos;
|
||||
|
||||
out_length = (strlen ((char *)string) * 2) + 1;
|
||||
out = (unsigned char *)malloc (out_length);
|
||||
if (!out)
|
||||
return NULL;
|
||||
|
||||
out_pos = 0;
|
||||
while (string[0] && (out_pos < out_length - 1))
|
||||
{
|
||||
switch (string[0])
|
||||
{
|
||||
case '%':
|
||||
string++;
|
||||
switch (string[0])
|
||||
{
|
||||
case '\0':
|
||||
out[out_pos++] = '%';
|
||||
break;
|
||||
case '%': /* double '%' replaced by single '%' */
|
||||
out[out_pos++] = string[0];
|
||||
string++;
|
||||
break;
|
||||
case 'B': /* bold */
|
||||
out[out_pos++] = GUI_ATTR_BOLD_CHAR;
|
||||
string++;
|
||||
break;
|
||||
case 'C': /* color */
|
||||
out[out_pos++] = GUI_ATTR_COLOR_CHAR;
|
||||
string++;
|
||||
if (isdigit (string[0]))
|
||||
{
|
||||
out[out_pos++] = string[0];
|
||||
string++;
|
||||
if (isdigit (string[0]))
|
||||
{
|
||||
out[out_pos++] = string[0];
|
||||
string++;
|
||||
}
|
||||
}
|
||||
if (string[0] == ',')
|
||||
{
|
||||
out[out_pos++] = ',';
|
||||
string++;
|
||||
if (isdigit (string[0]))
|
||||
{
|
||||
out[out_pos++] = string[0];
|
||||
string++;
|
||||
if (isdigit (string[0]))
|
||||
{
|
||||
out[out_pos++] = string[0];
|
||||
string++;
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
case 'O': /* reset */
|
||||
out[out_pos++] = GUI_ATTR_RESET_CHAR;
|
||||
string++;
|
||||
break;
|
||||
case 'R': /* reverse */
|
||||
out[out_pos++] = GUI_ATTR_REVERSE_CHAR;
|
||||
string++;
|
||||
break;
|
||||
case 'U': /* underline */
|
||||
out[out_pos++] = GUI_ATTR_UNDERLINE_CHAR;
|
||||
string++;
|
||||
break;
|
||||
default:
|
||||
out[out_pos++] = '%';
|
||||
out[out_pos++] = string[0];
|
||||
string++;
|
||||
}
|
||||
break;
|
||||
default:
|
||||
out[out_pos++] = string[0];
|
||||
string++;
|
||||
}
|
||||
}
|
||||
out[out_pos] = '\0';
|
||||
return out;
|
||||
}
|
||||
|
||||
/*
|
||||
* gui_color_build: build a WeeChat color with foreground,
|
||||
* background and attributes (attributes are
|
||||
* given with foreground color, with a OR)
|
||||
*/
|
||||
|
||||
t_gui_color *
|
||||
gui_color_build (int number, int foreground, int background)
|
||||
{
|
||||
t_gui_color *new_color;
|
||||
|
||||
new_color = (t_gui_color *)malloc (sizeof (t_gui_color));
|
||||
if (!new_color)
|
||||
return NULL;
|
||||
|
||||
new_color->foreground = gui_weechat_colors[foreground].foreground;
|
||||
new_color->background = gui_weechat_colors[background].foreground;
|
||||
new_color->attributes = gui_weechat_colors[foreground].attributes;
|
||||
new_color->string = (char *)malloc (4);
|
||||
if (new_color->string)
|
||||
snprintf (new_color->string, 4,
|
||||
"%s%02d",
|
||||
GUI_ATTR_WEECHAT_COLOR_STR, number);
|
||||
|
||||
return new_color;
|
||||
}
|
||||
|
||||
/*
|
||||
* gui_color_get_pair: get color pair with a WeeChat color number
|
||||
*/
|
||||
|
||||
int
|
||||
gui_color_get_pair (int num_color)
|
||||
{
|
||||
int fg, bg;
|
||||
|
||||
if ((num_color < 0) || (num_color > GUI_NUM_COLORS - 1))
|
||||
return WEECHAT_COLOR_WHITE;
|
||||
|
||||
fg = gui_color[num_color]->foreground;
|
||||
bg = gui_color[num_color]->background;
|
||||
|
||||
if (((fg == -1) || (fg == 99))
|
||||
&& ((bg == -1) || (bg == 99)))
|
||||
return 63;
|
||||
if ((fg == -1) || (fg == 99))
|
||||
fg = WEECHAT_COLOR_WHITE;
|
||||
if ((bg == -1) || (bg == 99))
|
||||
bg = 0;
|
||||
|
||||
return (bg * 8) + fg;
|
||||
}
|
||||
|
||||
/*
|
||||
* gui_color_init_pairs: init color pairs
|
||||
*/
|
||||
|
||||
void
|
||||
gui_color_init_pairs ()
|
||||
{
|
||||
int i;
|
||||
char shift_colors[8] = { 0, 4, 2, 6, 1, 5, 3, 7 };
|
||||
|
||||
if (has_colors ())
|
||||
{
|
||||
for (i = 1; i < 64; i++)
|
||||
init_pair (i, shift_colors[i % 8], (i < 8) ? -1 : shift_colors[i / 8]);
|
||||
|
||||
/* disable white on white, replaced by black on white */
|
||||
init_pair (63, -1, -1);
|
||||
|
||||
/* white on default bg is default (-1) */
|
||||
if (!cfg_col_real_white)
|
||||
init_pair (WEECHAT_COLOR_WHITE, -1, -1);
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* gui_color_init_weechat: init WeeChat colors
|
||||
*/
|
||||
|
||||
void
|
||||
gui_color_init_weechat ()
|
||||
{
|
||||
int i;
|
||||
|
||||
gui_color[COLOR_WIN_SEPARATOR] = gui_color_build (COLOR_WIN_SEPARATOR, cfg_col_separator, cfg_col_separator);
|
||||
gui_color[COLOR_WIN_TITLE] = gui_color_build (COLOR_WIN_TITLE, cfg_col_title, cfg_col_title_bg);
|
||||
gui_color[COLOR_WIN_CHAT] = gui_color_build (COLOR_WIN_CHAT, cfg_col_chat, cfg_col_chat_bg);
|
||||
gui_color[COLOR_WIN_CHAT_TIME] = gui_color_build (COLOR_WIN_CHAT_TIME, cfg_col_chat_time, cfg_col_chat_bg);
|
||||
gui_color[COLOR_WIN_CHAT_TIME_SEP] = gui_color_build (COLOR_WIN_CHAT_TIME_SEP, cfg_col_chat_time_sep, cfg_col_chat_bg);
|
||||
gui_color[COLOR_WIN_CHAT_PREFIX1] = gui_color_build (COLOR_WIN_CHAT_PREFIX1, cfg_col_chat_prefix1, cfg_col_chat_bg);
|
||||
gui_color[COLOR_WIN_CHAT_PREFIX2] = gui_color_build (COLOR_WIN_CHAT_PREFIX2, cfg_col_chat_prefix2, cfg_col_chat_bg);
|
||||
gui_color[COLOR_WIN_CHAT_SERVER] = gui_color_build (COLOR_WIN_CHAT_SERVER, cfg_col_chat_server, cfg_col_chat_bg);
|
||||
gui_color[COLOR_WIN_CHAT_JOIN] = gui_color_build (COLOR_WIN_CHAT_JOIN, cfg_col_chat_join, cfg_col_chat_bg);
|
||||
gui_color[COLOR_WIN_CHAT_PART] = gui_color_build (COLOR_WIN_CHAT_PART, cfg_col_chat_part, cfg_col_chat_bg);
|
||||
gui_color[COLOR_WIN_CHAT_NICK] = gui_color_build (COLOR_WIN_CHAT_NICK, cfg_col_chat_nick, cfg_col_chat_bg);
|
||||
gui_color[COLOR_WIN_CHAT_HOST] = gui_color_build (COLOR_WIN_CHAT_HOST, cfg_col_chat_host, cfg_col_chat_bg);
|
||||
gui_color[COLOR_WIN_CHAT_CHANNEL] = gui_color_build (COLOR_WIN_CHAT_CHANNEL, cfg_col_chat_channel, cfg_col_chat_bg);
|
||||
gui_color[COLOR_WIN_CHAT_DARK] = gui_color_build (COLOR_WIN_CHAT_DARK, cfg_col_chat_dark, cfg_col_chat_bg);
|
||||
gui_color[COLOR_WIN_CHAT_HIGHLIGHT] = gui_color_build (COLOR_WIN_CHAT_HIGHLIGHT, cfg_col_chat_highlight, cfg_col_chat_bg);
|
||||
gui_color[COLOR_WIN_CHAT_READ_MARKER] = gui_color_build (COLOR_WIN_CHAT_READ_MARKER, cfg_col_chat_read_marker, cfg_col_chat_read_marker_bg);
|
||||
gui_color[COLOR_WIN_STATUS] = gui_color_build (COLOR_WIN_STATUS, cfg_col_status, cfg_col_status_bg);
|
||||
gui_color[COLOR_WIN_STATUS_DELIMITERS] = gui_color_build (COLOR_WIN_STATUS_DELIMITERS, cfg_col_status_delimiters, cfg_col_status_bg);
|
||||
gui_color[COLOR_WIN_STATUS_CHANNEL] = gui_color_build (COLOR_WIN_STATUS_CHANNEL, cfg_col_status_channel, cfg_col_status_bg);
|
||||
gui_color[COLOR_WIN_STATUS_DATA_MSG] = gui_color_build (COLOR_WIN_STATUS_DATA_MSG, cfg_col_status_data_msg, cfg_col_status_bg);
|
||||
gui_color[COLOR_WIN_STATUS_DATA_PRIVATE] = gui_color_build (COLOR_WIN_STATUS_DATA_PRIVATE, cfg_col_status_data_private, cfg_col_status_bg);
|
||||
gui_color[COLOR_WIN_STATUS_DATA_HIGHLIGHT] = gui_color_build (COLOR_WIN_STATUS_DATA_HIGHLIGHT, cfg_col_status_data_highlight, cfg_col_status_bg);
|
||||
gui_color[COLOR_WIN_STATUS_DATA_OTHER] = gui_color_build (COLOR_WIN_STATUS_DATA_OTHER, cfg_col_status_data_other, cfg_col_status_bg);
|
||||
gui_color[COLOR_WIN_STATUS_MORE] = gui_color_build (COLOR_WIN_STATUS_MORE, cfg_col_status_more, cfg_col_status_bg);
|
||||
gui_color[COLOR_WIN_INFOBAR] = gui_color_build (COLOR_WIN_INFOBAR, cfg_col_infobar, cfg_col_infobar_bg);
|
||||
gui_color[COLOR_WIN_INFOBAR_DELIMITERS] = gui_color_build (COLOR_WIN_INFOBAR_DELIMITERS, cfg_col_infobar_delimiters, cfg_col_infobar_bg);
|
||||
gui_color[COLOR_WIN_INFOBAR_HIGHLIGHT] = gui_color_build (COLOR_WIN_INFOBAR_HIGHLIGHT, cfg_col_infobar_highlight, cfg_col_infobar_bg);
|
||||
gui_color[COLOR_WIN_INPUT] = gui_color_build (COLOR_WIN_INPUT, cfg_col_input, cfg_col_input_bg);
|
||||
gui_color[COLOR_WIN_INPUT_SERVER] = gui_color_build (COLOR_WIN_INPUT_SERVER, cfg_col_input_server, cfg_col_input_bg);
|
||||
gui_color[COLOR_WIN_INPUT_CHANNEL] = gui_color_build (COLOR_WIN_INPUT_CHANNEL, cfg_col_input_channel, cfg_col_input_bg);
|
||||
gui_color[COLOR_WIN_INPUT_NICK] = gui_color_build (COLOR_WIN_INPUT_NICK, cfg_col_input_nick, cfg_col_input_bg);
|
||||
gui_color[COLOR_WIN_INPUT_DELIMITERS] = gui_color_build (COLOR_WIN_INPUT_DELIMITERS, cfg_col_input_delimiters, cfg_col_input_bg);
|
||||
gui_color[COLOR_WIN_NICK] = gui_color_build (COLOR_WIN_NICK, cfg_col_nick, cfg_col_nick_bg);
|
||||
gui_color[COLOR_WIN_NICK_AWAY] = gui_color_build (COLOR_WIN_NICK_AWAY, cfg_col_nick_away, cfg_col_nick_bg);
|
||||
gui_color[COLOR_WIN_NICK_CHANOWNER] = gui_color_build (COLOR_WIN_NICK_CHANOWNER, cfg_col_nick_chanowner, cfg_col_nick_bg);
|
||||
gui_color[COLOR_WIN_NICK_CHANADMIN] = gui_color_build (COLOR_WIN_NICK_CHANADMIN, cfg_col_nick_chanadmin, cfg_col_nick_bg);
|
||||
gui_color[COLOR_WIN_NICK_OP] = gui_color_build (COLOR_WIN_NICK_OP, cfg_col_nick_op, cfg_col_nick_bg);
|
||||
gui_color[COLOR_WIN_NICK_HALFOP] = gui_color_build (COLOR_WIN_NICK_HALFOP, cfg_col_nick_halfop, cfg_col_nick_bg);
|
||||
gui_color[COLOR_WIN_NICK_VOICE] = gui_color_build (COLOR_WIN_NICK_VOICE, cfg_col_nick_voice, cfg_col_nick_bg);
|
||||
gui_color[COLOR_WIN_NICK_MORE] = gui_color_build (COLOR_WIN_NICK_MORE, cfg_col_nick_more, cfg_col_nick_bg);
|
||||
gui_color[COLOR_WIN_NICK_SEP] = gui_color_build (COLOR_WIN_NICK_SEP, cfg_col_nick_sep, cfg_col_nick_bg);
|
||||
gui_color[COLOR_WIN_NICK_SELF] = gui_color_build (COLOR_WIN_NICK_SELF, cfg_col_nick_self, cfg_col_nick_bg);
|
||||
gui_color[COLOR_WIN_NICK_PRIVATE] = gui_color_build (COLOR_WIN_NICK_PRIVATE, cfg_col_nick_private, cfg_col_nick_bg);
|
||||
|
||||
for (i = 0; i < COLOR_WIN_NICK_NUMBER; i++)
|
||||
{
|
||||
gui_color[COLOR_WIN_NICK_1 + i] = gui_color_build (COLOR_WIN_NICK_1 + i, cfg_col_nick_colors[i], cfg_col_chat_bg);
|
||||
}
|
||||
|
||||
gui_color[COLOR_DCC_SELECTED] = gui_color_build (COLOR_DCC_SELECTED, cfg_col_dcc_selected, cfg_col_chat_bg);
|
||||
gui_color[COLOR_DCC_WAITING] = gui_color_build (COLOR_DCC_WAITING, cfg_col_dcc_waiting, cfg_col_chat_bg);
|
||||
gui_color[COLOR_DCC_CONNECTING] = gui_color_build (COLOR_DCC_CONNECTING, cfg_col_dcc_connecting, cfg_col_chat_bg);
|
||||
gui_color[COLOR_DCC_ACTIVE] = gui_color_build (COLOR_DCC_ACTIVE, cfg_col_dcc_active, cfg_col_chat_bg);
|
||||
gui_color[COLOR_DCC_DONE] = gui_color_build (COLOR_DCC_DONE, cfg_col_dcc_done, cfg_col_chat_bg);
|
||||
gui_color[COLOR_DCC_FAILED] = gui_color_build (COLOR_DCC_FAILED, cfg_col_dcc_failed, cfg_col_chat_bg);
|
||||
gui_color[COLOR_DCC_ABORTED] = gui_color_build (COLOR_DCC_ABORTED, cfg_col_dcc_aborted, cfg_col_chat_bg);
|
||||
}
|
||||
|
||||
/*
|
||||
* gui_color_rebuild_weechat: rebuild WeeChat colors
|
||||
*/
|
||||
|
||||
void
|
||||
gui_color_rebuild_weechat ()
|
||||
{
|
||||
int i;
|
||||
|
||||
if (has_colors ())
|
||||
{
|
||||
for (i = 0; i < GUI_NUM_COLORS; i++)
|
||||
{
|
||||
if (gui_color[i])
|
||||
{
|
||||
if (gui_color[i]->string)
|
||||
free (gui_color[i]->string);
|
||||
free (gui_color[i]);
|
||||
gui_color[i] = NULL;
|
||||
}
|
||||
}
|
||||
gui_color_init_weechat ();
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* gui_color_init: init GUI colors
|
||||
*/
|
||||
|
||||
void
|
||||
gui_color_init ()
|
||||
{
|
||||
if (has_colors ())
|
||||
{
|
||||
start_color ();
|
||||
use_default_colors ();
|
||||
}
|
||||
gui_color_init_pairs ();
|
||||
gui_color_init_weechat ();
|
||||
}
|
||||
@@ -0,0 +1,131 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
/* gui-curses-infobar.c: infobar display functions for Curses GUI */
|
||||
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
#include "../../common/weechat.h"
|
||||
#include "../gui.h"
|
||||
#include "../../common/hotlist.h"
|
||||
#include "../../common/weeconfig.h"
|
||||
#include "gui-curses.h"
|
||||
|
||||
|
||||
/*
|
||||
* gui_infobar_draw_time: draw time in infobar window
|
||||
*/
|
||||
|
||||
void
|
||||
gui_infobar_draw_time (t_gui_buffer *buffer)
|
||||
{
|
||||
t_gui_window *ptr_win;
|
||||
time_t time_seconds;
|
||||
struct tm *local_time;
|
||||
|
||||
/* make gcc happy */
|
||||
(void) buffer;
|
||||
|
||||
if (!gui_ok)
|
||||
return;
|
||||
|
||||
for (ptr_win = gui_windows; ptr_win; ptr_win = ptr_win->next_window)
|
||||
{
|
||||
time_seconds = time (NULL);
|
||||
local_time = localtime (&time_seconds);
|
||||
if (local_time)
|
||||
{
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_infobar, COLOR_WIN_INFOBAR);
|
||||
mvwprintw (GUI_CURSES(ptr_win)->win_infobar,
|
||||
0, 1,
|
||||
"%02d:%02d",
|
||||
local_time->tm_hour, local_time->tm_min);
|
||||
if (cfg_look_infobar_seconds)
|
||||
wprintw (GUI_CURSES(ptr_win)->win_infobar,
|
||||
":%02d",
|
||||
local_time->tm_sec);
|
||||
}
|
||||
wnoutrefresh (GUI_CURSES(ptr_win)->win_infobar);
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* gui_infobar_draw: draw infobar window for a buffer
|
||||
*/
|
||||
|
||||
void
|
||||
gui_infobar_draw (t_gui_buffer *buffer, int erase)
|
||||
{
|
||||
t_gui_window *ptr_win;
|
||||
time_t time_seconds;
|
||||
struct tm *local_time;
|
||||
char text_time[1024 + 1];
|
||||
|
||||
/* make gcc happy */
|
||||
(void) buffer;
|
||||
|
||||
if (!gui_ok)
|
||||
return;
|
||||
|
||||
for (ptr_win = gui_windows; ptr_win; ptr_win = ptr_win->next_window)
|
||||
{
|
||||
if (erase)
|
||||
gui_window_curses_clear (GUI_CURSES(ptr_win)->win_infobar, COLOR_WIN_INFOBAR);
|
||||
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_infobar, COLOR_WIN_INFOBAR);
|
||||
|
||||
time_seconds = time (NULL);
|
||||
local_time = localtime (&time_seconds);
|
||||
if (local_time)
|
||||
{
|
||||
strftime (text_time, 1024, cfg_look_infobar_timestamp, local_time);
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_infobar, COLOR_WIN_INFOBAR_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_infobar, "[");
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_infobar, COLOR_WIN_INFOBAR);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_infobar,
|
||||
"%02d:%02d",
|
||||
local_time->tm_hour, local_time->tm_min);
|
||||
if (cfg_look_infobar_seconds)
|
||||
wprintw (GUI_CURSES(ptr_win)->win_infobar,
|
||||
":%02d",
|
||||
local_time->tm_sec);
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_infobar, COLOR_WIN_INFOBAR_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_infobar, "]");
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_infobar, COLOR_WIN_INFOBAR);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_infobar,
|
||||
" %s", text_time);
|
||||
}
|
||||
if (gui_infobar)
|
||||
{
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_infobar, COLOR_WIN_INFOBAR_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_infobar, " | ");
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_infobar, gui_infobar->color);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_infobar, "%s", gui_infobar->text);
|
||||
}
|
||||
|
||||
wnoutrefresh (GUI_CURSES(ptr_win)->win_infobar);
|
||||
refresh ();
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,446 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
/* gui-curses-input: input display functions for Curses GUI */
|
||||
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include <stdlib.h>
|
||||
|
||||
#include "../../common/weechat.h"
|
||||
#include "../gui.h"
|
||||
#include "../../common/utf8.h"
|
||||
#include "../../common/weeconfig.h"
|
||||
#include "gui-curses.h"
|
||||
|
||||
#ifdef PLUGINS
|
||||
#include "../../plugins/plugins.h"
|
||||
#endif
|
||||
|
||||
|
||||
/*
|
||||
* gui_input_set_color: set color for an input window
|
||||
*/
|
||||
|
||||
void
|
||||
gui_input_set_color (t_gui_window *window, int irc_color)
|
||||
{
|
||||
int fg, bg;
|
||||
|
||||
fg = gui_irc_colors[irc_color][0];
|
||||
bg = gui_color[COLOR_WIN_INPUT]->background;
|
||||
|
||||
irc_color %= GUI_NUM_IRC_COLORS;
|
||||
if (gui_irc_colors[irc_color][1] & A_BOLD)
|
||||
wattron (GUI_CURSES(window)->win_input, A_BOLD);
|
||||
|
||||
if (((fg == -1) || (fg == 99))
|
||||
&& ((bg == -1) || (bg == 99)))
|
||||
wattron (GUI_CURSES(window)->win_input, COLOR_PAIR(63));
|
||||
else
|
||||
{
|
||||
if ((fg == -1) || (fg == 99))
|
||||
fg = WEECHAT_COLOR_WHITE;
|
||||
if ((bg == -1) || (bg == 99))
|
||||
bg = 0;
|
||||
wattron (GUI_CURSES(window)->win_input, COLOR_PAIR((bg * 8) + fg));
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* gui_input_get_prompt_length: return input prompt length (displayed on screen)
|
||||
*/
|
||||
|
||||
int
|
||||
gui_input_get_prompt_length (t_gui_window *window, char *nick)
|
||||
{
|
||||
char *pos, saved_char, *modes;
|
||||
int char_size, length, mode_found;
|
||||
|
||||
length = 0;
|
||||
pos = cfg_look_input_format;
|
||||
while (pos && pos[0])
|
||||
{
|
||||
switch (pos[0])
|
||||
{
|
||||
case '%':
|
||||
pos++;
|
||||
switch (pos[0])
|
||||
{
|
||||
case 'c':
|
||||
if (CHANNEL(window->buffer))
|
||||
length += utf8_strlen (CHANNEL(window->buffer)->name);
|
||||
else
|
||||
{
|
||||
if (SERVER(window->buffer))
|
||||
length += utf8_strlen (SERVER(window->buffer)->name);
|
||||
}
|
||||
pos++;
|
||||
break;
|
||||
case 'm':
|
||||
if (SERVER(window->buffer))
|
||||
{
|
||||
mode_found = 0;
|
||||
for (modes = SERVER(window->buffer)->nick_modes;
|
||||
modes && modes[0]; modes++)
|
||||
{
|
||||
if (modes[0] != ' ')
|
||||
{
|
||||
length++;
|
||||
mode_found = 1;
|
||||
}
|
||||
}
|
||||
if (mode_found)
|
||||
length++;
|
||||
}
|
||||
pos++;
|
||||
break;
|
||||
case 'n':
|
||||
length += utf8_strlen (nick);
|
||||
pos++;
|
||||
break;
|
||||
default:
|
||||
length++;
|
||||
if (pos[0])
|
||||
{
|
||||
if (pos[0] == '%')
|
||||
pos++;
|
||||
else
|
||||
{
|
||||
length++;
|
||||
pos += utf8_char_size (pos);
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
break;
|
||||
default:
|
||||
char_size = utf8_char_size (pos);
|
||||
saved_char = pos[char_size];
|
||||
pos[char_size] = '\0';
|
||||
length += utf8_width_screen (pos);
|
||||
pos[char_size] = saved_char;
|
||||
pos += char_size;
|
||||
break;
|
||||
}
|
||||
}
|
||||
return length;
|
||||
}
|
||||
|
||||
/*
|
||||
* gui_input_draw_prompt: display input prompt
|
||||
* return: # chars displayed on screen (one UTF-8 char
|
||||
* may be displayed on more than 1 char on screen)
|
||||
*/
|
||||
|
||||
void
|
||||
gui_input_draw_prompt (t_gui_window *window, char *nick)
|
||||
{
|
||||
char *pos, saved_char, *modes;
|
||||
int char_size, mode_found;
|
||||
|
||||
wmove (GUI_CURSES(window)->win_input, 0, 0);
|
||||
pos = cfg_look_input_format;
|
||||
while (pos && pos[0])
|
||||
{
|
||||
switch (pos[0])
|
||||
{
|
||||
case '%':
|
||||
pos++;
|
||||
switch (pos[0])
|
||||
{
|
||||
case 'c':
|
||||
if (CHANNEL(window->buffer))
|
||||
{
|
||||
gui_window_set_weechat_color (GUI_CURSES(window)->win_input,
|
||||
COLOR_WIN_INPUT_CHANNEL);
|
||||
wprintw (GUI_CURSES(window)->win_input, "%s",
|
||||
CHANNEL(window->buffer)->name);
|
||||
}
|
||||
else
|
||||
{
|
||||
if (SERVER(window->buffer))
|
||||
{
|
||||
gui_window_set_weechat_color (GUI_CURSES(window)->win_input,
|
||||
COLOR_WIN_INPUT_SERVER);
|
||||
wprintw (GUI_CURSES(window)->win_input, "%s",
|
||||
SERVER(window->buffer)->name);
|
||||
}
|
||||
}
|
||||
pos++;
|
||||
break;
|
||||
case 'm':
|
||||
if (SERVER(window->buffer))
|
||||
{
|
||||
mode_found = 0;
|
||||
for (modes = SERVER(window->buffer)->nick_modes;
|
||||
modes && modes[0]; modes++)
|
||||
{
|
||||
if (modes[0] != ' ')
|
||||
mode_found = 1;
|
||||
}
|
||||
if (mode_found)
|
||||
{
|
||||
gui_window_set_weechat_color (GUI_CURSES(window)->win_input,
|
||||
COLOR_WIN_INPUT);
|
||||
wprintw (GUI_CURSES(window)->win_input, "+");
|
||||
for (modes = SERVER(window->buffer)->nick_modes;
|
||||
modes && modes[0]; modes++)
|
||||
{
|
||||
if (modes[0] != ' ')
|
||||
wprintw (GUI_CURSES(window)->win_input, "%c",
|
||||
modes[0]);
|
||||
}
|
||||
}
|
||||
}
|
||||
pos++;
|
||||
break;
|
||||
case 'n':
|
||||
gui_window_set_weechat_color (GUI_CURSES(window)->win_input,
|
||||
COLOR_WIN_INPUT_NICK);
|
||||
wprintw (GUI_CURSES(window)->win_input, "%s", nick);
|
||||
pos++;
|
||||
break;
|
||||
default:
|
||||
if (pos[0])
|
||||
{
|
||||
char_size = utf8_char_size (pos);
|
||||
saved_char = pos[char_size];
|
||||
pos[char_size] = '\0';
|
||||
gui_window_set_weechat_color (GUI_CURSES(window)->win_input,
|
||||
COLOR_WIN_INPUT_DELIMITERS);
|
||||
wprintw (GUI_CURSES(window)->win_input, "%%%s", pos);
|
||||
pos[char_size] = saved_char;
|
||||
pos += char_size;
|
||||
}
|
||||
else
|
||||
{
|
||||
wprintw (GUI_CURSES(window)->win_input, "%%");
|
||||
pos++;
|
||||
}
|
||||
break;
|
||||
}
|
||||
break;
|
||||
default:
|
||||
char_size = utf8_char_size (pos);
|
||||
saved_char = pos[char_size];
|
||||
pos[char_size] = '\0';
|
||||
gui_window_set_weechat_color (GUI_CURSES(window)->win_input,
|
||||
COLOR_WIN_INPUT_DELIMITERS);
|
||||
wprintw (GUI_CURSES(window)->win_input, "%s", pos);
|
||||
pos[char_size] = saved_char;
|
||||
pos += char_size;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* gui_input_draw_text: display text in input buffer, according to color mask
|
||||
* return: offset for cursor position on screen (one UTF-8
|
||||
* char may be displayed on more than 1 char on screen)
|
||||
*/
|
||||
|
||||
int
|
||||
gui_input_draw_text (t_gui_window *window, int input_width)
|
||||
{
|
||||
char *ptr_start, *ptr_next, saved_char;
|
||||
int pos_mask, size, last_color, color, count_cursor, offset_cursor;
|
||||
|
||||
ptr_start = utf8_add_offset (window->buffer->input_buffer,
|
||||
window->buffer->input_buffer_1st_display);
|
||||
pos_mask = ptr_start - window->buffer->input_buffer;
|
||||
last_color = -1;
|
||||
count_cursor = window->buffer->input_buffer_pos -
|
||||
window->buffer->input_buffer_1st_display;
|
||||
offset_cursor = 0;
|
||||
while ((input_width > 0) && ptr_start && ptr_start[0])
|
||||
{
|
||||
ptr_next = utf8_next_char (ptr_start);
|
||||
if (ptr_next)
|
||||
{
|
||||
saved_char = ptr_next[0];
|
||||
ptr_next[0] = '\0';
|
||||
size = ptr_next - ptr_start;
|
||||
if (window->buffer->input_buffer_color_mask[pos_mask] != ' ')
|
||||
color = window->buffer->input_buffer_color_mask[pos_mask] - '0';
|
||||
else
|
||||
color = -1;
|
||||
if (color != last_color)
|
||||
{
|
||||
if (color == -1)
|
||||
gui_window_set_weechat_color (GUI_CURSES(window)->win_input, COLOR_WIN_INPUT);
|
||||
else
|
||||
gui_input_set_color (window, color);
|
||||
}
|
||||
last_color = color;
|
||||
wprintw (GUI_CURSES(window)->win_input, "%s", ptr_start);
|
||||
if (count_cursor > 0)
|
||||
{
|
||||
offset_cursor += utf8_width_screen (ptr_start);
|
||||
count_cursor--;
|
||||
}
|
||||
ptr_next[0] = saved_char;
|
||||
ptr_start = ptr_next;
|
||||
pos_mask += size;
|
||||
}
|
||||
else
|
||||
ptr_start = NULL;
|
||||
input_width--;
|
||||
}
|
||||
return offset_cursor;
|
||||
}
|
||||
|
||||
/*
|
||||
* gui_input_draw: draw input window for a buffer
|
||||
*/
|
||||
|
||||
void
|
||||
gui_input_draw (t_gui_buffer *buffer, int erase)
|
||||
{
|
||||
t_gui_window *ptr_win;
|
||||
char format[32];
|
||||
char *ptr_nickname;
|
||||
int prompt_length, display_prompt, offset_cursor;
|
||||
t_irc_dcc *dcc_selected;
|
||||
|
||||
if (!gui_ok)
|
||||
return;
|
||||
|
||||
for (ptr_win = gui_windows; ptr_win; ptr_win = ptr_win->next_window)
|
||||
{
|
||||
if (ptr_win->buffer == buffer)
|
||||
{
|
||||
if (erase)
|
||||
gui_window_curses_clear (GUI_CURSES(ptr_win)->win_input, COLOR_WIN_INPUT);
|
||||
|
||||
switch (buffer->type)
|
||||
{
|
||||
case BUFFER_TYPE_STANDARD:
|
||||
if (buffer->has_input)
|
||||
{
|
||||
if (buffer->input_buffer_length == 0)
|
||||
buffer->input_buffer[0] = '\0';
|
||||
|
||||
if (SERVER(buffer))
|
||||
ptr_nickname = (SERVER(buffer)->nick) ?
|
||||
SERVER(buffer)->nick : SERVER(buffer)->nick1;
|
||||
else
|
||||
ptr_nickname = cfg_look_no_nickname;
|
||||
|
||||
prompt_length = gui_input_get_prompt_length (ptr_win, ptr_nickname);
|
||||
|
||||
if (ptr_win->win_width - prompt_length < 3)
|
||||
{
|
||||
prompt_length = 0;
|
||||
display_prompt = 0;
|
||||
}
|
||||
else
|
||||
display_prompt = 1;
|
||||
|
||||
if (buffer->input_buffer_pos - buffer->input_buffer_1st_display + 1 >
|
||||
ptr_win->win_width - prompt_length)
|
||||
buffer->input_buffer_1st_display = buffer->input_buffer_pos -
|
||||
(ptr_win->win_width - prompt_length) + 1;
|
||||
else
|
||||
{
|
||||
if (buffer->input_buffer_pos < buffer->input_buffer_1st_display)
|
||||
buffer->input_buffer_1st_display = buffer->input_buffer_pos;
|
||||
else
|
||||
{
|
||||
if ((buffer->input_buffer_1st_display > 0) &&
|
||||
(buffer->input_buffer_pos -
|
||||
buffer->input_buffer_1st_display + 1)
|
||||
< ptr_win->win_width - prompt_length)
|
||||
{
|
||||
buffer->input_buffer_1st_display =
|
||||
buffer->input_buffer_pos -
|
||||
(ptr_win->win_width - prompt_length) + 1;
|
||||
if (buffer->input_buffer_1st_display < 0)
|
||||
buffer->input_buffer_1st_display = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (display_prompt)
|
||||
gui_input_draw_prompt (ptr_win, ptr_nickname);
|
||||
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_input, COLOR_WIN_INPUT);
|
||||
snprintf (format, 32, "%%-%ds", ptr_win->win_width - prompt_length);
|
||||
offset_cursor = 0;
|
||||
if (ptr_win == gui_current_window)
|
||||
offset_cursor = gui_input_draw_text (ptr_win,
|
||||
ptr_win->win_width - prompt_length);
|
||||
else
|
||||
wprintw (GUI_CURSES(ptr_win)->win_input, format, "");
|
||||
wclrtoeol (GUI_CURSES(ptr_win)->win_input);
|
||||
ptr_win->win_input_x = prompt_length + offset_cursor;
|
||||
if (ptr_win == gui_current_window)
|
||||
move (ptr_win->win_y + ptr_win->win_height - 1,
|
||||
ptr_win->win_x + ptr_win->win_input_x);
|
||||
}
|
||||
break;
|
||||
case BUFFER_TYPE_DCC:
|
||||
dcc_selected = (ptr_win->dcc_selected) ? (t_irc_dcc *) ptr_win->dcc_selected : dcc_list;
|
||||
wmove (GUI_CURSES(ptr_win)->win_input, 0, 0);
|
||||
if (dcc_selected)
|
||||
{
|
||||
switch (dcc_selected->status)
|
||||
{
|
||||
case DCC_WAITING:
|
||||
if (DCC_IS_RECV(dcc_selected->type))
|
||||
wprintw (GUI_CURSES(ptr_win)->win_input, _(" [A] Accept"));
|
||||
wprintw (GUI_CURSES(ptr_win)->win_input, _(" [C] Cancel"));
|
||||
break;
|
||||
case DCC_CONNECTING:
|
||||
case DCC_ACTIVE:
|
||||
wprintw (GUI_CURSES(ptr_win)->win_input, _(" [C] Cancel"));
|
||||
break;
|
||||
case DCC_DONE:
|
||||
case DCC_FAILED:
|
||||
case DCC_ABORTED:
|
||||
wprintw (GUI_CURSES(ptr_win)->win_input, _(" [R] Remove"));
|
||||
break;
|
||||
}
|
||||
}
|
||||
wprintw (GUI_CURSES(ptr_win)->win_input, _(" [P] Purge old DCC"));
|
||||
wprintw (GUI_CURSES(ptr_win)->win_input, _(" [Q] Close DCC view"));
|
||||
wclrtoeol (GUI_CURSES(ptr_win)->win_input);
|
||||
ptr_win->win_input_x = 0;
|
||||
if (ptr_win == gui_current_window)
|
||||
move (ptr_win->win_y + ptr_win->win_height - 1,
|
||||
ptr_win->win_x);
|
||||
break;
|
||||
case BUFFER_TYPE_RAW_DATA:
|
||||
mvwprintw (GUI_CURSES(ptr_win)->win_input, 0, 0, _(" [Q] Close raw data view"));
|
||||
wclrtoeol (GUI_CURSES(ptr_win)->win_input);
|
||||
ptr_win->win_input_x = 0;
|
||||
if (ptr_win == gui_current_window)
|
||||
move (ptr_win->win_y + ptr_win->win_height - 1,
|
||||
ptr_win->win_x);
|
||||
break;
|
||||
}
|
||||
doupdate ();
|
||||
wrefresh (GUI_CURSES(ptr_win)->win_input);
|
||||
refresh ();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,320 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
/* gui-curses-keyboard.c: keyboard functions for Curses GUI */
|
||||
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
#include "../../common/weechat.h"
|
||||
#include "../gui.h"
|
||||
#include "../../common/utf8.h"
|
||||
#include "gui-curses.h"
|
||||
|
||||
#ifdef PLUGINS
|
||||
#include "../../plugins/plugins.h"
|
||||
#endif
|
||||
|
||||
|
||||
/*
|
||||
* gui_keyboard_default_bindings: create default key bindings
|
||||
*/
|
||||
|
||||
void
|
||||
gui_keyboard_default_bindings ()
|
||||
{
|
||||
int i;
|
||||
char key_str[32], command[32];
|
||||
|
||||
/* keys binded with internal functions */
|
||||
gui_keyboard_bind ( /* RC */ "ctrl-M", "return");
|
||||
gui_keyboard_bind ( /* RC */ "ctrl-J", "return");
|
||||
gui_keyboard_bind ( /* tab */ "ctrl-I", "tab");
|
||||
gui_keyboard_bind ( /* s-tab */ "meta2-Z", "tab_previous");
|
||||
gui_keyboard_bind ( /* basckp */ "ctrl-H", "backspace");
|
||||
gui_keyboard_bind ( /* basckp */ "ctrl-?", "backspace");
|
||||
gui_keyboard_bind ( /* del */ "meta2-3~", "delete");
|
||||
gui_keyboard_bind ( /* ^K */ "ctrl-K", "delete_end_line");
|
||||
gui_keyboard_bind ( /* ^U */ "ctrl-U", "delete_beginning_line");
|
||||
gui_keyboard_bind ( /* ^W */ "ctrl-W", "delete_previous_word");
|
||||
gui_keyboard_bind ( /* ^Y */ "ctrl-Y", "clipboard_paste");
|
||||
gui_keyboard_bind ( /* ^T */ "ctrl-T", "transpose_chars");
|
||||
gui_keyboard_bind ( /* home */ "meta2-1~", "home");
|
||||
gui_keyboard_bind ( /* home */ "meta2-H", "home");
|
||||
gui_keyboard_bind ( /* home */ "meta2-7~", "home");
|
||||
gui_keyboard_bind ( /* ^A */ "ctrl-A", "home");
|
||||
gui_keyboard_bind ( /* end */ "meta2-4~", "end");
|
||||
gui_keyboard_bind ( /* end */ "meta2-F", "end");
|
||||
gui_keyboard_bind ( /* end */ "meta2-8~", "end");
|
||||
gui_keyboard_bind ( /* ^E */ "ctrl-E", "end");
|
||||
gui_keyboard_bind ( /* left */ "meta2-D", "left");
|
||||
gui_keyboard_bind ( /* right */ "meta2-C", "right");
|
||||
gui_keyboard_bind ( /* up */ "meta2-A", "up");
|
||||
gui_keyboard_bind ( /* ^up */ "meta-Oa", "up_global");
|
||||
gui_keyboard_bind ( /* down */ "meta2-B", "down");
|
||||
gui_keyboard_bind ( /* ^down */ "meta-Ob", "down_global");
|
||||
gui_keyboard_bind ( /* pgup */ "meta2-5~", "page_up");
|
||||
gui_keyboard_bind ( /* pgdn */ "meta2-6~", "page_down");
|
||||
gui_keyboard_bind ( /* m-pgup */ "meta-meta2-5~", "scroll_up");
|
||||
gui_keyboard_bind ( /* m-pgdn */ "meta-meta2-6~", "scroll_down");
|
||||
gui_keyboard_bind ( /* m-home */ "meta-meta2-1~", "scroll_top");
|
||||
gui_keyboard_bind ( /* m-end */ "meta-meta2-4~", "scroll_bottom");
|
||||
gui_keyboard_bind ( /* F10 */ "meta2-21~", "infobar_clear");
|
||||
gui_keyboard_bind ( /* F11 */ "meta2-23~", "nick_page_up");
|
||||
gui_keyboard_bind ( /* F12 */ "meta2-24~", "nick_page_down");
|
||||
gui_keyboard_bind ( /* m-F11 */ "meta-meta2-23~", "nick_beginning");
|
||||
gui_keyboard_bind ( /* m-F12 */ "meta-meta2-24~", "nick_end");
|
||||
gui_keyboard_bind ( /* ^L */ "ctrl-L", "refresh");
|
||||
gui_keyboard_bind ( /* m-a */ "meta-a", "jump_smart");
|
||||
gui_keyboard_bind ( /* m-b */ "meta-b", "previous_word");
|
||||
gui_keyboard_bind ( /* ^left */ "meta-Od", "previous_word");
|
||||
gui_keyboard_bind ( /* m-d */ "meta-d", "delete_next_word");
|
||||
gui_keyboard_bind ( /* m-f */ "meta-f", "next_word");
|
||||
gui_keyboard_bind ( /* ^right */ "meta-Oc", "next_word");
|
||||
gui_keyboard_bind ( /* m-h */ "meta-h", "hotlist_clear");
|
||||
gui_keyboard_bind ( /* m-j,m-d */ "meta-jmeta-d", "jump_dcc");
|
||||
gui_keyboard_bind ( /* m-j,m-l */ "meta-jmeta-l", "jump_last_buffer");
|
||||
gui_keyboard_bind ( /* m-j,m-s */ "meta-jmeta-s", "jump_server");
|
||||
gui_keyboard_bind ( /* m-j,m-x */ "meta-jmeta-x", "jump_next_server");
|
||||
gui_keyboard_bind ( /* m-j,m-r */ "meta-jmeta-r", "jump_raw_data");
|
||||
gui_keyboard_bind ( /* m-k */ "meta-k", "grab_key");
|
||||
gui_keyboard_bind ( /* m-n */ "meta-n", "scroll_next_highlight");
|
||||
gui_keyboard_bind ( /* m-p */ "meta-p", "scroll_previous_highlight");
|
||||
gui_keyboard_bind ( /* m-r */ "meta-r", "delete_line");
|
||||
gui_keyboard_bind ( /* m-s */ "meta-s", "switch_server");
|
||||
gui_keyboard_bind ( /* m-u */ "meta-u", "scroll_unread");
|
||||
|
||||
/* keys binded with commands */
|
||||
gui_keyboard_bind ( /* m-left */ "meta-meta2-D", "/buffer -1");
|
||||
gui_keyboard_bind ( /* F5 */ "meta2-15~", "/buffer -1");
|
||||
gui_keyboard_bind ( /* m-right */ "meta-meta2-C", "/buffer +1");
|
||||
gui_keyboard_bind ( /* F6 */ "meta2-17~", "/buffer +1");
|
||||
gui_keyboard_bind ( /* F7 */ "meta2-18~", "/window -1");
|
||||
gui_keyboard_bind ( /* F8 */ "meta2-19~", "/window +1");
|
||||
gui_keyboard_bind ( /* m-w,m-up */ "meta-wmeta-meta2-A", "/window up");
|
||||
gui_keyboard_bind ( /* m-w,m-down */ "meta-wmeta-meta2-B", "/window down");
|
||||
gui_keyboard_bind ( /* m-w,m-left */ "meta-wmeta-meta2-D", "/window left");
|
||||
gui_keyboard_bind ( /* m-w,m-right */ "meta-wmeta-meta2-C", "/window right");
|
||||
gui_keyboard_bind ( /* m-0 */ "meta-0", "/buffer 10");
|
||||
gui_keyboard_bind ( /* m-1 */ "meta-1", "/buffer 1");
|
||||
gui_keyboard_bind ( /* m-2 */ "meta-2", "/buffer 2");
|
||||
gui_keyboard_bind ( /* m-3 */ "meta-3", "/buffer 3");
|
||||
gui_keyboard_bind ( /* m-4 */ "meta-4", "/buffer 4");
|
||||
gui_keyboard_bind ( /* m-5 */ "meta-5", "/buffer 5");
|
||||
gui_keyboard_bind ( /* m-6 */ "meta-6", "/buffer 6");
|
||||
gui_keyboard_bind ( /* m-7 */ "meta-7", "/buffer 7");
|
||||
gui_keyboard_bind ( /* m-8 */ "meta-8", "/buffer 8");
|
||||
gui_keyboard_bind ( /* m-9 */ "meta-9", "/buffer 9");
|
||||
|
||||
/* bind meta-j + {01..99} to switch to buffers # > 10 */
|
||||
for (i = 1; i < 100; i++)
|
||||
{
|
||||
sprintf (key_str, "meta-j%02d", i);
|
||||
sprintf (command, "/buffer %d", i);
|
||||
gui_keyboard_bind (key_str, command);
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* gui_keyboard_grab_end: insert grabbed key in input buffer
|
||||
*/
|
||||
|
||||
void
|
||||
gui_keyboard_grab_end ()
|
||||
{
|
||||
char *expanded_key, *expanded_key2;
|
||||
int length;
|
||||
char *buffer_before_key;
|
||||
|
||||
/* get expanded name (for example: ^U => ctrl-u) */
|
||||
expanded_key = gui_keyboard_get_expanded_name (gui_key_buffer);
|
||||
|
||||
if (expanded_key)
|
||||
{
|
||||
if (gui_current_window->buffer->has_input)
|
||||
{
|
||||
buffer_before_key =
|
||||
(gui_current_window->buffer->input_buffer) ?
|
||||
strdup (gui_current_window->buffer->input_buffer) : strdup ("");
|
||||
gui_insert_string_input (gui_current_window, expanded_key, -1);
|
||||
gui_current_window->buffer->input_buffer_pos += utf8_strlen (expanded_key);
|
||||
gui_input_draw (gui_current_window->buffer, 1);
|
||||
gui_current_window->buffer->completion.position = -1;
|
||||
#ifdef PLUGINS
|
||||
length = strlen (expanded_key) + 1 + 1;
|
||||
expanded_key2 = (char *) malloc (length);
|
||||
if (expanded_key2)
|
||||
{
|
||||
snprintf (expanded_key2, length, "*%s", expanded_key);
|
||||
(void) plugin_keyboard_handler_exec (expanded_key2,
|
||||
buffer_before_key,
|
||||
gui_current_window->buffer->input_buffer);
|
||||
free (expanded_key2);
|
||||
}
|
||||
#endif
|
||||
if (buffer_before_key)
|
||||
free (buffer_before_key);
|
||||
}
|
||||
free (expanded_key);
|
||||
}
|
||||
|
||||
/* end grab mode */
|
||||
gui_key_grab = 0;
|
||||
gui_key_grab_count = 0;
|
||||
gui_key_buffer[0] = '\0';
|
||||
}
|
||||
|
||||
/*
|
||||
* gui_keyboard_read: read keyboard chars
|
||||
*/
|
||||
|
||||
void
|
||||
gui_keyboard_read ()
|
||||
{
|
||||
int key, i, insert_ok;
|
||||
char key_str[32], key_str2[33];
|
||||
char *buffer_before_key;
|
||||
|
||||
i = 0;
|
||||
/* do not loop too much here (for example when big paste was made),
|
||||
to read also socket & co */
|
||||
while (i < 8)
|
||||
{
|
||||
if (gui_key_grab && (gui_key_grab_count > 10))
|
||||
gui_keyboard_grab_end ();
|
||||
|
||||
key = getch ();
|
||||
insert_ok = 1;
|
||||
|
||||
if (key == ERR)
|
||||
{
|
||||
if (gui_key_grab && (gui_key_grab_count > 0))
|
||||
gui_keyboard_grab_end ();
|
||||
break;
|
||||
}
|
||||
|
||||
if (key == KEY_RESIZE)
|
||||
{
|
||||
gui_window_refresh_screen ();
|
||||
continue;
|
||||
}
|
||||
|
||||
gui_last_activity_time = time (NULL);
|
||||
|
||||
if (key < 32)
|
||||
{
|
||||
insert_ok = 0;
|
||||
key_str[0] = '^';
|
||||
key_str[1] = (char) key + '@';
|
||||
key_str[2] = '\0';
|
||||
}
|
||||
else if (key == 127)
|
||||
{
|
||||
key_str[0] = '^';
|
||||
key_str[1] = '?';
|
||||
key_str[2] = '\0';
|
||||
}
|
||||
else
|
||||
{
|
||||
if (local_utf8)
|
||||
{
|
||||
/* 1 char: 0vvvvvvv */
|
||||
if (key < 0x80)
|
||||
{
|
||||
key_str[0] = (char) key;
|
||||
key_str[1] = '\0';
|
||||
}
|
||||
/* 2 chars: 110vvvvv 10vvvvvv */
|
||||
else if ((key & 0xE0) == 0xC0)
|
||||
{
|
||||
key_str[0] = (char) key;
|
||||
key_str[1] = (char) (getch ());
|
||||
key_str[2] = '\0';
|
||||
}
|
||||
/* 3 chars: 1110vvvv 10vvvvvv 10vvvvvv */
|
||||
else if ((key & 0xF0) == 0xE0)
|
||||
{
|
||||
key_str[0] = (char) key;
|
||||
key_str[1] = (char) (getch ());
|
||||
key_str[2] = (char) (getch ());
|
||||
key_str[3] = '\0';
|
||||
}
|
||||
/* 4 chars: 11110vvv 10vvvvvv 10vvvvvv 10vvvvvv */
|
||||
else if ((key & 0xF8) == 0xF0)
|
||||
{
|
||||
key_str[0] = (char) key;
|
||||
key_str[1] = (char) (getch ());
|
||||
key_str[2] = (char) (getch ());
|
||||
key_str[3] = (char) (getch ());
|
||||
key_str[4] = '\0';
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
key_str[0] = (char) key;
|
||||
key_str[1] = '\0';
|
||||
}
|
||||
}
|
||||
|
||||
if (strcmp (key_str, "^") == 0)
|
||||
{
|
||||
key_str[1] = '^';
|
||||
key_str[2] = '\0';
|
||||
}
|
||||
|
||||
/*gui_printf (gui_current_window->buffer, "gui_input_read: key = %s (%d)\n", key_str, key);*/
|
||||
|
||||
if ((gui_keyboard_pressed (key_str) != 0) && (insert_ok))
|
||||
{
|
||||
if (strcmp (key_str, "^^") == 0)
|
||||
key_str[1] = '\0';
|
||||
|
||||
switch (gui_current_window->buffer->type)
|
||||
{
|
||||
case BUFFER_TYPE_STANDARD:
|
||||
buffer_before_key =
|
||||
(gui_current_window->buffer->input_buffer) ?
|
||||
strdup (gui_current_window->buffer->input_buffer) : strdup ("");
|
||||
gui_insert_string_input (gui_current_window, key_str, -1);
|
||||
gui_current_window->buffer->input_buffer_pos += utf8_strlen (key_str);
|
||||
gui_input_draw (gui_current_window->buffer, 0);
|
||||
gui_current_window->buffer->completion.position = -1;
|
||||
#ifdef PLUGINS
|
||||
snprintf (key_str2, sizeof (key_str2), "*%s", key_str);
|
||||
(void) plugin_keyboard_handler_exec (key_str2,
|
||||
buffer_before_key,
|
||||
gui_current_window->buffer->input_buffer);
|
||||
#endif
|
||||
break;
|
||||
case BUFFER_TYPE_DCC:
|
||||
gui_exec_action_dcc (gui_current_window, key_str);
|
||||
break;
|
||||
case BUFFER_TYPE_RAW_DATA:
|
||||
gui_exec_action_raw_data (gui_current_window, key_str);
|
||||
break;
|
||||
}
|
||||
}
|
||||
i++;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,355 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
/* gui-curses-main.c: main loop for Curses GUI */
|
||||
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <stdio.h>
|
||||
#include <unistd.h>
|
||||
#include <string.h>
|
||||
#include <signal.h>
|
||||
|
||||
#include "../../common/weechat.h"
|
||||
#include "../gui.h"
|
||||
#include "../../common/fifo.h"
|
||||
#include "../../common/utf8.h"
|
||||
#include "../../common/weeconfig.h"
|
||||
#include "gui-curses.h"
|
||||
|
||||
#ifdef PLUGINS
|
||||
#include "../../plugins/plugins.h"
|
||||
#endif
|
||||
|
||||
|
||||
/*
|
||||
* gui_main_loop: main loop for WeeChat with ncurses GUI
|
||||
*/
|
||||
|
||||
void
|
||||
gui_main_loop ()
|
||||
{
|
||||
fd_set read_fd;
|
||||
static struct timeval timeout, tv;
|
||||
static struct timezone tz;
|
||||
t_irc_server *ptr_server;
|
||||
t_gui_buffer *ptr_buffer;
|
||||
int old_day, old_min, old_sec, diff;
|
||||
char text_time[1024];
|
||||
time_t new_time;
|
||||
struct tm *local_time;
|
||||
|
||||
quit_weechat = 0;
|
||||
|
||||
new_time = time (NULL);
|
||||
gui_last_activity_time = new_time;
|
||||
local_time = localtime (&new_time);
|
||||
old_day = local_time->tm_mday;
|
||||
|
||||
old_min = -1;
|
||||
old_sec = -1;
|
||||
check_away = 0;
|
||||
while (!quit_weechat)
|
||||
{
|
||||
/* refresh needed ? */
|
||||
if (gui_refresh_screen_needed)
|
||||
gui_window_refresh_screen ();
|
||||
|
||||
new_time = time (NULL);
|
||||
local_time = localtime (&new_time);
|
||||
|
||||
/* minute has changed ? => redraw infobar */
|
||||
if (local_time->tm_min != old_min)
|
||||
{
|
||||
old_min = local_time->tm_min;
|
||||
gui_infobar_draw (gui_current_window->buffer, 1);
|
||||
|
||||
if (cfg_look_day_change
|
||||
&& (local_time->tm_mday != old_day))
|
||||
{
|
||||
strftime (text_time, sizeof (text_time),
|
||||
cfg_look_day_change_timestamp, local_time);
|
||||
gui_add_hotlist = 0;
|
||||
for (ptr_buffer = gui_buffers; ptr_buffer;
|
||||
ptr_buffer = ptr_buffer->next_buffer)
|
||||
{
|
||||
if (ptr_buffer->type == BUFFER_TYPE_STANDARD)
|
||||
gui_printf_nolog_notime (ptr_buffer,
|
||||
_("Day changed to %s\n"),
|
||||
text_time);
|
||||
}
|
||||
gui_add_hotlist = 1;
|
||||
}
|
||||
old_day = local_time->tm_mday;
|
||||
}
|
||||
|
||||
/* second has changed ? */
|
||||
if (local_time->tm_sec != old_sec)
|
||||
{
|
||||
old_sec = local_time->tm_sec;
|
||||
|
||||
if (cfg_look_infobar_seconds)
|
||||
{
|
||||
gui_infobar_draw_time (gui_current_window->buffer);
|
||||
wmove (GUI_CURSES(gui_current_window)->win_input,
|
||||
0, gui_current_window->win_input_x);
|
||||
wrefresh (GUI_CURSES(gui_current_window)->win_input);
|
||||
}
|
||||
|
||||
/* infobar count down */
|
||||
if (gui_infobar && gui_infobar->remaining_time > 0)
|
||||
{
|
||||
gui_infobar->remaining_time--;
|
||||
if (gui_infobar->remaining_time == 0)
|
||||
{
|
||||
gui_infobar_remove ();
|
||||
gui_infobar_draw (gui_current_window->buffer, 1);
|
||||
}
|
||||
}
|
||||
|
||||
/* away check */
|
||||
if (cfg_irc_away_check != 0)
|
||||
{
|
||||
check_away++;
|
||||
if (check_away >= (cfg_irc_away_check * 60))
|
||||
{
|
||||
check_away = 0;
|
||||
server_check_away ();
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef PLUGINS
|
||||
/* call timer handlers */
|
||||
plugin_timer_handler_exec ();
|
||||
#endif
|
||||
}
|
||||
|
||||
/* read keyboard */
|
||||
|
||||
/* on GNU/Hurd 2 select() are causing troubles with keyboard */
|
||||
/* waiting for a fix, we use only one select() */
|
||||
#ifndef __GNU__
|
||||
FD_ZERO (&read_fd);
|
||||
timeout.tv_sec = 0;
|
||||
timeout.tv_usec = 8000;
|
||||
|
||||
FD_SET (STDIN_FILENO, &read_fd);
|
||||
|
||||
if (select (FD_SETSIZE, &read_fd, NULL, NULL, &timeout) > 0)
|
||||
{
|
||||
if (FD_ISSET (STDIN_FILENO, &read_fd))
|
||||
{
|
||||
gui_keyboard_read ();
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
/* read sockets (servers, child process when connecting, FIFO pipe) */
|
||||
|
||||
FD_ZERO (&read_fd);
|
||||
|
||||
#ifdef __GNU__
|
||||
timeout.tv_sec = 0;
|
||||
timeout.tv_usec = 10000;
|
||||
FD_SET (STDIN_FILENO, &read_fd);
|
||||
#else
|
||||
timeout.tv_sec = 0;
|
||||
timeout.tv_usec = 2000;
|
||||
#endif
|
||||
|
||||
if (weechat_fifo != -1)
|
||||
FD_SET (weechat_fifo, &read_fd);
|
||||
|
||||
for (ptr_server = irc_servers; ptr_server;
|
||||
ptr_server = ptr_server->next_server)
|
||||
{
|
||||
/* check if reconnection is pending */
|
||||
if ((!ptr_server->is_connected)
|
||||
&& (ptr_server->reconnect_start > 0)
|
||||
&& (new_time >= (ptr_server->reconnect_start + ptr_server->autoreconnect_delay)))
|
||||
server_reconnect (ptr_server);
|
||||
else
|
||||
{
|
||||
if (ptr_server->is_connected)
|
||||
{
|
||||
/* check for lag */
|
||||
if ((ptr_server->lag_check_time.tv_sec == 0)
|
||||
&& (new_time >= ptr_server->lag_next_check))
|
||||
{
|
||||
server_sendf (ptr_server, "PING %s\r\n", ptr_server->address);
|
||||
gettimeofday (&(ptr_server->lag_check_time), &tz);
|
||||
}
|
||||
|
||||
/* lag timeout => disconnect */
|
||||
if ((ptr_server->lag_check_time.tv_sec != 0)
|
||||
&& (cfg_irc_lag_disconnect > 0))
|
||||
{
|
||||
gettimeofday (&tv, &tz);
|
||||
diff = (int) get_timeval_diff (&(ptr_server->lag_check_time), &tv);
|
||||
if (diff / 1000 > cfg_irc_lag_disconnect * 60)
|
||||
{
|
||||
irc_display_prefix (ptr_server, ptr_server->buffer, PREFIX_ERROR);
|
||||
gui_printf (ptr_server->buffer,
|
||||
_("%s lag is high, disconnecting from server...\n"),
|
||||
WEECHAT_WARNING);
|
||||
server_disconnect (ptr_server, 1);
|
||||
continue;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (!ptr_server->is_connected && (ptr_server->child_pid > 0))
|
||||
FD_SET (ptr_server->child_read, &read_fd);
|
||||
else
|
||||
{
|
||||
if (ptr_server->sock >= 0)
|
||||
FD_SET (ptr_server->sock, &read_fd);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (select (FD_SETSIZE, &read_fd, NULL, NULL, &timeout) > 0)
|
||||
{
|
||||
#ifdef __GNU__
|
||||
if (FD_ISSET (STDIN_FILENO, &read_fd))
|
||||
{
|
||||
gui_keyboard_read ();
|
||||
}
|
||||
#endif
|
||||
if ((weechat_fifo != -1) && (FD_ISSET (weechat_fifo, &read_fd)))
|
||||
{
|
||||
fifo_read ();
|
||||
}
|
||||
for (ptr_server = irc_servers; ptr_server;
|
||||
ptr_server = ptr_server->next_server)
|
||||
{
|
||||
if (!ptr_server->is_connected && (ptr_server->child_pid > 0))
|
||||
{
|
||||
if (FD_ISSET (ptr_server->child_read, &read_fd))
|
||||
server_child_read (ptr_server);
|
||||
}
|
||||
else
|
||||
{
|
||||
if ((ptr_server->sock >= 0) &&
|
||||
(FD_ISSET (ptr_server->sock, &read_fd)))
|
||||
server_recv (ptr_server);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* manages active DCC */
|
||||
dcc_handle ();
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* gui_main_pre_init: pre-initialize GUI (called before gui_init)
|
||||
*/
|
||||
|
||||
void
|
||||
gui_main_pre_init (int *argc, char **argv[])
|
||||
{
|
||||
/* nothing for Curses interface */
|
||||
(void) argc;
|
||||
(void) argv;
|
||||
}
|
||||
|
||||
/*
|
||||
* gui_main_init: init GUI
|
||||
*/
|
||||
|
||||
void
|
||||
gui_main_init ()
|
||||
{
|
||||
initscr ();
|
||||
|
||||
curs_set (1);
|
||||
noecho ();
|
||||
nodelay (stdscr, TRUE);
|
||||
|
||||
gui_color_init ();
|
||||
|
||||
gui_infobar = NULL;
|
||||
|
||||
gui_ok = ((COLS > 5) && (LINES > 5));
|
||||
|
||||
refresh ();
|
||||
|
||||
/* init clipboard buffer */
|
||||
gui_input_clipboard = NULL;
|
||||
|
||||
/* create new window/buffer */
|
||||
if (gui_window_new (NULL, 0, 0, COLS, LINES, 100, 100))
|
||||
{
|
||||
gui_current_window = gui_windows;
|
||||
gui_buffer_new (gui_windows, NULL, NULL, BUFFER_TYPE_STANDARD, 1);
|
||||
|
||||
if (cfg_look_set_title)
|
||||
gui_window_set_title ();
|
||||
|
||||
gui_init_ok = 1;
|
||||
|
||||
signal (SIGWINCH, gui_window_refresh_screen_sigwinch);
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
* gui_main_end: GUI end
|
||||
*/
|
||||
|
||||
void
|
||||
gui_main_end ()
|
||||
{
|
||||
/* free clipboard buffer */
|
||||
if (gui_input_clipboard)
|
||||
free (gui_input_clipboard);
|
||||
|
||||
/* delete all panels */
|
||||
while (gui_panels)
|
||||
gui_panel_free (gui_panels);
|
||||
|
||||
/* delete all buffers */
|
||||
gui_window_merge_all (gui_current_window);
|
||||
while (gui_buffers)
|
||||
gui_buffer_free (gui_buffers, 0);
|
||||
|
||||
/* delete all windows */
|
||||
while (gui_windows)
|
||||
gui_window_free (gui_windows);
|
||||
gui_window_tree_free (&gui_windows_tree);
|
||||
|
||||
/* delete global history */
|
||||
history_global_free ();
|
||||
|
||||
/* delete infobar messages */
|
||||
while (gui_infobar)
|
||||
gui_infobar_remove ();
|
||||
|
||||
/* reset title */
|
||||
if (cfg_look_set_title)
|
||||
gui_window_reset_title ();
|
||||
|
||||
/* end of Curses output */
|
||||
refresh ();
|
||||
endwin ();
|
||||
}
|
||||
@@ -0,0 +1,230 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
/* gui-curses-nicklist.c: nicklist display functions for Curses GUI */
|
||||
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include "../../common/weechat.h"
|
||||
#include "../gui.h"
|
||||
#include "../../common/weeconfig.h"
|
||||
#include "../../irc/irc.h"
|
||||
#include "gui-curses.h"
|
||||
|
||||
|
||||
/*
|
||||
* gui_nicklist_draw: draw nick window for a buffer
|
||||
*/
|
||||
|
||||
void
|
||||
gui_nicklist_draw (t_gui_buffer *buffer, int erase)
|
||||
{
|
||||
t_gui_window *ptr_win;
|
||||
int i, j, x, y, x2, column, max_length, nicks_displayed;
|
||||
char format[32], format_empty[32];
|
||||
t_irc_nick *ptr_nick;
|
||||
|
||||
if (!gui_ok || !BUFFER_HAS_NICKLIST(buffer))
|
||||
return;
|
||||
|
||||
for (ptr_win = gui_windows; ptr_win; ptr_win = ptr_win->next_window)
|
||||
{
|
||||
if ((ptr_win->buffer == buffer) && (buffer->num_displayed > 0))
|
||||
{
|
||||
max_length = nick_get_max_length (CHANNEL(buffer));
|
||||
|
||||
if (gui_window_calculate_pos_size (ptr_win, 0))
|
||||
{
|
||||
delwin (GUI_CURSES(ptr_win)->win_chat);
|
||||
delwin (GUI_CURSES(ptr_win)->win_nick);
|
||||
GUI_CURSES(ptr_win)->win_chat = newwin (ptr_win->win_chat_height,
|
||||
ptr_win->win_chat_width,
|
||||
ptr_win->win_chat_y,
|
||||
ptr_win->win_chat_x);
|
||||
GUI_CURSES(ptr_win)->win_nick = newwin (ptr_win->win_nick_height,
|
||||
ptr_win->win_nick_width,
|
||||
ptr_win->win_nick_y,
|
||||
ptr_win->win_nick_x);
|
||||
gui_chat_draw (buffer, 1);
|
||||
erase = 1;
|
||||
}
|
||||
|
||||
if (erase)
|
||||
{
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_nick, COLOR_WIN_NICK);
|
||||
|
||||
snprintf (format_empty, 32, "%%-%ds", ptr_win->win_nick_width);
|
||||
for (i = 0; i < ptr_win->win_nick_height; i++)
|
||||
{
|
||||
mvwprintw (GUI_CURSES(ptr_win)->win_nick, i, 0, format_empty, " ");
|
||||
}
|
||||
}
|
||||
|
||||
if ((cfg_look_nicklist_position == CFG_LOOK_NICKLIST_TOP) ||
|
||||
(cfg_look_nicklist_position == CFG_LOOK_NICKLIST_BOTTOM))
|
||||
snprintf (format, 32, "%%.%ds", max_length);
|
||||
else
|
||||
snprintf (format, 32, "%%.%ds",
|
||||
((cfg_look_nicklist_min_size > 0)
|
||||
&& (max_length < cfg_look_nicklist_min_size)) ?
|
||||
cfg_look_nicklist_min_size :
|
||||
(((cfg_look_nicklist_max_size > 0)
|
||||
&& (max_length > cfg_look_nicklist_max_size)) ?
|
||||
cfg_look_nicklist_max_size : max_length));
|
||||
|
||||
if (has_colors ())
|
||||
{
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_nick, COLOR_WIN_NICK_SEP);
|
||||
switch (cfg_look_nicklist_position)
|
||||
{
|
||||
case CFG_LOOK_NICKLIST_LEFT:
|
||||
mvwvline (GUI_CURSES(ptr_win)->win_nick,
|
||||
0, ptr_win->win_nick_width - 1, ACS_VLINE,
|
||||
ptr_win->win_chat_height);
|
||||
break;
|
||||
case CFG_LOOK_NICKLIST_RIGHT:
|
||||
mvwvline (GUI_CURSES(ptr_win)->win_nick,
|
||||
0, 0, ACS_VLINE,
|
||||
ptr_win->win_chat_height);
|
||||
break;
|
||||
case CFG_LOOK_NICKLIST_TOP:
|
||||
mvwhline (GUI_CURSES(ptr_win)->win_nick,
|
||||
ptr_win->win_nick_height - 1, 0, ACS_HLINE,
|
||||
ptr_win->win_chat_width);
|
||||
break;
|
||||
case CFG_LOOK_NICKLIST_BOTTOM:
|
||||
mvwhline (GUI_CURSES(ptr_win)->win_nick,
|
||||
0, 0, ACS_HLINE,
|
||||
ptr_win->win_chat_width);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_nick, COLOR_WIN_NICK);
|
||||
x = 0;
|
||||
y = (cfg_look_nicklist_position == CFG_LOOK_NICKLIST_BOTTOM) ? 1 : 0;
|
||||
column = 0;
|
||||
|
||||
if ((cfg_look_nicklist_position == CFG_LOOK_NICKLIST_TOP) ||
|
||||
(cfg_look_nicklist_position == CFG_LOOK_NICKLIST_BOTTOM))
|
||||
nicks_displayed = (ptr_win->win_width / (max_length + 2)) * (ptr_win->win_nick_height - 1);
|
||||
else
|
||||
nicks_displayed = ptr_win->win_nick_height;
|
||||
|
||||
ptr_nick = CHANNEL(buffer)->nicks;
|
||||
for (i = 0; i < ptr_win->win_nick_start; i++)
|
||||
{
|
||||
if (!ptr_nick)
|
||||
break;
|
||||
ptr_nick = ptr_nick->next_nick;
|
||||
}
|
||||
if (ptr_nick)
|
||||
{
|
||||
for (i = 0; i < nicks_displayed; i++)
|
||||
{
|
||||
switch (cfg_look_nicklist_position)
|
||||
{
|
||||
case CFG_LOOK_NICKLIST_LEFT:
|
||||
x = 0;
|
||||
break;
|
||||
case CFG_LOOK_NICKLIST_RIGHT:
|
||||
x = 1;
|
||||
break;
|
||||
case CFG_LOOK_NICKLIST_TOP:
|
||||
case CFG_LOOK_NICKLIST_BOTTOM:
|
||||
x = column;
|
||||
break;
|
||||
}
|
||||
if ( ((i == 0) && (ptr_win->win_nick_start > 0))
|
||||
|| ((i == nicks_displayed - 1) && (ptr_nick->next_nick)) )
|
||||
{
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_nick, COLOR_WIN_NICK_MORE);
|
||||
j = (max_length + 1) >= 4 ? 4 : max_length + 1;
|
||||
for (x2 = 1; x2 <= j; x2++)
|
||||
mvwprintw (GUI_CURSES(ptr_win)->win_nick, y, x + x2, "+");
|
||||
}
|
||||
else
|
||||
{
|
||||
if (ptr_nick->flags & NICK_CHANOWNER)
|
||||
{
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_nick, COLOR_WIN_NICK_CHANOWNER);
|
||||
mvwprintw (GUI_CURSES(ptr_win)->win_nick, y, x, "~");
|
||||
x++;
|
||||
}
|
||||
else if (ptr_nick->flags & NICK_CHANADMIN)
|
||||
{
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_nick, COLOR_WIN_NICK_CHANADMIN);
|
||||
mvwprintw (GUI_CURSES(ptr_win)->win_nick, y, x, "&");
|
||||
x++;
|
||||
}
|
||||
else if (ptr_nick->flags & NICK_OP)
|
||||
{
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_nick, COLOR_WIN_NICK_OP);
|
||||
mvwprintw (GUI_CURSES(ptr_win)->win_nick, y, x, "@");
|
||||
x++;
|
||||
}
|
||||
else if (ptr_nick->flags & NICK_HALFOP)
|
||||
{
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_nick, COLOR_WIN_NICK_HALFOP);
|
||||
mvwprintw (GUI_CURSES(ptr_win)->win_nick, y, x, "%%");
|
||||
x++;
|
||||
}
|
||||
else if (ptr_nick->flags & NICK_VOICE)
|
||||
{
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_nick, COLOR_WIN_NICK_VOICE);
|
||||
mvwprintw (GUI_CURSES(ptr_win)->win_nick, y, x, "+");
|
||||
x++;
|
||||
}
|
||||
else
|
||||
{
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_nick, COLOR_WIN_NICK);
|
||||
mvwprintw (GUI_CURSES(ptr_win)->win_nick, y, x, " ");
|
||||
x++;
|
||||
}
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_nick,
|
||||
((cfg_irc_away_check > 0) && (ptr_nick->flags & NICK_AWAY)) ?
|
||||
COLOR_WIN_NICK_AWAY : COLOR_WIN_NICK);
|
||||
mvwprintw (GUI_CURSES(ptr_win)->win_nick, y, x, format, ptr_nick->nick);
|
||||
|
||||
ptr_nick = ptr_nick->next_nick;
|
||||
|
||||
if (!ptr_nick)
|
||||
break;
|
||||
}
|
||||
y++;
|
||||
if ((cfg_look_nicklist_position == CFG_LOOK_NICKLIST_TOP) ||
|
||||
(cfg_look_nicklist_position == CFG_LOOK_NICKLIST_BOTTOM))
|
||||
{
|
||||
if (y - ((cfg_look_nicklist_position == CFG_LOOK_NICKLIST_BOTTOM) ? 1 : 0) >= ptr_win->win_nick_height - 1)
|
||||
{
|
||||
column += max_length + 2;
|
||||
y = (cfg_look_nicklist_position == CFG_LOOK_NICKLIST_TOP) ?
|
||||
0 : 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
wnoutrefresh (GUI_CURSES(ptr_win)->win_nick);
|
||||
refresh ();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,202 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
/* gui-curses-panel.c: panel functions for Curses GUI */
|
||||
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include <stdlib.h>
|
||||
|
||||
#include "../../common/weechat.h"
|
||||
#include "../gui.h"
|
||||
#include "../../irc/irc.h"
|
||||
#include "gui-curses.h"
|
||||
|
||||
|
||||
/*
|
||||
* gui_panel_get_size: get total panel size for a position
|
||||
*/
|
||||
|
||||
int
|
||||
gui_panel_get_size (t_gui_window *window, int position)
|
||||
{
|
||||
t_gui_panel_window *ptr_panel_win;
|
||||
int total_size;
|
||||
|
||||
total_size = 0;
|
||||
for (ptr_panel_win = GUI_CURSES(window)->panel_windows; ptr_panel_win;
|
||||
ptr_panel_win = ptr_panel_win->next_panel_window)
|
||||
{
|
||||
if (ptr_panel_win->panel->position == position)
|
||||
{
|
||||
switch (position)
|
||||
{
|
||||
case GUI_PANEL_TOP:
|
||||
case GUI_PANEL_BOTTOM:
|
||||
total_size += ptr_panel_win->height;
|
||||
break;
|
||||
case GUI_PANEL_LEFT:
|
||||
case GUI_PANEL_RIGHT:
|
||||
total_size += ptr_panel_win->width;
|
||||
break;
|
||||
}
|
||||
if (ptr_panel_win->panel->separator)
|
||||
total_size++;
|
||||
}
|
||||
}
|
||||
return total_size;
|
||||
}
|
||||
|
||||
/*
|
||||
* gui_panel_window_new: create a new "window panel" for a panel, in screen or a window
|
||||
* if window is not NULL, panel window will be in this window
|
||||
*/
|
||||
|
||||
int
|
||||
gui_panel_window_new (t_gui_panel *panel, t_gui_window *window)
|
||||
{
|
||||
t_gui_panel_window *new_panel_win;
|
||||
int x1, y1, x2, y2;
|
||||
|
||||
if (window)
|
||||
{
|
||||
x1 = window->win_x;
|
||||
y1 = window->win_y + 1;
|
||||
x2 = x1 + window->win_width - 1;
|
||||
y2 = y1 + window->win_height - 1 - 4;
|
||||
}
|
||||
else
|
||||
{
|
||||
x1 = 0;
|
||||
y1 = 0;
|
||||
x2 = gui_window_get_width () - 1;
|
||||
y2 = gui_window_get_height () - 1;
|
||||
}
|
||||
|
||||
if ((new_panel_win = (t_gui_panel_window *) malloc (sizeof (t_gui_panel_window))))
|
||||
{
|
||||
new_panel_win->panel = panel;
|
||||
if (window)
|
||||
{
|
||||
panel->panel_window = NULL;
|
||||
new_panel_win->next_panel_window = GUI_CURSES(window)->panel_windows;
|
||||
GUI_CURSES(window)->panel_windows = new_panel_win;
|
||||
}
|
||||
else
|
||||
{
|
||||
panel->panel_window = new_panel_win;
|
||||
new_panel_win->next_panel_window = NULL;
|
||||
}
|
||||
switch (panel->position)
|
||||
{
|
||||
case GUI_PANEL_TOP:
|
||||
new_panel_win->x = x1;
|
||||
new_panel_win->y = y1;
|
||||
new_panel_win->width = x2 - x1 + 1;
|
||||
new_panel_win->height = panel->size;
|
||||
break;
|
||||
case GUI_PANEL_BOTTOM:
|
||||
new_panel_win->x = x1;
|
||||
new_panel_win->y = y2 - panel->size + 1;
|
||||
new_panel_win->width = x2 - x1 + 1;
|
||||
new_panel_win->height = panel->size;
|
||||
break;
|
||||
case GUI_PANEL_LEFT:
|
||||
new_panel_win->x = x1;
|
||||
new_panel_win->y = y1;
|
||||
new_panel_win->width = panel->size;
|
||||
new_panel_win->height = y2 - y1 + 1;
|
||||
break;
|
||||
case GUI_PANEL_RIGHT:
|
||||
new_panel_win->x = x2 - panel->size + 1;
|
||||
new_panel_win->y = y1;
|
||||
new_panel_win->width = panel->size;
|
||||
new_panel_win->height = y2 - y1 + 1;
|
||||
break;
|
||||
}
|
||||
new_panel_win->win_panel = newwin (new_panel_win->height,
|
||||
new_panel_win->width,
|
||||
new_panel_win->y,
|
||||
new_panel_win->x);
|
||||
new_panel_win->win_separator = NULL;
|
||||
if (new_panel_win->panel->separator)
|
||||
{
|
||||
switch (panel->position)
|
||||
{
|
||||
case GUI_PANEL_LEFT:
|
||||
new_panel_win->win_separator = newwin (new_panel_win->height,
|
||||
1,
|
||||
new_panel_win->y,
|
||||
new_panel_win->x + new_panel_win->width);
|
||||
break;
|
||||
}
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
else
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*
|
||||
* gui_panel_window_free: delete a panel window
|
||||
*/
|
||||
|
||||
void
|
||||
gui_panel_window_free (void *panel_win)
|
||||
{
|
||||
t_gui_panel_window *ptr_panel_win;
|
||||
|
||||
ptr_panel_win = (t_gui_panel_window *)panel_win;
|
||||
|
||||
free (ptr_panel_win);
|
||||
}
|
||||
|
||||
/*
|
||||
* gui_panel_redraw_buffer: redraw panels for windows displaying a buffer
|
||||
*/
|
||||
|
||||
void
|
||||
gui_panel_redraw_buffer (t_gui_buffer *buffer)
|
||||
{
|
||||
t_gui_window *ptr_win;
|
||||
t_gui_panel_window *ptr_panel_win;
|
||||
|
||||
if (!gui_ok)
|
||||
return;
|
||||
|
||||
for (ptr_win = gui_windows; ptr_win; ptr_win = ptr_win->next_window)
|
||||
{
|
||||
if ((ptr_win->buffer == buffer) && (buffer->num_displayed > 0))
|
||||
{
|
||||
for (ptr_panel_win = GUI_CURSES(ptr_win)->panel_windows;
|
||||
ptr_panel_win;
|
||||
ptr_panel_win = ptr_panel_win->next_panel_window)
|
||||
{
|
||||
switch (ptr_panel_win->panel->position)
|
||||
{
|
||||
case GUI_PANEL_LEFT:
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,396 @@
|
||||
/*
|
||||
* Copyright (c) 2003-2006 by FlashCode <flashcode@flashtux.org>
|
||||
* See README for License detail, AUTHORS for developers list.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
/* gui-curses-status.c: status display functions for Curses GUI */
|
||||
|
||||
|
||||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
#include "../../common/weechat.h"
|
||||
#include "../gui.h"
|
||||
#include "../../common/hotlist.h"
|
||||
#include "../../common/weeconfig.h"
|
||||
#include "gui-curses.h"
|
||||
|
||||
|
||||
/*
|
||||
* gui_status_draw: draw status window for a buffer
|
||||
*/
|
||||
|
||||
void
|
||||
gui_status_draw (t_gui_buffer *buffer, int erase)
|
||||
{
|
||||
t_gui_window *ptr_win;
|
||||
t_weechat_hotlist *ptr_hotlist;
|
||||
char format[32], str_nicks[32], *more;
|
||||
int i, first_mode, x, server_pos, server_total;
|
||||
int display_name, names_count;
|
||||
|
||||
/* make gcc happy */
|
||||
(void) buffer;
|
||||
|
||||
if (!gui_ok)
|
||||
return;
|
||||
|
||||
for (ptr_win = gui_windows; ptr_win; ptr_win = ptr_win->next_window)
|
||||
{
|
||||
if (erase)
|
||||
gui_window_curses_clear (GUI_CURSES(ptr_win)->win_status, COLOR_WIN_STATUS);
|
||||
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status, COLOR_WIN_STATUS);
|
||||
|
||||
/* display number of buffers */
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DELIMITERS);
|
||||
mvwprintw (GUI_CURSES(ptr_win)->win_status, 0, 0, "[");
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "%d",
|
||||
(last_gui_buffer) ? last_gui_buffer->number : 0);
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "] ");
|
||||
|
||||
/* display "<servers>" or current server */
|
||||
if (ptr_win->buffer->all_servers)
|
||||
{
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "[");
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, _("<servers>"));
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "] ");
|
||||
}
|
||||
else if (SERVER(ptr_win->buffer) && SERVER(ptr_win->buffer)->name)
|
||||
{
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "[");
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "%s", SERVER(ptr_win->buffer)->name);
|
||||
if (SERVER(ptr_win->buffer)->is_away)
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, _("(away)"));
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "] ");
|
||||
}
|
||||
|
||||
/* infos about current server buffer */
|
||||
if (SERVER(ptr_win->buffer) && !CHANNEL(ptr_win->buffer))
|
||||
{
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "%d",
|
||||
ptr_win->buffer->number);
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, ":");
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_CHANNEL);
|
||||
if (SERVER(ptr_win->buffer)->is_connected)
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "[%s] ",
|
||||
SERVER(ptr_win->buffer)->name);
|
||||
else
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "(%s) ",
|
||||
SERVER(ptr_win->buffer)->name);
|
||||
if (ptr_win->buffer->all_servers)
|
||||
{
|
||||
server_get_number_buffer (SERVER(ptr_win->buffer),
|
||||
&server_pos,
|
||||
&server_total);
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "(");
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "%d", server_pos);
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "/");
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "%d", server_total);
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, ") ");
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
/* infos about current channel/pv buffer */
|
||||
if (SERVER(ptr_win->buffer) && CHANNEL(ptr_win->buffer))
|
||||
{
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "%d",
|
||||
ptr_win->buffer->number);
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, ":");
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_CHANNEL);
|
||||
if (((CHANNEL(ptr_win->buffer)->type != CHANNEL_TYPE_PRIVATE)
|
||||
&& (CHANNEL(ptr_win->buffer)->type != CHANNEL_TYPE_DCC_CHAT)
|
||||
&& (!CHANNEL(ptr_win->buffer)->nicks))
|
||||
|| ((CHANNEL(ptr_win->buffer)->type == CHANNEL_TYPE_DCC_CHAT)
|
||||
&& (CHANNEL(ptr_win->buffer)->dcc_chat)
|
||||
&& (((t_irc_dcc *)(CHANNEL(ptr_win->buffer)->dcc_chat))->sock < 0)))
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "(%s)",
|
||||
CHANNEL(ptr_win->buffer)->name);
|
||||
else
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "%s",
|
||||
CHANNEL(ptr_win->buffer)->name);
|
||||
if (ptr_win->buffer == CHANNEL(ptr_win->buffer)->buffer)
|
||||
{
|
||||
/* display channel modes */
|
||||
if (CHANNEL(ptr_win->buffer)->type == CHANNEL_TYPE_CHANNEL)
|
||||
{
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "(");
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS);
|
||||
i = 0;
|
||||
first_mode = 1;
|
||||
while (CHANNEL(ptr_win->buffer)->modes[i])
|
||||
{
|
||||
if (CHANNEL(ptr_win->buffer)->modes[i] != ' ')
|
||||
{
|
||||
if (first_mode)
|
||||
{
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "+");
|
||||
first_mode = 0;
|
||||
}
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "%c",
|
||||
CHANNEL(ptr_win->buffer)->modes[i]);
|
||||
}
|
||||
i++;
|
||||
}
|
||||
if (CHANNEL(ptr_win->buffer)->modes[CHANNEL_MODE_KEY] != ' ')
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, ",%s",
|
||||
CHANNEL(ptr_win->buffer)->key);
|
||||
if (CHANNEL(ptr_win->buffer)->modes[CHANNEL_MODE_LIMIT] != ' ')
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, ",%d",
|
||||
CHANNEL(ptr_win->buffer)->limit);
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, ")");
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS);
|
||||
}
|
||||
|
||||
/* display DCC if private is DCC CHAT */
|
||||
if (CHANNEL(ptr_win->buffer)->type == CHANNEL_TYPE_DCC_CHAT)
|
||||
{
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "(");
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_CHANNEL);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "DCC");
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, ")");
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS);
|
||||
}
|
||||
}
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, " ");
|
||||
}
|
||||
if (!SERVER(ptr_win->buffer))
|
||||
{
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status, COLOR_WIN_STATUS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "%d",
|
||||
ptr_win->buffer->number);
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status, COLOR_WIN_STATUS_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, ":");
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status, COLOR_WIN_STATUS_CHANNEL);
|
||||
switch (ptr_win->buffer->type)
|
||||
{
|
||||
case BUFFER_TYPE_STANDARD:
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, _("[not connected] "));
|
||||
break;
|
||||
case BUFFER_TYPE_DCC:
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "<DCC> ");
|
||||
break;
|
||||
case BUFFER_TYPE_RAW_DATA:
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, _("<RAW_IRC> "));
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
/* display list of other active windows (if any) with numbers */
|
||||
if (hotlist)
|
||||
{
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "[");
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status, COLOR_WIN_STATUS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, _("Act: "));
|
||||
|
||||
names_count = 0;
|
||||
for (ptr_hotlist = hotlist; ptr_hotlist;
|
||||
ptr_hotlist = ptr_hotlist->next_hotlist)
|
||||
{
|
||||
switch (ptr_hotlist->priority)
|
||||
{
|
||||
case HOTLIST_LOW:
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DATA_OTHER);
|
||||
display_name = ((cfg_look_hotlist_names_level & 1) != 0);
|
||||
break;
|
||||
case HOTLIST_MSG:
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DATA_MSG);
|
||||
display_name = ((cfg_look_hotlist_names_level & 2) != 0);
|
||||
break;
|
||||
case HOTLIST_PRIVATE:
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DATA_PRIVATE);
|
||||
display_name = ((cfg_look_hotlist_names_level & 4) != 0);
|
||||
break;
|
||||
case HOTLIST_HIGHLIGHT:
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DATA_HIGHLIGHT);
|
||||
display_name = ((cfg_look_hotlist_names_level & 8) != 0);
|
||||
break;
|
||||
default:
|
||||
display_name = 0;
|
||||
break;
|
||||
}
|
||||
switch (ptr_hotlist->buffer->type)
|
||||
{
|
||||
case BUFFER_TYPE_STANDARD:
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "%d",
|
||||
ptr_hotlist->buffer->number);
|
||||
|
||||
if (display_name && (cfg_look_hotlist_names_count != 0)
|
||||
&& (names_count < cfg_look_hotlist_names_count))
|
||||
{
|
||||
names_count++;
|
||||
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, ":");
|
||||
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS);
|
||||
if (cfg_look_hotlist_names_length == 0)
|
||||
snprintf (format, sizeof (format) - 1, "%%s");
|
||||
else
|
||||
snprintf (format, sizeof (format) - 1, "%%.%ds", cfg_look_hotlist_names_length);
|
||||
if (BUFFER_IS_SERVER(ptr_hotlist->buffer))
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, format,
|
||||
(ptr_hotlist->server) ?
|
||||
ptr_hotlist->server->name :
|
||||
SERVER(ptr_hotlist->buffer)->name);
|
||||
else if (BUFFER_IS_CHANNEL(ptr_hotlist->buffer)
|
||||
|| BUFFER_IS_PRIVATE(ptr_hotlist->buffer))
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, format, CHANNEL(ptr_hotlist->buffer)->name);
|
||||
}
|
||||
break;
|
||||
case BUFFER_TYPE_DCC:
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "%d",
|
||||
ptr_hotlist->buffer->number);
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, ":");
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "DCC");
|
||||
break;
|
||||
case BUFFER_TYPE_RAW_DATA:
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "%d",
|
||||
ptr_hotlist->buffer->number);
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, ":");
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, _("RAW_IRC"));
|
||||
break;
|
||||
}
|
||||
|
||||
if (ptr_hotlist->next_hotlist)
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, ",");
|
||||
}
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "] ");
|
||||
}
|
||||
|
||||
/* display lag */
|
||||
if (SERVER(ptr_win->buffer))
|
||||
{
|
||||
if (SERVER(ptr_win->buffer)->lag / 1000 >= cfg_irc_lag_min_show)
|
||||
{
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "[");
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status, COLOR_WIN_STATUS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, _("Lag: %.1f"),
|
||||
((float)(SERVER(ptr_win->buffer)->lag)) / 1000);
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "]");
|
||||
}
|
||||
}
|
||||
|
||||
/* display "-MORE-" (if last line is not displayed) & nicks count */
|
||||
if (BUFFER_HAS_NICKLIST(ptr_win->buffer))
|
||||
{
|
||||
snprintf (str_nicks, sizeof (str_nicks) - 1, "%d", CHANNEL(ptr_win->buffer)->nicks_count);
|
||||
x = ptr_win->win_width - strlen (str_nicks) - 4;
|
||||
}
|
||||
else
|
||||
x = ptr_win->win_width - 2;
|
||||
more = strdup (_("-MORE-"));
|
||||
x -= strlen (more) - 1;
|
||||
if (x < 0)
|
||||
x = 0;
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status, COLOR_WIN_STATUS_MORE);
|
||||
if (ptr_win->scroll)
|
||||
mvwprintw (GUI_CURSES(ptr_win)->win_status, 0, x, "%s", more);
|
||||
else
|
||||
{
|
||||
snprintf (format, sizeof (format) - 1, "%%-%ds", (int)(strlen (more)));
|
||||
mvwprintw (GUI_CURSES(ptr_win)->win_status, 0, x, format, " ");
|
||||
}
|
||||
if (BUFFER_HAS_NICKLIST(ptr_win->buffer))
|
||||
{
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, " [");
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status, COLOR_WIN_STATUS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "%s", str_nicks);
|
||||
gui_window_set_weechat_color (GUI_CURSES(ptr_win)->win_status,
|
||||
COLOR_WIN_STATUS_DELIMITERS);
|
||||
wprintw (GUI_CURSES(ptr_win)->win_status, "]");
|
||||
}
|
||||
free (more);
|
||||
|
||||
wnoutrefresh (GUI_CURSES(ptr_win)->win_status);
|
||||
refresh ();
|
||||
}
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user