mirror of
https://github.com/gryf/wmaker.git
synced 2026-03-11 12:05:48 +01:00
Compare commits
573 Commits
release-0.
...
wmaker-0.9
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
9ead135f51 | ||
|
|
193a63511d | ||
|
|
b00076b32a | ||
|
|
51c2edf868 | ||
|
|
11b464a002 | ||
|
|
c3cff33f99 | ||
|
|
663df7b4cb | ||
|
|
b79524ce6f | ||
|
|
65a113f9a3 | ||
|
|
45c55a3e76 | ||
|
|
e93e16de06 | ||
|
|
620a280d64 | ||
|
|
4bda625076 | ||
|
|
b034bb077f | ||
|
|
d08691d5a5 | ||
|
|
08e811aae7 | ||
|
|
6de693a24d | ||
|
|
3a7749b0fc | ||
|
|
f555ccb9b9 | ||
|
|
f6682a9ade | ||
|
|
1166a58ec7 | ||
|
|
59d2a5cbe5 | ||
|
|
85f72d6576 | ||
|
|
435aee107e | ||
|
|
6cd91272a6 | ||
|
|
7908c9a66b | ||
|
|
f6fb9fbb3e | ||
|
|
9de3560d9f | ||
|
|
88e207f9e0 | ||
|
|
66ec682107 | ||
|
|
1076645853 | ||
|
|
30247c5886 | ||
|
|
1e3a40370d | ||
|
|
27b9e27ae0 | ||
|
|
28050dab72 | ||
|
|
bc6aeab722 | ||
|
|
737328566f | ||
|
|
6cfad0b10f | ||
|
|
19c7a99197 | ||
|
|
7929d55f3f | ||
|
|
1f12617065 | ||
|
|
944737dde7 | ||
|
|
a91a34732c | ||
|
|
744c0726a1 | ||
|
|
7055530895 | ||
|
|
9402724e40 | ||
|
|
cd36d73886 | ||
|
|
0c09179f01 | ||
|
|
884a3f1647 | ||
|
|
2e572717c5 | ||
|
|
8502709884 | ||
|
|
5f4a3f6777 | ||
|
|
067fc41354 | ||
|
|
36b55dc1e6 | ||
|
|
3a97c33072 | ||
|
|
62590be0db | ||
|
|
440f2abe6f | ||
|
|
f54f0856c1 | ||
|
|
62994167c5 | ||
|
|
00e709cec4 | ||
|
|
2b51c21ee5 | ||
|
|
3ed1d3e25c | ||
|
|
3088277b1e | ||
|
|
879b00a57b | ||
|
|
6830b05716 | ||
|
|
5912898b06 | ||
|
|
f614cb8341 | ||
|
|
9ff85407b7 | ||
|
|
d211420261 | ||
|
|
1ef52e0aec | ||
|
|
9aca0d5f6e | ||
|
|
c7c68c6fe7 | ||
|
|
95897acc30 | ||
|
|
57869b667b | ||
|
|
2c8a70b743 | ||
|
|
0445dd5c18 | ||
|
|
b6e06d4beb | ||
|
|
b75b7cbc01 | ||
|
|
eb646a6682 | ||
|
|
7b88cd8afd | ||
|
|
f5a6724142 | ||
|
|
afbab71401 | ||
|
|
20fe42df2b | ||
|
|
d0c5bedab6 | ||
|
|
ef31cd1323 | ||
|
|
427a42ab58 | ||
|
|
474c4caf94 | ||
|
|
109bb540ec | ||
|
|
9b7b9f6815 | ||
|
|
32973f6e15 | ||
|
|
5b26a68910 | ||
|
|
59014546aa | ||
|
|
e4483de406 | ||
|
|
90d830837a | ||
|
|
752163dfc6 | ||
|
|
6d02fe98f2 | ||
|
|
500d569c79 | ||
|
|
f54b0de7b4 | ||
|
|
b8193865f6 | ||
|
|
e7d0c5d9e9 | ||
|
|
791bb6a444 | ||
|
|
a018eff89d | ||
|
|
1096cfa991 | ||
|
|
5d9354f362 | ||
|
|
0b42849a3e | ||
|
|
df75c86ef0 | ||
|
|
20975c4918 | ||
|
|
1dfaec332e | ||
|
|
3d6d775f08 | ||
|
|
1f393ac4f7 | ||
|
|
847479b886 | ||
|
|
6aed0cd713 | ||
|
|
39b9edfdcd | ||
|
|
090cc27f00 | ||
|
|
08225948bc | ||
|
|
18d07e04a6 | ||
|
|
74ba4f8eef | ||
|
|
0852957ea1 | ||
|
|
7efcf57c18 | ||
|
|
44f636e91e | ||
|
|
8457611316 | ||
|
|
bd7943d9a7 | ||
|
|
b0d72a3db2 | ||
|
|
396b011610 | ||
|
|
c131f14d3e | ||
|
|
a4c986fa1b | ||
|
|
64468fcf63 | ||
|
|
8904783aee | ||
|
|
40c89b3399 | ||
|
|
27a396d7ed | ||
|
|
2cf5931890 | ||
|
|
d159da8671 | ||
|
|
ed0d234d7f | ||
|
|
4d701d8306 | ||
|
|
5dbb770aa4 | ||
|
|
479ccbda82 | ||
|
|
001cb65271 | ||
|
|
bc3ab27364 | ||
|
|
669d542408 | ||
|
|
3dcab96180 | ||
|
|
7f1d621f43 | ||
|
|
b0063c83c7 | ||
|
|
f06c9a1953 | ||
|
|
e1958b22c5 | ||
|
|
528243bb98 | ||
|
|
f058fdf72c | ||
|
|
5f79f1bcde | ||
|
|
18ed046356 | ||
|
|
277d0055fd | ||
|
|
e727cbadb6 | ||
|
|
fdeb749da7 | ||
|
|
dee8c6e770 | ||
|
|
fe4cd695af | ||
|
|
1902325087 | ||
|
|
5b28616212 | ||
|
|
ad05cc3b44 | ||
|
|
56f73aa4b9 | ||
|
|
40111188ec | ||
|
|
80c09f1075 | ||
|
|
b5ef388711 | ||
|
|
7a8bde44fa | ||
|
|
b381674375 | ||
|
|
e54a0954e6 | ||
|
|
c0965cd48b | ||
|
|
4153e2fde4 | ||
|
|
f3487c1ea2 | ||
|
|
0898a3d475 | ||
|
|
064f79ebae | ||
|
|
55d37178a0 | ||
|
|
90e8cfc5b8 | ||
|
|
ab511aca5e | ||
|
|
39d250888e | ||
|
|
00638fa5d3 | ||
|
|
ca43aba088 | ||
|
|
96c64e15ef | ||
|
|
dd1ccd2fd6 | ||
|
|
c0442b1c59 | ||
|
|
bde9b8a21a | ||
|
|
83d3625e1a | ||
|
|
5ad557c6c8 | ||
|
|
1fa3937001 | ||
|
|
a10214a502 | ||
|
|
0fe70d2b4e | ||
|
|
18b3753227 | ||
|
|
0bfa12a1fc | ||
|
|
4d6cd7f326 | ||
|
|
2fe1b0e3f8 | ||
|
|
3929660f39 | ||
|
|
c2ec1cfe8a | ||
|
|
d597c61cb7 | ||
|
|
5e18eadf22 | ||
|
|
19f7fbc949 | ||
|
|
55f3cb9577 | ||
|
|
811e508c84 | ||
|
|
60ee69979f | ||
|
|
4f80ec9178 | ||
|
|
5e37991b6c | ||
|
|
a4bc7f6a07 | ||
|
|
6724ec5a6d | ||
|
|
879d13ef45 | ||
|
|
a1d78d102a | ||
|
|
3af4aa7846 | ||
|
|
0f0afc48ab | ||
|
|
55efa1f268 | ||
|
|
ffa1a610c0 | ||
|
|
0bb76c0a76 | ||
|
|
7be0a97998 | ||
|
|
5230a57599 | ||
|
|
3bed15d673 | ||
|
|
1e92274495 | ||
|
|
2b2fecac12 | ||
|
|
17f26077b0 | ||
|
|
a2b404b5b3 | ||
|
|
e98da5a628 | ||
|
|
b9e7a1d3ca | ||
|
|
1941aaf34a | ||
|
|
11c466ec26 | ||
|
|
feaa80addc | ||
|
|
92b012e800 | ||
|
|
3fc803c0d8 | ||
|
|
a07b262a87 | ||
|
|
851835c7a5 | ||
|
|
d4de3d0a45 | ||
|
|
048b43aea4 | ||
|
|
579eb01c6c | ||
|
|
ca212985df | ||
|
|
c32806ae14 | ||
|
|
ee5b28b0af | ||
|
|
750917986e | ||
|
|
6e72c20248 | ||
|
|
ad0ad5af22 | ||
|
|
e4a53ba71e | ||
|
|
208ee16849 | ||
|
|
f9acc9313e | ||
|
|
92fb96eb69 | ||
|
|
18d347ecd5 | ||
|
|
97e20d94de | ||
|
|
65e65c4e9d | ||
|
|
84fa789cd6 | ||
|
|
efcf27f854 | ||
|
|
5fe90167a3 | ||
|
|
f857012f7a | ||
|
|
efb0090f8c | ||
|
|
1cd1f16c3c | ||
|
|
0c1881e224 | ||
|
|
5bb35d94a5 | ||
|
|
321bb04586 | ||
|
|
77b8fe05ac | ||
|
|
9466c00f2b | ||
|
|
a8950af8ac | ||
|
|
58e719654f | ||
|
|
ad58481487 | ||
|
|
5402fccd1e | ||
|
|
cf7859d145 | ||
|
|
5db8b5660f | ||
|
|
5873385d32 | ||
|
|
a26b723c5a | ||
|
|
bc3d012e7c | ||
|
|
c08b3c5f32 | ||
|
|
f37b4cf5d0 | ||
|
|
06f1bf91a9 | ||
|
|
8b5f31ad8b | ||
|
|
2cc90e649a | ||
|
|
9d41f432b9 | ||
|
|
b4f540ddd6 | ||
|
|
03f534c0bf | ||
|
|
9078b1a5a7 | ||
|
|
da02e76051 | ||
|
|
9c19d14d1a | ||
|
|
bc88390918 | ||
|
|
a1b9bf23a9 | ||
|
|
511a06628b | ||
|
|
8a25fdc672 | ||
|
|
a1a7ba7689 | ||
|
|
4f84c48ccb | ||
|
|
9b63a77d6a | ||
|
|
89a32e3663 | ||
|
|
501c3f48b8 | ||
|
|
cab71ba6a1 | ||
|
|
96f8ab167f | ||
|
|
a8c7375623 | ||
|
|
365556b676 | ||
|
|
7b00d9ec12 | ||
|
|
89cb6559cc | ||
|
|
372da5ca39 | ||
|
|
514258fd35 | ||
|
|
0b0002f75a | ||
|
|
cf2322ee03 | ||
|
|
c9dfd7f3a4 | ||
|
|
7eb705472f | ||
|
|
d35dd84ae5 | ||
|
|
0613a758f4 | ||
|
|
9e615bcff9 | ||
|
|
9031641ba6 | ||
|
|
9bfa0b6efb | ||
|
|
60409e290d | ||
|
|
03befcf729 | ||
|
|
beb83f52fe | ||
|
|
99a5f0da0f | ||
|
|
520a6cd0e4 | ||
|
|
f968d88070 | ||
|
|
e1ed96951b | ||
|
|
41996df786 | ||
|
|
932fcd1f37 | ||
|
|
cefdc204ba | ||
|
|
6f28d987a8 | ||
|
|
c8b3933c19 | ||
|
|
4140e6051f | ||
|
|
f0664d1344 | ||
|
|
f4ef34b814 | ||
|
|
90c77b1a45 | ||
|
|
672c42cc48 | ||
|
|
739fd1a567 | ||
|
|
363290d919 | ||
|
|
235b4c6d25 | ||
|
|
bbc87bded6 | ||
|
|
81a1f98ca5 | ||
|
|
06b48596f5 | ||
|
|
0c4dc1c24a | ||
|
|
af287fb8eb | ||
|
|
7688a9f626 | ||
|
|
9f62c660d7 | ||
|
|
cc9abd6e7e | ||
|
|
72150b1da7 | ||
|
|
b1565d01c4 | ||
|
|
3b1961d40d | ||
|
|
d7ffd46d89 | ||
|
|
8cb297a671 | ||
|
|
4be9abcdbc | ||
|
|
75f790160b | ||
|
|
4350cf540c | ||
|
|
dc9b99fe47 | ||
|
|
1dcb477fde | ||
|
|
7213271249 | ||
|
|
727f3e0529 | ||
|
|
0321fad531 | ||
|
|
33cc542e85 | ||
|
|
8bb50a6320 | ||
|
|
558d0fbd14 | ||
|
|
2d6f757114 | ||
|
|
0bf92703da | ||
|
|
0c365cfb9b | ||
|
|
aedbe70f63 | ||
|
|
e0f7284142 | ||
|
|
abc09951e1 | ||
|
|
e9ce423d8c | ||
|
|
aae7c8b73a | ||
|
|
1cd42480bf | ||
|
|
e848fb0d74 | ||
|
|
680b9d7731 | ||
|
|
49e59ab367 | ||
|
|
5ef342d905 | ||
|
|
86f3e2fdb1 | ||
|
|
e44cc81a03 | ||
|
|
2d5a062064 | ||
|
|
44363ce805 | ||
|
|
acdc0e3d6b | ||
|
|
dd9e7d6816 | ||
|
|
5e6b9009a0 | ||
|
|
761f193b0a | ||
|
|
80fefd29e4 | ||
|
|
eecf75029f | ||
|
|
f3e53e8a67 | ||
|
|
9bfdc31051 | ||
|
|
554f2a6842 | ||
|
|
4a2ed2f09f | ||
|
|
0ee6312164 | ||
|
|
717392246a | ||
|
|
6b75506e52 | ||
|
|
92232f3a78 | ||
|
|
64b168083f | ||
|
|
fa994f627e | ||
|
|
0e2ac9dd16 | ||
|
|
0ee684f718 | ||
|
|
e825f57f20 | ||
|
|
a5f92da05c | ||
|
|
41d939e32f | ||
|
|
c1f19bc9f7 | ||
|
|
d052b5a90c | ||
|
|
5908962cac | ||
|
|
a1a6e2531d | ||
|
|
86c059db3b | ||
|
|
46e12bffb6 | ||
|
|
6c494f1a2e | ||
|
|
c28d3d3ff9 | ||
|
|
882b9a8e1c | ||
|
|
0931e14a5a | ||
|
|
c687b42960 | ||
|
|
d4097e11c9 | ||
|
|
8a6afcdcf6 | ||
|
|
3b00e8acaa | ||
|
|
271de3c9de | ||
|
|
d6feaa1c75 | ||
|
|
eb0e33e0f5 | ||
|
|
7e1f0e1e48 | ||
|
|
adfe32ea1f | ||
|
|
058079bb19 | ||
|
|
0156c6f92e | ||
|
|
3ab16b3e40 | ||
|
|
f955b4b61d | ||
|
|
3fcfc9bc16 | ||
|
|
128403b487 | ||
|
|
60611fbd47 | ||
|
|
7d64e19f5a | ||
|
|
a4486f0cd9 | ||
|
|
22ae4f5a3c | ||
|
|
bcf7358072 | ||
|
|
b444894d88 | ||
|
|
205b3f35b9 | ||
|
|
ab61c599f9 | ||
|
|
430c12e2b2 | ||
|
|
3208e193d7 | ||
|
|
7848a2d03f | ||
|
|
962d9407c1 | ||
|
|
cf9975125d | ||
|
|
28793346ab | ||
|
|
19b49b3fc1 | ||
|
|
ff5680d010 | ||
|
|
309a9163bd | ||
|
|
ddde229665 | ||
|
|
19ad865f49 | ||
|
|
41c0e64eac | ||
|
|
e826a4122e | ||
|
|
0616167b0f | ||
|
|
3bde6495a3 | ||
|
|
649a7ac82c | ||
|
|
86154ba01d | ||
|
|
2eb1f26644 | ||
|
|
4fb6cd1b1e | ||
|
|
36e46831e0 | ||
|
|
eb11184ef0 | ||
|
|
656a1c17e4 | ||
|
|
b061bf9832 | ||
|
|
ee49804d93 | ||
|
|
6a1c354d3f | ||
|
|
1ca5543ecb | ||
|
|
79def3b196 | ||
|
|
1e5ca9ae9f | ||
|
|
c03f50530d | ||
|
|
010ce93e92 | ||
|
|
6df4a38a50 | ||
|
|
fd4937cd97 | ||
|
|
648d75c299 | ||
|
|
03824d5324 | ||
|
|
829e9d30fe | ||
|
|
4341224f6e | ||
|
|
c3d2a890d7 | ||
|
|
10e7985961 | ||
|
|
9d1306bf01 | ||
|
|
5c37df521e | ||
|
|
79b17caa73 | ||
|
|
3300f79501 | ||
|
|
046403dbbb | ||
|
|
a41b8993e5 | ||
|
|
09f4b0d409 | ||
|
|
81ccbdc743 | ||
|
|
e0235bb61b | ||
|
|
9035122c5f | ||
|
|
6bbe6f2b9d | ||
|
|
7e8bff904f | ||
|
|
1a3fd2f795 | ||
|
|
80fb289fc9 | ||
|
|
5045cdbe60 | ||
|
|
726ba653cf | ||
|
|
1cdc0e4c06 | ||
|
|
8564f5e409 | ||
|
|
a719eb98f1 | ||
|
|
a8da38c431 | ||
|
|
bc3b44acaa | ||
|
|
f5dcab0663 | ||
|
|
dd9fd9f12a | ||
|
|
f91e2693f9 | ||
|
|
7f8d51555b | ||
|
|
c1840e943d | ||
|
|
3b7b2ef6b7 | ||
|
|
eab5ea31ea | ||
|
|
51b1bf34b9 | ||
|
|
b85df20ba2 | ||
|
|
ab641e7320 | ||
|
|
e3decb34cb | ||
|
|
f8e94406df | ||
|
|
77e1b7038b | ||
|
|
6dafb928fe | ||
|
|
34c2bb0f0e | ||
|
|
a00fb1b2cf | ||
|
|
607bbb7e3a | ||
|
|
012d995ab1 | ||
|
|
99defe80a5 | ||
|
|
1a1775bae0 | ||
|
|
c720860ed3 | ||
|
|
64defd4d22 | ||
|
|
054d7cc006 | ||
|
|
c7f5318a41 | ||
|
|
fc38d1ca16 | ||
|
|
9451aae632 | ||
|
|
ae9e955f10 | ||
|
|
f6a889910a | ||
|
|
ae52b2a437 | ||
|
|
d5ebb27e2d | ||
|
|
10972f2666 | ||
|
|
affcc3babd | ||
|
|
4521852297 | ||
|
|
58ed9abf8d | ||
|
|
6684492033 | ||
|
|
26799953c9 | ||
|
|
36ebcf1949 | ||
|
|
8d988e5eae | ||
|
|
e926227b3e | ||
|
|
315136991d | ||
|
|
57bc9c54f3 | ||
|
|
b04c4ea500 | ||
|
|
50e85f57f2 | ||
|
|
d9249dd99a | ||
|
|
870252297a | ||
|
|
07c9bb7d8d | ||
|
|
2172a4478e | ||
|
|
8f0d2f9e4b | ||
|
|
bc7d29d46e | ||
|
|
d06532cb3e | ||
|
|
61933ceaa4 | ||
|
|
7a491db6c1 | ||
|
|
0fae7d3e77 | ||
|
|
0667b39554 | ||
|
|
de7f00d474 | ||
|
|
14f2db1eb2 | ||
|
|
e4ce88e7f1 | ||
|
|
21ab029532 | ||
|
|
543a46659b | ||
|
|
05f2a74ef5 | ||
|
|
4d8e691608 | ||
|
|
40386e1d40 | ||
|
|
a1fb870fe8 | ||
|
|
9d88b14f59 | ||
|
|
f91f2eb173 | ||
|
|
15b720046b | ||
|
|
0502a80dc7 | ||
|
|
17ae285f37 | ||
|
|
4637c09d19 | ||
|
|
8b7930f6c9 | ||
|
|
25b82b5b8c | ||
|
|
2cf8c125a5 | ||
|
|
ff5afa20f2 | ||
|
|
617525a573 | ||
|
|
c4f147ef01 | ||
|
|
14e5cc8357 | ||
|
|
b21ad7ad2d | ||
|
|
8493be9734 | ||
|
|
070645e329 | ||
|
|
0bbbdcb92f | ||
|
|
714db5cb3a | ||
|
|
e0fbdaa15e | ||
|
|
f9778df784 | ||
|
|
a20aebdef2 | ||
|
|
6a3b06e609 | ||
|
|
bb886be82e | ||
|
|
1b587b01ee | ||
|
|
b4851afbb7 | ||
|
|
fea4c4c84e | ||
|
|
5c62197542 | ||
|
|
017f3e5e4f | ||
|
|
7d88519c75 | ||
|
|
a7ec9dab95 | ||
|
|
9a43af3d83 | ||
|
|
b6f543df77 | ||
|
|
61675a7e19 | ||
|
|
1b41d56ad0 | ||
|
|
bc25a31733 | ||
|
|
22eb14c9d5 | ||
|
|
35c5908565 | ||
|
|
8ed773a437 | ||
|
|
efb4aa5b74 | ||
|
|
85e601eabc | ||
|
|
2b9ffb0bdb |
@@ -2,6 +2,7 @@ Makefile Makefile.in
|
|||||||
aclocal.m4
|
aclocal.m4
|
||||||
configure config.log config.cache config.guess config.status config.sub
|
configure config.log config.cache config.guess config.status config.sub
|
||||||
libtool ltconfig ltmain.sh
|
libtool ltconfig ltmain.sh
|
||||||
.psrc .inslog2 tca.map tca.log
|
autom4te.cache
|
||||||
*.rpt
|
.psrc .inslog2 tca.map tca.log pchdir *.rpt
|
||||||
update update-autoconf
|
update
|
||||||
|
WindowMaker*.tar.gz
|
||||||
|
|||||||
6
.cvsnotify
Normal file
6
.cvsnotify
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
#
|
||||||
|
# You can add here extra email addresses (one per line) where notifications
|
||||||
|
# should be sent on cvs commit.
|
||||||
|
# This is easier than to modify CVSROOT/loginfo to add extra addresses there.
|
||||||
|
# Lines that start with # or empty lines are ignored.
|
||||||
|
#
|
||||||
7
AUTHORS
7
AUTHORS
@@ -68,6 +68,9 @@ Various bugfixes
|
|||||||
Ullrich Hafner <hafner@bigfoot.de>
|
Ullrich Hafner <hafner@bigfoot.de>
|
||||||
Better detection of gfx libraries, added IconTitleColor/IconTitleBack
|
Better detection of gfx libraries, added IconTitleColor/IconTitleBack
|
||||||
|
|
||||||
|
Matthew Hawkins <matt@mh.dropbear.id.au>
|
||||||
|
former temporary project maintainer
|
||||||
|
|
||||||
Greg Hayes <sdc@choice.net>
|
Greg Hayes <sdc@choice.net>
|
||||||
Twisted miniaturization animation
|
Twisted miniaturization animation
|
||||||
|
|
||||||
@@ -102,7 +105,7 @@ EMACS/keypad like cursor movement for WINGs textfield
|
|||||||
Jim Knoble <jmknoble@pobox.com>
|
Jim Knoble <jmknoble@pobox.com>
|
||||||
made autoarrange icons a runtime option, SHADOW_RESIZEBAR c-time option,
|
made autoarrange icons a runtime option, SHADOW_RESIZEBAR c-time option,
|
||||||
no workspace switch to the same workspace, dashed icon selection,
|
no workspace switch to the same workspace, dashed icon selection,
|
||||||
misclellaneous bug fixes, definable cursors..
|
misclellaneous bug fixes, definable cursors, --no-polling command line option.
|
||||||
|
|
||||||
The JED Text Editor <xjed@windowmaker.org>
|
The JED Text Editor <xjed@windowmaker.org>
|
||||||
Project maintainer
|
Project maintainer
|
||||||
@@ -214,7 +217,7 @@ FRBall <frb@umr.edu>
|
|||||||
dgradient fix
|
dgradient fix
|
||||||
|
|
||||||
|
|
||||||
"]d" <id@maliwan.org>
|
"]d" <id@windowmaker.org>
|
||||||
Window list menu miniaturized/hidden hints, XDE support, XKB lock
|
Window list menu miniaturized/hidden hints, XDE support, XKB lock
|
||||||
language status, WINGs enhancements, bug fixes, window commands menu
|
language status, WINGs enhancements, bug fixes, window commands menu
|
||||||
enhancement, window move/resize by keyboard. GNUstepGlow.tiff icon,
|
enhancement, window move/resize by keyboard. GNUstepGlow.tiff icon,
|
||||||
|
|||||||
3
BUGFORM
3
BUGFORM
@@ -35,9 +35,6 @@ to bugs@windowmaker.org
|
|||||||
[ ] --enable-kanji
|
[ ] --enable-kanji
|
||||||
[ ] --disable-shape
|
[ ] --disable-shape
|
||||||
[ ] --enable-single-icon
|
[ ] --enable-single-icon
|
||||||
[ ] --enable-kde
|
|
||||||
[ ] --enable-gnome
|
|
||||||
[ ] --enable-openlook
|
|
||||||
[ ] --enable-modelock
|
[ ] --enable-modelock
|
||||||
[ ] Others: .......................
|
[ ] Others: .......................
|
||||||
|
|
||||||
|
|||||||
8
BUGS
8
BUGS
@@ -1,8 +1,12 @@
|
|||||||
|
Newly added
|
||||||
|
- after a crash, wmaker will forget the hidden state of the apps and just
|
||||||
|
show their windows minimized. normal restart is unaffected
|
||||||
|
- after a crash, wmaker will completely mess the window's saved geometries
|
||||||
|
and maximizing will have weird results. restart is unaffected
|
||||||
|
|
||||||
- wmaker will not stop managing a screen even if another window manager
|
- wmaker will not stop managing a screen even if another window manager
|
||||||
requests that, through the ICCCM 2.0 manager selection stuff
|
requests that, through the ICCCM 2.0 manager selection stuff
|
||||||
- stacking code is buggy (or XFree is buggy)
|
- stacking code is buggy (or XFree is buggy)
|
||||||
- after restart focus is losed or switched to another window. May be related
|
|
||||||
to the one above.
|
|
||||||
- save session doesnt work on some platforms (Alpha and Sparc)
|
- save session doesnt work on some platforms (Alpha and Sparc)
|
||||||
- texture pixmaps are being incorrectly freed somewhere. Either
|
- texture pixmaps are being incorrectly freed somewhere. Either
|
||||||
fix bug (to support broken MetroX servers) or remove all useless references
|
fix bug (to support broken MetroX servers) or remove all useless references
|
||||||
|
|||||||
@@ -29,7 +29,16 @@ xpm/textr.xpm
|
|||||||
xpm/tnew.xpm
|
xpm/tnew.xpm
|
||||||
inside Resources/Images.tiff "the little house", "the trash can",
|
inside Resources/Images.tiff "the little house", "the trash can",
|
||||||
"the folder", "the floppies"
|
"the folder", "the floppies"
|
||||||
|
Ear.png
|
||||||
|
Ftp.png
|
||||||
|
ICQ.png
|
||||||
|
Jabber.png
|
||||||
|
Mozilla.png
|
||||||
|
Pen.png
|
||||||
|
Pencil.png
|
||||||
|
Shell.png
|
||||||
|
Speaker.png
|
||||||
|
XChat.png
|
||||||
|
|
||||||
do What The Fuck you want to Public License
|
do What The Fuck you want to Public License
|
||||||
|
|
||||||
|
|||||||
427
ChangeLog
427
ChangeLog
@@ -1,3 +1,428 @@
|
|||||||
|
Changes since version 0.80.2:
|
||||||
|
.............................
|
||||||
|
|
||||||
|
- Some updates to WINGs WMConnection. See WINGs/ChangeLog for details.
|
||||||
|
- Fixed empty window list menu, if the window list menu was launched through
|
||||||
|
the root menu (sent by "Marc-Christian Petersen" <m.c.p@wolk-project.de>)
|
||||||
|
- Fixed dock's menu mapping position when dock is on the right side.
|
||||||
|
- Map clip's menu so that it never gets out of screen on the left or the right.
|
||||||
|
- Patch to add binary mode on opening files (needed for Windows with Cygwin)
|
||||||
|
(sent by luke <luke@posh.optushome.com.au>)
|
||||||
|
- Updated French translations (Antoine Hulin <antoine@origan.fdn.org>)
|
||||||
|
- Removed Hermes lib dependency in wrlib
|
||||||
|
- Put back asm/MMX code in wrlib
|
||||||
|
- Updated Russian locale files ("Andrew W. Nosenko" <awn@bcs.zp.ua>)
|
||||||
|
- API change in WINGs for WMDraw*String(). Details in WINGs/Changelog
|
||||||
|
- Removed obsoleted acconfig.h and implemented its functionality using
|
||||||
|
AC_DEFINE and AC_DEFINE_UNQUOTED as autoconf 2.5x recommends.
|
||||||
|
This will definitely enforce the need to use autoconf 2.5x
|
||||||
|
- Added Xft2 support to WINGs, for rendering antialiased fonts with
|
||||||
|
transparency. Details in WINGs/ChangeLog.
|
||||||
|
- Fixed problem with long, preset workspace names (Wanderlei Antonio Cavassin
|
||||||
|
<cavassin@conectiva.com.br>)
|
||||||
|
- Added kinput2 bug workaround to stock WMWindowAttributes (Seiichi SATO
|
||||||
|
<sato@cvs-net.co.jp>)
|
||||||
|
- Added Belarusian translation (Ihar Viarheichyk <iverg@mail.ru>)
|
||||||
|
- Fixed wrlib not to load braindead images with 0 sized width or height
|
||||||
|
- Removed double no-position-display when cycling position display types
|
||||||
|
with Shift key while moving windows.
|
||||||
|
- Changed the default position display while moving a window to 'Center'.
|
||||||
|
- Better outline when drawing balloons.
|
||||||
|
- Fixed wrlib to not accept too large images (fixes buffer overflow)
|
||||||
|
- Patched FAQ (David Coe <davidc@debian.org>)
|
||||||
|
- Fixed bug with resizebars appearing out of nothing when reloading configs
|
||||||
|
- Fixed sloppy focus bug (Pawel S. Veselov <Pawel.Veselov@Sun.COM>)
|
||||||
|
- Applied Xinerama patch (after fixes) from (Peter Zijlstra
|
||||||
|
<a.p.zijlstra@chello.nl>)
|
||||||
|
- Added switch to enable/disable antialiased fonts in WPrefs's Expert Settings
|
||||||
|
panel. (Temporary until the Font Settings panel in WPrefs is finished).
|
||||||
|
- Added a check that only %d is used in a font specification in WMGLOBAL and at
|
||||||
|
most once for each font in a fontset (eliminates a possible security exploit)
|
||||||
|
- Added fontpanel callback
|
||||||
|
- Fixed focus handling for windows that set WM_HINTS.take_focus = False.
|
||||||
|
- Fixed a problem in the stacking code which could lead to segmentation faults
|
||||||
|
(Jeff Teunissen <deek@d2dc.net>)
|
||||||
|
- Fixed a crashing bug in the menu code with modal panels involved.
|
||||||
|
- Fixed incorrect focusing of application's windows after an unhide (sometimes
|
||||||
|
the incorrect window got focus instead of the apps's last focused window)
|
||||||
|
- Unshade application's shaded windows when Dbl-MiddleClick-ing its appicon.
|
||||||
|
(this is to be consistent with deminiaturizing application's miniwindows
|
||||||
|
which also happens in this case, since shading is a form of miniaturization)
|
||||||
|
- Fixed bug with tpixmap from previous xinerama patch (reported by g0sh)
|
||||||
|
- Fixed edge resistance and move/resize frame drawing for borderless windows
|
||||||
|
- Fixed wrong display position for the move/resize widgets after xinerama
|
||||||
|
patch (Peter Zijlstra <a.p.zijlstra@chello.nl>)
|
||||||
|
- Fixed bug with cursor locked in drag mode after Alt-dragging a window
|
||||||
|
- Added Catalan translation (Ernest Adrogué <eadrogue@gmx.net>)
|
||||||
|
- Fixed a bug with deminiaturizing windows when the application is hidden and
|
||||||
|
the miniaturized window is selected from the window list menu
|
||||||
|
- Fixed a bug with not showing shaded window frames when the application is
|
||||||
|
hidden and another window belonging to the app is selected in the window
|
||||||
|
list menu
|
||||||
|
- Autoarrange icons after unhiding an application that has miniaturized
|
||||||
|
windows, else they may cover other icons which are now in the positions
|
||||||
|
they have occupied before hiding
|
||||||
|
- Fixed Clip's workspace menu mapping to be consistent with the others
|
||||||
|
- Fixed bug in wmsetbg that caused scale and maxscale to both do maxscale
|
||||||
|
(Alexey Voinov <voins@voins.program.ru>)
|
||||||
|
- Fixed bug with scrolling menus introduced by the xinerama patch.
|
||||||
|
- Fixed bug that could cause SIGSEGV by accessing beyond the end of text in
|
||||||
|
a WINGs textfield widget.
|
||||||
|
- Fixed small memory leak in WINGs' font panel code.
|
||||||
|
- Fixed memory leak in WINGs' file panel code.
|
||||||
|
- Updated Bulgarian translations (Anton Zinoviev <zinoviev@debian.org>)
|
||||||
|
- Fixed a bug in WINGs' hashtable which free'd the wrong memory in the
|
||||||
|
WMResetHashTable() function (possible source of SIGSEGVs)
|
||||||
|
- Fixed 2 syntax errors in plmenu.zh_TW.Big5 (Mike FABIAN <mfabian@suse.de>)
|
||||||
|
- Some .po file fixes (Mike FABIAN <mfabian@suse.de>)
|
||||||
|
- Fixed the problem with the root menu code changing the locale setting as
|
||||||
|
a side effect of loading a localized menu
|
||||||
|
- Fixed e memory leak in the code that reads a localized root menu
|
||||||
|
- Added support for generating pkgconfig files for WINGS, wmlib and wrlib.
|
||||||
|
("Marcelo E. Magallon" <mmagallo@debian.org>)
|
||||||
|
- Support for multiline balloons (Vitaly Ovtchinnikov <ov@rbcmail.ru>)
|
||||||
|
- Improved wsetfont (Mike FABIAN <mfabian@suse.de>)
|
||||||
|
- Updated single-click contrib patch (steve lion <steve.lion@verizon.net>
|
||||||
|
and vlaad)
|
||||||
|
- Updated French translations (Antoine Hulin <antoine@origan.fdn.org>)
|
||||||
|
- Xinerama support for Solaris
|
||||||
|
- Added global menu support (see NEWS)
|
||||||
|
- Fixed sloppy focus bug
|
||||||
|
- Made maximize behave differently with keyboard/mouse for xinerama
|
||||||
|
(Peter Zijlstra <a.p.zijlstra@chello.nl>)
|
||||||
|
- A few leftover xinerama fixes (Peter Zijlstra <a.p.zijlstra@chello.nl>)
|
||||||
|
- Extended the 'strut' to multiple heads
|
||||||
|
(Peter Zijlstra <a.p.zijlstra@chello.nl>)
|
||||||
|
- Icon placement now takes into account the new xinerama extended 'strut'
|
||||||
|
(Peter Zijlstra <a.p.zijlstra@chello.nl>)
|
||||||
|
- Icon arrangement that takes the new extended xinerama 'strut' into account
|
||||||
|
(Peter Zijlstra <a.p.zijlstra@chello.nl>)
|
||||||
|
- Fixed the 'KDE omnipresent' bug.
|
||||||
|
- Fixed bug with focusing a deminiaturized window with sloppy focus mode
|
||||||
|
- Fixed aspect of window list menu (window name was too close to workspace
|
||||||
|
indicator)
|
||||||
|
- Fixed menu panel in WPrefs.app. Explanatory text did not fit into the label
|
||||||
|
- Implemented a better logic to preserve the window's old geometry when
|
||||||
|
maximizing to support succesive maximizations in different directions
|
||||||
|
without the need to do an intermediary un-maximize step (eliminates flicker)
|
||||||
|
- Made keyboard/mouse maximization behavior consinstent relative to each other
|
||||||
|
- Enhanced wmsetbg's man page with description for -b | --back-color
|
||||||
|
(Marcelo E. Magallon <marcelo.magallon@bigfoot.com>)
|
||||||
|
- Do not use the disabled clip color for the clip's workspace navigation arrows
|
||||||
|
when the clip is collapsed (it made them look like disabled)
|
||||||
|
- Fixed bug with incorrect un-escaping if there is a dot in wm_class.
|
||||||
|
- Updated Catalan translations (Ernest Adrogue <eadrogue@gmx.net>)
|
||||||
|
- Updated Spanish translation of WPrefs (Alberto Gimenez <algibe@teleline.es>)
|
||||||
|
- Fixed synchronization problem between hair cursor and mouse cursor in
|
||||||
|
wmagnify with mouse cursor at the screen edge (Jon Diercks <jon@diercks.net>)
|
||||||
|
- Fixed 2 focus switching related bugs (Allan Peramaki <aperamak@cc.hut.fi>)
|
||||||
|
- Fixed a bug that made the crash panel to be shown again and again when the
|
||||||
|
'Restart Window Maker' option was selected, under some circumstances.
|
||||||
|
- Added workaround in global WMWindowAttributes, to avoid creating a second
|
||||||
|
appicon when a KDE3 application opens a config panel.
|
||||||
|
- Updated slovak translation (Jan Tomka <judas@linux.sk>)
|
||||||
|
- Added xdnd v3 support in WINGs (Sylvain Reynal <sreynal@nerim.net>)
|
||||||
|
- Check whether libXft is at least version 2.1.2 else refuse to compile.
|
||||||
|
- Fixed bug in icon chooser dialog that could cause a segmentation fault
|
||||||
|
in some cases (Pascal Hofstee <caelian@gmail.com>)
|
||||||
|
- Fixed crash in asm code in wrlib, with new versions of gcc.
|
||||||
|
- Fixed bug in the x86_PseudoColor_32_to_8() function which incorrectly
|
||||||
|
used the r, g, b fields in the conversion.
|
||||||
|
- Fixed x86 ASM code in wrlib to work on 64 bit architectures.
|
||||||
|
- Fixed the focus flicker seen with some apps (notably gtk2)
|
||||||
|
(Alexey Spiridonov <snarkmaster@gmail.com>)
|
||||||
|
- Fixed all crashing bugs that were generated by wmaker starting with the
|
||||||
|
WMState file missing.
|
||||||
|
- Added NetWM support (a modified version of the patch originaly written
|
||||||
|
by Peter Zijlstra <a.p.zijlstra@chello.nl>)
|
||||||
|
- Applied patch to enhance the Virtual Desktop behaviour, and to integrate
|
||||||
|
it with the NetWM code (Peter Zijlstra <a.p.zijlstra@chello.nl>)
|
||||||
|
- Applied a few xinerama and placement fixes (Peter Zijlstra
|
||||||
|
<a.p.zijlstra@chello.nl>)
|
||||||
|
- Fixed memory leak in dock code.
|
||||||
|
- Fixed and enhanced the text wrapping in WINGs.
|
||||||
|
- Fixed the layout of some elements in WPrefs.app
|
||||||
|
- Added workaround for aplications that don't set the required hints on the
|
||||||
|
client leader window, but they set them on normal windows (observer with
|
||||||
|
KDE 3.3.0 mainly). This will allow these apps to get an appicon again.
|
||||||
|
(they should be fixed still)
|
||||||
|
- Added workaround for applications that do not set a command with
|
||||||
|
XSetCommand(), but instead they set the _NET_WM_PID property. This works
|
||||||
|
with operating systems that offer a /proc interface similar to what linux
|
||||||
|
has. (This also is to fix problems with KDE 3.3.0 apps, but not only them).
|
||||||
|
- Fixed bug with autostart and exit scripts not being executed if user
|
||||||
|
GNUstep path was different from ~/GNUstep (when setting GNUSTEP_USER_ROOT)
|
||||||
|
- Removed legacy OFFIX_DND support code
|
||||||
|
- Fixed the signal handler for crashes (ie, removed it) and made wmaker
|
||||||
|
restarting be made automatically by a monitoring process.
|
||||||
|
- Made NetWM support be enabled by default
|
||||||
|
- Removed old code to store/restore workspace state (now relies on netwm)
|
||||||
|
- Added a (simple) Font Configuration for fontconfig fonts
|
||||||
|
- MacOS X style window switching panel (navigate through windows with Alt-Tab
|
||||||
|
or arrow keys)
|
||||||
|
- Added support for NET_WM_NAME/NET_WM_ICON_NAME
|
||||||
|
- Moved out font name conversion code from getstyle/setstyle/convertfonts and
|
||||||
|
made it support fontsets
|
||||||
|
- Converted all menu and po files to UTF-8
|
||||||
|
- Updated de.po (Thomas Otto <3.1415926535897932384626433832@gmx.net>)
|
||||||
|
- Fixed a crash bug when switching workspaces
|
||||||
|
- Removed obsoleted scripts from util: wsetfont, wmchlocale, wcopy, wpaste
|
||||||
|
|
||||||
|
|
||||||
|
Changes since version 0.80.1:
|
||||||
|
.............................
|
||||||
|
|
||||||
|
- Fixed a buffer overflow when allocating a RImage struct.
|
||||||
|
|
||||||
|
|
||||||
|
Changes since version 0.80.0:
|
||||||
|
.............................
|
||||||
|
|
||||||
|
- Fixed a bug that crashed wmaker when closing a window if multiple screens
|
||||||
|
were managed by wmaker (Valery Kotchiev <aggregator@nospam.dk>)
|
||||||
|
- Fixed a problem that crashed wmaker when trying to read an unexisting
|
||||||
|
WMState.<number> file on multihead system.
|
||||||
|
- Fixed problem with keyboard shortcuts executed an every screen for
|
||||||
|
multihead systems.
|
||||||
|
- Updated traditional chinese translations
|
||||||
|
- Fixed buglet in non-caching rootmenu option
|
||||||
|
("John H. Robinson, IV" <jhriv@ucsd.edu>)
|
||||||
|
- Added Malay translation
|
||||||
|
- Fixed problem with kcalc not having a miniaturize button.
|
||||||
|
- Added "Hide Others" to the window menu.
|
||||||
|
- Fixed text in info panel for multibyte (Seiichi SATO <ssato@sh.rim.or.jp>)
|
||||||
|
- Separated the font caches for normal fonts and fontsets in WINGs (they can
|
||||||
|
have the same names and collide in the cache giving unwanted results)
|
||||||
|
- Fixed Legal Panel not to display rectangles in place of new lines.
|
||||||
|
- Fixed problem with losing focus when changing to an empty workspace and back.
|
||||||
|
- Fixed another focus related problem when changing workspaces.
|
||||||
|
- Fixed problem with saving session when shared appicon is enabled (not
|
||||||
|
all instances were saved in the session, only one per shared appicon)
|
||||||
|
- Added support for the ukrainian language in wsetfont
|
||||||
|
(Bohdan Vlasyuk <bohdan@bodq.vstu.vinnica.ua>)
|
||||||
|
- Fixed a bug that crashed Window Maker when setting the "Emulate AppIcon"
|
||||||
|
option for a window using the window Inspector.
|
||||||
|
- Let XRender transparent window be see-through to desktop
|
||||||
|
- Added Greek (el) language pixmap (Michalis Kabrianis <Michalis@bigfoot.com>)
|
||||||
|
- Fixes icons being reduced twice when icon size != 64x64
|
||||||
|
Eduardo Pereira Habkost <ehabkost@conectiva.com.br>
|
||||||
|
- Fixed a bug that crashed wmaker when selecting the "Start alternate window
|
||||||
|
manager" option in the crashing dialog panel.
|
||||||
|
- Window Maker will now use the WINDOWMAKER_ALT_WM environment variable (if
|
||||||
|
it is defined) to overwrite the default hardcoded fallback window manager.
|
||||||
|
- Fixed marks for menu entries to be grayed as the text for disabled entries.
|
||||||
|
- Fixed Clip's "Autoraise" option to be marked as disabled when the
|
||||||
|
"Keep on Top" option is active.
|
||||||
|
- Added ability to browse for files/directories in the WPrefs menu editor.
|
||||||
|
- Added Czech translations of documentation (Jiri Hnidek <Jiri.Hnidek@vslib.cz>)
|
||||||
|
- Fixed segfault with incomplete WM_CLASS specifications.
|
||||||
|
- Fixed a bug about arranging subviews in a WMBox after removing a subview
|
||||||
|
and a memleak occuring in the same situation.
|
||||||
|
- Fixed a bug in wdread
|
||||||
|
- Fixed bug with windows that have WM_HINTS.take_focus = False. These windows
|
||||||
|
will not receive focus at all.
|
||||||
|
- Fixed a buffer overflow in winmenu.c
|
||||||
|
|
||||||
|
|
||||||
|
Changes since version 0.70.0:
|
||||||
|
.............................
|
||||||
|
|
||||||
|
- Disabled window birth animation by default (while it was ok with normal
|
||||||
|
windows, it was very annoying with menus editing in WPrefs.app)
|
||||||
|
- Added ability to shade/unshade a window using the mouse wheel.
|
||||||
|
- Fixed compilation for systems that required -lintl for WINGs
|
||||||
|
(Jim Knoble <jmknoble@pobox.com>)
|
||||||
|
- Removed redundant include/lib paths from the get-*-flags scripts
|
||||||
|
- Updated slovak .po files (Jan Tomka <judas@linux.sk>)
|
||||||
|
- Added "Save workspace state" switch button on the exit confirmation panel
|
||||||
|
(based on a patch sent by Jan Tomka <judas@linux.sk>)
|
||||||
|
- Fixed WPrefs crash when clicking on the menu editor to keep the current menu
|
||||||
|
(Alexey Voinov <voins@voins.program.ru>)
|
||||||
|
- Added patch to fix some gnome issues (Les Schaffer <schaffer@optonline.net>)
|
||||||
|
- SIGTERM is now handled and saves the internal state before exiting (like
|
||||||
|
SIGHUP and SIGINT already do). Now a "kill wmaker_pid" will exit cleanly
|
||||||
|
saving dock/clip/session information on exit.
|
||||||
|
- Added an internal strcasecmp() to WINGs (only on systems where's not present)
|
||||||
|
- Deminiaturizing a window that is also shaded, will perform an unshade too.
|
||||||
|
(Note that this only applies to deminiaturizing shaded windows. Unhiding
|
||||||
|
an application will keep the shaded/unshaded state of windows.)
|
||||||
|
- Removed compile time option for definable cursors and made them available by
|
||||||
|
default.
|
||||||
|
- Mapping a new window that belongs to a running application that is hidden,
|
||||||
|
will unhide the application.
|
||||||
|
- Added || pipe menu for generating non-cached menus
|
||||||
|
- Removed the collapse appicons thing.
|
||||||
|
- Added real appicon sharing (apps of the same kind will have a single shared
|
||||||
|
appicon).
|
||||||
|
- Fixed user and global defaults domain merging to preserve values present in
|
||||||
|
global but not in user, in sub-dictionaries.
|
||||||
|
- Made dock/clip steal appicons of applications that were started from a
|
||||||
|
shell/xterm or from the main menu, if there is a docked appicon of that
|
||||||
|
class that is not running at the time the app is launched.
|
||||||
|
- Added animation to show that the appicon was stolen by the dock (the way
|
||||||
|
NEXTSTEP did - map an appicon as it normally would have been, then slide it
|
||||||
|
to the position the docked appicon is).
|
||||||
|
- Updated the animation constants for scrolling/sliding/shading to better
|
||||||
|
adapt to newer/faster machines. Also used wusleep(10) when the delay was 0
|
||||||
|
to get rid of the jerky animation when there was no delay.
|
||||||
|
- Fixed bug with Unhide mapping windows from other workspaces.
|
||||||
|
- keyboard shortcuts are active during mouse window drag
|
||||||
|
- Saving a domain file will first strip all entries that are also present in
|
||||||
|
the global domain as well and are exactly the same. This fixes a bug where
|
||||||
|
settings from the global domain file were merged in the user domain file
|
||||||
|
and further changes in the global domain file for those merged values was
|
||||||
|
ignored making a system admin unable to set global defaults for all users
|
||||||
|
using the global domains.
|
||||||
|
- Fixed bug with improper setting of root/titlebar cursor (definable cursors).
|
||||||
|
|
||||||
|
Changes since version 0.65.1:
|
||||||
|
.............................
|
||||||
|
|
||||||
|
- fixed crash when saving empty menu item in WPrefs
|
||||||
|
- Fixed some more bash specific constructs in wsetfont.
|
||||||
|
(Marcelo E. Magallon <marcelo.magallon@bigfoot.com>)
|
||||||
|
- fixed crash with broken apps that set null WM_CLASS
|
||||||
|
- fixed crash when with gnome panel and multi-screens, some menu
|
||||||
|
updates and applied various other patches from
|
||||||
|
(Crutcher Dunnavant <crutcher@redhat.com>)
|
||||||
|
- po file fixes (Crutcher Dunnavant <crutcher@redhat.com>)
|
||||||
|
- replaced I18N_MB with I18N in one place in src/wconfig.h.in
|
||||||
|
- fixed default clip title font in WindowMaker.in
|
||||||
|
- fixed some locale related problems (Yukihiro Nakai <ynakai@redhat.com>)
|
||||||
|
- fixed a bug in RCombineAreaWithOpaqueness() (Brad <lists@anomie.yi.org>)
|
||||||
|
- added spanish INSTALL file (Efrain Maximiliano Palermo <max_drake2001@yahoo.com.ar>)
|
||||||
|
- updated Finnish pots (Tomi Kajala <tomi@iki.fi>)
|
||||||
|
- copy/paste launching in Dock
|
||||||
|
- fixed switch to wrong workspace bug (Masashi Shimbo <shimbo@cis.ibaraki.ac.jp>)
|
||||||
|
- added snprintf and removed XConvertCase usage for portability
|
||||||
|
- added wcopy/wpaste scripts from (<luke@research.canon.com.au>)
|
||||||
|
- added Xinerama support: see details in NEWS
|
||||||
|
- fixed artifact pattern left in TrueColor dithering code (visible with
|
||||||
|
tiled gradients)
|
||||||
|
- fixed bug in positioning of window list menu when opened by kbd
|
||||||
|
- internal code clean-up with notifications for window state change and other
|
||||||
|
stuff
|
||||||
|
- removed the libPropList dependancy by adding property list handling
|
||||||
|
code to WINGs. This code is not only better integrated with the other
|
||||||
|
WINGs data structures, but it's also more robust. Also a backward
|
||||||
|
compatibility header file is provided which maps old libPropList
|
||||||
|
function names to the new WINGs based proplist names allowing old code
|
||||||
|
to be linked to WINGs with minimal changes. For details on how to use
|
||||||
|
the compat mode, read the comments on top of WINGs/WINGs/proplist-compat.h
|
||||||
|
More details about this can be found in WINGs/ChangeLog and WINGs/NEWS.
|
||||||
|
Say bye, bye libPropList =)
|
||||||
|
- rewrote all Window Maker code to use the new WINGs based proplist functions.
|
||||||
|
- fixed a few compilation warnings and a problem caused by an uninitialized
|
||||||
|
variable.
|
||||||
|
|
||||||
|
|
||||||
|
Changes since version 0.65.0:
|
||||||
|
.............................
|
||||||
|
|
||||||
|
- removed FocusFollowMouse from wmaker and WPrefs
|
||||||
|
- fixed problem with alpha images showing a blue tint on big endian machines
|
||||||
|
- fixed problem with WINGs based apps exiting with a "X_RotateProperties"
|
||||||
|
related error when text was selected in a textfiled (including WPrefs.app
|
||||||
|
and Window Maker itself).
|
||||||
|
- fixed bug with maximization of windows with fixed resize increments
|
||||||
|
- added None geometry display type
|
||||||
|
- fixed window enumeration bug
|
||||||
|
- removed GNUisms from wsetfont (Marcelo E. Magallon <marcelo.magallon@bigfoot.com>, Masahide -mac- NODA <mac@clave.gr.jp>)
|
||||||
|
- added slovakian translations from (tomka@oalevice.sk)
|
||||||
|
- added WINGs i18n patch from tomka@oalevice.sk
|
||||||
|
- fixed wmsetbg.c to work in servers capable of multiple depths (overlay)
|
||||||
|
- added HMaximizeKey (Ruda Moura <ruda@conectiva.com.br>)
|
||||||
|
- fixed bad SIGPIPE handling setup across forks (Philippe Troin <phil@fifi.org>)
|
||||||
|
- added workaround for bug in locale handling on font set creation (Seiichi SATO <sato@cvs-net.co.jp>)
|
||||||
|
- Fixed some non-portable shell constructs used in installed scripts
|
||||||
|
(Johnny C. Lam <lamj@stat.cmu.edu>)
|
||||||
|
- Fixed crash with long titles in the window list menu (buffer overflow)
|
||||||
|
(Alban Hertroys <dalroi@wit401310.student.utwente.nl>, reported by
|
||||||
|
Robert Marshall <robert@chezmarshall.freeserve.co.uk>)
|
||||||
|
- Replaced almost all sprintf() calls with snprintf()
|
||||||
|
- fixed crash when removing menu entry for Window List or Workspace submenu
|
||||||
|
- added WINDOW_BIRTH_ZOOM2 (Éric Tremblay <delt@razorback.yi.org>)
|
||||||
|
|
||||||
|
Changes since version 0.64.0:
|
||||||
|
.............................
|
||||||
|
- fix with gnome hints stuff, related to tasklist/bar
|
||||||
|
- ripped off single appicon stuff
|
||||||
|
- added better appicon handling of apps of the same type
|
||||||
|
- applied patch for wkdemenu (Malcolm Cowe <malk@bruhaha.co.uk>)
|
||||||
|
- added WINDOWS_MENU submenu type for root menu (Bastien Nocera <hadess@hadess.net>)
|
||||||
|
- added kbd shortcuts for icon chooser
|
||||||
|
- use Hermes in wrlib
|
||||||
|
- removed MOUSE_WS_WHEEL #defines
|
||||||
|
- fixed bug with multibyte text on libc5 systems (Osamu Ajiki <osam-a@astroarts.co.jp>)
|
||||||
|
- fixed race conditions on signal handlers
|
||||||
|
- SIGINT will gently exit, SIGTERM will not be handled
|
||||||
|
- When Window Maker calls wmsetbg to set the background, it will consider the
|
||||||
|
value of the DisableDithering option and pass the right switch to wmsetbg.
|
||||||
|
- fixed a memleak in the dialog panels.
|
||||||
|
- made "Keep on Top" in the dock/clip menu a checked menu entry. It's _much_
|
||||||
|
easier to work with it this way.
|
||||||
|
- Fixed problem with GNOME apps that have windows which need to stay on the
|
||||||
|
desktop level.
|
||||||
|
- Fixed incorrect parsing of display and screen number from $DISPLAY.
|
||||||
|
- Organized the inspector panel a bit better.
|
||||||
|
- Replaced bags with arrays wherever appropriate. This will improve
|
||||||
|
performance a bit.
|
||||||
|
- Made the Gnome tasklist skip the windows with the "Skip window list" flag
|
||||||
|
enabled. (Bastien Nocera <hadess@hadess.net>)
|
||||||
|
- Fixed crashing bug when name and class were empty for a docked app.
|
||||||
|
- Removed MIN() and MAX() macros and replaced them with WMIN() and WMAX() from
|
||||||
|
WINGs.
|
||||||
|
- Added a hint that Window Maker crashed, to allow windows to be placed
|
||||||
|
correctly after a crash situation.
|
||||||
|
- Added a hint that Window Maker crashed, to allow windows to be placed
|
||||||
|
in their correct previous positions after a crash situation and also to
|
||||||
|
preserve their state before the crash (minimized, shaded, hidden, ...)
|
||||||
|
- Fixed wrong mapping position of the "Docked Applications Panel" for some
|
||||||
|
icons.
|
||||||
|
- Smoother animation for the smiley =)
|
||||||
|
- Added retain/release mechanism for RImages. RDestroyImage() has become
|
||||||
|
obsolete. More about this can be found in wrlib/Changelog and wrlib/NEWS.
|
||||||
|
- Small API change in WINGs to allow images with alpha blending set as the
|
||||||
|
application icons be shown correctly. More about this in WINGs/Changelog
|
||||||
|
and WINGs/NEWS.
|
||||||
|
- Made images with alpha blending be shown correctly in the panels and the
|
||||||
|
icon chooser.
|
||||||
|
- The icon image set to be shown in panels ("Logo.WMPanel") will be
|
||||||
|
automatically updated if its entry in WMWindowAttributes changes (without
|
||||||
|
a need to restart as until now).
|
||||||
|
- Fixed a bug in the icon chooser dialog that made the selected icon look
|
||||||
|
wrong if it had alpha blending.
|
||||||
|
- Removed the following 3 options from configuration: SelectWindowsMouseButton,
|
||||||
|
WindowListMouseButton and ApplicationMenuMouseButton.
|
||||||
|
- Added 4 options to the configuration file for binding workspace actions to
|
||||||
|
mouse buttons: MouseLeftButtonAction, MouseMiddleButtonAction,
|
||||||
|
MouseRightButtonAction and MouseWheelAction. They replace the above 3
|
||||||
|
removed options, but use a different semantic. More in NEWS.
|
||||||
|
- client supplied icons that were saved by Window Maker in the directory
|
||||||
|
~/GNUstep/.AppInfo/WindowMaker/ will be recreated if missing when the
|
||||||
|
application starts.
|
||||||
|
- fixed a small memleak when the client supplied icon was extracted and saved.
|
||||||
|
|
||||||
|
|
||||||
|
Changes since version 0.63.1:
|
||||||
|
.............................
|
||||||
|
- fixed messup in get-{wings,wutil,wraster}-flags
|
||||||
|
- fixed #wmdatadir# substitution in wmaker.inst
|
||||||
|
(Seiichi SATO <sato@cvs-net.co.jp>)
|
||||||
|
- Removed spurious focus disabling for GNUstep applications - but retain
|
||||||
|
code that lets GNUstep apps control their window titlebar.
|
||||||
|
(Richard Frith-Macdonald <rfm@gnu.org>)
|
||||||
|
- Fixed broken panels.
|
||||||
|
- Renamed se.po to sv.po
|
||||||
|
- New version of wkdemenu.pl (from Malcolm Cowe <malk@bruhaha.co.uk>)
|
||||||
|
- new updated Slovak translations (Jan Tomka/judas@hell <tomka@oalevice.sk>)
|
||||||
|
- integrated the 'no polling' patch from Jim Knoble <jmknoble@jmknoble.cx>.
|
||||||
|
- new wsetfont script (Anton Zinoviev <zinoviev@debian.org>)
|
||||||
|
- lots of i18n fixes (Jan Tomka/judas@hell <tomka@oalevice.sk>)
|
||||||
|
- window levels changed to match GNUstep <rfm@gnu.org> ... src/GNUstep.h
|
||||||
|
src/WindowMaker.h src/window.c wmlib/WMaker.h WINGs/WINGs/WINGs.h
|
||||||
|
|
||||||
|
|
||||||
Changes since version 0.63.0:
|
Changes since version 0.63.0:
|
||||||
.............................
|
.............................
|
||||||
- fixed compile prob with SGI compiler
|
- fixed compile prob with SGI compiler
|
||||||
@@ -16,6 +441,7 @@ Changes since version 0.63.0:
|
|||||||
- fixed WindozeCycling config in WPrefs
|
- fixed WindozeCycling config in WPrefs
|
||||||
- fixed circulate raise withour WindozeCycling
|
- fixed circulate raise withour WindozeCycling
|
||||||
|
|
||||||
|
|
||||||
Changes since version 0.62.1:
|
Changes since version 0.62.1:
|
||||||
.............................
|
.............................
|
||||||
- added blackbox style igradient (interwoven)
|
- added blackbox style igradient (interwoven)
|
||||||
@@ -68,6 +494,7 @@ Changes since version 0.62.0:
|
|||||||
- fixed sticky hint handling in GNOME
|
- fixed sticky hint handling in GNOME
|
||||||
- fixed saving of maximized state for restart
|
- fixed saving of maximized state for restart
|
||||||
|
|
||||||
|
|
||||||
Changes since version 0.61.1:
|
Changes since version 0.61.1:
|
||||||
.............................
|
.............................
|
||||||
|
|
||||||
|
|||||||
61
FAQ
61
FAQ
@@ -234,14 +234,11 @@ inside the WindowMaker directory.
|
|||||||
Installation:
|
Installation:
|
||||||
-=-=-=-=-=-=-
|
-=-=-=-=-=-=-
|
||||||
|
|
||||||
2.1 Where can I get proplist.h?
|
2.1 Where can I get libPropList/proplist.h?
|
||||||
-------------------------------
|
-------------------------------------------
|
||||||
You didn't read the INSTALL file, did you? Please read that now.
|
starting with Window Maker 0.70.0, libPropList is no longer needed.
|
||||||
libPropList is downloaded seperately and you need to install it _before_
|
It was obsoleted by adding property list handling code to the WINGs library.
|
||||||
attempting to configure Window Maker.
|
|
||||||
|
|
||||||
You can find a gzipped tar archive of libPropList at
|
|
||||||
ftp://ftp.windowmaker.org/pub/libs/
|
|
||||||
|
|
||||||
|
|
||||||
2.2 Why do no icons show up after installing Window Maker >= 0.15.x
|
2.2 Why do no icons show up after installing Window Maker >= 0.15.x
|
||||||
@@ -368,8 +365,8 @@ for your convenience.
|
|||||||
|
|
||||||
|
|
||||||
2.8 Can I use WindowMaker with KDE or GNOME or CDE?
|
2.8 Can I use WindowMaker with KDE or GNOME or CDE?
|
||||||
----------------------------------
|
---------------------------------------------------
|
||||||
Contrary to a lot of people thinks, KDE is NOT a window manager. KDE is
|
Contrary to a lot of people think, KDE is NOT a window manager. KDE is
|
||||||
a suite of various applications that includes a custom window manager (kwm).
|
a suite of various applications that includes a custom window manager (kwm).
|
||||||
The same is true for CDE.
|
The same is true for CDE.
|
||||||
|
|
||||||
@@ -389,7 +386,7 @@ mouse.
|
|||||||
|
|
||||||
|
|
||||||
2.9 How do I get Window Maker working with xdm in Redhat 5.[01]?
|
2.9 How do I get Window Maker working with xdm in Redhat 5.[01]?
|
||||||
----------------------------------
|
----------------------------------------------------------------
|
||||||
After running wmaker.inst and letting it write to .xinitrc,
|
After running wmaker.inst and letting it write to .xinitrc,
|
||||||
cp .xinitrc .xsession
|
cp .xinitrc .xsession
|
||||||
and make sure that /usr/local/bin is in your $PATH for the Xserver. You can
|
and make sure that /usr/local/bin is in your $PATH for the Xserver. You can
|
||||||
@@ -1077,22 +1074,35 @@ to force the modification time into the future.
|
|||||||
4.16 How can I set dock/clip to use single click to launch
|
4.16 How can I set dock/clip to use single click to launch
|
||||||
applications, instead of double click?
|
applications, instead of double click?
|
||||||
----------------------------------
|
----------------------------------
|
||||||
You cannot do this. This is because single click is used to select app-icons,
|
This question was officially answered as follows:
|
||||||
or to raise/lower the app-icon or the dock/clip.
|
|
||||||
If this is impelmented then you will be unable to select or raise/lower
|
|
||||||
dock/clip or app-icons, without also launching the application it represents.
|
|
||||||
|
|
||||||
So don't ask for this to be implemented, because it will not be. Double
|
You cannot do this. This is because single click is used to select
|
||||||
click is used for a reason, is not just some weird idea we got in a morning
|
app-icons, or to raise/lower the app-icon or the dock/clip. If
|
||||||
when we wake up too early.
|
this is impelmented then you will be unable to select or
|
||||||
|
raise/lower dock/clip or app-icons, without also launching the
|
||||||
|
application it represents.
|
||||||
|
|
||||||
|
So don't ask for this to be implemented, because it will not
|
||||||
|
be. Double click is used for a reason, is not just some weird idea
|
||||||
|
we got in a morning when we wake up too early.
|
||||||
|
|
||||||
|
Regardless of that, there is now an option in WPrefs, under "Expert
|
||||||
|
User Preferences," which allows you to set "Launch applications and
|
||||||
|
restore windows with a single click." (See the files contrib/README
|
||||||
|
and contrib/single_click.diff in the source package for details.)
|
||||||
|
|
||||||
|
If you set that option, a left button single click will launch or
|
||||||
|
restore, rather than select, the app-icon. You can use other methods
|
||||||
|
(or temporarily turn the option off again) to select app-icons or
|
||||||
|
raise/lower the dock/clip. You can toggle the selected state of any
|
||||||
|
app-icon via its right button menu, and there are auto-raise and
|
||||||
|
keep-on-top options for the dock and clip.
|
||||||
|
|
||||||
|
|
||||||
4.18 How do I restore the configuration app to the dock?
|
4.18 How do I restore the configuration app to the dock?
|
||||||
----------------------------------]
|
----------------------------------]
|
||||||
You should start it from a terminal using its full path name, which is
|
You should start it from a terminal using its full path name, which is
|
||||||
/usr/local/GNUstep/Apps/WPrefs.app/WPrefs
|
/usr/local/GNUstep/Applications/WPrefs.app/WPrefs
|
||||||
by default.
|
by default.
|
||||||
|
|
||||||
|
|
||||||
@@ -1301,14 +1311,8 @@ in routines/xsci/jpc_SGraph.c
|
|||||||
5.12 Netscape shows black and white icons
|
5.12 Netscape shows black and white icons
|
||||||
----------------------------------
|
----------------------------------
|
||||||
|
|
||||||
This is because Netscape uses monochrome icons when running under olwm
|
I have seen this happen on some systems if you run Netscape in a high
|
||||||
and you are using the OPEN LOOK emulation option. If you do not use any XView
|
colour depth (32bpp). That is a Netscape bug. Therefore, bug Netscape.
|
||||||
apps anyway, recompile Window Maker without the --enable-openlook option.
|
|
||||||
If you need OPEN LOOK emulation, you will have to get used to the monochrome
|
|
||||||
icons or change then manually in the Attributes panel for each window.
|
|
||||||
I have also seen this happen on some systems if you run Netscape in a high
|
|
||||||
colour depth (32bpp) regardless of whether you're using openlook or not.
|
|
||||||
That is a Netscape bug. Therefore, bug Netscape.
|
|
||||||
|
|
||||||
|
|
||||||
5.13 Snow flakes from xsnow don't acumulate on titlebars!
|
5.13 Snow flakes from xsnow don't acumulate on titlebars!
|
||||||
@@ -1460,11 +1464,14 @@ the files manually. Or download the whole distribution.
|
|||||||
|
|
||||||
|
|
||||||
7.5 Will you add GNOME or KDE support?
|
7.5 Will you add GNOME or KDE support?
|
||||||
----------------------------------
|
--------------------------------------
|
||||||
|
|
||||||
Support for GNOME (and KDE) hints is included since 0.50.0. You have to
|
Support for GNOME (and KDE) hints is included since 0.50.0. You have to
|
||||||
enable them at compile-time using the appropriate arguments to ./configure.
|
enable them at compile-time using the appropriate arguments to ./configure.
|
||||||
Please read the INSTALL file for more details.
|
Please read the INSTALL file for more details.
|
||||||
|
Note: starting with version 0.90.0, support for legacy Gnome-1.x and KDE-2.x
|
||||||
|
was dropped in favor of NETWM support (used by both Gnome-2.x and KDE-3.x)
|
||||||
|
|
||||||
|
|
||||||
-=-=-=-=-
|
-=-=-=-=-
|
||||||
Themes:
|
Themes:
|
||||||
|
|||||||
33
FAQ.I18N
33
FAQ.I18N
@@ -32,24 +32,35 @@ If I18N support does not work for you, check these:
|
|||||||
here:
|
here:
|
||||||
ftp://ftp.linux.or.jp/pub/RPM/glibc
|
ftp://ftp.linux.or.jp/pub/RPM/glibc
|
||||||
|
|
||||||
- if you'd like to display multibyte characters, set the
|
|
||||||
MultiByteText option to YES in ~/GNUstep/Defaults/WindowMaker
|
|
||||||
and ~/GNUstep/Defaults/WMGLOBAL
|
|
||||||
|
|
||||||
- the fonts you're using support your locale. if your font
|
- the fonts you're using support your locale. if your font
|
||||||
setting on $HOME/GNUstep/Defaults/WindowMaker is like..
|
setting on $HOME/GNUstep/Defaults/WindowMaker is like..
|
||||||
|
|
||||||
WindowTitleFont = "-*-helvetica-bold-r-normal-*-12-*-*-*-*-*-*-*";
|
WindowTitleFont = "Trebuchet MS:bold:pixelsize=12";
|
||||||
MenuTitleFont = "-*-helvetica-bold-r-normal-*-12-*-*-*-*-*-*-*";
|
MenuTitleFont = "Trebuchet MS:bold:pixelsize=12";
|
||||||
......................................................
|
......................................................
|
||||||
|
|
||||||
then you can't display non iso8859-x charcters by helvetica.
|
then you can't display asian language (ja,ko,ch) characters using
|
||||||
so quick way to display various languages' font is to change
|
Trebuchet MS. A font that is guaranteed to work for any language is
|
||||||
all the font settings into:
|
sans (or sans-serif). sans is not a font itself, but an alias which
|
||||||
|
points to multiple fonts and will load the first in that list that
|
||||||
|
has the ability to show glyphs in your language. If you don't know
|
||||||
|
a font that is suited for you language you can always set all your
|
||||||
|
fonts to something like:
|
||||||
|
|
||||||
"-*-*-medium-r-normal-*-14-*-*-*-*-*-*-*"
|
"sans:pixelsize=12"
|
||||||
|
|
||||||
and also you need to change font settings in style files in
|
However, please note that if your font is something like:
|
||||||
|
|
||||||
|
"Trebuchet MS,Luxi Sans,sans:pixelsize=12"
|
||||||
|
|
||||||
|
this will not be able to display asian languages if any of the
|
||||||
|
previous fonts before sans are installed. This is because unlike
|
||||||
|
the proper font pickup that sans guarantees for your language,
|
||||||
|
this construct only allows a font fallback mechanism, which tries
|
||||||
|
all the fonts in the list in order, until it finds one that is
|
||||||
|
available, even if it doesn't support your language.
|
||||||
|
|
||||||
|
Also you need to change font settings in style files in
|
||||||
the "$HOME/Library/WindowMaker/Style" directory.
|
the "$HOME/Library/WindowMaker/Style" directory.
|
||||||
|
|
||||||
- the LC_CTYPE environment variable is unset or it has the correct
|
- the LC_CTYPE environment variable is unset or it has the correct
|
||||||
|
|||||||
64
FAQ.I18N.cs
Normal file
64
FAQ.I18N.cs
Normal file
@@ -0,0 +1,64 @@
|
|||||||
|
Často kladené otázky na podporu místního nastavení
|
||||||
|
==================================================
|
||||||
|
|
||||||
|
Pokud vám nefunguje podpora I18N, tak zkontrolujte tato nastavení:
|
||||||
|
|
||||||
|
- systémová proměnná LANG musí být nastavená tak, aby odpovídala vašemu
|
||||||
|
místnímu nastavení (čeština = czech), vaše místní nastavení musí být
|
||||||
|
podporovatelné vaším operačním systémem nebo X emulací. Všechny
|
||||||
|
podporovatelné lokalizace zobrazíte příkazem "locale -a". Měli byste
|
||||||
|
také zkontrolovat, zda-li je vaše místní nastavení podporované
|
||||||
|
X emulací. Soubor: "/usr/X11R6/lib/X11/locale/locale.alias" by měl
|
||||||
|
obsahovat podobnou sekvenci (podpora pro češtinu):
|
||||||
|
|
||||||
|
cs cs_CZ.ISO8859-2
|
||||||
|
cs_CS cs_CZ.ISO8859-2
|
||||||
|
cs_CS.ISO8859-2 cs_CZ.ISO8859-2
|
||||||
|
cs_CZ cs_CZ.ISO8859-2
|
||||||
|
cs_CZ.iso88592 cs_CZ.ISO8859-2
|
||||||
|
cz cz_CZ.ISO8859-2
|
||||||
|
cz_CZ cz_CZ.ISO8859-2
|
||||||
|
|
||||||
|
- zkontrolujte použití správných fontů pro vaše místní nastavení.
|
||||||
|
Pokud nepoužíváte správné fonty s kódováním, které je nastaveno v
|
||||||
|
Xlib nebo libc, tak se můžou dít "dost divné věci". Zkuste explicitně
|
||||||
|
zadat kování do proměnné LANG: LANG=cs_CS.ISO8859-2 nebo
|
||||||
|
LANG=cs_CZ.iso88592 a znovu zkontrolujte:
|
||||||
|
"/usr/X11R6/lib/X11/locale/locale.alias"
|
||||||
|
|
||||||
|
- pokud váš operační systém nepodporuje místní nastavení (locales), nebo
|
||||||
|
pokud váš OS nepodporuje místní nastavení pro váš jazyk, můžete
|
||||||
|
použít emulaci místního nastavení X Window Systému. Zprovoznit tuto
|
||||||
|
emulaci je možné spuštěním ./configure s volbou "--witn-x-locale".
|
||||||
|
Pokud používáte nějaký komerční systém jako je například IRIX, AIX,
|
||||||
|
Solaris, ...,tak asi X emulaci nebudete potřebovat. Ovšem pokud je
|
||||||
|
vaším operačním systémem Linux, NetBSD nebo jiný užasný, volně
|
||||||
|
šiřitelný operační systém, tak je možné, že vaše místní nastavení
|
||||||
|
zatím není podporované. Potom použijte volbu "--witn-x-locale".
|
||||||
|
|
||||||
|
Pozn: Aby jste mohli používat X emulaci místních nastavení, tak vaše
|
||||||
|
Xlib musí být zkompilované s touto podporou. Xlib v RedHat 5.0
|
||||||
|
tak zkompilované nejsou (RH4.x jsou OK). Překompilované Xlib
|
||||||
|
s podporou pro emulací místních nastavení pro RH5.0 jsou
|
||||||
|
dostupné na adrese:
|
||||||
|
|
||||||
|
ftp://ftp.linux.or.jp/pub/RPM/glibc
|
||||||
|
|
||||||
|
- fonty, které používáte by měli být podporované vaším místním nastavením.
|
||||||
|
Jestliže vaše nastavení fontů v souboru ~/GNUstep/Defaults/WindowMaker
|
||||||
|
vypadá takto:
|
||||||
|
|
||||||
|
WindowTitleFont = "-*-helvetica-bold-r-normal-*-12-*-*-*-*-*-*-*";
|
||||||
|
MenuTitleFont = "-*-helvetica-bold-r-normal-*-12-*-*-*-*-*-*-*"; ,
|
||||||
|
|
||||||
|
nemůžete zobrazovat znaky jiné než iso8859-x ve fontu helvetica.
|
||||||
|
Jednoduchý způsob, jak zobrazovat znaky různých jazyků, je nastavit všechny
|
||||||
|
fonty takto:
|
||||||
|
|
||||||
|
"-*-*-medium-r-normal-*-14-*-*-*-*-*-*-*"
|
||||||
|
|
||||||
|
Také je nutné změnit nastavení fontů v souborech stylů v adresáři:
|
||||||
|
~/Library/WindowMaker/Style.
|
||||||
|
|
||||||
|
- pokud si nejste jisti, zda-li má systémová proměnná LC_TYPE správnou
|
||||||
|
hodnotu, tak ji nenastavujte.
|
||||||
57
FAQ.I18N.sk
Normal file
57
FAQ.I18N.sk
Normal file
@@ -0,0 +1,57 @@
|
|||||||
|
(Toto je len preklad dosť starého súboru! Ak by ste mali skutočne problémy
|
||||||
|
s Window Makerom a slovenčinou a v tomto súbore by ste nenašli pomoc,
|
||||||
|
pošlite popis problému na adresu <judas@linux.sk>.)
|
||||||
|
|
||||||
|
Ak vám nefunguje podpora miestnych nastavení, skontrolujte nasledujúce:
|
||||||
|
|
||||||
|
- premenná LANG je nastavená na vaše miestne nastavenia a tieto
|
||||||
|
sú podporované vašim OS alebo X emuláciou. Zoznam podporovaných
|
||||||
|
miestnych nastavení získate príkazom "locale -a". Zoznam
|
||||||
|
miestnych nastvení podporovaných X emuláciou sa nachádza v
|
||||||
|
súbore "/usr/X11R6/lib/X11/locale/locale.alias".
|
||||||
|
|
||||||
|
- používate správne fonty pre svoje miestne nastavenia. Ak
|
||||||
|
používate font s odlišným kódovaním ako je nastavené v Xlib
|
||||||
|
alebo libc, môžu sa diať čudné veci. Skúste explicitne zadať
|
||||||
|
kókovanie do premennej LANG, teda sk_SK.ISO-8859-2. Znovu,
|
||||||
|
pozrite si súbor "/usr/X11R6/lib/X11/locale/locale.aliax".
|
||||||
|
|
||||||
|
- ak váš OS nepodporuje žiadne miestne nastavenia alebo váš OS
|
||||||
|
nepodporuje vaše miestne nastavenia, môžete použiť emuláciu
|
||||||
|
podpory miestnych nastavení X Window Systému. To urobíte
|
||||||
|
voľbou "--with-x-locale" skriptu configure. Ak používate
|
||||||
|
komerčný OS ako Solaris, IRIX, AIX, ..., pravdepodobne
|
||||||
|
nepotrebujete použiť X emuláciu miestnych nastavení. Ale ak
|
||||||
|
je váš OS Linux alebo NetBSD alebo ..., je možné, že vaše
|
||||||
|
miestne nastavenia ešte nie sú podporované. Vtedy použite
|
||||||
|
"--with-x-locale".
|
||||||
|
|
||||||
|
Pozor: aby ste mohli používať X emuláciu miestnych nastvení,
|
||||||
|
vaša Xlib musí byť skompilovaná s touto podporou.
|
||||||
|
Xlib v Linux RedHat5.0 tak skompilovaná nie je.
|
||||||
|
(RH4.x je v poriadku). Prekompilovaná Xlib pre
|
||||||
|
RH5.0 s podporou emulácie miestnych nastavení je
|
||||||
|
dostupná na adrese
|
||||||
|
|
||||||
|
ftp://ftp.linux.or.jp/pub/RPM/glibc
|
||||||
|
|
||||||
|
- fonty, ktoré používate, podporujú vaše miesne nastavenia.
|
||||||
|
Ak vaše nastavenia fontov v ~/GNUstep/Defaults/WindowMaker
|
||||||
|
vyzerajú takto:
|
||||||
|
|
||||||
|
WindowTitleFont = "-*-helvetica-bold-r-normal-*-12-*-*-*-*-*-*-*";
|
||||||
|
MenuTitleFont = "-*-helvetica-bold-r-normal-*-12-*-*-*-*-*-*-*";
|
||||||
|
......................................................
|
||||||
|
|
||||||
|
potom nemôžete zobrazovať znaky iné ako iso8859-x vo fonte
|
||||||
|
helvetica. Jednoduchý spôsob ako zobrazovať znaky rôznych
|
||||||
|
jazykov je nastaviť všetky fonty takto:
|
||||||
|
|
||||||
|
"-*-*-medium-r-normal-*-14-*-*-*-*-*-*-*"
|
||||||
|
|
||||||
|
a tiež potrebujete zmeniť nastavenia fontov v súboroch štýlov
|
||||||
|
v adresári ~/Library/WindowMaker/Style.
|
||||||
|
|
||||||
|
- premenná LC_CTYPE nie je nastavená alebo má správnu hodnotu. Ak
|
||||||
|
si nie ste istí, nenastavujte ju.
|
||||||
|
|
||||||
151
INSTALL
151
INSTALL
@@ -21,6 +21,7 @@ SUPPORTED PLATFORMS
|
|||||||
- Solaris 2.5.1, 2.5.2
|
- Solaris 2.5.1, 2.5.2
|
||||||
- Solaris 2.6.0
|
- Solaris 2.6.0
|
||||||
- Solaris 2.7beta
|
- Solaris 2.7beta
|
||||||
|
- Solaris 2.8 on Ultra Sparc 10 and E450
|
||||||
- SCO Unix
|
- SCO Unix
|
||||||
- SGI Irix 5.x, 6.5
|
- SGI Irix 5.x, 6.5
|
||||||
- OSF/1
|
- OSF/1
|
||||||
@@ -37,7 +38,13 @@ SUPPORTED PLATFORMS
|
|||||||
- PowerMac / Power MachTen 4.1.1 over MacOS
|
- PowerMac / Power MachTen 4.1.1 over MacOS
|
||||||
- Amiga 3000 running RedHat Linux 5.1 (Rawhide)
|
- Amiga 3000 running RedHat Linux 5.1 (Rawhide)
|
||||||
- IBM S/390 running Linux
|
- IBM S/390 running Linux
|
||||||
|
- IBM S/390 running Conectiva Linux (experimental)
|
||||||
- iBook running Darwin
|
- iBook running Darwin
|
||||||
|
- Darwin PPC / Macos X
|
||||||
|
- Windows NT with Cygwin/XFree86
|
||||||
|
- Sony PlayStation2 running Linux
|
||||||
|
|
||||||
|
All registered trademarks are registered by their owners. (duh)
|
||||||
|
|
||||||
Patches to make it work on other platforms are welcome.
|
Patches to make it work on other platforms are welcome.
|
||||||
|
|
||||||
@@ -57,34 +64,18 @@ The following software is required to use Window Maker:
|
|||||||
The following is required to build Window Maker:
|
The following is required to build Window Maker:
|
||||||
|
|
||||||
- Basic obvious stuff
|
- Basic obvious stuff
|
||||||
If you will build Window Maker, make sure you have gcc (or some
|
gcc (or some other ANSI C compiler)
|
||||||
other ANSI C compiler) and the X header files installed. Specially
|
glibc development files (usually glibc-devel in Linux distributions)
|
||||||
for newbie Linux users: you must install all X development packages
|
X development files (XFree86-devel or something similar)
|
||||||
and the gcc suite. Otherwise you won't be able to build any X
|
|
||||||
program, including Window Maker.
|
|
||||||
|
|
||||||
- libPropList
|
|
||||||
This library can be found in ftp://ftp.windowmaker.org/pub/libs
|
|
||||||
or in ftp://ftp.gnome.org/pub/libPropList
|
|
||||||
Install it before building Window Maker.
|
|
||||||
|
|
||||||
- autoconf, automake and libtool
|
- autoconf, automake and libtool
|
||||||
These tools are NOT needed, but IF you have one or
|
autoconf 2.54
|
||||||
more of them installed, make sure you have ALL of the following
|
|
||||||
with exactly these versions:
|
|
||||||
autoconf 2.13
|
|
||||||
automake 1.4
|
automake 1.4
|
||||||
libtool 1.3
|
libtool 1.4.2
|
||||||
If you have a different version, disable them by temporarily
|
|
||||||
renaming them to something else or uninstalling them from your
|
|
||||||
system. If you don't develop software you don't need them,
|
|
||||||
so you can safely uninstall.
|
|
||||||
|
|
||||||
- lex (or flex) and yacc (or bison)
|
- Xft2
|
||||||
These are used by libPropList. lex is actually not needed since
|
and its dependencies (such as freetype2 and fontconfig)
|
||||||
it's output file is included, but either me or automake is stupid,
|
You will also need the development files for it (xft2-devel)
|
||||||
causing the configure script for libPropList to simply abort for no
|
|
||||||
convincent reason if lex is not found.
|
|
||||||
|
|
||||||
|
|
||||||
OPTIONAL:
|
OPTIONAL:
|
||||||
@@ -132,10 +123,10 @@ CONFIGURE OPTIONS:
|
|||||||
These options can be passed to the configure script to enable/disable
|
These options can be passed to the configure script to enable/disable
|
||||||
some Window Maker features. Example:
|
some Window Maker features. Example:
|
||||||
|
|
||||||
./configure --enable-kde --enable-gnome
|
./configure --enable-modelock --disable-gif
|
||||||
|
|
||||||
will configure Window Maker with KDE and GNOME supported compiled in.
|
|
||||||
|
|
||||||
|
will configure Window Maker with modelock supported and disable gif support.
|
||||||
|
Normally, you won't need any of them.
|
||||||
|
|
||||||
To get a list of other options, run ./configure --help
|
To get a list of other options, run ./configure --help
|
||||||
|
|
||||||
@@ -149,12 +140,6 @@ To get a list of other options, run ./configure --help
|
|||||||
The -I flag must precede each paths, like:
|
The -I flag must precede each paths, like:
|
||||||
--with-incs-from="-I/opt/headers -I/usr/local/include"
|
--with-incs-from="-I/opt/headers -I/usr/local/include"
|
||||||
|
|
||||||
--enable-single-icon
|
|
||||||
enables the collapsing of all appicons of the WM_CLASS+WM_INSTANCE
|
|
||||||
into a single one. This feature is not supported at all by the
|
|
||||||
developers. If you have some trouble with it, contact it's author:
|
|
||||||
Christopher Seawood <cls@seawood.org>
|
|
||||||
|
|
||||||
--disable-shm
|
--disable-shm
|
||||||
disable use of the MIT shared memory extension. This will slow down
|
disable use of the MIT shared memory extension. This will slow down
|
||||||
texture generation a little bit, but in some cases it seems to be
|
texture generation a little bit, but in some cases it seems to be
|
||||||
@@ -163,15 +148,6 @@ To get a list of other options, run ./configure --help
|
|||||||
--disable-motif
|
--disable-motif
|
||||||
disable support for mwm window manager hints
|
disable support for mwm window manager hints
|
||||||
|
|
||||||
--enable-openlook
|
|
||||||
enable support for OPEN LOOK(tm) window manager hints
|
|
||||||
|
|
||||||
--enable-gnome
|
|
||||||
enable support for GNOME window manager hints
|
|
||||||
|
|
||||||
--enable-kde
|
|
||||||
enable support for kde/kwm window manager hints
|
|
||||||
|
|
||||||
--enable-lite
|
--enable-lite
|
||||||
remove things that are already supported in desktop environments,
|
remove things that are already supported in desktop environments,
|
||||||
like KDE and GNOME. Disabled things are: window list, root
|
like KDE and GNOME. Disabled things are: window list, root
|
||||||
@@ -184,9 +160,6 @@ To get a list of other options, run ./configure --help
|
|||||||
XKB language status lock support. If you don't know what it is you
|
XKB language status lock support. If you don't know what it is you
|
||||||
probably don't need it.
|
probably don't need it.
|
||||||
|
|
||||||
--enable-sound
|
|
||||||
enable support of sound effects module
|
|
||||||
|
|
||||||
--disable-xpm
|
--disable-xpm
|
||||||
disables use of the XPM library even if it is available on your
|
disables use of the XPM library even if it is available on your
|
||||||
system.
|
system.
|
||||||
@@ -291,27 +264,6 @@ apply.
|
|||||||
* make sure you have /usr/local/lib in /etc/ld.so.conf before running
|
* make sure you have /usr/local/lib in /etc/ld.so.conf before running
|
||||||
ldconfig;
|
ldconfig;
|
||||||
|
|
||||||
* if you have problems that mention an error message with --no-reexec
|
|
||||||
uninstall libtool-1.2b and install libtool-1.3 instead. libtool-1.3
|
|
||||||
can be found in ftp.gnu.org Also read the TROUBLESHOOTING section;
|
|
||||||
|
|
||||||
* if you installed the Window Maker package from RedHat and are
|
|
||||||
installing a new version of it by hand (compiling yourself), uninstall
|
|
||||||
the package from RedHat before.
|
|
||||||
|
|
||||||
* make sure you have a symbolic link from /usr/include/X11 to
|
|
||||||
/usr/X11R6/include/X11 (if not, type ln -s /usr/X11R6/include/X11
|
|
||||||
/usr/include/X11 )
|
|
||||||
|
|
||||||
* make sure you have /lib/cpp pointing to the cpp program
|
|
||||||
|
|
||||||
If you have any doubts in doing any of the stuff above, please
|
|
||||||
don't hesitate to contact the RedHat user support. They will
|
|
||||||
kindly answer to all your questions regarding their system.
|
|
||||||
They also know much more about their own system than us
|
|
||||||
(we don't use RedHat).
|
|
||||||
|
|
||||||
|
|
||||||
- PowerPC MkLinux
|
- PowerPC MkLinux
|
||||||
You will need to have the latest version of Xpmac. Older versions
|
You will need to have the latest version of Xpmac. Older versions
|
||||||
seem to have bugs that cause the system to hang.
|
seem to have bugs that cause the system to hang.
|
||||||
@@ -334,15 +286,6 @@ apply.
|
|||||||
INSTALLATION:
|
INSTALLATION:
|
||||||
=============
|
=============
|
||||||
|
|
||||||
Unpack WindowMaker-extra-<version-number>.tar.gz in /usr/local/share
|
|
||||||
|
|
||||||
You can get the file at ftp://ftp.windowmaker.org. This file is optional
|
|
||||||
and only have a few icons, and themes. Look for the latest <version-number>
|
|
||||||
available.
|
|
||||||
Also there is a WindowMaker-extra.readme to instruct you where that package
|
|
||||||
should go.
|
|
||||||
|
|
||||||
|
|
||||||
Build Window Maker
|
Build Window Maker
|
||||||
------------------
|
------------------
|
||||||
For a quick start, type the following in your shell prompt:
|
For a quick start, type the following in your shell prompt:
|
||||||
@@ -374,9 +317,9 @@ following.
|
|||||||
to get a complete listing of other options that are available.
|
to get a complete listing of other options that are available.
|
||||||
|
|
||||||
2. Run configure with the options you want. For example, if you
|
2. Run configure with the options you want. For example, if you
|
||||||
want to use the --enable-kde option, type:
|
want to use the --enable-modelock option, type:
|
||||||
|
|
||||||
./configure --enable-kde
|
./configure --enable-modelock
|
||||||
|
|
||||||
3. (optional) Edit src/wconfig.h with your favorite text editor
|
3. (optional) Edit src/wconfig.h with your favorite text editor
|
||||||
and browse through it for some options you might want to change.
|
and browse through it for some options you might want to change.
|
||||||
@@ -417,6 +360,20 @@ Read the User Guide for a more in-depth explanation of Window Maker.
|
|||||||
You might want to take a look at the FAQ too.
|
You might want to take a look at the FAQ too.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Installing the extras package
|
||||||
|
-----------------------------
|
||||||
|
|
||||||
|
Unpack WindowMaker-extra-<version-number>.tar.gz in /usr/local/share
|
||||||
|
|
||||||
|
You can get the file at ftp://ftp.windowmaker.org. This file is optional
|
||||||
|
and only have a few icons, and themes. Look for the latest <version-number>
|
||||||
|
available.
|
||||||
|
Also there is a WindowMaker-extra.readme to instruct you where that package
|
||||||
|
should go.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
I don't have the root password :(
|
I don't have the root password :(
|
||||||
---------------------------------
|
---------------------------------
|
||||||
|
|
||||||
@@ -445,8 +402,8 @@ If you are upgrading from an older version of Window Maker:
|
|||||||
|
|
||||||
1. Configure and build Window Maker as always
|
1. Configure and build Window Maker as always
|
||||||
2. Install Window Maker (but do not run wmaker.inst)
|
2. Install Window Maker (but do not run wmaker.inst)
|
||||||
3. Read the NEWS file and update your configuration files,
|
3. Read the NEWS file and update your configuration files if necessary.
|
||||||
if necessary.
|
|
||||||
|
|
||||||
TROUBLESHOOTING
|
TROUBLESHOOTING
|
||||||
===============
|
===============
|
||||||
@@ -466,8 +423,7 @@ ltconfig: unrecognized option `--no-reexec'
|
|||||||
Try `ltconfig --help' for more information.
|
Try `ltconfig --help' for more information.
|
||||||
configure: error: libtool configure failed
|
configure: error: libtool configure failed
|
||||||
|
|
||||||
remove the --no-reexec option from aclocal.m4 and libPropList/aclocal.m4
|
remove the --no-reexec option from aclocal.m4 and reconfigure
|
||||||
and reconfigure
|
|
||||||
Also make sure the autoconf and automake versions you have installed are:
|
Also make sure the autoconf and automake versions you have installed are:
|
||||||
autoconf 2.13
|
autoconf 2.13
|
||||||
automake 1.4
|
automake 1.4
|
||||||
@@ -476,12 +432,6 @@ libtool 1.3
|
|||||||
Note that it must not be libtool 1.2b, it must be libtool 1.3,
|
Note that it must not be libtool 1.2b, it must be libtool 1.3,
|
||||||
from the GNU sites.
|
from the GNU sites.
|
||||||
|
|
||||||
== Cant find proplist.h or libPropList.something
|
|
||||||
|
|
||||||
Download and install libPropList from the places pointed to
|
|
||||||
somewhere else in this file.
|
|
||||||
|
|
||||||
|
|
||||||
== configure doesn't detect libtiff, or other graphic libraries.
|
== configure doesn't detect libtiff, or other graphic libraries.
|
||||||
|
|
||||||
Delete config.cache, then rerun configure adding the following options to
|
Delete config.cache, then rerun configure adding the following options to
|
||||||
@@ -582,30 +532,3 @@ menu.pt
|
|||||||
menu
|
menu
|
||||||
|
|
||||||
|
|
||||||
5 - If you chose a language that uses multi-byte characters, you must
|
|
||||||
configure the fonts appropriately. Read the manual page for XCreateFontSet
|
|
||||||
to have more details about it. You must change the ~/G/D/WindowMaker file
|
|
||||||
for fonts used in titlebars, menus and other things. For fonts used in
|
|
||||||
dialog windows, change ~/G/D/WMGLOBAL. The %d in the font names must not be
|
|
||||||
removed. You can also use the supplied wsetfont script for the task.
|
|
||||||
Read the script itself for instructions.
|
|
||||||
|
|
||||||
For example, you can specify the following in ~/G/D/WindowMaker:
|
|
||||||
|
|
||||||
WindowTitleFont = "-*-helvetica-bold-r-normal-*-12-*,-*-*-medium-r-normal-*-14-*";
|
|
||||||
MenuTitleFont = "-*-helvetica-bold-r-normal-*-12-*,-*-*-medium-r-normal-*-14-*";
|
|
||||||
MenuTextFont = "-*-helvetica-medium-r-normal-*-12-*,-*-*-medium-r-normal-*-14-*";
|
|
||||||
IconTitleFont = "-*-helvetica-medium-r-normal-*-8-*,-*-*-medium-r-normal-*-12-*";
|
|
||||||
ClipTitleFont = "-*-helvetica-bold-r-normal-*-10-*,-*-*-medium-r-normal-*-12-*";
|
|
||||||
DisplayFont = "-*-helvetica-medium-r-normal-*-12-*,-*-*-medium-r-normal-*-12-*";
|
|
||||||
|
|
||||||
and in ~/G/D/WMGLOBAL:
|
|
||||||
|
|
||||||
SystemFont = "-*-*-medium-r-normal-*-%d-*-*-*-*-*-*-*";
|
|
||||||
BoldSystemFont = "-*-*-medium-r-normal-*-%d-*-*-*-*-*-*-*";
|
|
||||||
|
|
||||||
The above 2 fonts are only used by applications that use WINGs (WindowMaker
|
|
||||||
and WPrefs.app)
|
|
||||||
|
|
||||||
The wsetfont script that's supplied will allow you to change the font
|
|
||||||
settings in a easier way. Take a look in the script for details on usage.
|
|
||||||
|
|||||||
604
INSTALL.cs
Normal file
604
INSTALL.cs
Normal file
@@ -0,0 +1,604 @@
|
|||||||
|
Instrukce pro instalaci okenního manažera Window Maker
|
||||||
|
|
||||||
|
PODPOROVANÉ PLATFORMY
|
||||||
|
=====================
|
||||||
|
("Podporované" znamená, že už to na dané platformě někdo zprovoznil...)
|
||||||
|
|
||||||
|
- Intel GNU/Linux Conectiva 5.9 (beta)
|
||||||
|
- Intel GNU/Linux Slackware
|
||||||
|
- Intel GNU/Linux Debian
|
||||||
|
- Intel GNU/Linux ostatní distribuce
|
||||||
|
- Sparc GNU/Linux RedHat 5.1
|
||||||
|
- PowerPC GNU/MkLinux
|
||||||
|
- Alpha GNU/Linux RedHat 5.1
|
||||||
|
- FreeBSD
|
||||||
|
- NetBSD
|
||||||
|
- OpenBSD
|
||||||
|
- BSDI 4.0
|
||||||
|
- Solaris 2.5.1, 2.5.2
|
||||||
|
- Solaris 2.6.0
|
||||||
|
- Solaris 2.7beta
|
||||||
|
- SCO Unix
|
||||||
|
- SGI Irix 5.x, 6.5
|
||||||
|
- OSF/1
|
||||||
|
- HP-UX
|
||||||
|
- AIX 3.2.5
|
||||||
|
- AIX 4.1.4 / IBM PowerPC
|
||||||
|
- AIX 4.3.1 / IBM CC compiler
|
||||||
|
- AIX 4.3.2 / IBM PowerPC
|
||||||
|
- AIX 5.3
|
||||||
|
- DEC Alpha/Digital UNIX 4.x
|
||||||
|
- XFree86 / OS/2
|
||||||
|
- Corel NetWinder
|
||||||
|
- SunOS 4.x
|
||||||
|
- PowerMac / Power MachTen 4.1.1 over MacOS
|
||||||
|
- Amiga 3000 running RedHat Linux 5.1 (Rawhide)
|
||||||
|
- IBM S/390 s Linuxem
|
||||||
|
- iBook s OS Darwin
|
||||||
|
|
||||||
|
Patche pro rozběhání na jiných platformách jsou vítané.
|
||||||
|
|
||||||
|
POŽADAVKY
|
||||||
|
=========
|
||||||
|
|
||||||
|
Následující software je potřebný/nezbytný pro běh Window Makeru:
|
||||||
|
|
||||||
|
- X11R6.x
|
||||||
|
Window Maker může být zkompilován na starších verzích X, jako
|
||||||
|
je X11R5 (Solaris) nebo X11R4 (OpenWindows), ale nebude to pracovat
|
||||||
|
100% spolehlivě. Na těchto systémech nebudou fungovat ikony
|
||||||
|
aplikací a budete mít problémy s používáním doku. Upgrade
|
||||||
|
uživatelských knihoven (Xlib, Xt atd.) zlepší tyto problémy pokud
|
||||||
|
nemůžete aktualizovat váš X server.
|
||||||
|
|
||||||
|
Následující software je potřebný ke zkompilování Window Makeru:
|
||||||
|
|
||||||
|
- Zákládní běžné věci
|
||||||
|
Když budete komplivat Window Maker, tak se ujistěte, že máte gcc
|
||||||
|
(nebo jiný ANCI C kompilátor) a nainstalované hlavičkové soubory
|
||||||
|
pro X. Hlavně pro začátečníky v Linuxu: musíte nainstalovat všechny
|
||||||
|
X-devel balíky a gcc. Jinak nebudete schopni zkompilovat žádný
|
||||||
|
program s grafickým rozhraním, tedy ani Window Maker.
|
||||||
|
|
||||||
|
- autoconf, automake a libtool
|
||||||
|
Tyto nástroje NEJSOU POTŘEBA, ale když máte jeden nebo dva nebo
|
||||||
|
všechny tři nainstalované, tak se UJISTĚTE, že máte přesně
|
||||||
|
následující VERZE:
|
||||||
|
autoconf 2.54
|
||||||
|
automake 1.4
|
||||||
|
libtool 1.4.2
|
||||||
|
Máte-li odlišnou verzi, tak ji dočasně přejmenujte, nebo ji rovnou
|
||||||
|
odinstalujte z vašeho systému. Pokud nebudete programovat, tak ji
|
||||||
|
stejně nebudete potřebovat, takže ji můžete bezpečně odinstalovat.
|
||||||
|
|
||||||
|
Pozn. libProblist už není potřeba ke zkompilování Window Makeru, protože
|
||||||
|
libProblist byl přímo zabudován do WINGs. Z toho důvodu už není
|
||||||
|
potřeba ani lex (flex) a yacc (nebo bison).
|
||||||
|
|
||||||
|
|
||||||
|
NEPOVINNÉ
|
||||||
|
=========
|
||||||
|
|
||||||
|
Tyto knihovny nejsou nutné pro běh Windo Makeru, ale jsou podporované, když
|
||||||
|
je budete chtít použít. Tyto verze jsou používané vývojovým týmem, který
|
||||||
|
garantuje, že budou fungovat. Ostatní verze by měli fungovat také.
|
||||||
|
|
||||||
|
- libXPM 4.7 nebo novější
|
||||||
|
Starší verze nemusí fungovat!!!
|
||||||
|
Dostupné na ftp://sunsite.unc.edu/pub/Linux/libs/X/
|
||||||
|
|
||||||
|
Je zde zabudovaná podpora pro soubory XPM, ale nenačte obrázky s
|
||||||
|
nestandardním formátem kódování.
|
||||||
|
|
||||||
|
- libpng 0.96 nebo novější a zlib
|
||||||
|
Pro podporu PNG obrázků
|
||||||
|
http://www.cdrom.com/pub/png/
|
||||||
|
|
||||||
|
- libtiff 3.4 nebo novější
|
||||||
|
Pro podporu TIFF obrázků
|
||||||
|
Dostupné na ftp://ftp.sgi.com/graphics/tiff
|
||||||
|
|
||||||
|
- libjpeg 6.0.1 nebo novější
|
||||||
|
Pro podporu JPEG obrázků
|
||||||
|
http://www.ijg.org/
|
||||||
|
|
||||||
|
- libgif 2.2 nebo libungif
|
||||||
|
Pro podporu GIF obrázků
|
||||||
|
Dostupné na ftp://prtr-13.ucsc.edu/pub/libungif/
|
||||||
|
|
||||||
|
-GNU xgettxt
|
||||||
|
Když chcete používat češtinu nebo jiné jazyky kromě angličtiny,
|
||||||
|
tak potřebujete GNU xgettext.
|
||||||
|
Ostatní verze nejsou kompatibilní a nebudou fungovat
|
||||||
|
GNU verze je dostupná na ftp://ftp.gnu.org
|
||||||
|
|
||||||
|
|
||||||
|
KONFIGURAČNÍ NASTAVENÍ
|
||||||
|
======================
|
||||||
|
|
||||||
|
Tyto volby mohou být předané konfiguračnímu skriptu jako argumenty za
|
||||||
|
účelem povolení/zakázání určité vlastnosti Window Makera.
|
||||||
|
|
||||||
|
Příklad:
|
||||||
|
|
||||||
|
./configura --enable-kde --enable-gnome
|
||||||
|
|
||||||
|
nakonfiguruje Window Maker s podporou KDE a GNOME
|
||||||
|
|
||||||
|
Seznam ostatních možností dostanete spuštěním ./configure --help
|
||||||
|
|
||||||
|
--with-libs-from
|
||||||
|
specifikuje, které další adresáře s knihovnami se mají
|
||||||
|
prohledávat. Řetězec -L musí předcházet každému adresáři,
|
||||||
|
např:
|
||||||
|
--with-libs-from="-L/opt/libs -L/usr/local/lib"
|
||||||
|
|
||||||
|
--with-incs-from
|
||||||
|
určuje, které další adresáře s hlavičkovými soubory se mají
|
||||||
|
prohledat. Řetězec -I musí předcházet každému adresáři,
|
||||||
|
např:
|
||||||
|
--with-incs-from="-I/opt/headers -I/usr/local/include"
|
||||||
|
|
||||||
|
--enable-single-icon
|
||||||
|
umožňuje skrýt všechny ikony aplikací WM_CLASS+WM_INSTANCE
|
||||||
|
do jedné jediné. Tato vlastnost není podporovaná ze strany vývojářů.
|
||||||
|
Když budete mít s touto funkcí problémy, tak se obraťte na jejího
|
||||||
|
autora: Christopher Seawood <cls@seawood.org>
|
||||||
|
|
||||||
|
--disable-shm
|
||||||
|
zakáže používání zdílené paměti MIT. To trochu zpomalí generování
|
||||||
|
textur, ale v některých případech se to jeví jako nezbytnost z důvodu
|
||||||
|
chyby, která způsobuje špatné zobrazování ikon a textur.
|
||||||
|
|
||||||
|
--disable-motif
|
||||||
|
zakáže podporu pokynů pro okenní manažer mwm.
|
||||||
|
|
||||||
|
--enable-lite
|
||||||
|
odstraní nástroje a funkce, které jsou už dostupné v desktopových
|
||||||
|
prosředích KDE a GNOME. Odstraní se: seznam oken, menu aplikací,
|
||||||
|
výběr více oken. Uvědomte si, že takto už nebudete schopni ukončit
|
||||||
|
samotný Window Maker pomocí aplikačního menu. Budete muset zabít Window
|
||||||
|
Maker z textové konzole nebo ho ukončit z KDE nebo GNOME.
|
||||||
|
Nedoporučuje se povolit tuto vlastnost.
|
||||||
|
|
||||||
|
--enable-modelock
|
||||||
|
podpora pro XKB nastavení jazyka. Když nevíte, o co jde, tak to
|
||||||
|
pravděpodobně nebudete potřebovat.
|
||||||
|
|
||||||
|
--enable-sound
|
||||||
|
povolí podporu modulu zvukových efektů.
|
||||||
|
|
||||||
|
--disable-xpm
|
||||||
|
zakáže podporu knihovny XPM, pokud je dostupná na vašem systému.
|
||||||
|
|
||||||
|
--disable-png
|
||||||
|
zakáže podporu knihovny PNG.
|
||||||
|
|
||||||
|
--disable-tiff
|
||||||
|
zakáže podporu knihovny TIFF.
|
||||||
|
|
||||||
|
--disable-gif
|
||||||
|
zakáže podporu knihovny GIF.
|
||||||
|
|
||||||
|
--disable-jpeg
|
||||||
|
zakáže podporu knihovny JPEG.
|
||||||
|
|
||||||
|
--disable-shape
|
||||||
|
zakáže tvarovaná okna (pro oclock, xeyes, atd.).
|
||||||
|
|
||||||
|
POŽADAVKY PRO SPECIFICKÉ PLATFORMY
|
||||||
|
==================================
|
||||||
|
|
||||||
|
-DEC/Alpha
|
||||||
|
|
||||||
|
Následující mail není přeložen, ale hovoří se v něm, že pravděpodobně
|
||||||
|
není potřeba konfigurovat Window Maker na Alphě s volbou --disable-shm.
|
||||||
|
|
||||||
|
-------------------------------------------------------------------------------
|
||||||
|
From: Anton Ivanov <aivanov@eu.level3.net>
|
||||||
|
To: Marcelo E. Magallon <mmagallo@debian.org>
|
||||||
|
Subject: Re: Is the WindowMaker package working ok on Alpha?
|
||||||
|
|
||||||
|
> Hi,
|
||||||
|
>
|
||||||
|
> I was reading some docs on the WindowMaker tarball, and found this:
|
||||||
|
>
|
||||||
|
> | - DEC/Alpha machines
|
||||||
|
> | You might need to pass the --disable-shm flag to configure,
|
||||||
|
> | like ./configure --disable-shm
|
||||||
|
>
|
||||||
|
> is anyone having problems with WindowMaker on Alpha? Can someone
|
||||||
|
> please test this? Should the flag be passed when building on Alpha?
|
||||||
|
|
||||||
|
Disclaimer: alphas under my command have never run X and are least likely to
|
||||||
|
suddenly start running it anytime soon.
|
||||||
|
|
||||||
|
Alpha used to have some ridiculously low amount of shared memory
|
||||||
|
configured.
|
||||||
|
So quite a lot of apps used to barf. Namely - cdrecord, mysql server, etc.
|
||||||
|
|
||||||
|
Check where is yours at the moment and raise it to a more appropriate
|
||||||
|
value by either catting to the appropriate /proc entry or changing the
|
||||||
|
/usr/src/linux/include/asm/shmparam.h.
|
||||||
|
|
||||||
|
Otherwise the shared memory on alpha should be fully functional and I
|
||||||
|
see no reason to disable it. Mine are bumped up to 32 or more on most
|
||||||
|
machines.
|
||||||
|
|
||||||
|
And If I recall correctly the comments in that file are actually
|
||||||
|
wrong. Value is not bytes, but in machine size word. For alpha *8.
|
||||||
|
|
||||||
|
As I said - I do not run X on them so all #include "stdisclaimer.h"
|
||||||
|
apply.
|
||||||
|
|
||||||
|
-------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
- SCO Unix - configure spusťte takto:
|
||||||
|
CFLAGS="-belf -DANSICPP" ./configure
|
||||||
|
|
||||||
|
- SunOS, Solaris
|
||||||
|
Když máte naistalovaný gcc, tak configure spusťte takto:
|
||||||
|
CPP_PATH="gcc -E -x c" ./configure
|
||||||
|
Preprocesoru cpp od Sunu chybějí některé vlastnosti, které Window Maker
|
||||||
|
potřebuje, a to může způsobit problémy během parsování konfiguračních
|
||||||
|
souborů. Je možné, že budete muset použít --with-libs-from a
|
||||||
|
--with-incs-from k nahrazení adresáře s libtiff.
|
||||||
|
Někdo doporučuje použít /usr/local/lib jako první cestu v LD_LIBRARY_PATH.
|
||||||
|
|
||||||
|
Když máte Ultra Creator 3D nebo jinou high-end grafickou kartu, tak se
|
||||||
|
ujistěte, že X server startuje s 24 bitovou barevnou hloubkou, jinak
|
||||||
|
můžete mít problémy s pomícháním barev. Toto je chyba Window Makeru,
|
||||||
|
která bude odstraněna.
|
||||||
|
|
||||||
|
- GNU/Linux obecně
|
||||||
|
Ujistěte se, že soubor /etc/ld.so.conf obsahuje řádek "/usr/local/lib".
|
||||||
|
Odinstalujte jakoukoliv starší verzi balíčku Window Makeru před instalací
|
||||||
|
novější verze.
|
||||||
|
Nezapomeňte spustit ldconfig po instalaci Window Makeru.
|
||||||
|
|
||||||
|
- RedHat GNU/Linux
|
||||||
|
RedHat má několik obtěžujících chyb. Pokud ho používáte dodržujte několik
|
||||||
|
následujících kroků, jinak vám Window Maker nebude fungovat.
|
||||||
|
|
||||||
|
* pokud máte nainstalovaný Window Maker z distribuce RedHat, tak ho před
|
||||||
|
upgradem odinstalujte
|
||||||
|
|
||||||
|
* ujistěte se, že nemáte systémové proměnné LANG a LINGUAS nastavené
|
||||||
|
na en_RN
|
||||||
|
|
||||||
|
* ujistěte se, že vaše systémová proměnná PATH obsahuje položku
|
||||||
|
/usr/local/bin
|
||||||
|
|
||||||
|
* ujistěte se, že soubor /etc/ld.so.conf obsahuje řádek "/usr/local/lib"
|
||||||
|
před tím, než spustíte ldconfig (na konci instalace)
|
||||||
|
|
||||||
|
* pokud máte problémy, které se projevují chybovou hláškou, která
|
||||||
|
obsahuje text --no-reexec, tak odinstalujte libtool-1.2b a nainstalujte
|
||||||
|
si novější verzi libtool-1.3. libtool-1.3 můžete nalézt na adrese:
|
||||||
|
ftp.gnu.org . Přečtěte si také odstavec ŘEŠENÍ PROBLÉMÚ.
|
||||||
|
|
||||||
|
* pokud máte nainstalovaný balíček Window Maker od RedHatu a nyní
|
||||||
|
instalujete novou verzi "ručně" (kompilováním zdrojových kódů), tak
|
||||||
|
nejprve odinstalujte stávající balíček.
|
||||||
|
|
||||||
|
* ujistěte se, že se na vašem systému nachází symbolický link z
|
||||||
|
/usr/include/X11 na /usr/X11R6/include/X11. Pokud tomu tak není, tak
|
||||||
|
na příkazovou řádku napište:
|
||||||
|
|
||||||
|
ln -s /usr/X11R6/include/X11 /usr/include/X11
|
||||||
|
|
||||||
|
* ujistěte se, že máte symbolický link /lib/cpp ukazující na cpp
|
||||||
|
program
|
||||||
|
|
||||||
|
Pokud pochybujete o nějakém z předcházejích kroků, tak neváhejte
|
||||||
|
kontaktovat uživatelskou podporu distribuce RedHat. Oni vám laskavě
|
||||||
|
zodpoví všechny vaše dotazy zohledňující váš systém. Oni vědí
|
||||||
|
mnohem více o vašem (jejich) systému než my (my nepoužíváme
|
||||||
|
RedHat).
|
||||||
|
|
||||||
|
- PowerPC MkLinux
|
||||||
|
Budete potřebovat poslední verzi Xpma. Starší verze pravděpodobně
|
||||||
|
obsahují chybu, která způsobuje zamrznutí systému.
|
||||||
|
|
||||||
|
- Debian GNU/Linux
|
||||||
|
Pokud chcete podporu JPEG a TIFF, tak se ujistěte, že máte nainstalovány
|
||||||
|
balíčky libtiff-dev a libjpeg-dev.
|
||||||
|
|
||||||
|
- SuSE GNU/Linux
|
||||||
|
Pokud máte již nainstalován baliček Window Maker od SuSE, tak ho
|
||||||
|
odstraňte než se pustíte do kompilace Window Makeru. když tak
|
||||||
|
neučiníte, budete mít problémy.
|
||||||
|
|
||||||
|
- MetroX (neznámá verze)
|
||||||
|
Metrox obsahuje chybu, která zapřičiňuje, že obrázky, které jsou
|
||||||
|
nastaveny jako pozadí, jsou poškozeny. Pokud používáte Metrox a
|
||||||
|
máte podivné problémy s texturami, tak nepoužívejte textury v
|
||||||
|
titulcích nebo používejte jiný X server.
|
||||||
|
|
||||||
|
INSTALACE
|
||||||
|
=========
|
||||||
|
|
||||||
|
Nejjednodušší způsob, jak nainstalovat Window Maker, je spustit skript
|
||||||
|
Install nebo Install.cs (ten s vámi komunikuje česky). Oba skripty
|
||||||
|
vás jednoduše provedou celou instalací.
|
||||||
|
|
||||||
|
su
|
||||||
|
Install.cs
|
||||||
|
|
||||||
|
Poznámka: tato metoda neposkytuje všechny možnosti konfigurace a pokud
|
||||||
|
se setkáte s nějakými problémy, tak stejně budete muset
|
||||||
|
použít následující způsob kompilace.
|
||||||
|
|
||||||
|
Kompilace Window Makeru
|
||||||
|
-----------------------
|
||||||
|
Pro osvědčený způsob zadejte následující příkazy v shellu:
|
||||||
|
|
||||||
|
./configure
|
||||||
|
make
|
||||||
|
|
||||||
|
pak se přihlašte jako root a zadejte:
|
||||||
|
|
||||||
|
make install
|
||||||
|
ldconfig
|
||||||
|
|
||||||
|
pokud nejste programátor a nebudete ladit Window Maker, tak se můžete zbavit
|
||||||
|
ladících symbolů v binárních souborech a zmenšit jejich velikost:
|
||||||
|
|
||||||
|
make install-strip
|
||||||
|
ldconfig
|
||||||
|
|
||||||
|
Takto zkompilujete a nainstalujete Window Maker se standartními parametry.
|
||||||
|
|
||||||
|
Pokud chcete upravit některé vlastnosti, tak musíte učinit následující:
|
||||||
|
|
||||||
|
1. (volitelné) Podívejte se na část MOŽNOSTI KONFIGURACE, kde jsou
|
||||||
|
uvedené možnosti konfigurace. Nebo spusťte:
|
||||||
|
|
||||||
|
./configure --help
|
||||||
|
|
||||||
|
tak dostanete kompletní seznam všech dostupných možností konfigurace.
|
||||||
|
|
||||||
|
2. Spusťte ./configure s možností, kterou jste si vybrali. Například,
|
||||||
|
pokud chcete použít možnost --enable-kde, tak zadejte:
|
||||||
|
|
||||||
|
./configure --enable-kde
|
||||||
|
|
||||||
|
3. (volitelné) Otevřete soubor ./src/wconfig.h vaším oblíbeným editorem
|
||||||
|
a upravte některé možnosti, které si přejete změnit.
|
||||||
|
|
||||||
|
4. Kompilace. Zadejte pouze:
|
||||||
|
|
||||||
|
make
|
||||||
|
|
||||||
|
5. Přihlaste se jako root (pokud tak nemůžetet učinit, tak si přečtěte
|
||||||
|
část "Nemám rootovské helso :-(") a nainstalujte Window Maker na váš
|
||||||
|
systém:
|
||||||
|
|
||||||
|
su root
|
||||||
|
make install
|
||||||
|
|
||||||
|
Nastavení specifické pro uživatele
|
||||||
|
----------------------------------
|
||||||
|
|
||||||
|
Tyto instrukce nejsou povinné, pokud upgradujete Window Maker ze starší
|
||||||
|
verze na novější a pokud není uvedeno jinak v souboru NEWS.
|
||||||
|
|
||||||
|
Každý uživatel na vašem systému, který si přeje používat Window Maker musí
|
||||||
|
udělat následující:
|
||||||
|
|
||||||
|
1. Nainsatlovat konfigurační soubory Window Makeru do jeho domovského
|
||||||
|
adresáře:
|
||||||
|
|
||||||
|
wmaker.inst
|
||||||
|
|
||||||
|
wmaker.inst nainstaluje konfigurační soubory a nastaví X server tak,
|
||||||
|
aby automaticky spouštěl Window Maker při jejich spuštění.
|
||||||
|
|
||||||
|
To je všechno, přátelé.
|
||||||
|
|
||||||
|
Informace o konfiguraci a spoustě ostatních věcí vám poskytne:
|
||||||
|
|
||||||
|
man wmaker
|
||||||
|
|
||||||
|
Pro hlubší úvod do Window Makeru si přečtěte Uživatelskou příručku (User Guide).
|
||||||
|
|
||||||
|
Měli byste se také podívat na FAQ (Frequently Asked Questions = často kladené
|
||||||
|
otázky), pokud budete mít nějaké problémy/potíže jak při samotné kompilaci,
|
||||||
|
tak s užíváním Window Makeru.
|
||||||
|
|
||||||
|
Instalování speciálního balíčku
|
||||||
|
-------------------------------
|
||||||
|
|
||||||
|
Rozbalte WindowMaker-extra-<číslo_verze>.tar.gz v adresáři /usr/local/share
|
||||||
|
|
||||||
|
Tento soubor si můžete sehnat na adrese: ftp://ftp.windowmaker.org. Instalace
|
||||||
|
tohoto souboru vůbec není nutná. tento balíček obsahuje několik ikon a témat.
|
||||||
|
Hledejte poslední dostupnou verzi. V balíčku také naleznete soubor
|
||||||
|
WindowMaker-extra.readme, který vám poradí, co máte udělat.
|
||||||
|
|
||||||
|
Nemám rootovské helso :-(
|
||||||
|
-------------------------
|
||||||
|
|
||||||
|
Pokud nemáte superuživatelská privilegia (nemůžete se přihlásit jako root),
|
||||||
|
tak nezoufejte, protože můžete nainstalovat Window Maker do vašeho vlastního
|
||||||
|
domovského adresáře. K tomu musíte použít volbu --prefix při spuštění
|
||||||
|
./configure. Také musíte použít volbu --with-appspath, která specifikuje
|
||||||
|
cestu pro WPrefs.app.
|
||||||
|
Příklad:
|
||||||
|
|
||||||
|
./configure --prefix=/home/karel --with-appspath=/home/karel/GNUstep/Apps
|
||||||
|
|
||||||
|
Potom přidejte adresář /home/karel/bin do systémové proměnné PATH a adresář
|
||||||
|
/home/karel/lib do sytémové proměnné LD_LIBRARY_PATH a nakonec spusťte
|
||||||
|
~/bin/wmaker.inst.
|
||||||
|
|
||||||
|
Samozřejmě, že adresář /home/karel bude ve vašem případě nahrazen vaším
|
||||||
|
vlastním domovským adresářem.
|
||||||
|
|
||||||
|
|
||||||
|
UPGRADE
|
||||||
|
=======
|
||||||
|
|
||||||
|
Pokud upgradujete ze starší verze Window Makeru:
|
||||||
|
|
||||||
|
1. Nakonfigurujte a zkompilujte Window Maker jako obvykle.
|
||||||
|
2. Nainstalujte Window Maker (ale nespouštějte wmaker.inst).
|
||||||
|
3. Přečtěte si soubor NEWS a aktualizujte vaše konfigurační soubory,
|
||||||
|
pokud je to nezbytné.
|
||||||
|
|
||||||
|
ŘEŠENÍ PROBLÉMÚ
|
||||||
|
===============
|
||||||
|
|
||||||
|
Pokud máte nějaké problémy během konfigurace (když běží configure), jako
|
||||||
|
například neschopnost použít knihovnu grafického formátu, o kterém víte, že
|
||||||
|
ho máte nainstalován, tak se podívejte do souboru config.log. Možná zde
|
||||||
|
najdete příčinu svých problémů.
|
||||||
|
|
||||||
|
== Error with loading fonts, even if they exist.
|
||||||
|
|
||||||
|
Zkuste kompilaci bez podpory NLS (národního prostředí).
|
||||||
|
|
||||||
|
== Error when configuring
|
||||||
|
|
||||||
|
ltconfig: unrecognized option `--no-reexec'
|
||||||
|
Try `ltconfig --help' for more information.
|
||||||
|
configure: error: libtool configure failed
|
||||||
|
|
||||||
|
odstraňte volbu --no-reexec ze souboru aclocal.mc a spusťte znovu configure.
|
||||||
|
Také zkontrolujte, zda verze autoconfu a automaku, které máte nainsatlované
|
||||||
|
odpovídají níže uvedeným hodnotám:
|
||||||
|
autoconf 2.13
|
||||||
|
automake 1.4
|
||||||
|
libtool 1.3
|
||||||
|
|
||||||
|
Poznámka: nemůže to být libtool 1.2b, ale musí to být libtool 1.3 ze stránek
|
||||||
|
GNU.
|
||||||
|
|
||||||
|
== configure doesn't detect libtiff, or other graphic libraries.
|
||||||
|
|
||||||
|
Smažte soubor config.cache, pak znovu spusťte configure s následujícími
|
||||||
|
volbami (a jinými, které používáte):
|
||||||
|
--with-libs-from="-L/usr/local/lib"
|
||||||
|
--with-incs-from="-I/usr/local/include -I/usr/local/include/tiff"
|
||||||
|
Na příslušná místa vložte cesty k vaším grafickým knihovnám a odpovídajícím
|
||||||
|
hlavičkovým souborům. Můžete zadat několik cest do těchto voleb, jako je to
|
||||||
|
ve výše uvedeném příkladě --with-incs-from. Jenom je nezapomeňte oddělit
|
||||||
|
mezerou.
|
||||||
|
|
||||||
|
== configure doesn't detect libXpm.
|
||||||
|
|
||||||
|
* Zkontrolujte, jestli máte symbolický link ze souboru libXpm.so.4.9 na
|
||||||
|
soubor libXpm.so
|
||||||
|
|
||||||
|
== Segmentation fault on startup
|
||||||
|
|
||||||
|
* Zkontrolujte, jestli verze knihovny libXPM je vyšší než 4.7
|
||||||
|
|
||||||
|
* Zkontrolujte, zda-li máte upravenou verzi ~/GNUstep/Defaults/WindowMaker
|
||||||
|
Pokud si nejste jisti, tak zkuste přejmenovat ~/GNUstep na ~/GNUtmp a
|
||||||
|
spusťte wmaker.inst
|
||||||
|
|
||||||
|
== "...: your machine is misconfigured. gethostname() returned (none)"
|
||||||
|
|
||||||
|
* Jméno vašeho počítače je nastaveno nesprávně, protože začíná uvozovkami.
|
||||||
|
Spusťte man hostname a zde se dozvíte, jak změnit jméno vašeho počítače.
|
||||||
|
|
||||||
|
== The root menu contains only 2 entries. ("XTerm" and "Exit...")
|
||||||
|
|
||||||
|
* Window Maker nemůže nalézt cpp (preprocesor jazyka C). Pokud se váš cpp
|
||||||
|
nenachází v /lib/cpp, tak otevřte soubor src/config.h a nastavte správně
|
||||||
|
cestu CPP_PATH.
|
||||||
|
|
||||||
|
== checking lex output file root... configure: error: cannot find output from true; giving up
|
||||||
|
|
||||||
|
* Přečtěte si odstavec POŽADAVKY na začátku tohoto souboru.
|
||||||
|
|
||||||
|
MÍSTNÍ NASTAVENÍ / INTERNACIONALIZACE
|
||||||
|
=====================================
|
||||||
|
|
||||||
|
Window Maker má podporu národních jazyků. Aby jste ji povolili, tak
|
||||||
|
musíte zkompilovat Window Maker s několika dalšími parametry.
|
||||||
|
Seznam podporovaných jazyků naleznete v souboru ./po/README.
|
||||||
|
|
||||||
|
0 - Musíte mít nainstalovaný balíček GNU gettextu. Tento balíček
|
||||||
|
můžete nalézt na ftp://prep.ai.mit.edu/pub/gnu/gettext-nnn.tar.gz
|
||||||
|
|
||||||
|
Kroky 1,2 a 3 můžete vynechat, pokud používáte skript Install.cs nebo
|
||||||
|
skript Install.
|
||||||
|
|
||||||
|
1 - Vyberte si jazyky, které budete chtít používat. Zadejte seznam
|
||||||
|
těchto jazyků do systémové proměnné LINGUAS. Angličtina je
|
||||||
|
podporována vždy. Příklady
|
||||||
|
|
||||||
|
C - shell:
|
||||||
|
|
||||||
|
setenv LINGUAS "pt ja de"
|
||||||
|
|
||||||
|
Bash(sh):
|
||||||
|
|
||||||
|
export LINGUAS
|
||||||
|
LINGUAS="pt ja de"
|
||||||
|
|
||||||
|
Přečtěte si soubor po/README pokud chcete přeložit Window Maker
|
||||||
|
pro nějaký další jazyk.
|
||||||
|
|
||||||
|
2 - Navíc, pokud váš jazyk používá multi-byte znaky, například Japonština
|
||||||
|
nebo Korejština, tak musíte nastavit volbu the MultiByteText na YES
|
||||||
|
v souboru ~/GNUstep/Defaults/WMGLOBAL
|
||||||
|
|
||||||
|
3 - Nakonfigurujte, zkompilujte a nainstalujte Window Maker jako obvykle.
|
||||||
|
|
||||||
|
4 - Národní prostředí si můžete změnit i za běhu Window Makeru. Systémovou
|
||||||
|
proměnnou LANG nastavíte na vámi zvolenou hodnotu. Například, pokud
|
||||||
|
chcete použít portugalské prostředí, musíte spustit:
|
||||||
|
|
||||||
|
C - shell:
|
||||||
|
|
||||||
|
setenv LANG pt
|
||||||
|
|
||||||
|
Bourne shell a podobné:
|
||||||
|
|
||||||
|
export LANG
|
||||||
|
LANG=pt
|
||||||
|
|
||||||
|
Nakonec musíte restartovat/spustit Window Maker.
|
||||||
|
|
||||||
|
Poznámka: Když máte nastavenou systémovou proměnnou LC_TYPE, tak jí
|
||||||
|
musíte zrušit před spuštěním Window Makeru.
|
||||||
|
|
||||||
|
Window Maker hledá soubory s definicí menu v tomto pořadí (pro
|
||||||
|
brazilskou portugalštinu):
|
||||||
|
|
||||||
|
menu.pt_BR
|
||||||
|
menu.pt
|
||||||
|
menu
|
||||||
|
|
||||||
|
5 - Pokud si vyberete jazyk, který používá multi-byte znaky, tak musíte
|
||||||
|
příslušným způsobem nastavit fonty. Přečtěte si manuálové stránky
|
||||||
|
o XCreateFontSet k získání většího množství informací o daném
|
||||||
|
problému. Musíte změnit v souboru ~/GNUstep/Default/WindowMaker
|
||||||
|
nastavení fontů pro titulky, menu, atd. Fonty pro dialogy nastavíte
|
||||||
|
v souboru ~/GNUstep/Default/WMGLOBAL. Řetězce %d ve jménech fontů
|
||||||
|
nemusí být odstraněné. Také můžete použít skript wsetfont, který
|
||||||
|
toto vše učiní za vás. Pokud se ho rozhodnote použít, tak si k němu
|
||||||
|
přečtěte instrukce tak, že spustíte wsetfont bez argumentů.
|
||||||
|
|
||||||
|
Příklad části souboru ~/GNUstep/Default/WindowMaker:
|
||||||
|
|
||||||
|
WindowTitleFont = "-*-helvetica-bold-r-normal-*-12-*,-*-*-medium-r-normal-*-14-*";
|
||||||
|
MenuTitleFont = "-*-helvetica-bold-r-normal-*-12-*,-*-*-medium-r-normal-*-14-*";
|
||||||
|
MenuTextFont = "-*-helvetica-medium-r-normal-*-12-*,-*-*-medium-r-normal-*-14-*";
|
||||||
|
IconTitleFont = "-*-helvetica-medium-r-normal-*-8-*,-*-*-medium-r-normal-*-12-*";
|
||||||
|
ClipTitleFont = "-*-helvetica-bold-r-normal-*-10-*,-*-*-medium-r-normal-*-12-*";
|
||||||
|
DisplayFont = "-*-helvetica-medium-r-normal-*-12-*,-*-*-medium-r-normal-*-12-*";
|
||||||
|
|
||||||
|
a souboru ~/GNUstep/Default/WMGLOBAL:
|
||||||
|
|
||||||
|
SystemFont = "-*-*-medium-r-normal-*-%d-*-*-*-*-*-*-*";
|
||||||
|
BoldSystemFont = "-*-*-medium-r-normal-*-%d-*-*-*-*-*-*-*";
|
||||||
|
|
||||||
|
Tyto dva fonty jsou používány v aplikacích, které používají WINGs (WindowMaker a
|
||||||
|
WPrefs.app).
|
||||||
|
|
||||||
|
Skript wsetfont vám umožní nastavit fonty mnohem jednoduším způsobem. Podívejte
|
||||||
|
se na jeho manuálové stránku k získání bližších informací.
|
||||||
594
INSTALL.es
Normal file
594
INSTALL.es
Normal file
@@ -0,0 +1,594 @@
|
|||||||
|
|
||||||
|
Instrucciones de Instalación para Window Maker
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
PLATAFORMAS SOPORTADAS
|
||||||
|
======================
|
||||||
|
(obs: Alguien me mencionó que lo compiló en...)
|
||||||
|
|
||||||
|
- Intel GNU/Linux Conectiva 5.9 (beta)
|
||||||
|
- Intel GNU/Linux Slackware
|
||||||
|
- Intel GNU/Linux Debian
|
||||||
|
- Intel GNU/Linux other distributions
|
||||||
|
- Sparc GNU/Linux RedHat 5.1
|
||||||
|
- PowerPC GNU/MkLinux
|
||||||
|
- Alpha GNU/Linux RedHat 5.1
|
||||||
|
- FreeBSD
|
||||||
|
- NetBSD
|
||||||
|
- OpenBSD
|
||||||
|
- BSDI 4.0
|
||||||
|
- Solaris 2.5.1, 2.5.2
|
||||||
|
- Solaris 2.6.0
|
||||||
|
- Solaris 2.7beta
|
||||||
|
- SCO Unix
|
||||||
|
- SGI Irix 5.x, 6.5
|
||||||
|
- OSF/1
|
||||||
|
- HP-UX
|
||||||
|
- AIX 3.2.5
|
||||||
|
- AIX 4.1.4 / IBM PowerPC
|
||||||
|
- AIX 4.3.1 / IBM CC compiler
|
||||||
|
- AIX 4.3.2 / IBM PowerPC
|
||||||
|
- AIX 5.3
|
||||||
|
- DEC Alpha/Digital UNIX 4.x
|
||||||
|
- XFree86 / OS/2
|
||||||
|
- Corel NetWinder
|
||||||
|
- SunOS 4.x
|
||||||
|
- PowerMac / Power MachTen 4.1.1 over MacOS
|
||||||
|
- Amiga 3000 running RedHat Linux 5.1 (Rawhide)
|
||||||
|
- IBM S/390 running Linux
|
||||||
|
- iBook running Darwin
|
||||||
|
- Windows NT with Cygwin/XFree86
|
||||||
|
- Sony PlayStation2 running Linux
|
||||||
|
|
||||||
|
Todas las marcas registradas están registradas por sus dueños. (duh)
|
||||||
|
|
||||||
|
Los parches que lo hagan funcionar en otras plataformas son bienvenidos.
|
||||||
|
|
||||||
|
|
||||||
|
REQUERIMIENTOS:
|
||||||
|
==============
|
||||||
|
|
||||||
|
El siguiente software se necesita para usar Window Maker:
|
||||||
|
|
||||||
|
- X11R6.x
|
||||||
|
Window Maker puede ser compilado en versiones más antiguas de X,
|
||||||
|
como X11R5 (Solaris) o X11R4 (OpenWindows) pero no funcionará 100%
|
||||||
|
correctamente.
|
||||||
|
En tales servidores no habrá íconos de aplicación y tendrá problemas
|
||||||
|
usando el dock. Actualizar las bibliotecas cliente (Xlib, Xt, etc)
|
||||||
|
ayudará si no puede actualizar el servidor.
|
||||||
|
|
||||||
|
Lo siguiente se necesita para compilar Window Maker:
|
||||||
|
|
||||||
|
- Requerimientos básicos y obvios
|
||||||
|
Si compila Window Maker, asegúrese de tener gcc (u algún otro
|
||||||
|
compilador ANSI C) y los archivos header de X instalados. Especialmente
|
||||||
|
para los usuarios de Linux principiantes: debe instalar todos los paquetes
|
||||||
|
de desarrollo de X y la suite gcc. De lo contrario no será capaz de
|
||||||
|
compilar ningún programa X, incluyendo Window Maker.
|
||||||
|
|
||||||
|
- libPropList
|
||||||
|
Esta biblioteca se puede encontrar en ftp://ftp.windowmaker.org/pub/libs
|
||||||
|
o en ftp://ftp.gnome.org/pub/libPropList
|
||||||
|
Instálela antes de compilar Window Maker.
|
||||||
|
|
||||||
|
- autoconf, automake y libtool
|
||||||
|
Estas herramientas NO son necesarias, pero SI tiene una o más de ellas
|
||||||
|
instaladas, asegúrese de tener TODO lo siguiente con estas versiones
|
||||||
|
exactas:
|
||||||
|
|
||||||
|
autoconf 2.54
|
||||||
|
automake 1.4
|
||||||
|
libtool 1.4.2
|
||||||
|
|
||||||
|
Si tiene una versión distinta, desactívelas temporalemte renombrándolas
|
||||||
|
a otras cosa o desinstalándolas desde su sistema. Si no desarrolla
|
||||||
|
software no las necesita, así que puede desinstalarla sin peligro.
|
||||||
|
|
||||||
|
- lex (o flex) y yacc (o bison)
|
||||||
|
Estas son usadas por libPropList. lex en realidad no se necesita ya que
|
||||||
|
su archivo de salida está incluido, pero o yo o automake es tonto,
|
||||||
|
causando que el script configure para libPropList simplemente
|
||||||
|
aborte sin ningún motivo si lex no es encontrado.
|
||||||
|
|
||||||
|
OPCIONAL:
|
||||||
|
=========
|
||||||
|
Estas bibliotecas no son necesarias para hacer que Window Maker funcione,
|
||||||
|
pero están soportadas en caso de que quiera usarlas. Los números de versión
|
||||||
|
son aquellos que yo tengo (y por lo tanto, garantizo que funciona), pero
|
||||||
|
otras versiones podría funcionar también.
|
||||||
|
|
||||||
|
- libXPM 4.7 o más actual.
|
||||||
|
Versiones antiguas pueden no funcionar!!!
|
||||||
|
Disponible en ftp://sunsite.unc.edu/pub/Linux/libs/X/
|
||||||
|
|
||||||
|
Hay soporte nativo para archivos XPM, pero no cargará imagenes de
|
||||||
|
algunos formatos poco comunes.
|
||||||
|
|
||||||
|
-libpng 0.96 o más actual y zlib
|
||||||
|
Para soporte de imágenes PNG.
|
||||||
|
http://www.cdrom.com/pub/png/
|
||||||
|
|
||||||
|
- libtiff 3.4 o más actual.
|
||||||
|
Para soporte de imaen TIFF.
|
||||||
|
Puede obtenerla en ftp://ftp.sgi.com/graphics/tiff
|
||||||
|
|
||||||
|
- libjpeg 6.0.1 o más actual
|
||||||
|
Para soporte de imagen JPEG
|
||||||
|
http://www.ijg.org/
|
||||||
|
|
||||||
|
- libgif 2.2 o libungif
|
||||||
|
Para soporte de imagen GIF.
|
||||||
|
ftp://prtr-13.ucsc.edu/pub/libungif/
|
||||||
|
|
||||||
|
- GNU xgettext
|
||||||
|
Si quiere usar mensajes traducidos, necesitará GNU gettext.
|
||||||
|
Otras versiones de gettext no son compatibles y no funcionarán.
|
||||||
|
Obtenga la versión GNU desde ftp://ftp.gnu.org
|
||||||
|
|
||||||
|
OPCIONES DE CONFIGURACIÓN:
|
||||||
|
=========================
|
||||||
|
Estas opciones pueden ser pasadas al script configure para activar/desactivar
|
||||||
|
algunas opciones de Window Maker. Ejemplo:
|
||||||
|
|
||||||
|
./configure --enable-kde --enable-gnome
|
||||||
|
|
||||||
|
configurará Window Maker para que sea compilado con soporte para KDE y GNOME.
|
||||||
|
|
||||||
|
Para obtener una lista de otras opciones, ejecute ./configure --help
|
||||||
|
|
||||||
|
--with-libs-from
|
||||||
|
especifica rutas adicionales por donde se debe buscar bibliotecas.
|
||||||
|
El -L flag debe preceder a cada ruta, tal como:
|
||||||
|
|
||||||
|
--with-libs-from="-L/opt/libs -L/usr/local/lib"
|
||||||
|
|
||||||
|
--with-incs-from
|
||||||
|
especifica rutas adicionales para la búsqueda de archivos header.
|
||||||
|
El parámetro -I debe preceder a cada ruta, tal como:
|
||||||
|
|
||||||
|
--with-incs-from="-I/opt/headers -I/usr/local/include"
|
||||||
|
|
||||||
|
--enable-single-icon
|
||||||
|
activa el agrupamiento de todos los appicons (iconos de aplicaciones)
|
||||||
|
del WM_CLASS+WM_INSTANCE en uno solo. Esta característica no es soportada
|
||||||
|
por todos los desarrolladores. Si tiene algún problema con ella, contacte
|
||||||
|
a su autor: Christopher Seawood <cls@seawood.org>
|
||||||
|
|
||||||
|
--disable-shm
|
||||||
|
desactiva el uso de la extensión MIT de memoria compartida. Esto
|
||||||
|
ralentizará la generación de texturas un poco, pero en algunos casos
|
||||||
|
parecerá necesario debido a un error que se manifiesta como íconos y
|
||||||
|
texturas desordenadas.
|
||||||
|
|
||||||
|
--disable-motif
|
||||||
|
desactiva el soporte para el gestor de ventanas mwm.
|
||||||
|
|
||||||
|
--enable-lite
|
||||||
|
quita cosas que ya están soportadas en los entornos de escritorio,
|
||||||
|
tal como KDE y Gnome. Desactiva cosas como: lista de ventanas,
|
||||||
|
menú de aplicaciones raíz, selección de ventanas múltiple. Note
|
||||||
|
que no podrá salir más desde dentro de Window Maker; tendrá que usar
|
||||||
|
kill con la señal SIGTERM o salir de KDE. No aconsejo activarlo.
|
||||||
|
|
||||||
|
--enable-modelock
|
||||||
|
Soporte para bloqueo de estado de lenguaje XKB. Si no sabe que es esto
|
||||||
|
probablemente no lo necesite.
|
||||||
|
|
||||||
|
--enable-sound
|
||||||
|
activa el soporte del módulo para efectos sonoros.
|
||||||
|
|
||||||
|
--disable-xpm
|
||||||
|
desactiva el uso de la biblioteca XPM aunque este disponible en su
|
||||||
|
sistema.
|
||||||
|
|
||||||
|
--disable-png
|
||||||
|
desactiva el uso de la biblioteca PNG.
|
||||||
|
|
||||||
|
--disable-tiff
|
||||||
|
desactiva el uso de la biblioteca TIFF.
|
||||||
|
|
||||||
|
--disable-gif
|
||||||
|
desactiva el uso de la biblioteca GIF.
|
||||||
|
|
||||||
|
--disable-jpeg
|
||||||
|
desactiva el uso de la biblioteca JPEG.
|
||||||
|
|
||||||
|
--disable-shape
|
||||||
|
desactiva la forma de ventanas (para oclock, xeyes etc.)
|
||||||
|
|
||||||
|
NOTAS ESPECÍFICAS A LA PLATAFORMA:
|
||||||
|
=================================
|
||||||
|
|
||||||
|
- máquinas DEC/Alpha
|
||||||
|
|
||||||
|
#>>>>>>>>>>>
|
||||||
|
From: Anton Ivanov <aivanov@eu.level3.net>
|
||||||
|
To: Marcelo E. Magallon <mmagallo@debian.org>
|
||||||
|
Subject: Re: El paquete WindowMaker funciona bien en Alpha?
|
||||||
|
|
||||||
|
> Hola,
|
||||||
|
>
|
||||||
|
> Estuve leyendo algunos documentos en el tarball de WindowMaker,
|
||||||
|
> y encontré esto:
|
||||||
|
>
|
||||||
|
> | - máquinas DEC/Alpha
|
||||||
|
> | podría necesitar pasar el parámetro --disable-shm a configure,
|
||||||
|
> | así ./configure --disable-shm
|
||||||
|
>
|
||||||
|
> alguien está teniendo problemas con WindowMaker en Alpha? Puede alguien
|
||||||
|
> por favor probar esto? Debería el parámetro ser pasado al compilar
|
||||||
|
> en Alpha?
|
||||||
|
|
||||||
|
Descargo de responsabilidad: alphas bajo mi mando nunca han ejecutado X
|
||||||
|
y es poco probable de que las ejecute repentinamente en algún momento.
|
||||||
|
|
||||||
|
Alpha suele tener alguna ridícula poca cantidad de memoria compartida
|
||||||
|
configurada.
|
||||||
|
|
||||||
|
Así que muchísimas aplicaciones suelen to barf. Concretamente - cdrecord, mysql server, etc.
|
||||||
|
|
||||||
|
Verifique donde está el suyo en este momento y súbalo a un valor más adecuado catting la entrada
|
||||||
|
adecuada de /proc o cambiando el /usr/src/linux/include/asm/shmparam.h.
|
||||||
|
|
||||||
|
De lo contrario la memoria compartida en alpha debiera ser completamente funcional y no veo razón
|
||||||
|
para desactivarla. Las mías están aumentadas a 32 o más en muchas máquinas.
|
||||||
|
|
||||||
|
Y si recuerdo correctamente los comentarios en aquél archivo están en realidad mal.
|
||||||
|
El valor no está en bytes, pero si en palabra de tamaño máquina. Para alpha *8.
|
||||||
|
|
||||||
|
Como dije - no ejecuto X en ellas asi que apliqué a todas #include "stdisclaimer.h".
|
||||||
|
#<<<<<<<<<<<<
|
||||||
|
|
||||||
|
- SCO Unix - ejecute configure así
|
||||||
|
CFLAGS="-belf -DANSICPP" ./configure
|
||||||
|
|
||||||
|
-SunOS, Solaris
|
||||||
|
Si tiene gcc instalado, ejecute configure como:
|
||||||
|
CPP_PATH="gcc -E -x c" ./configure
|
||||||
|
Sun cpp le falta algunas características que necesita Window Maker y
|
||||||
|
puede causarle problemas al analizar sintacticamente los archivos config.
|
||||||
|
También podría necesitar usar el --with-libs-from y --with-incs-from para
|
||||||
|
suministrarle el directorio donde libtiff se aloja.
|
||||||
|
Alguien me envió un mensaje diciéndome que también debe hacer que /usr/local/lib
|
||||||
|
sea la primera ruta en LD_LIBRARY_PATH para que funcione.
|
||||||
|
|
||||||
|
Si tiene un Ultra Creator 3D o alguna otra máquina con gráficos high-end,
|
||||||
|
asegúrese de iniciar el servidor X con el valor visual por defecto a 24bpp o
|
||||||
|
podría experimentar problemas con colores destrozados.
|
||||||
|
Este es un error de wmaker y será reparado.
|
||||||
|
|
||||||
|
- GNU/Linux en general
|
||||||
|
Asegúrese de tener /usr/local/lib en /etc/ld.so.conf y de ejecutar
|
||||||
|
ldconfig después de instalar.
|
||||||
|
Desinstale cualquier versión empaquetada de Window Maker antes de
|
||||||
|
instalar una nueva versión.
|
||||||
|
|
||||||
|
- RedHat GNU/Linux
|
||||||
|
Los sistemas RedHat tienen varios problemas molestos. Si lo usa,
|
||||||
|
asegúrese de seguir los pasos de más abajo o Window Maker no funcionará:
|
||||||
|
|
||||||
|
* si instaló el Window Maker que viene con RedHat, desinstálelo antes de
|
||||||
|
actualizar;
|
||||||
|
|
||||||
|
*asegúrese que no tiene las variables de entorno LANG y LINGUAS establecidas a
|
||||||
|
en_RN;
|
||||||
|
|
||||||
|
*asegúrese de tener /usr/local/bin en su variable de entorno PATH;
|
||||||
|
|
||||||
|
* asegúrese de tener /usr/local/lib en /etc/ld.so.conf antes de ejecutar
|
||||||
|
ldconfig;
|
||||||
|
|
||||||
|
*si tiene problemas que mencionan un menaje de error con --no-reexec
|
||||||
|
desinstale libtool-1.2b e instale libtool-1.3 en su lugar. libtool-1.3
|
||||||
|
se puede encontrar en ftp.gnu.org. También lea la sección TROUBLESHOOTING
|
||||||
|
(PROBLEMAS);
|
||||||
|
|
||||||
|
* si instaló el paquete Window Maker desde RedHat y está instalando una
|
||||||
|
nueva versión de WM a mano (compilandolo usted mismo), desinstale antes el
|
||||||
|
paquete desde RedHat.
|
||||||
|
|
||||||
|
*asegúrese de tener un enlace simbólico desde /usr/include/X11 hacia
|
||||||
|
/usr/X11R6/include/X11 (si no, tipee ln -s /usr/X11R6/include/X11 /usr/include/X11)
|
||||||
|
|
||||||
|
* asegúrese de tener /lib/cpp apuntando al programa cpp.
|
||||||
|
|
||||||
|
Si tiene alguna duda en cuanto a hacer algunas de las cosas de arriba,
|
||||||
|
por favor no dude en contactar el soporte para usuarios de RedHat. Ellos
|
||||||
|
responderán amablemente a todas sus preguntas en lo que respecta a su sistema.
|
||||||
|
Ellos también conocen mucho más acerca de su propio sistema que nosotros
|
||||||
|
(nosotros no usamos RedHat).
|
||||||
|
|
||||||
|
- PowerPC MkLinux
|
||||||
|
Necesitará tener la última version de Xpmac. Las versiones más antiguas
|
||||||
|
parecen tener errores que producen el cuelgue del sistema.
|
||||||
|
|
||||||
|
- Debian GNU/Linux
|
||||||
|
Si quiere soporte JPEG y TIFF, asegúrese de tener libtiff-dev y
|
||||||
|
libjpeg-dev instalados.
|
||||||
|
|
||||||
|
- SuSE GNU/Linux
|
||||||
|
Si instaló el paquete Window Maker desde SuSE,
|
||||||
|
desinstálelo antes de instentar compilar wmaker o podría
|
||||||
|
tener problemas.
|
||||||
|
|
||||||
|
|
||||||
|
- MetroX (version desconocida)
|
||||||
|
MetroX tiene un error que corrompe pixmaps que se establecen como
|
||||||
|
fondos de ventana. Si usa MetroX y tuvo problemas raros con texturas, no use
|
||||||
|
texturas en las barras de títulos. O use un servidor X distinto.
|
||||||
|
|
||||||
|
INSTALACIÓN:
|
||||||
|
=============
|
||||||
|
|
||||||
|
Compilando Window Maker
|
||||||
|
------------------
|
||||||
|
Para un comienzo rápido, tipee lo siguiente en el prompt del shell:
|
||||||
|
|
||||||
|
./configure
|
||||||
|
make
|
||||||
|
|
||||||
|
luego, regístrese como root y tipee:
|
||||||
|
|
||||||
|
make install
|
||||||
|
ldconfig
|
||||||
|
|
||||||
|
o si quiere remover los símbolos de depuración desde los binarios y hacerlos más
|
||||||
|
pequeños, puede tipear:
|
||||||
|
|
||||||
|
make install-strip
|
||||||
|
ldconfig
|
||||||
|
|
||||||
|
Esto compilará e instalará Window Maker con los parámetros por defecto.
|
||||||
|
|
||||||
|
Si quiere personalizar algunas opciones de compilación, puede hacer lo siguiente.
|
||||||
|
|
||||||
|
1. (opcional)Mire en la sección OPCIONES DE CONFIGURACIÓN para ver las
|
||||||
|
opciones disponibles. También ejecute:
|
||||||
|
|
||||||
|
./configure --help
|
||||||
|
|
||||||
|
para obtener un listado completo de otras opciones que están disponibles.
|
||||||
|
|
||||||
|
2. Ejecute configure con las opciones que quiera. Por ejemplo, si quiere
|
||||||
|
usar la opción --enable-kde, tipee:
|
||||||
|
|
||||||
|
./configure --enable-kde
|
||||||
|
|
||||||
|
3. (opcional) Edite src/wconfig.h con su editor de texto favorito y
|
||||||
|
echele un vistazo por algunas opciones que podría querer cambiar.
|
||||||
|
|
||||||
|
4. Compile. Solo tipee:
|
||||||
|
|
||||||
|
make
|
||||||
|
|
||||||
|
5. Regístrese como root (si no puede hacerlo, lea la sección "No tengo la contraseña de root" :-()
|
||||||
|
e instale Window Maker en su sistema:
|
||||||
|
su root
|
||||||
|
make install
|
||||||
|
|
||||||
|
|
||||||
|
Configuración específica del usuario
|
||||||
|
------------------------------------
|
||||||
|
|
||||||
|
Estas instrucciones no necesitan ser seguidas al actualizar Window Maker
|
||||||
|
desde una versión más antigua, a menos que se indique de otra forma en el archivo
|
||||||
|
NEWS.
|
||||||
|
|
||||||
|
Todo usuario en su sistema que desee ejecutar Window Maker debe hacer lo siguiente:
|
||||||
|
|
||||||
|
1. Instale los archivos de configuración de Window Maker en su directorio home.
|
||||||
|
Tipee:
|
||||||
|
wmaker.inst
|
||||||
|
|
||||||
|
wmaker.inst instalará los archivos de configuración de Window Maker y
|
||||||
|
configurará X para que automáticamente lance Window Maker al inicio.
|
||||||
|
|
||||||
|
Eso es todo!
|
||||||
|
|
||||||
|
Puede tipear "man wmaker" para obtener algo de ayuda general para la
|
||||||
|
configuración y otras cosas.
|
||||||
|
Lea la Guia de Usuario para una explicación más a fondo de Window Maker.
|
||||||
|
|
||||||
|
Podría querer dar una mirada a la FAQ también.
|
||||||
|
|
||||||
|
Instalando el paquete extras
|
||||||
|
----------------------------
|
||||||
|
|
||||||
|
Desempaquete WindowMaker-extra-<número-de-versión>.tar.gz en /usr/local/share
|
||||||
|
|
||||||
|
Puede obtener el archivo en ftp://ftp.windowmmaker.org. Este archivo es optativo
|
||||||
|
y solo tiene unos pocos íconos, y temas. Busque el último <número-de-versión>
|
||||||
|
disponible.
|
||||||
|
También hay un WindowMaker-extra.readme que le enseña donde vería ir ese paquete.
|
||||||
|
|
||||||
|
|
||||||
|
No tengo la contraseña de root :(
|
||||||
|
--------------------------------
|
||||||
|
|
||||||
|
Si no puede obtener privilegios de superusuario (no puede ser root) puede
|
||||||
|
instalar wmaker en su propio directorio home. Para esto, proporcione la
|
||||||
|
opción --prefix al ejecutar configure en el paso 2 de compilando Window Maker.
|
||||||
|
También necesitará proporcionar la opción --with-appspath, para especificar la ruta
|
||||||
|
para WPrefs.app. Ejemplo:
|
||||||
|
|
||||||
|
./configure --prefix=/home/jshmoe --with-appspath=/home/jshmoe/GNUstep/Apps
|
||||||
|
|
||||||
|
Luego haga /home/jshmoe/bin para que se lo incluya en su ruta de búsqueda, agregue
|
||||||
|
/home/jshmoe/lib a su variable de entorno LD_LIBRARY_PATH y ejecute bin/wmaker.inst
|
||||||
|
|
||||||
|
Por supuesto, /home/jshmoe se supone que va a ser reemplazado con la ruta a su
|
||||||
|
directorio home real.
|
||||||
|
|
||||||
|
|
||||||
|
ACTUALIZANDO
|
||||||
|
============
|
||||||
|
Si está actualizando desde una versión antigua de Window Maker:
|
||||||
|
|
||||||
|
1. Configure y compile Window Maker como siempre.
|
||||||
|
2. Instale Window Maker (pero no ejecute wmaker.inst)
|
||||||
|
3. Lea el archivo NEWS y actualice sus archivos de configuración,
|
||||||
|
si es necesario.
|
||||||
|
|
||||||
|
PROBLEMAS
|
||||||
|
=========
|
||||||
|
|
||||||
|
Cuando tenga alguno problemas durante la configuración (al ejecutar configure),
|
||||||
|
tal como no poder usar una biblioteca de formato gráfico que piensa tener instalada,
|
||||||
|
mire en el archivo config.log para obtener ideas sobre el problema.
|
||||||
|
|
||||||
|
== Error al cargar las fuentes, siempre que existan.
|
||||||
|
|
||||||
|
Intente recompilar sin el soporte NLS.
|
||||||
|
|
||||||
|
== Error al configurar
|
||||||
|
|
||||||
|
ltconfig: unrecognized option `--no-reexec'
|
||||||
|
Try `ltconfig --help' for more information.
|
||||||
|
configure: error: libtool configure failed
|
||||||
|
|
||||||
|
quite la opción --no-reexec desde aclocal.m4 y libPropList/aclocal.m4 y
|
||||||
|
reconfigure.
|
||||||
|
También asegúrese que las versiones de autoconf y automake que tenga instaladas son:
|
||||||
|
|
||||||
|
autoconf 2.13
|
||||||
|
automake 1.4
|
||||||
|
libtool 1.3
|
||||||
|
|
||||||
|
Note que ella no debe ser libtool 1.2b, debe ser libtool 1.3,
|
||||||
|
desde los sitios GNU.
|
||||||
|
|
||||||
|
== No puedo encontrar proplist.h o libPropList.something
|
||||||
|
|
||||||
|
Baje e instale libPropList desde los lugares ya citados en algún lugar
|
||||||
|
de este archivo.
|
||||||
|
|
||||||
|
== configure no detecta libtiff, u otras bibliotecas gráficas.
|
||||||
|
|
||||||
|
Elimine config.cache, luego vuelva a ejecutar configure añadiendo las siguientes
|
||||||
|
opciones a configure (entre sus otras opciones):
|
||||||
|
|
||||||
|
--with-libs-from="-L/usr/local/lib"
|
||||||
|
--with-incs-from="-I/usr/local/include -I/usr/local/include/tiff"
|
||||||
|
|
||||||
|
Sustituya las rutas donde están localizadas sus bibliotecas gráficas y sus
|
||||||
|
correspondientes archivos header. Puede colocar rutas múltiples en cualquiera de
|
||||||
|
estas opciones, como se muestra en el ejemplo de --with-incs-from . Solo coloque
|
||||||
|
un espacio entre ellas.
|
||||||
|
|
||||||
|
== configure no detecta libXpm.
|
||||||
|
|
||||||
|
* Verifique si tiene un enlace simbólico desde libXpm.so.4.9 a libXpm.so
|
||||||
|
|
||||||
|
== Segmentation fault al inicio.
|
||||||
|
|
||||||
|
* Verifique si la versión de libXPM que tiene es por lo menos la 4.7
|
||||||
|
|
||||||
|
* Verifique si tiene una versión actualizada de ~/GNUstep/Defaults/WindowMaker
|
||||||
|
|
||||||
|
Si no está seguro, intente renombrar ~/GNUstep a ~/GNUtmp y luego ejecute wmaker.inst
|
||||||
|
|
||||||
|
== "...: your machine is misconfigured. gethostname() returned (none)"
|
||||||
|
|
||||||
|
* el hostname de su máquina está definido a algo inválido, como comenzar con
|
||||||
|
un paréntesis. Haga un man hostname para obtener información acerca de como definirlo.
|
||||||
|
|
||||||
|
|
||||||
|
== El menú raíz contiene solo 2 entradas. ("XTerm" y "Exit...")
|
||||||
|
|
||||||
|
* Window Maker no está encontrando cpp (el preprocesador de C). Si su
|
||||||
|
cpp no está ubicado en /lib/cpp, edite src/config.h y corrija la ruta en
|
||||||
|
CPP_PATH.
|
||||||
|
|
||||||
|
== checking lex output file root... configure: error: cannot find output from true; giving up
|
||||||
|
|
||||||
|
* Lea la sección REQUERIMIENTOS de este archivo.
|
||||||
|
|
||||||
|
|
||||||
|
LOCALES/INTERNACIONALIZACIÓN
|
||||||
|
============================
|
||||||
|
|
||||||
|
Window Maker tiene soporte de idioma nacional. Para activar este soporte,
|
||||||
|
debe compilar Window Maker con algunos parámetros adicionales.
|
||||||
|
|
||||||
|
0 - Debe tener el paquete GNU gettext instalado. Puede obtenerse en
|
||||||
|
ftp://prep.ai.mit.edu/pub/gnu/gettext-nnn.tar.gz
|
||||||
|
|
||||||
|
Los pasos 1 al 3 pueden saltearse si usa el script Install.
|
||||||
|
|
||||||
|
1 - Debe seleccionar los idiomas que quiere soportar. Defina el
|
||||||
|
LINGUAS a la lista de locales que quiera. El Inglés siempre está
|
||||||
|
soportado. Ejemplo:
|
||||||
|
|
||||||
|
setenv LINGUAS "pt ja de"
|
||||||
|
en csh
|
||||||
|
|
||||||
|
o
|
||||||
|
|
||||||
|
export LINGUAS;LINGUAS="pt ja de"
|
||||||
|
en sh
|
||||||
|
|
||||||
|
La lista de locales soportados se pueden encontrar en po/README.
|
||||||
|
El Inglés es el idioma pr defecto.
|
||||||
|
|
||||||
|
Lea po/README si desea traducir y mantener archivos locale para otros
|
||||||
|
idiomas.
|
||||||
|
|
||||||
|
2 - Adicionalmente, si su idioma usa caracteres multi-byte, tal como
|
||||||
|
Japonés o Coreano, debe definir la opción MultiByteText a YES
|
||||||
|
en ~/GNUstep/Defaults/WMGLOBAL
|
||||||
|
|
||||||
|
3 - Configure, compile e instale Window Maker normalmente.
|
||||||
|
|
||||||
|
4 - Para seleccionar un locale particular en tiempo de ejecución debe definir la
|
||||||
|
variable de entorno LANG al locale que quiera. Por ejemplo, si quiere definir
|
||||||
|
el locale portugués, debe ejecutar
|
||||||
|
|
||||||
|
setenv LANG pt
|
||||||
|
|
||||||
|
en csh o
|
||||||
|
|
||||||
|
export LANG; LANG=pt
|
||||||
|
|
||||||
|
en Bourne sh y similares
|
||||||
|
|
||||||
|
Nota: Si tiene definida la variable de entorno LC_CTYPE, debe
|
||||||
|
indefinirla antes de ejecutar wmaker.
|
||||||
|
|
||||||
|
Window Maker busca los archivos de definición de menú en el siguiente orden:
|
||||||
|
(para portugués brasileño, en este caso):
|
||||||
|
|
||||||
|
menu.pt_BR
|
||||||
|
menu.pt
|
||||||
|
menu
|
||||||
|
|
||||||
|
5 - Si elige un idioma que usa caracteres multi-byte, debe configurar
|
||||||
|
las fuentes adecuadamente. Lea la página del manual para XCreateFontSet
|
||||||
|
para obtener más detalles sobre esto. Debe cambiar el archivo ~/G/D/Windowmaker
|
||||||
|
para las fuentes usadas en barras de título, menús y otras cosas. Para las fuentes
|
||||||
|
usadas en ventanas de diálogo, cambie ~/G/D/WMGLOBAL. El %d en los nombres de las
|
||||||
|
fuentes no debe ser quitado. Puede también usar el script wsetfont proporcionado para
|
||||||
|
esta tarea. Lea el mismo script para obtener instrucciones.
|
||||||
|
|
||||||
|
Por ejemplo, puede especificar lo siguiente en ~/G/D/WindowMaker:
|
||||||
|
|
||||||
|
WindowTitleFont = "-*-helvetica-bold-r-normal-*-12-*,-*-*-medium-r-normal-*-14-*";
|
||||||
|
MenuTitleFont = "-*-helvetica-bold-r-normal-*-12-*,-*-*-medium-r-normal-*-14-*";
|
||||||
|
MenuTextFont = "-*-helvetica-medium-r-normal-*-12-*,-*-*-medium-r-normal-*-14-*";
|
||||||
|
IconTitleFont = "-*-helvetica-medium-r-normal-*-8-*,-*-*-medium-r-normal-*-12-*";
|
||||||
|
ClipTitleFont = "-*-helvetica-bold-r-normal-*-10-*,-*-*-medium-r-normal-*-12-*";
|
||||||
|
DisplayFont = "-*-helvetica-medium-r-normal-*-12-*,-*-*-medium-r-normal-*-12-*";
|
||||||
|
|
||||||
|
y en ~/G/D/WMGLOBAL:
|
||||||
|
|
||||||
|
SystemFont = "-*-*-medium-r-normal-*-%d-*-*-*-*-*-*-*";
|
||||||
|
BoldSystemFont = "-*-*-medium-r-normal-*-%d-*-*-*-*-*-*-*";
|
||||||
|
|
||||||
|
Las 2 fuentes de arriba son usadas únicamente por aplicaciones que usan WINGs
|
||||||
|
(WindowMaker y WPrefs.app)
|
||||||
|
|
||||||
|
El script wsetfont que se proporciona le permitirá cambiar las definiciones de fuentes
|
||||||
|
de una manera fácil. De una mirada al script para detalles de uso.
|
||||||
|
|
||||||
|
traducido por Efraín Maximiliano Palermo <max_drake2001@yahoo.com.ar>
|
||||||
631
INSTALL.fr
Normal file
631
INSTALL.fr
Normal file
@@ -0,0 +1,631 @@
|
|||||||
|
|
||||||
|
Instructions pour l'installation de Window Maker
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
PLATEFORMES SUPPORTÉES
|
||||||
|
======================
|
||||||
|
(c.à.d. : j'ai entendu dire que la compilation a été réalisée avec succès sur..)
|
||||||
|
|
||||||
|
- Intel GNU/Linux Conectiva 5.9 (beta)
|
||||||
|
- Intel GNU/Linux Slackware
|
||||||
|
- Intel GNU/Linux Debian
|
||||||
|
- Intel GNU/Linux (autres)
|
||||||
|
- Sparc GNU/Linux RedHat 5.1
|
||||||
|
- PowerPC GNU/MkLinux
|
||||||
|
- Alpha GNU/Linux RedHat 5.1
|
||||||
|
- FreeBSD
|
||||||
|
- NetBSD
|
||||||
|
- OpenBSD
|
||||||
|
- BSDI 4.0
|
||||||
|
- Solaris 2.5.1, 2.5.2
|
||||||
|
- Solaris 2.6.0
|
||||||
|
- Solaris 2.7beta
|
||||||
|
- Solaris 2.8 sur Ultra Sparc 10 et E450
|
||||||
|
- SCO Unix
|
||||||
|
- SGI Irix 5.x, 6.5
|
||||||
|
- OSF/1
|
||||||
|
- HP-UX
|
||||||
|
- AIX 3.2.5
|
||||||
|
- AIX 4.1.4 / IBM PowerPC
|
||||||
|
- AIX 4.3.1 / IBM CC compiler
|
||||||
|
- AIX 4.3.2 / IBM PowerPC
|
||||||
|
- AIX 5.3
|
||||||
|
- DEC Alpha/Digital UNIX 4.x
|
||||||
|
- XFree86 / OS/2
|
||||||
|
- Corel NetWinder
|
||||||
|
- SunOS 4.x
|
||||||
|
- PowerMac / Power MachTen 4.1.1 sous MacOS
|
||||||
|
- Amiga 3000 sous RedHat Linux 5.1 (Rawhide)
|
||||||
|
- IBM S/390 sous Linux
|
||||||
|
- IBM S/390 sous Conectiva Linux (experimental)
|
||||||
|
- iBook sous Darwin
|
||||||
|
- Windows NT sous Cygwin/XFree86
|
||||||
|
- Sony PlayStation2 sous Linux
|
||||||
|
|
||||||
|
Toutes les marques déposées sont la propriété de leur propriétaire.
|
||||||
|
|
||||||
|
Tout patch qui pourrait faciliter l'adaptation à d'autres plateformes
|
||||||
|
est le bienvenu.
|
||||||
|
|
||||||
|
|
||||||
|
PRÉ-REQUIS
|
||||||
|
==========
|
||||||
|
|
||||||
|
Les logiciels suivants sont nécessaires à l'utilisation de Window Maker :
|
||||||
|
|
||||||
|
- X11R6.x
|
||||||
|
Window Maker peut être compilé avec des versions plus anciennes de X,
|
||||||
|
comme X11R5 (Solaris) ou X11R4 (OpenWindows), mais il ne fonctionnera
|
||||||
|
pas correctement à 100%.
|
||||||
|
Avec ces serveurs X, les icônes des applications n'apparaîtrons pas,
|
||||||
|
et vous aurez des problèmes à l'utilisation du dock. La mise à jour
|
||||||
|
des librairies côté client (Xlib, Xt, etc.) pourront améliorer les
|
||||||
|
choses si vous ne pouvez pas mettre à jour le serveur.
|
||||||
|
|
||||||
|
Les éléments suivants sont nécessaires à la compilation de Window Maker :
|
||||||
|
|
||||||
|
- pré-requis de base
|
||||||
|
Pour compiler Window Maker, assurez-vous que gcc (ou tout autre
|
||||||
|
compilateur de C ANSI) ainsi que les fichiers d'en-têtes de X sont
|
||||||
|
installés. Débutants sous Linux : vous devez installer les paquetages
|
||||||
|
de développement de X ainsi que ceux de la suite gcc. Le cas contraire,
|
||||||
|
vous ne pourrez jamais compiler aucun programme prévu pour X, y compris
|
||||||
|
Window Maker.
|
||||||
|
|
||||||
|
- autoconf, automake et libtool
|
||||||
|
Ces outils ne sont pas indispensables, mais si au moins l'un d'eux
|
||||||
|
est installé sur votre système, assurez-vous que TOUS le sont, et
|
||||||
|
que les versions de ces outils sont exactement :
|
||||||
|
autoconf 2.54
|
||||||
|
automake 1.4
|
||||||
|
libtool 1.4.2
|
||||||
|
Si les versions installées sur votre système différent, désactivez-les
|
||||||
|
provisoirement, par exemple en les renommant, ou en les désinstallant
|
||||||
|
de votre système. Si vous ne développez ni de compilez de logiciels,
|
||||||
|
vous n'en avez pas besoin et leur désinstallation n'est donc pas un
|
||||||
|
problème.
|
||||||
|
|
||||||
|
|
||||||
|
OPTIONNEL
|
||||||
|
=========
|
||||||
|
|
||||||
|
Ces librairies ne sont pas nécessaires pour utiliser Window Maker, mais
|
||||||
|
elles sont supportées, au cas où vous souhaiteriez les utiliser. Les
|
||||||
|
versions ci-dessous sont celles dont je dispose (et du coup, il est
|
||||||
|
garanti qu'elles fonctionnent), mais des versions différentes peuvent
|
||||||
|
fonctionner aussi bien.
|
||||||
|
|
||||||
|
|
||||||
|
- libXPM 4.7 ou plus récent
|
||||||
|
Les versions plus anciennes peuvent ne pas fonctionner !!!
|
||||||
|
Disponible sur ftp://sunsite.unc.edu/pub/Linux/libs/X/
|
||||||
|
|
||||||
|
Le support des fichiers XPM est intégré, mais il ne prendra
|
||||||
|
pas en compte les images dont le format est exotique.
|
||||||
|
|
||||||
|
- libpng 0.96 ou plus récent, et zlib
|
||||||
|
Pour pouvoir utiliser les images au format PNG.
|
||||||
|
http://www.cdrom.com/pub/png/
|
||||||
|
|
||||||
|
- libtiff 3.4 ou plus récent
|
||||||
|
Pour pouvoir utiliser les images au format TIFF.
|
||||||
|
Vous trouverez ça ici : ftp://ftp.sgi.com/graphics/tiff
|
||||||
|
|
||||||
|
- libjpeg 6.0.1 ou plus récent
|
||||||
|
Pour pouvoir utiliser les images au format JPEG.
|
||||||
|
http://www.ijg.org/
|
||||||
|
|
||||||
|
- libgif 2.2 ou libungif
|
||||||
|
Pour pouvoir utiliser les images au format GIF.
|
||||||
|
ftp://prtr-13.ucsc.edu/pub/libungif/
|
||||||
|
|
||||||
|
- GNU xgettext
|
||||||
|
Si vous voulez disposer des traductions en d'autres langues, GNU gettext
|
||||||
|
est nécessaire. Les autres versions de gettext sont incompatibles et ne
|
||||||
|
fonctionneront pas.
|
||||||
|
Vous trouverez la version GNU sur ftp://ftp.gnu.org
|
||||||
|
|
||||||
|
|
||||||
|
OPTIONS DE CONFIGURATION
|
||||||
|
========================
|
||||||
|
|
||||||
|
Ces options peuvent être passées au script de configuration afin d'activer
|
||||||
|
ou désactiver des fonctionnalités de Window Maker. Par exemple :
|
||||||
|
|
||||||
|
./configure --enable-kde --enable-gnome
|
||||||
|
|
||||||
|
configurera Window Maker avec le support intégré pour KDE et GNOME.
|
||||||
|
|
||||||
|
|
||||||
|
Afin d'obtenir la liste des autres options, exécutez ./configure --help
|
||||||
|
|
||||||
|
--with-libs-from
|
||||||
|
ajoute des chemins d'accès pour la recherche des librairies.
|
||||||
|
L'option -L doit précéder chaque chemin d'accès, comme suit :
|
||||||
|
--with-libs-from="-L/opt/libs -L/usr/local/lib"
|
||||||
|
|
||||||
|
--with-incs-from
|
||||||
|
ajoute des chemins d'accès pour la recherche des fichiers d'en-tête.
|
||||||
|
L'option -I doit précéder chaque chemin d'accès, comme suit :
|
||||||
|
--with-incs-from="-I/opt/headers -I/usr/local/include"
|
||||||
|
|
||||||
|
--enable-single-icon
|
||||||
|
active le regroupement des toutes les appicons des WM_CLASS et WM_INSTANCE
|
||||||
|
en une seule icône. Aucun support n'est offert par les développeurs pour
|
||||||
|
cette fonctionnalité. Si vous avez des problèmes avec celle-ci, contactez
|
||||||
|
son auteur :
|
||||||
|
Christopher Seawood <cls@seawood.org>
|
||||||
|
|
||||||
|
--disable-shm
|
||||||
|
désactive l'utilisation de l'extension "MIT shared memory". Cela ralentira
|
||||||
|
un petit peu la génération des textures, mais il semble que cela soit
|
||||||
|
nécessaire dans certains cas pour éviter un bogue se manifestant au niveau
|
||||||
|
des icônes et des textures.
|
||||||
|
|
||||||
|
--disable-motif
|
||||||
|
désactive le support pour les fonctionnalités en rapport avec le gestionnaire
|
||||||
|
de fenêtres mwm.
|
||||||
|
|
||||||
|
--enable-lite
|
||||||
|
désactive des fonctionnalités déjà prises en compte par les gestionnaires de
|
||||||
|
bureau tels que KDE et GNOME. Celà concerne : la liste de fenêtres, le menu
|
||||||
|
des applications, la sélection multiple de fenêtres. Attention : vous ne
|
||||||
|
pourrez plus sortir de Window Maker autrement qu'en utilisant kill avec le
|
||||||
|
signal SIGTERM ou en quittant à l'aide de KDE. Il n'est pas conseillé
|
||||||
|
d'utiliser cette option.
|
||||||
|
|
||||||
|
--enable-modelock
|
||||||
|
active le support pour le verrouillage du "XKB language status". Si vous ne
|
||||||
|
savez pas de quoi il retourne, c'est probablement que vous n'en avez pas
|
||||||
|
utilité.
|
||||||
|
|
||||||
|
--enable-sound
|
||||||
|
active le support pour le module de gestion des effets sonores.
|
||||||
|
|
||||||
|
--disable-xpm
|
||||||
|
désactive l'utilisation de la librairie XPM même si elle est présente
|
||||||
|
sur votre système.
|
||||||
|
|
||||||
|
--disable-png
|
||||||
|
désactive l'utilisation de la librairie PNG.
|
||||||
|
|
||||||
|
--disable-tiff
|
||||||
|
désactive l'utilisation de la librairie TIFF.
|
||||||
|
|
||||||
|
--disable-gif
|
||||||
|
désactive l'utilisation de la librairie GIF.
|
||||||
|
|
||||||
|
--disable-jpeg
|
||||||
|
désactive l'utilisation de la librairie JPEG.
|
||||||
|
|
||||||
|
--disable-shape
|
||||||
|
désactive l'utilisation de "shaped windows" (pour oclock, xeyes, etc.).
|
||||||
|
|
||||||
|
|
||||||
|
NOTES SPÉCIFIQUES AUX PLATEFORMES
|
||||||
|
=================================
|
||||||
|
|
||||||
|
- machines DEC/Alpha
|
||||||
|
|
||||||
|
#>>>>>>>>>>>
|
||||||
|
De : Anton Ivanov <aivanov@eu.level3.net>
|
||||||
|
A : Marcelo E. Magallon <mmagallo@debian.org>
|
||||||
|
Sujet : Re : Est-ce que le paquetage WindowMaker fonctionne correctement sur Alpha?
|
||||||
|
|
||||||
|
> Salut,
|
||||||
|
>
|
||||||
|
> Je lisais la doc contenue dans l'archive de WindowMaker, quand je suis
|
||||||
|
> tombé sur ça :
|
||||||
|
>
|
||||||
|
> | - machines DEC/Alpha
|
||||||
|
> | Il est possible que vous deviez utiliser l'option --disable-shm pour
|
||||||
|
> | configurer la compilation, comme suit :
|
||||||
|
> | ./configure --disable-shm
|
||||||
|
>
|
||||||
|
> est-ce que quelqu'un a eu des problèmes avec WindowMaker sur Alpha? Est-ce
|
||||||
|
> que quelqu'un peut tester cela? Doit-on vraiment utiliser cette option
|
||||||
|
> pour compiler sur Alpha?
|
||||||
|
|
||||||
|
Notez bien : les Alphas dont je me sers ne sont jamais sous X et ne sont pas près
|
||||||
|
de l'être.
|
||||||
|
|
||||||
|
Bien souvent, la configuration des Alphas n'inclut qu'un volume ridiculement
|
||||||
|
petit de mémoire partagée. Aussi il n'est pas étonnant qu'un grand nombre
|
||||||
|
d'applications comme cdrecord ou mysql server plantent carrément.
|
||||||
|
|
||||||
|
Vérifiez ces réglages sur votre système et modifiez-les en conséquent :
|
||||||
|
pour cela, manipulez l'entrée appropriée dans /proc ou modifiez le fichier
|
||||||
|
/usr/src/linux/include/asm/shmparam.h.
|
||||||
|
|
||||||
|
En dehors de ce cas, la mémoire partagée sous Alpha est sensée ne pas
|
||||||
|
poser de problème et je ne vois aucune raison de la désactiver.
|
||||||
|
Pour ma part, elle est à 32 ou plus sur la pluspart des machines.
|
||||||
|
|
||||||
|
De plus, si ma mémoire est exacte, les commentaires dans ce fichier
|
||||||
|
sont tout à fait inexacts. La valeur n'est pas exprimée en octets, mais en
|
||||||
|
mots, dépendant de la machine. Pour les Alphas, c'est donc *8.
|
||||||
|
|
||||||
|
Je rappelle que je n'utilise pas X sur ces machines, donc ce que j'indique
|
||||||
|
est soumis à toutes les réserves habituelles. (#include "standard_disclaimer.h")
|
||||||
|
#<<<<<<<<<<<<
|
||||||
|
|
||||||
|
|
||||||
|
- SCO Unix
|
||||||
|
Lancez configure comme suit :
|
||||||
|
CFLAGS="-belf -DANSICPP" ./configure
|
||||||
|
|
||||||
|
- SunOS, Solaris
|
||||||
|
Si gcc est installé, lancez configure comme suit :
|
||||||
|
CPP_PATH="gcc -E -x c" ./configure
|
||||||
|
Le cpp de Sun ne dispose pas de certaines fonctionnalités nécessaire pour
|
||||||
|
Window Maker et cela peut occasionner des problèmes avec l'utilisation des
|
||||||
|
fichiers de configuration.
|
||||||
|
Il peut être aussi nécessaire d'indiquer le chemin d'accès à la librairie
|
||||||
|
libtiff en utilisant les options --with-libs-from et --with-incs-from
|
||||||
|
avec configure.
|
||||||
|
Quelqu'un m'a rapporté qu'il est nécessaire de faire figurer /usr/local/lib
|
||||||
|
en premier dans la variable d'environnement LD_LIBRARY_PATH.
|
||||||
|
|
||||||
|
Si vous utilisez un Ultra Creator 3D ou une autre machine graphique
|
||||||
|
de haut niveau, faites en sorte de démarrer le serveur X avec le mode
|
||||||
|
graphique par défaut à 24bpp sinon vous pourriez constaer des problèmes
|
||||||
|
au niveau des couleurs.
|
||||||
|
C'est une bogue répertorié au niveau de Window Maker, il sera corrigé.
|
||||||
|
|
||||||
|
- GNU/Linux en général
|
||||||
|
Assurez-vous que /usr/local/lib figure dans /etc/ld.so.conf et que vous
|
||||||
|
avez lancé ldconfig après l'installation.
|
||||||
|
Désinstallez tout précédent paquetage de Window Maker avant d'installer
|
||||||
|
une nouvelle version.
|
||||||
|
|
||||||
|
- RedHat GNU/Linux
|
||||||
|
Il peut y avoir plusieurs problèmes ennuyeux sur les systèmes RedHat.
|
||||||
|
Voici la marche à suivre sous peine de ne pouvoir utiliser Window Maker
|
||||||
|
sur ces systèmes :
|
||||||
|
|
||||||
|
* si la version de Window Maker livrée avec RedHat est installée,
|
||||||
|
désinstallez-la avant de mettre à jour votre système;
|
||||||
|
|
||||||
|
* assurez-vous que ni la variable d'environnement LANG ni LINGUAS ne
|
||||||
|
contiennent "en_RN";
|
||||||
|
|
||||||
|
* vérifiez que /usr/local/bin est présent dans votre variable d'environnement
|
||||||
|
PATH;
|
||||||
|
|
||||||
|
* il faut que /usr/local/lib soit dans /etc/ld.so.conf avant de lancer
|
||||||
|
ldconfig;
|
||||||
|
|
||||||
|
* si vous rencontrez des messages d'erreur en rapport avec "--no-reexec",
|
||||||
|
désinstallez libtool-1.2b et installez libtool-1.3.
|
||||||
|
libtool-1.3 peut être trouvé sur ftp.gnu.org.
|
||||||
|
Consultez aussi la section PROBLÈMES;
|
||||||
|
|
||||||
|
* si vous aviez auparavant installé le paquetage de Window Maker livré
|
||||||
|
avec RedHat et que vous voulez installer maintenant manuellement une nouvelle
|
||||||
|
version, vous devez au préalable désinstaller le paquetage provenant de la
|
||||||
|
RedHat;
|
||||||
|
|
||||||
|
* assurez-vous qu'il existe un lien symbolique de from /usr/include/X11 vers
|
||||||
|
/usr/X11R6/include/X11 (le cas échéant, lancez cette commande :
|
||||||
|
ln -s /usr/X11R6/include/X11 /usr/include/X11);
|
||||||
|
|
||||||
|
* assurez-vous que /lib/cpp pointe bien vers le programme cpp
|
||||||
|
|
||||||
|
Si vous avez un doute concernant quoi que ce soit de relatif à l'installation
|
||||||
|
de Window Maker sur une RedHat, n'hésitez pas à contacter le support
|
||||||
|
utilisateur de RedHat. Ils vous renseigneront toujours et tenteront de vous
|
||||||
|
dépanner dans l'utilisation et la configuration de votre système RedHat.
|
||||||
|
D'un autre côté, ils sont plus au fait que nous pour tout ce qui est relatif
|
||||||
|
aux RedHat (nous n'en utilisons pas).
|
||||||
|
|
||||||
|
- PowerPC MkLinux
|
||||||
|
Installez la version la plus récente de Xpmac. Les versions plus
|
||||||
|
anciennes semblent contenir un bogue qui est susceptible de bloquer
|
||||||
|
le système.
|
||||||
|
|
||||||
|
- Debian GNU/Linux
|
||||||
|
Si vous voulez bénéficier du support des fichier JPEG et TIFF,
|
||||||
|
assurez-vous que les paquetages libtiff-dev et libjpeg-dev sont installés.
|
||||||
|
|
||||||
|
- SuSE GNU/Linux
|
||||||
|
Désinstallez tout précédent paquetage de Window Maker avant d'installer
|
||||||
|
une nouvelle version. Le cas échéant, vous pourriez rencontrer des
|
||||||
|
problèmes.
|
||||||
|
|
||||||
|
- MetroX (version indéterminée)
|
||||||
|
MetroX contient un bogue qui corrompt les pixmaps utilisées en fond
|
||||||
|
de fenêtres. Si vous utilisez MetroX et rencontrer des problèmes
|
||||||
|
avec les textures, n'utilisez pas les textures dans les barres de titre,
|
||||||
|
ou bien utilisez un autre serveur X.
|
||||||
|
|
||||||
|
|
||||||
|
INSTALLATION
|
||||||
|
============
|
||||||
|
|
||||||
|
Compiler Window Maker
|
||||||
|
---------------------
|
||||||
|
Pour aller vite, tapez ce qui suit dans un prompt shell :
|
||||||
|
|
||||||
|
./configure
|
||||||
|
make
|
||||||
|
|
||||||
|
puis, loguez-vous en tant que root and tapez :
|
||||||
|
|
||||||
|
make install
|
||||||
|
ldconfig
|
||||||
|
|
||||||
|
ou, si vous voulez ôter les infos de débogage des exécutables et ainsi les
|
||||||
|
rendre plus petits, tapez plutôt :
|
||||||
|
|
||||||
|
make install-strip
|
||||||
|
ldconfig
|
||||||
|
|
||||||
|
Tout ceci compile et installe Window Maker avec les réglages par défaut.
|
||||||
|
|
||||||
|
Maintenant, si vous voulez personnaliser des options de compilation, vous
|
||||||
|
pouvez faire :
|
||||||
|
|
||||||
|
1. (optionnel) Consulter la section OPTIONS DE CONFIGURATION
|
||||||
|
dans ce même fichier. Exécutez aussi :
|
||||||
|
|
||||||
|
./configure --help
|
||||||
|
|
||||||
|
pour avoir la liste des autres options disponibles.
|
||||||
|
|
||||||
|
2. Lancez configure avec les options choisies. Par exemple, si vous voulez
|
||||||
|
utiliser l'option --enable-kde, tapez :
|
||||||
|
|
||||||
|
./configure --enable-kde
|
||||||
|
|
||||||
|
3. (optionnel) Éditez src/wconfig.h avec votre éditeur de texte favori et
|
||||||
|
et modifiez sont contenu à votre guise.
|
||||||
|
|
||||||
|
4. Compilez. Il faut juste taper :
|
||||||
|
|
||||||
|
make
|
||||||
|
|
||||||
|
5. Loguez-vous en tant que root (si vous ne pouvez pas le faire, lisez le
|
||||||
|
paragraphe "Je n'ai pas le mot de passe de root :-(") et installez
|
||||||
|
Window Maker sur votre système :
|
||||||
|
su root
|
||||||
|
make install
|
||||||
|
|
||||||
|
|
||||||
|
Réglages pour un utilisateur
|
||||||
|
----------------------------
|
||||||
|
|
||||||
|
Ces instructions suivantes ne sont pas nécessaires si vous mettez à jour
|
||||||
|
Window Maker à partir d'une version plus ancienne, à moins que ce soit
|
||||||
|
précisé dans le fichier NEWS.
|
||||||
|
|
||||||
|
Chaque utilisateur qui veut utiliser Window Maker sur votre système doit
|
||||||
|
faire ce qui suit :
|
||||||
|
|
||||||
|
1. Installer les fichiers de configuration de Window Maker dans son
|
||||||
|
répertoire personnel.
|
||||||
|
|
||||||
|
Pour ceci, il doit taper :
|
||||||
|
wmaker.inst
|
||||||
|
|
||||||
|
wmaker.inst installera les fichiers de configuration de Window Maker
|
||||||
|
pour l'utilisateur et configurera ses paramètres de X de façon à ce que
|
||||||
|
Window Maker soit automatiquement lancé au démarrage de X.
|
||||||
|
|
||||||
|
C'est tout!
|
||||||
|
|
||||||
|
Vous pouvez aussi taper "man wmaker" afin d'obtenir plus de renseignements
|
||||||
|
sur la configuration et d'autres sujets.
|
||||||
|
|
||||||
|
Consultez le Guide de l'utilisateur afin d'obtenir des informationss plus
|
||||||
|
en détail sur Window Maker.
|
||||||
|
|
||||||
|
Pourquoi ne pas aussi jeter un oeil aux FAQs..
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Installation du paquetage additionnel
|
||||||
|
-------------------------------------
|
||||||
|
|
||||||
|
Décompressez WindowMaker-extra-<version-number>.tar.gz dans /usr/local/share
|
||||||
|
|
||||||
|
Vous trouverez le fichier sur ftp://ftp.windowmaker.org. Ce paquetage est optionnel,
|
||||||
|
il contient des icônes et des thèmes supplémentaires. Vérifiez que vous avez
|
||||||
|
bien la derniere version de ce paquetage.
|
||||||
|
Il y a aussi un fichier WindowMaker-extra.readme qui indique comment procéder à
|
||||||
|
l'installation de ce paquetage.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Je n'ai pas le mot de passe de root :-(
|
||||||
|
---------------------------------------
|
||||||
|
|
||||||
|
Si vous n'avez pas acc-s aux privilèges du super-utilisateur (root), vous pouvez
|
||||||
|
installer Window Maker dans votre répertoire personnel. Pour ce faire, ajoutez
|
||||||
|
l'option --prefix correctement renseignée au moment de l'exécution de ./configure
|
||||||
|
(étape 2 de la compilation de Window Maker).
|
||||||
|
Il est aussi nécessaire d'utiliser l'option --with-appspath, afin de préciser
|
||||||
|
le chemin d'accès à WPrefs.app. Par exemple :
|
||||||
|
|
||||||
|
./configure --prefix=/home/jshmoe --with-appspath=/home/jshmoe/GNUstep/Apps
|
||||||
|
|
||||||
|
|
||||||
|
Puis, faites en sorte que /home/jshmoe/bin soit inclus dans votre PATH, ajoutez
|
||||||
|
/home/jshmoe/lib à votre variable d'environnement LD_LIBRARY_PATH puis lancez
|
||||||
|
bin/wmaker.inst
|
||||||
|
|
||||||
|
Bien sûr, /home/jshmoe est supposé être remplacé par votre répertoire personnel.
|
||||||
|
|
||||||
|
|
||||||
|
MISE À JOUR
|
||||||
|
===========
|
||||||
|
|
||||||
|
Si vous mettez à jour une version plus ancienne de Window Maker :
|
||||||
|
|
||||||
|
1. Configurez et compilez Window Maker comme d'habitude
|
||||||
|
2. Installez Window Maker (mais n'exécutez pas wmaker.inst)
|
||||||
|
3. Consultez le fichier NEWS et mettez à jour vos fichiers de configuration
|
||||||
|
si nécessaire.
|
||||||
|
|
||||||
|
|
||||||
|
PROBLÈMES
|
||||||
|
=========
|
||||||
|
|
||||||
|
Si vous rencontrez des problèmes pendant la phase de configuration, comme par
|
||||||
|
exemple l'impossibilité d'utiliser une librairie de manipulation de format
|
||||||
|
graphique alors que vous pensez qu'elle est installée, jetez un oeil au contenu
|
||||||
|
du fichier config.log, vous y trouverez peut-être des indices pour résoudre
|
||||||
|
ce problème.
|
||||||
|
|
||||||
|
|
||||||
|
== erreur de chargement de polices, alors qu'elles existent
|
||||||
|
|
||||||
|
Essayez de recompiler sans le support pour le NLS.
|
||||||
|
|
||||||
|
|
||||||
|
== erreur à la configuration
|
||||||
|
|
||||||
|
ltconfig: unrecognized option `--no-reexec'
|
||||||
|
Try `ltconfig --help' for more information.
|
||||||
|
configure: error: libtool configure failed
|
||||||
|
|
||||||
|
Otez l'option --no-reexec du fichier aclocal.m4 et relancer la configuration.
|
||||||
|
Assurez vous aussi que les versions d'autoconf et d'automake correspondent bien
|
||||||
|
aux pré-requis :
|
||||||
|
autoconf 2.13
|
||||||
|
automake 1.4
|
||||||
|
libtool 1.3
|
||||||
|
|
||||||
|
Notez bien que ce ne doit PAS être libtool 1.2b, mais libtool bien 1.3,
|
||||||
|
disponible sur les sites GNU.
|
||||||
|
|
||||||
|
|
||||||
|
== configure ne trouve pas libtiff ou une autre librairie graphique
|
||||||
|
|
||||||
|
Effacez le fichier config.cache, et exécutez à nouveau configure avec les options
|
||||||
|
suivantes (en plus des options que vous utilisiez déjà) :
|
||||||
|
--with-libs-from="-L/usr/local/lib"
|
||||||
|
--with-incs-from="-I/usr/local/include -I/usr/local/include/tiff"
|
||||||
|
Insérez les chemins d'accès aux librairies graphiques et à leurs fichiers d'en-tête.
|
||||||
|
Plusieurs chemins d'accès peuvent être ajoutés pour chacune de ces options,
|
||||||
|
comme montré pour --with-incs-from. Séparez-les juste par un espace.
|
||||||
|
|
||||||
|
|
||||||
|
== configure ne trouve pas libXpm
|
||||||
|
|
||||||
|
* Vérifiez que vous avez un lien sympbolique de libXpm.so.4.9 vers libXpm.so
|
||||||
|
|
||||||
|
|
||||||
|
== segmentation fault au démarrage
|
||||||
|
|
||||||
|
* Vérifiez que la version de libXPM qui est installée est au moins 4.7.
|
||||||
|
|
||||||
|
* Vérifiez que votre fichier ~/GNUstep/Defaults/WindowMaker est à jour.
|
||||||
|
|
||||||
|
Si vous n'en êtes pas sûr, renommez ~/GNUstep en ~/GNUtmp et lancez wmaker.inst.
|
||||||
|
|
||||||
|
|
||||||
|
== "...: your machine is misconfigured. gethostname() returned (none)"
|
||||||
|
|
||||||
|
* Le nom d'hôte de votre machine n'est pas indiqué ou est invalide (il commence
|
||||||
|
par une parenthèse par exemple). Consultez les pages du manuel (man hostname) pour
|
||||||
|
savoir comment le positionner correctement.
|
||||||
|
|
||||||
|
|
||||||
|
== Le menu des applications ne contient que 2 entrées ("XTerm" et "Exit...")
|
||||||
|
|
||||||
|
* Window Maker ne trouve pas cpp (le preprocesseur de C). Si votre cpp n'est pas situé
|
||||||
|
dans /lib/cpp, editez src/config.h et modifiez le chemin d'accès dans CPP_PATH en conséquent.
|
||||||
|
|
||||||
|
== checking lex output file root... configure: error: cannot find output from true; giving up
|
||||||
|
|
||||||
|
* Consultez la section PRE-REQUIS dans ce même fichier.
|
||||||
|
|
||||||
|
|
||||||
|
LOCALES/INTERNATIONALISATION
|
||||||
|
============================
|
||||||
|
|
||||||
|
Window Maker supporte les langues étrangères. Pour activer cette fonctionalité,
|
||||||
|
vous devez compiler Window Maker avec des paramètres supplémentaires.
|
||||||
|
|
||||||
|
|
||||||
|
0 - GNU gettext doit être installé. Il peut être trouvé ici :
|
||||||
|
ftp://prep.ai.mit.edu/pub/gnu/gettext-nnn.tar.gz
|
||||||
|
|
||||||
|
Vous pouvez passer à l'étape 4 si vous utilisez le script Install.
|
||||||
|
|
||||||
|
1 - Il vous faut choisir les langues que vous voulez rendre disponible. Modifiez
|
||||||
|
pour cela la liste des codes de nationalité dans LINGUAS. L'anglais est inclus
|
||||||
|
de façon implicite dans cette liste. Par exemple :
|
||||||
|
|
||||||
|
setenv LINGUAS "pt ja de"
|
||||||
|
sous csh
|
||||||
|
|
||||||
|
ou
|
||||||
|
|
||||||
|
export LINGUAS;LINGUAS="pt ja de"
|
||||||
|
sous sh
|
||||||
|
|
||||||
|
La liste de tous les codes de nationalité peut être trouvée dans po/README.
|
||||||
|
L'anglais est la langue par défault.
|
||||||
|
|
||||||
|
Lisez po/README si vous souhaitez traduire ou maintenir les fichiers propres
|
||||||
|
à d'autres adaptations nationales.
|
||||||
|
|
||||||
|
2 - De plus, si votre langue utilise des caractères multi-octets, comme
|
||||||
|
le japonais ou le coréen, vous devez vous assurer que l'option MultiByteText est à YES
|
||||||
|
dans ~/GNUstep/Defaults/WMGLOBAL.
|
||||||
|
|
||||||
|
3 - Configurez, compilez et installez Window Maker normalement.
|
||||||
|
|
||||||
|
4 - Pour choisir une langue particulière à l'exécution, vous devez positionner la variable
|
||||||
|
d'environnement LANG avec la valeur correspondant au code de nationalité adéquat.
|
||||||
|
Par exemple, si vous voulez utiliser le portugais, vous devez faire :
|
||||||
|
|
||||||
|
setenv LANG pt
|
||||||
|
|
||||||
|
sous csh ou
|
||||||
|
|
||||||
|
export LANG; LANG=pt
|
||||||
|
|
||||||
|
sous Bourne sh et apparentés
|
||||||
|
|
||||||
|
Note : si la variable d'environnement LC_CTYPE est positionnée, vous devez l'ôter de
|
||||||
|
l'environnement (unset LC_CTYPE), avant d'exécuter Window Maker.
|
||||||
|
|
||||||
|
En ce qui concerne les fichiers de configuration des menus, Window Maker procède
|
||||||
|
à une recherche suivant cet ordre (pour le portugais brésilien, dans ce cas) :
|
||||||
|
|
||||||
|
menu.pt_BR
|
||||||
|
menu.pt
|
||||||
|
menu
|
||||||
|
|
||||||
|
|
||||||
|
5 - Si vous choisissez une langue qui utilise les caractères multi-octets, vous
|
||||||
|
devez configurer les polices de façon adéquate. Consultez pour cela les pages
|
||||||
|
de manuel de XCreateFontSet. Vous devez modifier dans votre fichier ~/G/D/WindowMaker
|
||||||
|
les polices utilisées dans les titres, menus et autres. En ce qui concerne les polices
|
||||||
|
utilisées dans les boîte de dialogue, modifiez ~/G/D/WMGLOBAL.
|
||||||
|
Le %d dans la définition des polices ne doit PAS être enlevé. Vous pouvez aussi utiliser
|
||||||
|
le script wsetfont, fourni à ces fins.
|
||||||
|
Consultez le script lui-même pour en connaître les instructions.
|
||||||
|
|
||||||
|
Par exemple, vous pouvez mettre ceci dans ~/G/D/WindowMaker :
|
||||||
|
|
||||||
|
WindowTitleFont = "-*-helvetica-bold-r-normal-*-12-*,-*-*-medium-r-normal-*-14-*";
|
||||||
|
MenuTitleFont = "-*-helvetica-bold-r-normal-*-12-*,-*-*-medium-r-normal-*-14-*";
|
||||||
|
MenuTextFont = "-*-helvetica-medium-r-normal-*-12-*,-*-*-medium-r-normal-*-14-*";
|
||||||
|
IconTitleFont = "-*-helvetica-medium-r-normal-*-8-*,-*-*-medium-r-normal-*-12-*";
|
||||||
|
ClipTitleFont = "-*-helvetica-bold-r-normal-*-10-*,-*-*-medium-r-normal-*-12-*";
|
||||||
|
DisplayFont = "-*-helvetica-medium-r-normal-*-12-*,-*-*-medium-r-normal-*-12-*";
|
||||||
|
|
||||||
|
et dans ~/G/D/WMGLOBAL :
|
||||||
|
|
||||||
|
SystemFont = "-*-*-medium-r-normal-*-%d-*-*-*-*-*-*-*";
|
||||||
|
BoldSystemFont = "-*-*-medium-r-normal-*-%d-*-*-*-*-*-*-*";
|
||||||
|
|
||||||
|
Les 2 polices ci-dessus sont uniquement utilisées par les applications qui utilisent
|
||||||
|
WINGs (Window Maker et WPrefs.app).
|
||||||
|
|
||||||
|
Le script wsetfont inclus vous permettra de changer les réglages des polices de
|
||||||
|
façon plus aisée. Consultez-le afin d'obtenir plus d'informations.
|
||||||
13
INSTALL.pt
13
INSTALL.pt
@@ -68,9 +68,9 @@ Para compilar o Window Maker voc
|
|||||||
- autoconf, automake and libtool
|
- autoconf, automake and libtool
|
||||||
Estes pacotes não são necessários, mas se você tiver um ou mais deles instalados,
|
Estes pacotes não são necessários, mas se você tiver um ou mais deles instalados,
|
||||||
verifique se todos eles são das seguintes versões:
|
verifique se todos eles são das seguintes versões:
|
||||||
autoconf 2.13
|
autoconf 2.54
|
||||||
automake 1.4
|
automake 1.4
|
||||||
libtool 1.3
|
libtool 1.4.2
|
||||||
Se você possui uma versão diferente, desative-os mudando os nomes dos arquivos
|
Se você possui uma versão diferente, desative-os mudando os nomes dos arquivos
|
||||||
para outra coisa ou removendo-os do seu sistema. Se você não desenvolve
|
para outra coisa ou removendo-os do seu sistema. Se você não desenvolve
|
||||||
software você não precisa deles, logo, você pode desinstalá-los com segurança.
|
software você não precisa deles, logo, você pode desinstalá-los com segurança.
|
||||||
@@ -155,15 +155,6 @@ Para obter uma lista com outras opcoes, execute ./configure --help:
|
|||||||
--disable-motif
|
--disable-motif
|
||||||
Desativa compatibilidade com gerenciador de janelas mwm.
|
Desativa compatibilidade com gerenciador de janelas mwm.
|
||||||
|
|
||||||
--enable-openlook
|
|
||||||
Ativa compatibilidade com gerenciador de janelas OPEN LOOK(tm).
|
|
||||||
|
|
||||||
--enable-gnome
|
|
||||||
Ativa compatibilidade com gerenciador de janelas GNOME.
|
|
||||||
|
|
||||||
--enable-kde
|
|
||||||
Ativa compatibilidade com gerenciador de janelas kde/kwm.
|
|
||||||
|
|
||||||
--enable-lite
|
--enable-lite
|
||||||
Remove coisas que já são suportadas em ambientes desktops como o KDE
|
Remove coisas que já são suportadas em ambientes desktops como o KDE
|
||||||
e o GNOME. As opções desativadas são: lista de janelas (window list), menu de
|
e o GNOME. As opções desativadas são: lista de janelas (window list), menu de
|
||||||
|
|||||||
601
INSTALL.sk
Normal file
601
INSTALL.sk
Normal file
@@ -0,0 +1,601 @@
|
|||||||
|
|
||||||
|
In¹trukcie pre in¹taláciu Window Makera
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
PODPOROVANÉ PLATFORMY
|
||||||
|
=====================
|
||||||
|
(tzn: vraj to na tom niekto skompiloval...)
|
||||||
|
|
||||||
|
- Intel GNU/Linux Conectiva 5.9 (beta)
|
||||||
|
- Intel GNU/Linux Slackware
|
||||||
|
- Intel GNU/Linux Debian
|
||||||
|
- Intel GNU/Linux other distributions
|
||||||
|
- Sparc GNU/Linux RedHat 5.1
|
||||||
|
- PowerPC GNU/MkLinux
|
||||||
|
- Alpha GNU/Linux RedHat 5.1
|
||||||
|
- FreeBSD
|
||||||
|
- NetBSD
|
||||||
|
- OpenBSD
|
||||||
|
- BSDI 4.0
|
||||||
|
- Solaris 2.5.1, 2.5.2
|
||||||
|
- Solaris 2.6.0
|
||||||
|
- Solaris 2.7beta
|
||||||
|
- SCO Unix
|
||||||
|
- SGI Irix 5.x, 6.5
|
||||||
|
- OSF/1
|
||||||
|
- HP-UX
|
||||||
|
- AIX 3.2.5
|
||||||
|
- AIX 4.1.4 / IBM PowerPC
|
||||||
|
- AIX 4.3.1 / IBM CC compiler
|
||||||
|
- AIX 4.3.2 / IBM PowerPC
|
||||||
|
- AIX 5.3
|
||||||
|
- DEC Alpha/Digital UNIX 4.x
|
||||||
|
- XFree86 / OS/2
|
||||||
|
- Corel NetWinder
|
||||||
|
- SunOS 4.x
|
||||||
|
- PowerMac / Power MachTen 4.1.1 over MacOS
|
||||||
|
- Amiga 3000 running RedHat Linux 5.1 (Rawhide)
|
||||||
|
- IBM S/390 running Linux
|
||||||
|
- iBook running Darwin
|
||||||
|
|
||||||
|
Patche na rozbehanie na iných platformách sú vítané.
|
||||||
|
|
||||||
|
|
||||||
|
PO®IADAVKY:
|
||||||
|
===========
|
||||||
|
|
||||||
|
Nasledovný softvér je potrebný pre beh Window Makera:
|
||||||
|
|
||||||
|
- X11R6.x
|
||||||
|
Window Maker mô¾e by» skompilovaný na star¹ích verziách X, ako
|
||||||
|
X11R5 (Solaris) alebo X11R4 (OpenWindows) ale nebude pracova»
|
||||||
|
100% korektne. Na takých serveroch nebudú ikony aplikácií a budete
|
||||||
|
ma» problémy s pou¾ívaním doku. Upgrade klientských kni¾níc (Xlib,
|
||||||
|
Xt, atï.) pomô¾e, ak u¾ nemô¾ete spravi» upgrade servera.
|
||||||
|
|
||||||
|
Nasledovné je potrebné k skompilovaniu Window Makera:
|
||||||
|
|
||||||
|
- Základné be¾né veci
|
||||||
|
Ak chcete kompilova» Window Maker, uistite sa, ¾e máte gcc (alebo
|
||||||
|
iný ANSI C kompilátor) a hlavièkové súbory iXov. Hlavne pre zaèia-
|
||||||
|
toèníkov v Linuxe: musíte nain¹talova» v¹etky X-devel balíky a gcc.
|
||||||
|
Inak nebudete schopní skompilova» ¾iadny program pre X, teda ani
|
||||||
|
Window Maker.
|
||||||
|
|
||||||
|
- libPropList
|
||||||
|
Túto kni¾nicu mo¾no nájs» na ftp://ftp.windowmaker.org/pub/libs alebo
|
||||||
|
ftp://ftp.gnome.org/pub/libPropList. Nain¹talujte ju pred kompiláciou
|
||||||
|
Window Makera.
|
||||||
|
|
||||||
|
- autoconf, automake a libtool
|
||||||
|
Tieto nástroje NIE sú potrebné, ale ak máte niektoré z nich nain¹talo-
|
||||||
|
vané, uistite sa, ¾e V©ETKY sú presne nasledovné verzie:
|
||||||
|
autoconf 2.54
|
||||||
|
automake 1.4
|
||||||
|
libtool 1.4.2
|
||||||
|
Ak máte odli¹né verzie, odin¹talujte ich alebo ich doèasne premenujte.
|
||||||
|
Ak neprogramujete, nebudete ich potrebova» a teda ich mô¾ete
|
||||||
|
odin¹talova».
|
||||||
|
|
||||||
|
- lex (alebo flex) a yacc (alebo bison)
|
||||||
|
Tieto sú vyu¾ívané z libPropList. Lex v skutoènosti nie je nutný,
|
||||||
|
lebo jeho výstupný súbor je prítomný, ale buï ja alebo automake je
|
||||||
|
hlupák, lebo configuraèný skript pre libPropList sa jednoducho
|
||||||
|
ukonèí z neznámych dôvodov ak lex nie je prítomný.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
NEPOVINNÉ:
|
||||||
|
==========
|
||||||
|
|
||||||
|
Tieto kni¾nice nie sú nutné pre beh Window Makera, ale sú podporované
|
||||||
|
v prípade, ¾e ich chcete pou¾íva». Èísla verzií sú tie, ktoré som pou¾il
|
||||||
|
ja (teda urèite fungujú), ale aj iné verzie mô¾u pracova» správne.
|
||||||
|
|
||||||
|
|
||||||
|
- libXPM 4.7 alebo nov¹ia
|
||||||
|
Star¹ie verzie nemusia fungova»!!!
|
||||||
|
Dostupné na ftp://sunsite.unc.edu/pub/Linux/libs/X/
|
||||||
|
|
||||||
|
Podpora XPM je aj vstavaná, ale nenaèíta obrázky v
|
||||||
|
ne¹tandardných kódovaniach.
|
||||||
|
|
||||||
|
- libpng 0.96 alebo nov¹ia a zlib
|
||||||
|
Pre podporu obrázkov PNG.
|
||||||
|
http://www.cdrom.com/pub/png/
|
||||||
|
|
||||||
|
- libtiff 3.4 alebo nov¹ia
|
||||||
|
Pre podporu obrázkov TIFF.
|
||||||
|
ftp://ftp.sgi.com/graphics/tiff
|
||||||
|
|
||||||
|
- libjpeg 6.0.1 alebo nov¹ia
|
||||||
|
Pre podporu obrázkov JPEG.
|
||||||
|
http://www.ijg.org/
|
||||||
|
|
||||||
|
- libgif 2.2 alebo libungif
|
||||||
|
Pre podporu obrázkov GIF.
|
||||||
|
ftp://prtr-13.ucsc.edu/pub/libungif/
|
||||||
|
|
||||||
|
- GNU xgettext
|
||||||
|
Ak chcete pou¾íva» prelo¾ené hlásenia, potrebujete GNU gettext.
|
||||||
|
Iné verzie gettext nie sú kompatibilné a nebudú fungova».
|
||||||
|
Stiahnite si GNU verziu z ftp://ftp.gnu.org
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
MO®NOSTI CONFIGURE:
|
||||||
|
===================
|
||||||
|
|
||||||
|
Tieto mo¾nosti mô¾u by» dané skriptu configure ako argumenty za úèelom
|
||||||
|
povolenia/zakázania urèitých vlastností Window Makera. Príklad:
|
||||||
|
|
||||||
|
./configure --enable-kde --enable-gnome
|
||||||
|
|
||||||
|
nakonfiguruje Window Maker s podporou KDE a GNOME.
|
||||||
|
|
||||||
|
|
||||||
|
Zoznam v¹etkých mo¾ností vypí¹e príkaz ./configure --help
|
||||||
|
|
||||||
|
--with-libs-from
|
||||||
|
cesty, kde sa majú hµada» kni¾nice. Re»azec -L musí predchádza»
|
||||||
|
ka¾dú cestu, napr.:
|
||||||
|
--with-libs-from="-L/opt/libs -L/usr/local/lib"
|
||||||
|
|
||||||
|
--with-incs-from
|
||||||
|
cesty, kde sa majú hµada» hlavièkové súbory. Re»azec -I musí
|
||||||
|
predchádza» ka¾dú cestu, napr.:
|
||||||
|
--with-incs-from="-I/opt/headers -I/usr/local/include"
|
||||||
|
|
||||||
|
--enable-single-icon
|
||||||
|
umo¾òuje zrolovanie v¹etký ikon aplikácií WM_CLASS+WM_INSTANCE do
|
||||||
|
jedinej. Táto vlastnos» nie je podporovaná zo strany vývojárov.
|
||||||
|
V prípade problémov s òou, kontaktujte autora:
|
||||||
|
Christopher Seawood <cls@seawood.org>
|
||||||
|
|
||||||
|
--disable-shm
|
||||||
|
zaká¾e pou¾itie roz¹írenia zdieµanej pamäte MIT. Toto trochu spomalí
|
||||||
|
generovanie textúr, ale v niektorých prípadoch je táto voµba potrebná
|
||||||
|
kvôli chybe, ktorá spôsobuje nesprávne zobrazovanie ikon a textúr.
|
||||||
|
|
||||||
|
--disable-motif
|
||||||
|
zaká¾e podporu pre pokyny mana¾éra okien wmw
|
||||||
|
|
||||||
|
--enable-lite
|
||||||
|
odstráni veci, ktoré sa u¾ nachádzajú v desktopových prostrediach
|
||||||
|
ako KDE a GNOME. Odstránené veci sú: zoznam okien, menu aplikácií,
|
||||||
|
výber viacerých okien. Vedzte, ¾e u¾ nebudete schopní ukonèi»
|
||||||
|
Window Maker; budete ho musie» zabi» pou¾itím signálu SIGTERM alebo
|
||||||
|
ho ukonèi» z KDE. Neodporúèa sa povoli» túto vlastnos».
|
||||||
|
|
||||||
|
--enable-modelock
|
||||||
|
podpora pre XKB nastavenie jazyka. Ak neviete, èo to je, pravdepo-
|
||||||
|
dobne to nepotrebujete. (Slú¾i to na prepínanie rozlo¾enia kláves
|
||||||
|
pomocou nového tlaèidla na hornom paneli okien.)
|
||||||
|
|
||||||
|
--enable-sound
|
||||||
|
povolí podporu pre modul zvukových efektov
|
||||||
|
|
||||||
|
--disable-xpm
|
||||||
|
zaká¾e podporu pre kni¾nicu XPM aj keï je dostupná na va¹om systéme.
|
||||||
|
|
||||||
|
--disable-png
|
||||||
|
zaká¾e pou¾itie kni¾nice PNG
|
||||||
|
|
||||||
|
--disable-tiff
|
||||||
|
zaká¾e pou¾itie kni¾nice TIFF
|
||||||
|
|
||||||
|
--disable-gif
|
||||||
|
zaká¾e pou¾itie kni¾nice GIF
|
||||||
|
|
||||||
|
--disable-jpeg
|
||||||
|
zaká¾e pou¾itie kni¾nice JPEG
|
||||||
|
|
||||||
|
--disable-shape
|
||||||
|
zaká¾e tvarované okná (pre oclock, xeyes atï.)
|
||||||
|
|
||||||
|
|
||||||
|
POZNÁMKY PRE ©PECIFICKÉ PLATFORMY:
|
||||||
|
==================================
|
||||||
|
|
||||||
|
- DEC/Alpha
|
||||||
|
|
||||||
|
Nasledovný mail nie je prelo¾ený, ale hovorí sa v òom, ¾e
|
||||||
|
_pravdepodobne_ nie je nutné konfigurova» Window Maker na
|
||||||
|
Alphe s voµbou --disable-shm.
|
||||||
|
|
||||||
|
#>>>>>>>>>>>
|
||||||
|
From: Anton Ivanov <aivanov@eu.level3.net>
|
||||||
|
To: Marcelo E. Magallon <mmagallo@debian.org>
|
||||||
|
Subject: Re: Is the WindowMaker package working ok on Alpha?
|
||||||
|
|
||||||
|
> Hi,
|
||||||
|
>
|
||||||
|
> I was reading some docs on the WindowMaker tarball, and found this:
|
||||||
|
>
|
||||||
|
> | - DEC/Alpha machines
|
||||||
|
> | You might need to pass the --disable-shm flag to configure,
|
||||||
|
> | like ./configure --disable-shm
|
||||||
|
>
|
||||||
|
> is anyone having problems with WindowMaker on Alpha? Can someone
|
||||||
|
> please test this? Should the flag be passed when building on Alpha?
|
||||||
|
|
||||||
|
Disclaimer: alphas under my command have never run X and are least likely to
|
||||||
|
suddenly start running it anytime soon.
|
||||||
|
|
||||||
|
Alpha used to have some ridiculously low amount of shared memory
|
||||||
|
configured.
|
||||||
|
So quite a lot of apps used to barf. Namely - cdrecord, mysql server, etc.
|
||||||
|
|
||||||
|
Check where is yours at the moment and raise it to a more appropriate
|
||||||
|
value by either catting to the appropriate /proc entry or changing the
|
||||||
|
/usr/src/linux/include/asm/shmparam.h.
|
||||||
|
|
||||||
|
Otherwise the shared memory on alpha should be fully functional and I
|
||||||
|
see no reason to disable it. Mine are bumped up to 32 or more on most
|
||||||
|
machines.
|
||||||
|
|
||||||
|
And If I recall correctly the comments in that file are actually
|
||||||
|
wrong. Value is not bytes, but in machine size word. For alpha *8.
|
||||||
|
|
||||||
|
As I said - I do not run X on them so all #include "stdisclaimer.h"
|
||||||
|
apply.
|
||||||
|
#<<<<<<<<<<<<
|
||||||
|
|
||||||
|
|
||||||
|
- SCO Unix - spustite configure takto
|
||||||
|
CFLAGS="-belf -DANSICPP" ./configure
|
||||||
|
|
||||||
|
- SunOS, Solaris
|
||||||
|
Ak máte nain¹alované gcc, spustite configure takto:
|
||||||
|
CPP_PATH="gcc -E -x c" ./configure
|
||||||
|
Cpp od Sunu chýbajú niektoré vlastnosti, ktoré Window Maker potrebuje,
|
||||||
|
a to mô¾e spôsobi» problémy pri parsovaní konfiguraèných súborov.
|
||||||
|
Je tie¾ mo¾né, ¾e budete musie» pou¾i» --with-libs-from a
|
||||||
|
--with-incs-from na urèenie ciest k libtiff.
|
||||||
|
Niekto mi mailoval, ¾e tie¾ /usr/local/lib musí by» prvá cesta v
|
||||||
|
premennej LD_LIBRARY_PATH, aby to fungovalo.
|
||||||
|
Ak máte Ultra Creator 3D alebo iný stroj s high-end grafikou,
|
||||||
|
uistite sa, ¾e spú¹»ate iXy s 24-bitovou farebnou håbkou alebo
|
||||||
|
mô¾ete ma» problémy s pomie¹anými farbami. Toto je chyba wmakera
|
||||||
|
a bude opravená.
|
||||||
|
|
||||||
|
- GNU/Linux vo v¹eobecnosti
|
||||||
|
Uistite sa, ¾e máte /usr/local/lib v /etc/ld.so.conf a ¾e ste
|
||||||
|
po in¹talácii spustili ldconfig.
|
||||||
|
Odin¹talujte v¹etky balíkované verzie Window Makera pred in¹talovaním
|
||||||
|
novej verzie.
|
||||||
|
|
||||||
|
- RedHat GNU/Linux
|
||||||
|
Systémy RedHat majú niekoµko nepríjemných problémov. Ak ich pou¾ívate,
|
||||||
|
dodr¾ujte nasledovné kroky, alebo vám Window Maker nebude fungova»:
|
||||||
|
|
||||||
|
* ak máte nain¹alovaný Window Maker, ktorý je dodaný s RedHatom,
|
||||||
|
pred upgadom ho odin¹talujte;
|
||||||
|
|
||||||
|
* uistite sa, ¾e nemáte premenné LANG a LINGUAS nastavené na en_RN;
|
||||||
|
|
||||||
|
* uistite sa, ¾e máte /usr/local/bin v premennej PATH;
|
||||||
|
|
||||||
|
* uistite sa, ¾e máte /usr/local/lib v /etc/ld.so.conf pred
|
||||||
|
spustením ldconfig;
|
||||||
|
|
||||||
|
* ak máte problémy, v ktorých sa spomína chyba s --no-reexec,
|
||||||
|
odin¹talujte libtool-1.2b a nain¹talujte libtool-1.3. libtool-1.3
|
||||||
|
nájdete na ftp.gnu.org. Tie¾ si preèítajte èas» RIE©ENIE PROBLÉMOV.
|
||||||
|
|
||||||
|
|
||||||
|
* uistite sa, ¾e máte symbolický odkaz z /usr/include/X11 na
|
||||||
|
/usr/X11R6/include/X11 (ak nie, zadajte ln -s /usr/X11R6/include/X11
|
||||||
|
/usr/include/X11 )
|
||||||
|
|
||||||
|
* uistite sa, ¾e /lib/cpp odkazuje na program cpp
|
||||||
|
|
||||||
|
Ak máte akékoµvek pochybnosti, prosím, neotáµajte a spojte sa
|
||||||
|
s u¾ívateµskou podporou RedHatu. Radi vám odpovedia na v¹etky
|
||||||
|
va¹e otázky týkajúce sa ich systému. Vedia toho o svojom
|
||||||
|
systéme viac ako my (nepou¾ívame RedHat).
|
||||||
|
|
||||||
|
|
||||||
|
- PowerPC MkLinux
|
||||||
|
Musíte ma» poslednú verziu Xpmac. Star¹ie verzie majú asi chyby,
|
||||||
|
ktoré spôsobujú zmrznutie celého systému.
|
||||||
|
|
||||||
|
- Debian GNU/Linux
|
||||||
|
Ak chcete podporu JPEG a TIFF, uistite sa, ¾e máte nain¹talované
|
||||||
|
libiff-dev a libjpeg-dev.
|
||||||
|
|
||||||
|
- SuSE GNU/Linux
|
||||||
|
Ak ste si nain¹talovali balík Window Makera od SuSE, odin¹talujte
|
||||||
|
ho pred pokusmi o skompilovanie wmakera, alebo mô¾ete ma» problémy.
|
||||||
|
|
||||||
|
- MetroX (neznáma verzia)
|
||||||
|
MetroX má chybu, ktorá kazí obrázky, ktoré sú nastavené ako pozadie
|
||||||
|
okien. Ak pou¾ívate MetroX a máte èudné problémy s textúrami,
|
||||||
|
nepou¾ívajte textúry v horných li¹tách. Alebo pou¾ite iný X server.
|
||||||
|
|
||||||
|
|
||||||
|
IN©TALÁCIA:
|
||||||
|
===========
|
||||||
|
|
||||||
|
Kompilácia Window Makera
|
||||||
|
------------------------
|
||||||
|
Pre rýchly ¹tart, zadajte nasledovné príkazy v shelly:
|
||||||
|
|
||||||
|
./configure
|
||||||
|
make
|
||||||
|
|
||||||
|
potom sa prihláste ako root a zadajte:
|
||||||
|
|
||||||
|
make install
|
||||||
|
ldconfig
|
||||||
|
|
||||||
|
alebo ak chcete z binárnych súborov odstráni» symboly pre debugger a urobi»
|
||||||
|
ich men¹ie, napí¹te miesto toho
|
||||||
|
|
||||||
|
make install-strip
|
||||||
|
ldconfig
|
||||||
|
|
||||||
|
Toto skompiluje a nain¹taluje Window Maker so ¹tandardnými parametrami.
|
||||||
|
|
||||||
|
Ak si chcete prispôsobi» nastavenia kompilácie, mo¾ete to urobi» nasledovne:
|
||||||
|
|
||||||
|
1. (voliteµne) Pozrite sa na èas» MO®NOSTI CONFIGURE, kde sú
|
||||||
|
uvedené mo¾nosti. Tie¾ spustite:
|
||||||
|
|
||||||
|
./configure --help
|
||||||
|
|
||||||
|
ktorý vám vypí¹e kompletný zoznam ostatných mo¾ných nastavení.
|
||||||
|
|
||||||
|
2. Spustite configure s nastaveniami, ktoré chcete. Napríklad,
|
||||||
|
ak chcete pou¾íva» podporu pre KDE, zadajte:
|
||||||
|
|
||||||
|
./configure --enable-kde
|
||||||
|
|
||||||
|
3. (voliteµne) Otvorte si súbor src/wconfig.h vo svojom obµúbenom
|
||||||
|
textovom editore a prejdite si ho, èi nenájdete nejaké nastavenia,
|
||||||
|
ktoré chcete zmeni».
|
||||||
|
|
||||||
|
4. Kompilácia. Zadajte len:
|
||||||
|
|
||||||
|
make
|
||||||
|
|
||||||
|
5. Prihláste sa ako root (ak to nie je mo¾né, èítajte èas» "Nemám
|
||||||
|
rootove heslo :-( ") a nain¹talujte Window Maker:
|
||||||
|
|
||||||
|
su root
|
||||||
|
make install
|
||||||
|
|
||||||
|
|
||||||
|
Nastavenia ¹pecifické pre u¾ívateµov
|
||||||
|
------------------------------------
|
||||||
|
|
||||||
|
Nemusíte sa dr¾a» týchto in¹trukcií, ak robíte upgrade Window Makera zo
|
||||||
|
star¹ej verzie, pokiaµ to nie je uvedené v súbore NEWS.
|
||||||
|
|
||||||
|
Ka¾dý u¾ívateµ na va¹om systéme, ktorý chce pou¾íva» Window Maker, musí
|
||||||
|
urobi» nasledovné:
|
||||||
|
|
||||||
|
1. Nain¹talova» konfiguraèné súbory Window Makera do svojho
|
||||||
|
domovského adresára:
|
||||||
|
|
||||||
|
wmaker.inst
|
||||||
|
|
||||||
|
wmaker.inst nain¹taluje konfiguraèné súbory Window Makera a nastaví
|
||||||
|
iXy aby sa pri ¹tarte automaticky spustil Window Maker.
|
||||||
|
|
||||||
|
To je v¹etko!
|
||||||
|
|
||||||
|
Základné informácie o konfigurácii a iných veciach vám poskytne
|
||||||
|
"man wmaker".
|
||||||
|
|
||||||
|
Pre hlb¹í úvod do Window Makera si preèítajte si U¾ívateµký manuál.
|
||||||
|
|
||||||
|
Tie¾ sa mô¾te pozrie» na FAQ.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Installing the extras package
|
||||||
|
-----------------------------
|
||||||
|
|
||||||
|
Unpack WindowMaker-extra-<version-number>.tar.gz in /usr/local/share
|
||||||
|
|
||||||
|
You can get the file at ftp://ftp.windowmaker.org. This file is optional
|
||||||
|
and only have a few icons, and themes. Look for the latest <version-number>
|
||||||
|
available.
|
||||||
|
Also there is a WindowMaker-extra.readme to instruct you where that package
|
||||||
|
should go.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
Nemám rootove heslo :(
|
||||||
|
----------------------
|
||||||
|
|
||||||
|
Ak nemáte práva roota, mô¾ete si nain¹talova» Window Maker do svojho
|
||||||
|
domovského adresára. Na to musíte pou¾i» voµbu --prefix pre configure
|
||||||
|
v druhom kroku kompilácie Window Makera. Tie¾ musíte pou¾i» voµbu
|
||||||
|
--with-appspath, pomocou ktorej ¹pecifikujete cestu pre WPrefs.app.
|
||||||
|
Príklad:
|
||||||
|
|
||||||
|
./configure --prefix=/home/jshome --with-appspath=/home/jshome/GNUstep/Apps
|
||||||
|
|
||||||
|
Poto pridajte adresár /home/jshome/bin do premennej PATH, /home/jshome/lib
|
||||||
|
do premennej LD_LIBRARY_PATH a spustite bin/wmaker.inst
|
||||||
|
|
||||||
|
Samozrejme, predpokladá sa, ¾e /home/jshome nahradíte va¹im skutoèným
|
||||||
|
domovským adresárom.
|
||||||
|
|
||||||
|
|
||||||
|
UPGRADE
|
||||||
|
=======
|
||||||
|
|
||||||
|
Ak robíte upgrade zo star¹ej verzie Window Makera:
|
||||||
|
|
||||||
|
1. Skofigurujte a skompilujte Window Maker ako v¾dy
|
||||||
|
2. Nain¹talujte Window Maker (ale nespustite wmaker.inst)
|
||||||
|
3. Preèítajte si súbor NEWS a ak je to potrebné, upravte
|
||||||
|
svoje konfiguraèné súbory.
|
||||||
|
|
||||||
|
|
||||||
|
RIE©ENIA PROBLÉMOV
|
||||||
|
==================
|
||||||
|
|
||||||
|
Ak máte problémy poèas konfigurácie (spú¹»ania configure), napríklad
|
||||||
|
nemo¾nos» pou¾i» grafickú kni¾nicu, o ktorej viete, ¾e ju máte nain¹talovanú,
|
||||||
|
v súbore config.log nájdete príèinu problému.
|
||||||
|
|
||||||
|
== Error with loading fonts, even if they exist.
|
||||||
|
|
||||||
|
Skúste kompiláciu bez podpory NLS.
|
||||||
|
|
||||||
|
== Error when configuring
|
||||||
|
|
||||||
|
ltconfig: unrecognized option `--no-reexec'
|
||||||
|
Try `ltconfig --help' for more information.
|
||||||
|
configure: error: libtool configure failed
|
||||||
|
|
||||||
|
Odstáòte voµbu --no-reexec zo súborov aclocal.m4 a libPropList/aclocal.m4
|
||||||
|
a spustite configure.
|
||||||
|
Tie¾ sa uistite, ¾e autoconf a automake, ktoré máte nain¹talované, sú v
|
||||||
|
týchto verziách:
|
||||||
|
autoconf 2.13
|
||||||
|
automake 1.4
|
||||||
|
libtool 1.3
|
||||||
|
|
||||||
|
Nesmie to by» libtool 1.2b, ale libtool 1.3, zo stránok GNU.
|
||||||
|
|
||||||
|
== Cant find proplist.h or libPropList.something
|
||||||
|
|
||||||
|
Stiahnite a nain¹talujte si libPropList zo stránok uvedených
|
||||||
|
niekde v tomto súbore.
|
||||||
|
|
||||||
|
|
||||||
|
== configure doesn't detect libtiff, or other graphic libraries.
|
||||||
|
|
||||||
|
Odstráòte config.cache, spustite configure s pridanými nasledovnými voµbami
|
||||||
|
(okrem iných, ktoré pou¾ívate):
|
||||||
|
--with-libs-from="-L/usr/local/lib"
|
||||||
|
--with-incs-from="-I/usr/local/include -I/usr/local/include/tiff"
|
||||||
|
Vlo¾te cesty k va¹im grafickým kni¾niciam a zodpovedajúcim hlavièkovým
|
||||||
|
súborom. Mô¾ete vlo¾i» viac ciest do ka¾dej z týchto volieb, ako je to
|
||||||
|
uvedené v príklade --with-incs-from. Len ich oddeµte medzerou.
|
||||||
|
|
||||||
|
|
||||||
|
== configure doesn't detect libXpm.
|
||||||
|
|
||||||
|
* Skontrolujte, èi máte symbolický odkaz z libXpm.so.4.9 na libXpm.so
|
||||||
|
|
||||||
|
|
||||||
|
== Segmentation fault on startup
|
||||||
|
|
||||||
|
* Skontrolujte verziu libXpm, musíte ma» aspoò 4.7
|
||||||
|
|
||||||
|
* Skontrolujte, èi máte upravenú verziu ~/GNUstep/Defaults/WindowMaker
|
||||||
|
|
||||||
|
Ak si nie ste istí, skúste premenova» ~/GNUstep na ~/GNUtmp a spustite
|
||||||
|
wmaker.inst
|
||||||
|
|
||||||
|
|
||||||
|
== "...: your machine is misconfigured. gethostname() returned (none)"
|
||||||
|
|
||||||
|
* Meno va¹eho poèítaèa je nastavené na nieèo nesprávne, èo zaèína
|
||||||
|
úvodzovkami. Preèítajte si man hostname a dozviete sa, ako to nastavi».
|
||||||
|
|
||||||
|
|
||||||
|
== The root menu contains only 2 entries. ("XTerm" and "Exit...")
|
||||||
|
|
||||||
|
* Window Maker nevie nájs» cpp (C preprocesor). Ak sa vá¹ cpp nenachádza
|
||||||
|
v /lib/cpp, upravte src/config.h a vlo¾te správnu cestu do CPP_PATH.
|
||||||
|
|
||||||
|
|
||||||
|
== checking lex output file root... configure: error: cannot find output from true; giving up
|
||||||
|
|
||||||
|
* Preèítajte si èas» PO®IADAVKY v tomto súbore.
|
||||||
|
|
||||||
|
|
||||||
|
MIESTNE NASTAVENIA/INTERNACIONALIZÁCIA
|
||||||
|
======================================
|
||||||
|
|
||||||
|
Window Maker má podporu pre národné jazyky. Aby ste ju povolili, musíte
|
||||||
|
skompilova» Window Maker s niekoµkými prídavnými parametrami.
|
||||||
|
|
||||||
|
|
||||||
|
0 - Musíte ma» nain¹talovaný balík GNU gettext. Mô¾ete ho nájs» na
|
||||||
|
adrese ftp://prep.ai.mit.edu/pub/gnu/gettext-nnn.tar.gz
|
||||||
|
|
||||||
|
Kroky 1 a¾ 3 mô¾ete vynecha», ak pou¾ívate skript Install
|
||||||
|
|
||||||
|
1 - Musíte urèi» jazyky, pre ktoré chcete podporu. Nastavte premennú
|
||||||
|
LINGUAS na zoznam miestnych nastavení, ktoré chcete. Angliètina je
|
||||||
|
podporovaná v¾dy. Príklad:
|
||||||
|
|
||||||
|
setenv LINGUAS "pt ja de"
|
||||||
|
(csh)
|
||||||
|
|
||||||
|
alebo
|
||||||
|
|
||||||
|
export LINGUAS;LINGUAS="pt ja de"
|
||||||
|
(sh)
|
||||||
|
|
||||||
|
Zoznam podporovaných miestnych nastavení nájdete v súbore po/README.
|
||||||
|
Angliètina je implicitným jazykom.
|
||||||
|
|
||||||
|
Ak chcete preklada» a udr¾iava» súbory s miestnymi nastaveniami, preèítajte
|
||||||
|
si súbor po/README.
|
||||||
|
|
||||||
|
2 - Naviac, ak vá¹ jazyk pou¾íva multi-byte znaky, napríklad Japonèina
|
||||||
|
alebo Kórejèina, musíte nastaveniu MultiByteText priradi» YES v súbore
|
||||||
|
~/GNUstep/Defaults/WMGLOBAL
|
||||||
|
|
||||||
|
3 - Konfigurujte, kompilujte a in¹talujte Window Maker ako zvyèajne.
|
||||||
|
|
||||||
|
4 - Urèité miesne nastavenia si zvolíte nastavením premennej LANG na
|
||||||
|
to, ktoré chcete. Napríklad, ak chcete nastavi» slovenské miestne
|
||||||
|
nastavenia, musíte spusti»
|
||||||
|
|
||||||
|
setenv LANG pt
|
||||||
|
|
||||||
|
(csh)
|
||||||
|
|
||||||
|
export LANG; LANG=pt
|
||||||
|
|
||||||
|
(Bourne sh a podobné)
|
||||||
|
|
||||||
|
Pozor: Ak máte nastavenú premennú LC_CTYPE, musíte ju zru¹i» pred
|
||||||
|
spustením wmaker.
|
||||||
|
|
||||||
|
Window Maker hµadá súbory s definíciou menu v nasledovnom poradí
|
||||||
|
(v tomto prípade pre brazílsku portugalèinu):
|
||||||
|
|
||||||
|
menu.pt_BR
|
||||||
|
menu.pt
|
||||||
|
menu
|
||||||
|
|
||||||
|
|
||||||
|
5 - Ak si zvolíte jazyk, ktorý pou¾íva multi-byte znaky, musíte poriadne
|
||||||
|
nastavi» svoje fonty. Preèítajte si manuálovú stránku k XCreateFontSet,
|
||||||
|
kde nájdete viac detailov. Musíte v súbore ~/G/D/WindowMaker upravi» fonty
|
||||||
|
pre horné li¹ty, menu a iné veci. Pre fonty pou¾ité v dialógových oknách
|
||||||
|
upravte súbor ~/G/D/WMGLOBAL. Re»azce %d v menách fontov nesmú by»
|
||||||
|
odstránené. Tie¾ mô¾ete pou¾i» skript wsetfont, ktorý to urobí za vás.
|
||||||
|
|
||||||
|
Napríklad mô¾e zada» v súbore ~/G/D/WindowMaker nasledovné:
|
||||||
|
|
||||||
|
WindowTitleFont = "-*-helvetica-bold-r-normal-*-12-*,-*-*-medium-r-normal-*-14-*";
|
||||||
|
MenuTitleFont = "-*-helvetica-bold-r-normal-*-12-*,-*-*-medium-r-normal-*-14-*";
|
||||||
|
MenuTextFont = "-*-helvetica-medium-r-normal-*-12-*,-*-*-medium-r-normal-*-14-*";
|
||||||
|
IconTitleFont = "-*-helvetica-medium-r-normal-*-8-*,-*-*-medium-r-normal-*-12-*";
|
||||||
|
ClipTitleFont = "-*-helvetica-bold-r-normal-*-10-*,-*-*-medium-r-normal-*-12-*";
|
||||||
|
DisplayFont = "-*-helvetica-medium-r-normal-*-12-*,-*-*-medium-r-normal-*-12-*";
|
||||||
|
|
||||||
|
a v ~/G/D/WMGLOBAL:
|
||||||
|
|
||||||
|
SystemFont = "-*-*-medium-r-normal-*-%d-*-*-*-*-*-*-*";
|
||||||
|
BoldSystemFont = "-*-*-medium-r-normal-*-%d-*-*-*-*-*-*-*";
|
||||||
|
|
||||||
|
Tieto dva fonty sa pou¾ijú len v aplikáciách, ktoré pou¾ívajú WINGs
|
||||||
|
(Window Maker a WPrefs.app)
|
||||||
|
|
||||||
|
Skript wsetfont vám umo¾ní nastavi» fonty jednoduch¹ím spôsobom. Pozrite
|
||||||
|
sa priamo do jeho súboru pre bli¾¹ie informácie.
|
||||||
|
|
||||||
270
Install
270
Install
@@ -1,270 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
#
|
|
||||||
# WindowMaker configuration and compilation script.
|
|
||||||
#
|
|
||||||
# Copyright (c) 1997, 1998, 1999 Alfredo K. Kojima
|
|
||||||
#
|
|
||||||
|
|
||||||
export LINGUAS;LINGUAS=""
|
|
||||||
if test "$NLSDIR" = ""; then
|
|
||||||
export NLSDIR;NLSDIR="/usr/lib/locale"
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
OPTIONS=""
|
|
||||||
PREFIX="/usr/local"
|
|
||||||
|
|
||||||
perai() {
|
|
||||||
echo "Type <Return> to continue"
|
|
||||||
read nada
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
perform() {
|
|
||||||
if ! $* ; then
|
|
||||||
echo
|
|
||||||
echo "Window Maker installation failed or aborted by user."
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
trap "echo Window Maker installation aborted. ; exit 1" 2 3
|
|
||||||
|
|
||||||
echo
|
|
||||||
echo "========================="
|
|
||||||
echo "Window Maker Installation"
|
|
||||||
echo "========================="
|
|
||||||
echo
|
|
||||||
echo "NOTE: If this script fails, read the INSTALL file and"
|
|
||||||
echo "install by hand."
|
|
||||||
echo
|
|
||||||
echo "Please read the README, INSTALL and FAQ files before e-mailing "
|
|
||||||
echo "questions. We will IGNORE any questions that are already"
|
|
||||||
echo "answered in the documentation."
|
|
||||||
echo
|
|
||||||
perai
|
|
||||||
echo
|
|
||||||
echo "Did you install libPropList? If not, please install it now."
|
|
||||||
echo
|
|
||||||
perai
|
|
||||||
echo "Did you read the INSTALL file?"
|
|
||||||
echo -n "<y/n> "
|
|
||||||
read rtfm
|
|
||||||
if [ "$rtfm" != y ]; then
|
|
||||||
echo "Please read the INSTALL file before installing"
|
|
||||||
exit
|
|
||||||
fi
|
|
||||||
echo "Are you sure?"
|
|
||||||
echo -n "<y/n> "
|
|
||||||
read rtfm
|
|
||||||
if [ "$rtfm" != y ]; then
|
|
||||||
echo "Please read the INSTALL file before installing"
|
|
||||||
exit
|
|
||||||
fi
|
|
||||||
echo "Are you lying?"
|
|
||||||
echo -n "<y/n> "
|
|
||||||
read rtfm
|
|
||||||
if [ "$rtfm" != n ]; then
|
|
||||||
echo "What a shame!"
|
|
||||||
echo "Please read the INSTALL file before installing"
|
|
||||||
exit
|
|
||||||
fi
|
|
||||||
echo "Do you *swear* that you really read the INSTALL file?"
|
|
||||||
echo -n "<y/n> "
|
|
||||||
read rtfm
|
|
||||||
if [ "$rtfm" != y ]; then
|
|
||||||
echo "Please read the INSTALL file before installing"
|
|
||||||
exit
|
|
||||||
fi
|
|
||||||
echo "Last chance. You will not get help if you have some problem"
|
|
||||||
echo "because you didn't read that file. Even if your computer explodes."
|
|
||||||
echo "Do you *really* read it?"
|
|
||||||
echo -n "<y/n> "
|
|
||||||
read rtfm
|
|
||||||
if [ "$rtfm" != y ]; then
|
|
||||||
echo "Please read the INSTALL file before installing"
|
|
||||||
exit
|
|
||||||
fi
|
|
||||||
echo
|
|
||||||
echo "Ok, you have been warned."
|
|
||||||
echo
|
|
||||||
perai
|
|
||||||
|
|
||||||
|
|
||||||
if test "$USER" != "root"; then
|
|
||||||
echo
|
|
||||||
echo "Warning: you must run this script as root to install"
|
|
||||||
echo "Window Maker. Hit <Control>-<C> to quit this script."
|
|
||||||
perai
|
|
||||||
echo
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
echo
|
|
||||||
echo "Option Selection"
|
|
||||||
echo "================"
|
|
||||||
|
|
||||||
######################## KDE
|
|
||||||
echo
|
|
||||||
echo "Do you want KDE support?"
|
|
||||||
echo -n "<y/n> [n] "
|
|
||||||
read kde
|
|
||||||
if [ "$kde" = y -o "$kde" = Y ]; then
|
|
||||||
OPTIONS="$OPTIONS --enable-kde"
|
|
||||||
fi
|
|
||||||
|
|
||||||
######################## GNOME
|
|
||||||
echo
|
|
||||||
echo "Do you want GNOME support?"
|
|
||||||
echo -n "<y/n> [n] "
|
|
||||||
read gnome
|
|
||||||
if [ "$gnome" = y -o "$gnome" = Y ]; then
|
|
||||||
OPTIONS="$OPTIONS --enable-gnome"
|
|
||||||
fi
|
|
||||||
|
|
||||||
######################## OLWM
|
|
||||||
echo
|
|
||||||
echo "Do you want OPEN LOOK(tm)/olwm support?"
|
|
||||||
echo -n "<y/n> [n] "
|
|
||||||
read olwm
|
|
||||||
if [ "$olwm" = y -o "$olwm" = Y ]; then
|
|
||||||
OPTIONS="$OPTIONS --enable-openlook"
|
|
||||||
fi
|
|
||||||
|
|
||||||
######################## NLS
|
|
||||||
echo
|
|
||||||
echo "Do you want National Language Support?"
|
|
||||||
echo -n "<y/n> [n] "
|
|
||||||
read NLS
|
|
||||||
|
|
||||||
if [ "$NLS" = "y" -o "$NLS" = "Y" ]; then
|
|
||||||
NLS="Y"
|
|
||||||
echo "The supported locales are:"
|
|
||||||
ling=` (cd po; /bin/ls *.po) `
|
|
||||||
ALL_LINGUAS=""
|
|
||||||
for l in $ling; do
|
|
||||||
lname=`(cd po; grep Language-Team $l|cut -f 2 -d: |cut -f 2 -d\ )`
|
|
||||||
lname=`echo $lname`
|
|
||||||
lcode=`basename $l .po`
|
|
||||||
ALL_LINGUAS="$ALL_LINGUAS $lcode"
|
|
||||||
echo "$lcode $lname"
|
|
||||||
done
|
|
||||||
echo "Type in the locales you want (all will install everything) [none]"
|
|
||||||
read foo
|
|
||||||
if test "$foo" = "all"; then
|
|
||||||
LINGUAS="$ALL_LINGUAS"
|
|
||||||
else
|
|
||||||
LINGUAS="$foo"
|
|
||||||
fi
|
|
||||||
echo "Selected locales are: $LINGUAS"
|
|
||||||
|
|
||||||
MB=""
|
|
||||||
for i in $LINGUAS; do
|
|
||||||
ok=0
|
|
||||||
for b in $ALL_LINGUAS; do
|
|
||||||
if test "$b" = "$i"; then
|
|
||||||
ok=1
|
|
||||||
break
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
if test "$ok" = "0"; then
|
|
||||||
echo
|
|
||||||
echo "$i is not a supported locale"
|
|
||||||
perai
|
|
||||||
continue
|
|
||||||
fi
|
|
||||||
|
|
||||||
done
|
|
||||||
echo
|
|
||||||
echo "Where do you want to put the message files? [$NLSDIR]"
|
|
||||||
echo -n "? "
|
|
||||||
read foo
|
|
||||||
if test "x$foo" != "x"; then
|
|
||||||
NLSDIR=$foo
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
##################### Installation path
|
|
||||||
|
|
||||||
done=0
|
|
||||||
while [ $done = 0 ]; do
|
|
||||||
echo
|
|
||||||
echo "Where do you want to install Window Maker? [$PREFIX]"
|
|
||||||
echo "Don't change it if you don't know what you're doing."
|
|
||||||
if test "$USER" != "root"; then
|
|
||||||
echo "Make sure to specify a path where you have write permission."
|
|
||||||
fi
|
|
||||||
echo "(The default will put Window Maker in $PREFIX/bin, $PREFIX/lib etc.)"
|
|
||||||
echo -n "? "
|
|
||||||
read foo
|
|
||||||
if test "x$foo" != "x"; then
|
|
||||||
if [ "$foo" = "y" -o "$foo" = "n" ]; then
|
|
||||||
echo
|
|
||||||
echo "Hmm... I don't think you really want to install Window Maker into \"$foo\""
|
|
||||||
echo
|
|
||||||
else
|
|
||||||
done=1
|
|
||||||
PREFIX=$foo
|
|
||||||
fi
|
|
||||||
else
|
|
||||||
done=1
|
|
||||||
fi
|
|
||||||
echo
|
|
||||||
echo " $PREFIX/bin must be in the PATH environment variable"
|
|
||||||
echo "of all users who will use Window Maker"
|
|
||||||
perai
|
|
||||||
done
|
|
||||||
|
|
||||||
OPTIONS="$OPTIONS --prefix=$PREFIX"
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
##################### Configure
|
|
||||||
echo "--------------------------"
|
|
||||||
echo "Configuring Window Maker..."
|
|
||||||
echo "--------------------------"
|
|
||||||
if [ `uname -s` = "SCO_SV" ]; then
|
|
||||||
echo "CFLAGS=\"$CFLAGS -belf -DANSICPP\" ./configure $OPTIONS"
|
|
||||||
|
|
||||||
CFLAGS="$CFLAGS -belf -DANSICPP"
|
|
||||||
|
|
||||||
perform ./configure $OPTIONS
|
|
||||||
else
|
|
||||||
echo "CFLAGS=\"$CFLAGS $GCCFLAGS\" ./configure $OPTIONS"
|
|
||||||
|
|
||||||
CFLAGS="$CFLAGS $GCCFLAGS"
|
|
||||||
|
|
||||||
perform ./configure $OPTIONS
|
|
||||||
fi
|
|
||||||
|
|
||||||
|
|
||||||
#################### Compile
|
|
||||||
echo "-------------------------"
|
|
||||||
echo "Compiling Window Maker..."
|
|
||||||
echo "-------------------------"
|
|
||||||
(cd src; perform make clean)
|
|
||||||
perform make
|
|
||||||
|
|
||||||
echo "--------------------------"
|
|
||||||
echo "Installing Window Maker..."
|
|
||||||
echo "--------------------------"
|
|
||||||
|
|
||||||
perform make install
|
|
||||||
|
|
||||||
if [ `uname -s` = "Linux" ]; then
|
|
||||||
echo
|
|
||||||
echo " Make sure $PREFIX/lib is in the /etc/ld.so.conf file"
|
|
||||||
/sbin/ldconfig
|
|
||||||
fi
|
|
||||||
|
|
||||||
echo
|
|
||||||
echo "Installation Finished!"
|
|
||||||
echo
|
|
||||||
echo "Now, each user that wishes to use WindowMaker must run the wmaker.inst"
|
|
||||||
echo "script that was just installed."
|
|
||||||
|
|
||||||
|
|
||||||
if test "$NLS" = "Y"; then
|
|
||||||
echo "Don't forget to set the LANG environment variable to your locale"
|
|
||||||
fi
|
|
||||||
|
|
||||||
22
Makefile.am
22
Makefile.am
@@ -3,24 +3,8 @@
|
|||||||
SUBDIRS = wrlib WINGs src util po WindowMaker wmlib test WPrefs.app doc\
|
SUBDIRS = wrlib WINGs src util po WindowMaker wmlib test WPrefs.app doc\
|
||||||
contrib
|
contrib
|
||||||
|
|
||||||
EXTRA_DIST = TODO BUGS BUGFORM FAQ FAQ.I18N MIRRORS COPYING.WTFPL \
|
EXTRA_DIST = TODO BUGS BUGFORM FAQ FAQ.I18N FAQ.I18N.cs FAQ.I18N.sk \
|
||||||
Install acconfig.h INSTALL.pt README.pt\
|
INSTALL.cs INSTALL.fr INSTALL.es INSTALL.pt INSTALL.sk \
|
||||||
mkpatch README.KDE README.GNOME WindowMaker.lsm.in\
|
README.definable-cursor README.pt MIRRORS COPYING.WTFPL mkpatch
|
||||||
README.definable-cursor
|
|
||||||
# libwmfun-0.0.3.tar.gz
|
# libwmfun-0.0.3.tar.gz
|
||||||
|
|
||||||
WindowMaker.lsm: WindowMaker.lsm.in
|
|
||||||
size=`wc -c $(distdir).tar.gz|cut -d\ -f1`;\
|
|
||||||
size=`echo scale=2\;$$size/1048576|bc`;\
|
|
||||||
sed -e "s/VERSION/"$(VERSION)"/" \
|
|
||||||
-e "s/DATE/`date +%d%b%Y|tr a-z A-Z`/"\
|
|
||||||
-e "s/SIZE/$$size M/"\
|
|
||||||
WindowMaker.lsm.in > WindowMaker-$(VERSION).lsm
|
|
||||||
|
|
||||||
#dist-hook:
|
|
||||||
# touch `find -name configure.in -print`
|
|
||||||
# touch `find -name aclocal.m4 -print`
|
|
||||||
# touch `find -name Makefile.am -print`
|
|
||||||
# touch `find -name Makefile.in -print`
|
|
||||||
# touch `find -name configure -print`
|
|
||||||
|
|
||||||
|
|||||||
329
NEWS
329
NEWS
@@ -2,6 +2,335 @@
|
|||||||
NEWS for veteran Window Maker users
|
NEWS for veteran Window Maker users
|
||||||
-----------------------------------
|
-----------------------------------
|
||||||
|
|
||||||
|
--- 0.90.0
|
||||||
|
|
||||||
|
|
||||||
|
NetWM / EWMH Support
|
||||||
|
--------------------
|
||||||
|
|
||||||
|
Support for the EWMH standard has been added. Applications from GNOME 2.x and
|
||||||
|
KDE 3.x should now interoperate better with Window Maker.
|
||||||
|
|
||||||
|
Support for the obsolete/legacy GNOME 1.x, KDE 1.x and OpenLook(!) hints was
|
||||||
|
wiped out for the sake of sanity.
|
||||||
|
|
||||||
|
|
||||||
|
Antialiased font support
|
||||||
|
------------------------
|
||||||
|
|
||||||
|
With the addition of Xft2 support in the WINGs library, now
|
||||||
|
Window Maker can display antialiased text with TrueType or any scalable fonts.
|
||||||
|
|
||||||
|
You can pick fonts for Window Maker in the Font configuration section of
|
||||||
|
WPrefs.
|
||||||
|
|
||||||
|
Antialiased text is enabled by default, but can be disabled by adding
|
||||||
|
|
||||||
|
AntialiasedText = NO; in ~/GNUstep/Defaults/WMGLOBAL
|
||||||
|
|
||||||
|
This will disable antialiased text for any WINGs based application. If you
|
||||||
|
only want to disable them for a specific application only, like WindowMaker
|
||||||
|
for example, then add the same option in the applications configuration file,
|
||||||
|
in this case ~/GNUstep/Defaults/WindowMaker
|
||||||
|
For WindowMaker, this can also be achieved from the Expert panel in WPrefs.
|
||||||
|
|
||||||
|
Note that bitmapped fonts look much better than TrueType when antialiasing is
|
||||||
|
disabled.
|
||||||
|
|
||||||
|
Global Submenus
|
||||||
|
---------------
|
||||||
|
|
||||||
|
Global menus allow for system wide menus that are added to every users
|
||||||
|
application menus. They are located in /usr/etc/WindowMaker/,
|
||||||
|
/usr/local/etc/WindowMaker or whatever is your sysconf directory
|
||||||
|
for WindowMaker. There are 2 files:
|
||||||
|
|
||||||
|
GlobalMenu.pre, which is added to the beginning of the menu and
|
||||||
|
GlobalMenu.post, which is added to the end of the menu.
|
||||||
|
|
||||||
|
These are to be proplist format menus, for example:
|
||||||
|
|
||||||
|
(("Foobar", EXEC, foobar),
|
||||||
|
("Blabla", EXEC, blabla))
|
||||||
|
|
||||||
|
or, in case you want a submenu:
|
||||||
|
|
||||||
|
(("Submenu",
|
||||||
|
("Foobar", EXEC, foobar),
|
||||||
|
("Blabla", EXEC, blabla)))
|
||||||
|
|
||||||
|
|
||||||
|
UTF-8 Support
|
||||||
|
-------------
|
||||||
|
|
||||||
|
Window Maker now uses UTF-8 internally (and thus can display UTF-8 text
|
||||||
|
in window titles and other places). Menus and po files must now be
|
||||||
|
encoded in UTF-8. If your menus contain non ASCII characters, you can convert
|
||||||
|
them to UTF-8 with the following command:
|
||||||
|
|
||||||
|
iconv -f <current-file-encoding> -t utf-8 <filename> > <filename>.utf8
|
||||||
|
|
||||||
|
For example:
|
||||||
|
|
||||||
|
iconv -f iso-8859-1 -t utf-8 menu > menu.utf
|
||||||
|
mv menu.utf menu
|
||||||
|
|
||||||
|
|
||||||
|
Icon Panel for Alt-Tabbing
|
||||||
|
--------------------------
|
||||||
|
|
||||||
|
A panel with icons for the windows that you can switch to will appear
|
||||||
|
when you press Alt-Tab. You can navigate through the windows with Alt-Tab
|
||||||
|
(Alt-Shift-Tab) or with the left/right keys once the panel is shown.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
--- 0.80.0
|
||||||
|
|
||||||
|
Shading/Unshading windows using mouse wheel on their titlebar
|
||||||
|
-------------------------------------------------------------
|
||||||
|
|
||||||
|
In addition to the known methods of shading/unshading a window, one can now
|
||||||
|
do this by using the mouse wheel on the window's titlebar. The mouse events
|
||||||
|
are interpreted via a mapping in the global WINGs configuration file,
|
||||||
|
WMGLOBAL, by the MouseWheelUp and MouseWheelDown directives which will do
|
||||||
|
shading and unshading respectfully.
|
||||||
|
|
||||||
|
However, to avoid unwanted triggers of shading/unshading the window, two
|
||||||
|
consecutive mouse wheel events in the same direction are required. The
|
||||||
|
trigger won't occur if the events are separated by more than a double-click's
|
||||||
|
worth of time, which is technically speaking like making a double-click with
|
||||||
|
the button that corresponds to the mouse wheel direction.
|
||||||
|
|
||||||
|
Practically speaking, this means that you have to move the mouse wheel up
|
||||||
|
or down quickly, like when you want to quickly scroll over something big.
|
||||||
|
|
||||||
|
|
||||||
|
Shared application icons
|
||||||
|
------------------------
|
||||||
|
|
||||||
|
Real application icon sharing was implemented in place of the collapse
|
||||||
|
appicon thing. With this applications of the same instance.class will
|
||||||
|
have a single shared application icon and hiding will hide all windows
|
||||||
|
of the aplications attached to that appicon as if there is a single
|
||||||
|
application. This feature is enabled by default for all applications in
|
||||||
|
the global WMWindowAttributes defaults domain using:
|
||||||
|
|
||||||
|
"*" = {SharedAppIcon = Yes;};
|
||||||
|
|
||||||
|
If you're not satisfied with this or want the old behaviour back you
|
||||||
|
can revert this (either in the global domain for all users or in your
|
||||||
|
personal WMWindowAttibutes domain) using SharedAppIcon = No; for "*"
|
||||||
|
It can also be enabled/disabled for individual applications as needed.
|
||||||
|
|
||||||
|
Setting this option can be done using the window's inspector panel in the
|
||||||
|
"Application Specific" section. You can set/unset it for all applications by
|
||||||
|
using the "Defaults for all windows" in the "Window Specification" section
|
||||||
|
|
||||||
|
Basically using this can have 2 major scenarios:
|
||||||
|
1. Leave it on by default, but disable it for the few specific
|
||||||
|
applications that do not behave well with it. (default)
|
||||||
|
2. Leave it off by default, and enable it for all applications for
|
||||||
|
which you want it enabled.
|
||||||
|
|
||||||
|
At this point all applications we tested work ok, some of them even
|
||||||
|
work better with this feature turned on: for example xmms and Corel's
|
||||||
|
WorkPerfect8 now only have 1 appicon (they used to have 2 without this
|
||||||
|
feature).
|
||||||
|
|
||||||
|
This feature is turned off by default for the following applications
|
||||||
|
because it's incompatible with them:
|
||||||
|
1. all GNUstep applications
|
||||||
|
2. applications with an application menu (wterm, Aileron, etc)
|
||||||
|
3. all applications with withdrawn windows only (this means all dockapps)
|
||||||
|
|
||||||
|
As a side note: wterm can use the shared appicon feature as long as it
|
||||||
|
doesn't use the appmenu (will do this by default). If you start it
|
||||||
|
using the appmenu (wterm -wm) it will disable the shared appicon
|
||||||
|
feature because apps with appmenus are incompatible with this feature.
|
||||||
|
|
||||||
|
If an application is a GNUstep application or if it has an appmenu, it's
|
||||||
|
detected automatically and the shared appicon is disabled automatically
|
||||||
|
without any user intervention or need to configure anything.
|
||||||
|
|
||||||
|
|
||||||
|
Dock/Clip stealing appicons
|
||||||
|
---------------------------
|
||||||
|
|
||||||
|
This feature is different form the Clip's "Autoattract Icons" feature
|
||||||
|
as it won't attach any new icon to the dock/clip.
|
||||||
|
What it does, is when you start an application by other means than
|
||||||
|
dock/clip, like for example using the main menu or a terminal, it will
|
||||||
|
search the dock/clips for the presence of an appicon for that
|
||||||
|
application, that is not already running at that moment and will attach
|
||||||
|
the started application to that appicon in the dock/clip if available,
|
||||||
|
making it look like the dock/clip just stole the appicon for the started
|
||||||
|
application. There is an animation for this to offer visual feedback
|
||||||
|
that this happened.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
--- 0.70.0
|
||||||
|
|
||||||
|
New dock option
|
||||||
|
---------------
|
||||||
|
|
||||||
|
Copy/paste launch in dock.
|
||||||
|
==========================
|
||||||
|
|
||||||
|
For example, put netscape %s in the Docked icon for Netscape, select an url
|
||||||
|
somewhere and then middle-click the icon. The command will be launched with
|
||||||
|
the "pasted" string.
|
||||||
|
|
||||||
|
|
||||||
|
Xinerama Support
|
||||||
|
================
|
||||||
|
|
||||||
|
Supported Xinerama features:
|
||||||
|
|
||||||
|
- Normal maximization of windows will maximize to only one of the screens,
|
||||||
|
the one where the cursor pointer is.
|
||||||
|
|
||||||
|
- Full Maximize command in window menu
|
||||||
|
|
||||||
|
- Place dialogs in the middle of the head where the pointer is
|
||||||
|
|
||||||
|
- Try to place windows inside one head in non-manual placement modes
|
||||||
|
|
||||||
|
|
||||||
|
Less dependancies
|
||||||
|
-----------------
|
||||||
|
|
||||||
|
starting with 0.70.0 libPropList is no longer required to build Window
|
||||||
|
Maker. PropList handling code was added to WINGs being now better
|
||||||
|
integrated with all the rest. For more details check the Changelog and the
|
||||||
|
following files:
|
||||||
|
./WINGs/ChangeLog
|
||||||
|
./WINGs/NEWS
|
||||||
|
./WINGs/WINGs/WUtil.h
|
||||||
|
./WINGs/WINGs/proplist-compat.h
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
--- 0.65.1
|
||||||
|
|
||||||
|
Removed FocusFollowMouse option, only SloppyFocus present now.
|
||||||
|
|
||||||
|
Added None option to MoveDisplay and ResizeDisplay
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
--- 0.65.0
|
||||||
|
|
||||||
|
Single AppIcon
|
||||||
|
--------------
|
||||||
|
|
||||||
|
Removed --single-appicon patch and replaced it with a application
|
||||||
|
specific collapsing option. Check inspector panel and appicon menu.
|
||||||
|
|
||||||
|
New options to configure the workspace mouse actions
|
||||||
|
----------------------------------------------------
|
||||||
|
|
||||||
|
The following options were removed from the WindowMaker defaults configuration
|
||||||
|
file:
|
||||||
|
|
||||||
|
SelectWindowsMouseButton, WindowListMouseButton and ApplicationMenuMouseButton.
|
||||||
|
|
||||||
|
They were replaced with the following 3+1:
|
||||||
|
|
||||||
|
MouseLeftButtonAction, MouseMiddleButtonAction and MouseRightButtonAction plus
|
||||||
|
MouseWheelAction
|
||||||
|
|
||||||
|
In the old way because all gravitated around the workspace actions to which
|
||||||
|
specific mouse buttons could have been bound, it allowed one to specify in
|
||||||
|
the configuration file settings which would have led to weird situations
|
||||||
|
that also had undesirable results.
|
||||||
|
For example the same mouse button (for example left) could have been
|
||||||
|
assigned to all workspace actions: 'select windows', 'show window list menu'
|
||||||
|
and 'show applications menu' which of course were not only impossible to
|
||||||
|
accomplish while still having a properly working workspace, but they also
|
||||||
|
allowed one to specify some settings in the configuration file that were
|
||||||
|
never in fact translatable to proper workspace actions.
|
||||||
|
|
||||||
|
To void this kind of user interface inconsistency, the new options now
|
||||||
|
gravitate around the physical device (the mouse and its buttons) to which
|
||||||
|
specific workspace actions can be bound. This way, even if one assigns the
|
||||||
|
same action to all mouse buttons, that situation while gives redundant and
|
||||||
|
unpractical settings it will still translatable to proper workspace actions:
|
||||||
|
all buttons will execute the same action, but a button will execute only one
|
||||||
|
action at a time.
|
||||||
|
|
||||||
|
The new options take the following values:
|
||||||
|
all Mouse...ButtonAction can have one of the following values:
|
||||||
|
|
||||||
|
None, SelectWindows, OpenApplicationsMenu or OpenWindowListMenu
|
||||||
|
|
||||||
|
MouseWheelAction can be one of None or SwitchWorkspaces
|
||||||
|
|
||||||
|
If you had the default actions bound to mouse buttons before, then it will
|
||||||
|
work for you without any intervention in the configuration files.
|
||||||
|
Else you need to use WPrefs.app to bind the actions to the mouse buttons
|
||||||
|
again to your old settings. Also if you want to change the mouse wheel
|
||||||
|
behavior regarding workspaces you can now (use WPrefs.app to do this).
|
||||||
|
|
||||||
|
Client supplied icons
|
||||||
|
---------------------
|
||||||
|
|
||||||
|
Window Maker saves the client supplied icons in ~/GNUstep/.AppInfo/WindowMaker
|
||||||
|
in XPM format for later use when the app is no longer running (to have the
|
||||||
|
image to display for docked icons for example).
|
||||||
|
|
||||||
|
Until recently the XPM images saved by Window Maker were incorrect, but a
|
||||||
|
recent fix in the code to save XPM's fixed them. But with this fix, all
|
||||||
|
previously saved XPM's in that directory are no longer readable (they give
|
||||||
|
wrong images on screen or fail to load).
|
||||||
|
|
||||||
|
To avoid the need for the user to fix this by hand editing WMWindowAttributes
|
||||||
|
and removing all references to icons in ~/GNUstep/.AppInfo/WindowMaker which
|
||||||
|
can be annoying, new code was added to Window Maker to permit the regeneration
|
||||||
|
of images in ~/GNUstep/.AppInfo/WindowMaker if they are missing.
|
||||||
|
|
||||||
|
With this addition, all you need to do to fix your old broken images, is to
|
||||||
|
delete all *.xpm files from ~/GNUstep/.AppInfo/WindowMaker. Next time the
|
||||||
|
application that is supplying an icon image will start the icon will be
|
||||||
|
recreated if missing, but this time it will be saved with the new XPM save
|
||||||
|
code which produces good XPM images.
|
||||||
|
All the rest of the process is transparent to the user.
|
||||||
|
|
||||||
|
Hermes library support
|
||||||
|
----------------------
|
||||||
|
|
||||||
|
If configure finds hermes library (an optimized pixel format conversion
|
||||||
|
library) installed it will use it to do the pixel format conversion in
|
||||||
|
the wraster library for some cases (TrueColor visuals without dithering).
|
||||||
|
Currently the hermes routines cannot convert to an indexed destination,
|
||||||
|
so we can't use hermes for PseudoColor, GrayScale and StaticGray visuals.
|
||||||
|
Also hermes only does dithering for just 2 combinations of source/destination
|
||||||
|
bits/masks none of them useful to out needs so for dithering we still
|
||||||
|
use out routines.
|
||||||
|
|
||||||
|
The Hermes library is completely optional, you can build Window Maker
|
||||||
|
without having it, it just speeds up the things a little for some
|
||||||
|
situations.
|
||||||
|
|
||||||
|
hermes library is available here: http://www.clanlib.org/hermes/
|
||||||
|
|
||||||
|
|
||||||
|
--- 0.64.0
|
||||||
|
|
||||||
|
No Polling of Configuration Files
|
||||||
|
---------------------------------
|
||||||
|
|
||||||
|
Running Window Maker with one of -nopolling or --no-polling command line
|
||||||
|
options will make it not to poll every 3 seconds for changes in its
|
||||||
|
configuration files (good for laptops to let them spin disks down when idle).
|
||||||
|
|
||||||
|
Note:
|
||||||
|
For the ones used with Jim Knoble's 'no polling' patch, this is the same,
|
||||||
|
except that the need to #define ENABLE_NO_POLLING in wconfig.h was removed
|
||||||
|
and the behaviour is always available if you use the command line option.
|
||||||
|
|
||||||
|
|
||||||
--- 0.63.0
|
--- 0.63.0
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
56
README
56
README
@@ -13,9 +13,6 @@
|
|||||||
|
|
||||||
Dan Pascu
|
Dan Pascu
|
||||||
|
|
||||||
Matthew Hawkins
|
|
||||||
|
|
||||||
]d
|
|
||||||
|
|
||||||
|
|
||||||
Web/FTP Master
|
Web/FTP Master
|
||||||
@@ -54,7 +51,8 @@ Window Maker was designed keeping integration with GNUstep in mind and is the
|
|||||||
(www.gnu.org) Read more about GNUstep further on this file.
|
(www.gnu.org) Read more about GNUstep further on this file.
|
||||||
|
|
||||||
Hints (information given by applications to integrate well with the window
|
Hints (information given by applications to integrate well with the window
|
||||||
manager) for Motif(tm), OPEN LOOK(tm), KDE and GNOME are also supported.
|
manager) for Motif(tm) and NETWM are also supported (NETWM is used by KDE
|
||||||
|
and GNOME, so they are automatically supported as a result).
|
||||||
So you can replace any of the window managers for these environments
|
So you can replace any of the window managers for these environments
|
||||||
with Window Maker while keeping most, if not all, of the native window manager
|
with Window Maker while keeping most, if not all, of the native window manager
|
||||||
functionality.
|
functionality.
|
||||||
@@ -223,31 +221,6 @@ Note that you must compile Window Maker with the --enable-sound configure
|
|||||||
flag and set the DisableSound option to NO.
|
flag and set the DisableSound option to NO.
|
||||||
|
|
||||||
|
|
||||||
OpenL**k support
|
|
||||||
================
|
|
||||||
|
|
||||||
I guess many users, mainly from the academic world, have to use
|
|
||||||
applications written using the OpenL**k toolkits, so having support
|
|
||||||
for these apps must be of some use.
|
|
||||||
|
|
||||||
To enable, use --enable-openlook when doing the configure. Note that
|
|
||||||
not everything is implemented.
|
|
||||||
|
|
||||||
Implemented stuff include decoration hints and the push-pin. Not implemented
|
|
||||||
stuff include _SUN_WINDOW_STATE (the compose led state stuff), drag and drop
|
|
||||||
interest stuff, header (not sure what's it) and footer strings.
|
|
||||||
|
|
||||||
Please give me feedback if something doesn't work. If the feature is
|
|
||||||
already implemented, but is not working because of a bug, I'll try to
|
|
||||||
have that fixed. If it's a non-implemented feature and you mention that
|
|
||||||
it's important (ie: not just cosmetical), I'll consider implementing it.
|
|
||||||
|
|
||||||
The "out" state of the pushpin is emulated as a pushed-in close button.
|
|
||||||
Just click on the button to make it pushed-out, which corresponds
|
|
||||||
to the pinned-in state of the pushpin. If you push again in the pushed-out
|
|
||||||
close button, it will act as a normal close button: it will close the window.
|
|
||||||
|
|
||||||
|
|
||||||
Performance Tuning
|
Performance Tuning
|
||||||
==================
|
==================
|
||||||
|
|
||||||
@@ -273,7 +246,7 @@ bellow:
|
|||||||
- to reduce memory usage, disable the icon cache, by setting the RIMAGE_CACHE
|
- to reduce memory usage, disable the icon cache, by setting the RIMAGE_CACHE
|
||||||
environment variable to 0. If you want to increase performance at the cost
|
environment variable to 0. If you want to increase performance at the cost
|
||||||
of memory usage, set it's value to a value like the number of different
|
of memory usage, set it's value to a value like the number of different
|
||||||
icons you use.
|
icons you use. Also, disable anti-aliased text support in ~/GNUstep/Defaults/WMGLOBAL.
|
||||||
|
|
||||||
|
|
||||||
Keyboard Mouse Control
|
Keyboard Mouse Control
|
||||||
@@ -364,7 +337,6 @@ Authors
|
|||||||
|
|
||||||
Alfredo K. Kojima <kojima@windowmaker.org>
|
Alfredo K. Kojima <kojima@windowmaker.org>
|
||||||
Dan Pascu <dan@windowmaker.org>
|
Dan Pascu <dan@windowmaker.org>
|
||||||
Matt Hawkins <matt@windowmaker.org>
|
|
||||||
]d <id@windowmaker.org>
|
]d <id@windowmaker.org>
|
||||||
|
|
||||||
Please don't ask us questions before reading the documentation (esp. the
|
Please don't ask us questions before reading the documentation (esp. the
|
||||||
@@ -379,25 +351,3 @@ can be found in po/README and Window Maker/README
|
|||||||
If you have any comments, fixes and bug reports (filled BUGFORMs) send them
|
If you have any comments, fixes and bug reports (filled BUGFORMs) send them
|
||||||
to developers@windowmaker.org
|
to developers@windowmaker.org
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Musicware
|
|
||||||
=========
|
|
||||||
|
|
||||||
If you use Window Maker and *really* like it, please consider making my day
|
|
||||||
by sending me a music CD (or a MiniDisc or even a MP3 CDR) of your favorite
|
|
||||||
band, singer, instrumentist, composer or whatever :^). I like listening to
|
|
||||||
music and would love to get new CDs, especially from other parts of the
|
|
||||||
world. I like almost any kind of music, from Ozzy Osbourne to Bach (mas não
|
|
||||||
pagode e sertanejo pelamordideus :), so I will be happy to receive just about
|
|
||||||
anything.
|
|
||||||
|
|
||||||
Snail mail address:
|
|
||||||
|
|
||||||
Alfredo Kengi Kojima
|
|
||||||
Rua Firmino O. Bimbi, 255/25B
|
|
||||||
Porto Alegre - RS
|
|
||||||
CEP 91751-330
|
|
||||||
Brazil
|
|
||||||
|
|
||||||
|
|||||||
53
README.GNOME
53
README.GNOME
@@ -1,53 +0,0 @@
|
|||||||
|
|
||||||
Information on Using Window Maker with GNOME
|
|
||||||
--------------------------------------------
|
|
||||||
|
|
||||||
|
|
||||||
Status of GNOME support
|
|
||||||
-----------------------
|
|
||||||
|
|
||||||
|
|
||||||
GNOME window manager protocols seem to be a work in progress.
|
|
||||||
Things still change fairly frequently, so, the stuff implemented
|
|
||||||
may not reflect the latest protocol. If something doesn't work,
|
|
||||||
that's probably because the protocols have changed again and I still
|
|
||||||
didn't have time to reimplement everything or noticed that it
|
|
||||||
changed. If that happens, please tell me exactly what doesn't work.
|
|
||||||
|
|
||||||
Other than that, the so called "GNOME Window Manager Compliance - How to
|
|
||||||
write a GNOME compliant Window Manager" document, says this:
|
|
||||||
|
|
||||||
"There are currently a set of other hints available that are, at the
|
|
||||||
current time, not essential and therefore not documented here. It is,
|
|
||||||
however envisaged that they will be finalized and added to this
|
|
||||||
document, but for now are not needed."
|
|
||||||
|
|
||||||
Since they are non-essential and undocumented they are not yet implemented.
|
|
||||||
|
|
||||||
|
|
||||||
Implemented stuff:
|
|
||||||
|
|
||||||
- GNOME window manager hints
|
|
||||||
- Motif window manager hints
|
|
||||||
|
|
||||||
On the works:
|
|
||||||
|
|
||||||
- R6 style session management
|
|
||||||
|
|
||||||
|
|
||||||
Compilation/Installation
|
|
||||||
------------------------
|
|
||||||
|
|
||||||
To compile Window Maker with GNOME support, just configure it as:
|
|
||||||
./configure --enable-gnome
|
|
||||||
|
|
||||||
before compiling.
|
|
||||||
|
|
||||||
Also, do not disable mwm hints support (they are enabled by default).
|
|
||||||
|
|
||||||
|
|
||||||
Configuration
|
|
||||||
-------------
|
|
||||||
|
|
||||||
In WPrefs, go to the last section and toggle the "Disable miniwindows" option.
|
|
||||||
|
|
||||||
125
README.KDE
125
README.KDE
@@ -1,125 +0,0 @@
|
|||||||
|
|
||||||
|
|
||||||
Information on Using Window Maker with KDE
|
|
||||||
------------------------------------------
|
|
||||||
|
|
||||||
|
|
||||||
Window Maker supports almost all KDE/KWM specific client
|
|
||||||
communication protocols, so you can simply replace kwm with
|
|
||||||
Window Maker, if you think these advantages are worthy:
|
|
||||||
|
|
||||||
Window Maker KWM
|
|
||||||
=============================================================================
|
|
||||||
Looks NEXTSTEP(tm)/NEXTSTEP(tm) Original, but reminds
|
|
||||||
enhanced Windows(tm)
|
|
||||||
|
|
||||||
Decoration solid, gradient, multi-color solid, vertical and
|
|
||||||
Textures gradient, pixmaps, textured horizontal gradient,
|
|
||||||
gradient - all gradients are pixmap
|
|
||||||
supported in horizontal,
|
|
||||||
vertical and diagonal
|
|
||||||
directions
|
|
||||||
|
|
||||||
Configurable No Yes, but not totally
|
|
||||||
Titlebar Buttons
|
|
||||||
|
|
||||||
Mini CLI Yes, but limited Yes
|
|
||||||
|
|
||||||
Window Specific Yes In KDE 1.1, yes.
|
|
||||||
Configuration In KDE 1.0, no.
|
|
||||||
|
|
||||||
Quick Keyboard Yes In KDE 1.1, yes
|
|
||||||
Navigation In KDE 1.0, no.
|
|
||||||
|
|
||||||
Pager KDE pagers will work as Yes
|
|
||||||
well as GNOME pagers
|
|
||||||
|
|
||||||
Session Not yet supported, but Yes, old (pre-X11R6) style
|
|
||||||
Management X11R6 style SM is being worked.
|
|
||||||
|
|
||||||
Dock kpanel, GNOME panel and Dock kpanel
|
|
||||||
|
|
||||||
Built-in Yes No
|
|
||||||
krootbgwm
|
|
||||||
|
|
||||||
GNOME support Yes No
|
|
||||||
|
|
||||||
Memory Usage(1) 1.85Mb In KDE 1.0, 3.13Mb
|
|
||||||
In KDE 1.1, probably more
|
|
||||||
|
|
||||||
|
|
||||||
(1) Memory usage was tested by running wmaker and kwm at the same machine
|
|
||||||
with the same windows, on the same screen and similar window texture
|
|
||||||
configurations (at different times, of course). I looked in the output of
|
|
||||||
ps -m, in the SIZE field, right after starting the window managers.
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Enabling KDE Support
|
|
||||||
--------------------
|
|
||||||
|
|
||||||
To enable KDE support in Window Maker, you must compile it after
|
|
||||||
configuring it as follows:
|
|
||||||
./configure --enable-kde
|
|
||||||
|
|
||||||
Then, just replace kwm with wmaker in your startkde script.
|
|
||||||
If you are going to use Window Makers sound server, comment out
|
|
||||||
kwmsound in startkde. Also if wmaker sets your root window
|
|
||||||
background, comment out kbgndwm, kde's wallpaper setter.
|
|
||||||
|
|
||||||
Make sure to disable workspace background setting in KDE. If you
|
|
||||||
wont be using Window Maker themes anyway, you can set
|
|
||||||
WorkspaceBack = (none);
|
|
||||||
|
|
||||||
in ~/GNUstep/Defaults/WindowMaker
|
|
||||||
|
|
||||||
|
|
||||||
Enhancing Integration
|
|
||||||
---------------------
|
|
||||||
|
|
||||||
Window Maker adds some extensions to KDE's messaging stuff, so you can run
|
|
||||||
Window Maker specific commands from places like kpanel, krootwm or even
|
|
||||||
kwmcom. Recently KDE developers have kindly added support for these extensions
|
|
||||||
in the more recent KDE versions from CVS. The added stuff are the following
|
|
||||||
kwm like commands:
|
|
||||||
|
|
||||||
wm:wmaker - select Window Maker support mode
|
|
||||||
wmaker:info - show info panel
|
|
||||||
wmaker:legal - show legal panel
|
|
||||||
wmaker:arrangeIcons - arrange icons
|
|
||||||
wmaker:showAll - show all windows
|
|
||||||
wmaker:hideOthers - hide others
|
|
||||||
wmaker:restart - restart wmaker
|
|
||||||
wmaker:exit - exit wmaker
|
|
||||||
|
|
||||||
You can test them with kwmcom, like:
|
|
||||||
kwmcom wmaker:info
|
|
||||||
|
|
||||||
|
|
||||||
Problems
|
|
||||||
--------
|
|
||||||
|
|
||||||
* kpanel will not be kept always on top. That's because kpanel is an
|
|
||||||
OverrideRedirect window, so Window Maker can't do anything about that.
|
|
||||||
|
|
||||||
Before requesting for a hack to work around that in Window Maker, please
|
|
||||||
request the kpanel author to fix it.
|
|
||||||
|
|
||||||
* because the KDE protocol for letting the window manager know the usable
|
|
||||||
window region is broken, you might find some problems with the window
|
|
||||||
positioning/maximization code and kpanel's position.
|
|
||||||
|
|
||||||
* It seems kpanel (and maybe KDE in general) doesn't like dynamically
|
|
||||||
changing the number of workspaces. So, don't create or destroy workspaces
|
|
||||||
while running on KDE, unless you really need.
|
|
||||||
|
|
||||||
* If kpanel, kwmpager or kpager becomes confused about the number of
|
|
||||||
windows present, restart them.
|
|
||||||
|
|
||||||
* Wmaker opens windows by default under/over the panel, when the panel is
|
|
||||||
at top or left of screen. Use the GUI configuration tool WPrefs to change
|
|
||||||
this.
|
|
||||||
|
|
||||||
* Some commands, such as cascade windows and rearrange windows are not
|
|
||||||
yet implemented.
|
|
||||||
|
|
||||||
@@ -1,67 +1,78 @@
|
|||||||
# README.definable-cursor: How to use definable-cursor patch for Window Maker
|
|
||||||
# created 1999-Apr-24 14:53 jmk
|
|
||||||
# autodate: 1999-Apr-24 16:29
|
|
||||||
|
|
||||||
__________________________________________________
|
|
||||||
|O| Definable Mouse Cursors for Window Maker |X|
|
|
||||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
||||||
|
|
||||||
The definable-cursor patch for Window Maker
|
Definable Mouse Cursors for Window Maker
|
||||||
<http://www.windowmaker.org/> allows user-definable mouse cursors; the
|
----------------------------------------
|
||||||
|
|
||||||
|
The definable-cursor feature allows user-definable mouse cursors; the
|
||||||
cursors can either be the built-in ones from the X11 cursor font, or
|
cursors can either be the built-in ones from the X11 cursor font, or
|
||||||
they can be bitmap (XBM) files. User-definable cursors can be useful
|
they can be bitmap (XBM) files. User-definable cursors can be useful
|
||||||
for theme-builders, lefthanders, and the visually impaired.
|
for theme-builders, lefthanders, and the visually impaired.
|
||||||
|
|
||||||
This README describes how to apply the patch to Window Maker and how to
|
|
||||||
use the features it enables.
|
|
||||||
|
|
||||||
____________________________
|
Defining Your Own Cursors
|
||||||
|O| Applying the Patch |X|
|
-------------------------
|
||||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
||||||
|
|
||||||
The definable-cursor patch is available from
|
A cursor specification takes one of the following forms in the
|
||||||
<http://www.pobox.com/~jmknoble/WindowMaker/patches/>.
|
~/GNUstep/Defaults/WindowMaker file:
|
||||||
|
|
||||||
To apply the patch, do the following (where `XX' is the version of
|
|
||||||
Window Maker you're patching):
|
|
||||||
|
|
||||||
(0) gzip -dc WindowMaker-XX.tar.gz | tar -xvf -
|
|
||||||
|
|
||||||
(1) cd ./WindowMaker-XX
|
|
||||||
|
|
||||||
(2) patch </wherever/you/put/WindowMaker-XX-definable-cursor.patch
|
|
||||||
|
|
||||||
(3) Build Window Maker according to the instructions in the
|
|
||||||
accompanying `INSTALL' file.
|
|
||||||
|
|
||||||
___________________________________
|
|
||||||
|O| Defining Your Own Cursors |X|
|
|
||||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
||||||
|
|
||||||
A cursor specification is one of:
|
|
||||||
|
|
||||||
(none)
|
(none)
|
||||||
(builtin, <cursor-name>)
|
(builtin, <cursor-name>)
|
||||||
(bitmap, <bitmap-filename>, <mask-filename>)
|
(bitmap, <bitmap-filename>, <mask-filename>)
|
||||||
|
|
||||||
where <cursor-name> uses the same syntax as for `xsetroot -cursor_name',
|
They have the following meanings:
|
||||||
and <bitmap-filename> and <mask-filename> are the same as for
|
|
||||||
`xsetroot -cursor'; <bitmap-filename> and <mask-filename> are searched
|
none The cursor is inherited from the parent window (often,
|
||||||
for along WM's PixmapPath. If you use `(none)', the cursor will be
|
this means the root window).
|
||||||
inherited from the parent window (which often ends up being the root
|
|
||||||
window).
|
builtin Use the cursor named <cursor-name> from X11's set of
|
||||||
|
built-in cursors. The names are the same as you use
|
||||||
|
with 'xsetroot -cursor_name'. See the xsetroot(1) man
|
||||||
|
page for more information.
|
||||||
|
|
||||||
|
bitmap Use the bitmap in <bitmap-filename> as the foreground
|
||||||
|
cursor bitmap, and the one in <mask-filename> as the
|
||||||
|
background (mask) bitmap. This is pretty much the same
|
||||||
|
as 'xsetroot -cursor', except that Window Maker searches
|
||||||
|
for the bitmaps along its PixmapPath.
|
||||||
|
|
||||||
You can set the following cursor types (they're shown here with their
|
You can set the following cursor types (they're shown here with their
|
||||||
defaults):
|
defaults):
|
||||||
|
|
||||||
NormalCursor = (builtin, left_ptr);
|
NormalCursor = (builtin, left_ptr);
|
||||||
|
ArrowCursor = (builtin, top_left_arrow);
|
||||||
MoveCursor = (builtin, fleur);
|
MoveCursor = (builtin, fleur);
|
||||||
ResizeCursor = (builtin, sizing);
|
TopLeftResizeCursor = (builtin, top_left_corner);
|
||||||
|
TopRightResizeCursor = (builtin, top_right_corner);
|
||||||
|
BottomLeftResizeCursor = (builtin, bottom_left_corner);
|
||||||
|
BottomRightResizeCursor = (builtin, bottom_right_corner);
|
||||||
|
VerticalResizeCursor = (builtin, sb_v_double_arrow);
|
||||||
|
HorizontalResizeCursor = (builtin, sb_h_double_arrow);
|
||||||
WaitCursor = (builtin, watch);
|
WaitCursor = (builtin, watch);
|
||||||
|
QuestionCursor = (builtin, question_arrow);
|
||||||
|
TextCursor = (builtin, xterm);
|
||||||
|
SelectCursor = (builtin, cross);
|
||||||
|
|
||||||
______________________
|
The following cursor types are allowed, but they're deprecated (Window
|
||||||
|O| Random Notes |X|
|
Maker used them in the past, but doesn't use them anymore):
|
||||||
^^^^^^^^^^^^^^^^^^^^^^
|
|
||||||
|
ResizeCursor = (builtin, sizing);
|
||||||
|
|
||||||
|
|
||||||
|
Using Cursors with 'getstyle' and 'setstyle'
|
||||||
|
--------------------------------------------
|
||||||
|
|
||||||
|
The 'getstyle' and 'setstyle' style/theme-management utilities can
|
||||||
|
handle user-definable cursors. By default, 'getstyle' ignores cursor
|
||||||
|
definitions; using 'getstyle -t' to get theme-related settings will
|
||||||
|
also include any cursors you've defined in the resulting stylefile.
|
||||||
|
|
||||||
|
However, by default, 'setstyle' does NOT ignore cursor settings. If
|
||||||
|
you wish to set a style or theme without installing cursor settings,
|
||||||
|
you can use 'setstyle --no-cursors' to ignore the cursor definitions.
|
||||||
|
|
||||||
|
|
||||||
|
Random Notes
|
||||||
|
------------
|
||||||
|
|
||||||
Most X11 cursors are 16x16 bitmaps. Many X servers can actually handle
|
Most X11 cursors are 16x16 bitmaps. Many X servers can actually handle
|
||||||
larger cursors, though. To check, use:
|
larger cursors, though. To check, use:
|
||||||
@@ -75,12 +86,7 @@ and in the resulting output look for a line such as:
|
|||||||
The example above indicates that my X server can handle cursors up to
|
The example above indicates that my X server can handle cursors up to
|
||||||
64 pixels wide by 64 pixels high.
|
64 pixels wide by 64 pixels high.
|
||||||
|
|
||||||
You can create your own bitmap cursors using the `bitmap' program that
|
You can create your own bitmap cursors using the 'bitmap' program that
|
||||||
accompanies most X11 distributions. For example bitmap cursors, see
|
accompanies most X11 distributions. For example bitmap cursors and
|
||||||
<http://www.pobox.com/~jmknoble/WindowMaker/cursors/>.
|
masks, see <http://www.pobox.com/~jmknoble/WindowMaker/cursors/>.
|
||||||
|
|
||||||
For an example
|
|
||||||
|
|
||||||
--jim
|
|
||||||
|
|
||||||
%%%%%%%%%%%%%%% jim knoble %%%%%%%% jmknoble@pobox.com %%%%%%%%%%%%%%%%%
|
|
||||||
|
|||||||
345
README.es
Normal file
345
README.es
Normal file
@@ -0,0 +1,345 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
GNU Window Maker
|
||||||
|
X11 Window Manager
|
||||||
|
|
||||||
|
<http://windowmaker.org>
|
||||||
|
<ftp://ftp.windowmaker.org>
|
||||||
|
|
||||||
|
por
|
||||||
|
|
||||||
|
Alfredo K. Kojima
|
||||||
|
|
||||||
|
Dan Pascu
|
||||||
|
|
||||||
|
]d
|
||||||
|
|
||||||
|
|
||||||
|
Web/FTP Master
|
||||||
|
|
||||||
|
Phillip Smith
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
¡Felicitaciones! Ha adquirido un dispositivo
|
||||||
|
excelentísimo que le proporcionará miles de años de uso sin
|
||||||
|
problemas, si no fuera porque indudablemente lo destruirá a
|
||||||
|
través de alguna maniobra estúpida típica de consumidor. Por
|
||||||
|
eso le pedimos por EL AMOR DE DIOS LEA ESTE MANUAL DEL
|
||||||
|
PROPIETARIO CUIDADOSAMENTE ANTES DE DESEMPAQUETAR EL
|
||||||
|
DISPOSITIVO. ¿YA LO DESEMPAQUETÓ, NO? LO DESEMPAQUETÓ Y LO
|
||||||
|
ENCHUFÓ Y LO ENCENDIÓ Y TOQUETEÓ LAS PERILLAS, Y AHORA SU
|
||||||
|
CHICO, EL MISMO CHICO QUE UNA VEZ METIÓ UNA SALCHICHA EN SU
|
||||||
|
VIDEOCASETERA Y ACCIONÓ "AVANCE RÁPIDO", ESTE CHICO
|
||||||
|
TAMBIÉN ESTÁ TUOQUETEANDO LAS PERILLAS, ¿CIERTO? Y RECIÉN
|
||||||
|
AHORA ESTÁ COMENZANDO A LEER LAS INSTRUCCIONES, ¿¿¿CIERTO???
|
||||||
|
NOSOTROS PODRÍAMOS SIMPLEMENTE ROMPER ESTOS DISPOSITIVOS EN LA
|
||||||
|
FÁBRICA ANTES DE DESPACHARLOS, ¿SABE?
|
||||||
|
-- Dave Barry, "¡Lea Esto Primero!"
|
||||||
|
|
||||||
|
|
||||||
|
Descripción
|
||||||
|
===========
|
||||||
|
|
||||||
|
Window Maker es el gestor de ventanas GNU para el Sistema de Ventanas X. Fue
|
||||||
|
diseñado para emular la apariencia y funcionalidad de parte del GUI de NEXTSTEP(mr).
|
||||||
|
Procura ser relativamente rápido y pequeño, rico en características, fácil de configurar
|
||||||
|
y usar, con una simple y elegante apariencia sacada desde NEXTSTEP(mr).
|
||||||
|
|
||||||
|
Window Maker fue diseñado teniendo en mente la integración con GNUstep y por eso
|
||||||
|
es el gestor de ventanas "oficial". Es también parte del proyecto GNU (www.gnu.org)
|
||||||
|
. Lea mas sobre GNUstep más adelante en este archivo.
|
||||||
|
|
||||||
|
|
||||||
|
Pistas (información dada por las aplicaciones para integrarse bien con el gestor de
|
||||||
|
ventanas) para Motif(tm), OPEN LOOK(tm), KDE y GNOME también son soportados.
|
||||||
|
Entonces puede reemplazar cualquiera de los gestores de ventana para estos entornos
|
||||||
|
con Window Maker manteniendo la mayoría, si no todo, de la funcionalidad del
|
||||||
|
gestor de ventanas nativo.
|
||||||
|
|
||||||
|
Window Maker antes se llamaba WindowMaker.
|
||||||
|
|
||||||
|
Window Maker no tiene relación con Windowmaker, el software para
|
||||||
|
hacer ventanas y puertas.
|
||||||
|
|
||||||
|
|
||||||
|
Documentación
|
||||||
|
=============
|
||||||
|
|
||||||
|
Lea antes de preguntar.
|
||||||
|
|
||||||
|
* Los archivos README distribuidos por todas partes del árbol de fuentes
|
||||||
|
contienen información relacionada al contenido en los directorios.
|
||||||
|
|
||||||
|
* INSTALL tiene instrucciones de instalación y algunos consejos cuando tenga
|
||||||
|
algún problema. Significa que debería leerlo antes de la instalación.
|
||||||
|
No fue escrito solo para ocupar espacio en el paquete...
|
||||||
|
|
||||||
|
* FAQ: Preguntas Frecuentes. LEALO!!! FAQ.I18N es para
|
||||||
|
preguntas relacionadas con la internacionalización.
|
||||||
|
|
||||||
|
* NEWS: lista los cambios visibles por el usuario desde la versión anterior.
|
||||||
|
Léalo si está actualizando.
|
||||||
|
|
||||||
|
* MIRRORS: algunos lugares alternativos donde puede obtener Window Maker,
|
||||||
|
incluyendo paquetes de Window Maker específicos para ciertas plataformas.
|
||||||
|
|
||||||
|
* BUGFORM: uselo para enviar reportes de errores. Por favor uselo.
|
||||||
|
|
||||||
|
* ChangeLog: ¿que cambió desde la versión anterior?
|
||||||
|
|
||||||
|
* BUGS: lista de errores conocidos.
|
||||||
|
|
||||||
|
*** Tutorial
|
||||||
|
|
||||||
|
Hay un tutorial mantenido por Georges Tarbouriech en:
|
||||||
|
|
||||||
|
http://www.linuxfocus.org/~georges.t/
|
||||||
|
|
||||||
|
*** Guía del Usuario
|
||||||
|
|
||||||
|
La Guía del Usuario de Window Maker puede ser bajada desde el ftp oficial
|
||||||
|
o por sitios web.
|
||||||
|
Puede también ser vista en formato HTML en:
|
||||||
|
|
||||||
|
http://people.delphi.com/crc3419/WMUserGuide/index.htm
|
||||||
|
|
||||||
|
La Guía del Usuario explica como usar Window Maker, los archivos de configuración
|
||||||
|
y opciones.
|
||||||
|
|
||||||
|
*** man pages
|
||||||
|
|
||||||
|
Tipee "man wmaker" en el prompt del shell para obtener ayuda general sobre Window Maker.
|
||||||
|
|
||||||
|
|
||||||
|
Directorios y Archivos en el Árbol de Fuentes
|
||||||
|
=============================================
|
||||||
|
|
||||||
|
* Install es un script para configurar y compilar Window Maker de una forma
|
||||||
|
fácil (no es que la forma normal sea difícil, pero...).
|
||||||
|
|
||||||
|
* AUTORES: los créditos
|
||||||
|
|
||||||
|
* TODO: planes para el futuro.
|
||||||
|
|
||||||
|
* contrib/ tiene algunos parches aportados que no están soportados por Window Maker
|
||||||
|
porque entran en conflicto con la filosofía de diseño de los desarrolladores o por
|
||||||
|
alguna otra razón.
|
||||||
|
|
||||||
|
* util/ tiene varios programas utilitarios.
|
||||||
|
|
||||||
|
* WPrefs.app/ es el programa de configuración.
|
||||||
|
|
||||||
|
* src/wconfig.h posee opciones de compilación que puede cambiar para
|
||||||
|
seleccionar algunas opciones/caracteristicas y otras cosas.
|
||||||
|
|
||||||
|
* WINGs/ biblioteca widget para imitación de NEXTSTEP.
|
||||||
|
|
||||||
|
* wrlib/ biblioteca de procesamiento de imagen.
|
||||||
|
|
||||||
|
* po/ posee catálogos de mensajes que son las versiones traducidas de los mensajes
|
||||||
|
mostrados por Window Maker.
|
||||||
|
|
||||||
|
* docklib-x.x.tar.gz es una biblioteca para escribir dockapps.
|
||||||
|
|
||||||
|
SOCORRO!!!
|
||||||
|
==========
|
||||||
|
|
||||||
|
Hay una lista de correo para discutir sobre Window Maker en
|
||||||
|
wm-user@windowmaker.org. Para suscribirse, envie un mensaje que contenga:
|
||||||
|
|
||||||
|
subscribe
|
||||||
|
en el tema del mensaje a wm-user-request@windowmaker.org
|
||||||
|
|
||||||
|
Si tiene algun problema, pregunte aquí (después de leer los docs, por supuesto). Es
|
||||||
|
más probable que las personas de la lista sepan contestar sus preguntas
|
||||||
|
que nosotros. Para reportes de errores use el BUGFORM.
|
||||||
|
|
||||||
|
Si tiene un problema con una versión precompilada de Window Maker
|
||||||
|
(rpm, deb etc), primero pregunte a la persona que hizo el paquete.
|
||||||
|
|
||||||
|
NOTA IMPORTANTE: cuando pida ayuda (en la lista de correo o a los desarrolladores,
|
||||||
|
directamente) *siempre* envie información sobre el sistema que está usando. Puede
|
||||||
|
usar la sección de información del sistema al final del BUGFORM como una guía.
|
||||||
|
Otra cosa: por favor no envie correo HTML.
|
||||||
|
|
||||||
|
También hay un canal de IRC #windowmaker en openprojects. Únase aquí,
|
||||||
|
conecte su cliente de irc a irc.openprojects.net, irc.linux.com o algún otro
|
||||||
|
servidor de esa red.
|
||||||
|
|
||||||
|
GNUstep
|
||||||
|
=======
|
||||||
|
|
||||||
|
GNUStep es un completo sistema de desarrollo orientado a objetos, basado en la
|
||||||
|
especificación OpenStep liberada por NeXT(tm) (ahora Apple(tm) y Sun(tm)). Ello
|
||||||
|
proveerá todo lo que se necesita para producir aplicaciones multiplataforma,
|
||||||
|
orientadas a objetos, gráficas (y no gráficas); suministrando dentro de otras cosas,
|
||||||
|
bibliotecas base del sistema, una estructura de alto nivel para aplicaciones GUI que
|
||||||
|
usan un modelo de imagenes de tipo Display PostScript(tm) (DGS), objetos para acceso
|
||||||
|
a bases de datos relacionales, objetos distribuidos y un entorno de desarrollo gráfico,
|
||||||
|
con herramientas como un modelador de interfaces, un sistema para administración del
|
||||||
|
proyecto (central de proyecto) y otras herramientas.
|
||||||
|
|
||||||
|
El sistema de desarrollo de GNUStep será usado para crear un entorno de usuario,
|
||||||
|
con todo lo necesario para una completa interface gráfica de usuario, tal como
|
||||||
|
un visualizador de archivos, editores de texto y otras aplicaciones. Note que el
|
||||||
|
entorno de usuario (o "entorno de escritorio") es solo un pequeña parte de todo
|
||||||
|
el proyecto GNUStep y por lo tanto no "compite" con otros proyectos como KDE o GNOME,
|
||||||
|
simplemente porque son cosas completamente diferentes.
|
||||||
|
|
||||||
|
Para más información sobre el proyecto GNUStep, visite: http://www.gnustep.org y
|
||||||
|
http://gnustep.current.nu
|
||||||
|
|
||||||
|
|
||||||
|
Ejecutando multiples instancias de Window Maker
|
||||||
|
===============================================
|
||||||
|
|
||||||
|
No es una buena idea eejcutar más de una instancia de Window Maker desde
|
||||||
|
el mismo usuario (ya que wmaker usará los mismos archivos de configuración)
|
||||||
|
al mismo tiempo. Podría obtener un comportamiento inesperado cuando Window
|
||||||
|
Maker actualiza sus archivos de configuración.
|
||||||
|
|
||||||
|
Si de verdad desea hacer esto, intente ejecutar Window Maker con la opción
|
||||||
|
de linea de comando --static ya que así no actualizará o cambiará ninguno de los
|
||||||
|
archivos de configuración.
|
||||||
|
|
||||||
|
Soporte para Sonido
|
||||||
|
===================
|
||||||
|
|
||||||
|
El sonido es soportado por los sistemas Linux y FreeBSD con el uso de
|
||||||
|
un módulo distribuido separadamente llamado WSoundServer. Hay también
|
||||||
|
una herramienta de configuracion gráfica para definir sus sonidos llamada
|
||||||
|
WSoundPref.
|
||||||
|
Puede bajar esto en:
|
||||||
|
http://shadowmere.student.utwente.nl/
|
||||||
|
|
||||||
|
Note que debe compilar Window Maker con el parámetro --enable-sound
|
||||||
|
y definir la opción DisableSound a NO.
|
||||||
|
|
||||||
|
|
||||||
|
Ajuste de Rendimiento.
|
||||||
|
=====================
|
||||||
|
Si quiere disminuir el uso de memoria por parte de Window Maker y mejorar el
|
||||||
|
rendimiento, manteniendo una linda apariencia y buena funcionalidad, siga los
|
||||||
|
items de abajo:
|
||||||
|
|
||||||
|
- use texturas sólidas para todo, principalmente barras de título y menúes.
|
||||||
|
Si quiere un escritorio de aspecto lindo, use el estilo Tradicional.
|
||||||
|
- Apague NewStyle y Superfluous
|
||||||
|
- No una muchos atajos al menú y mantenga solo los items esenciales en el menú.
|
||||||
|
- Active DisableClip
|
||||||
|
- edite wconfig.h y desactive el NUMLOCK_HACK y lo mismo con las características
|
||||||
|
que no use (tenga en mente que algunos de los #defines podrían no funcionar,
|
||||||
|
ya que ellos no están completamente soportados). Asegúrese de mantener siempre
|
||||||
|
Numlock y ScrollLock apagados.
|
||||||
|
- Active DisableAnimations. Puede también #undefine ANIMATIONS en wconfig.h
|
||||||
|
- quite las entradas por defecto IconPath y PixmapPath para contener solo las
|
||||||
|
rutas que en verdad tiene en su sistema.
|
||||||
|
- no use imágenes grandes en el fondo raíz.
|
||||||
|
- quite el soporte para los formatos de imagen que no use.
|
||||||
|
- para reducir el uso de la memoria, desactive el caché de ícono, definiendo
|
||||||
|
la variable de entorno RIMAGE_CACHE a 0. Si quiere aumentar el rendimiento
|
||||||
|
a expensas del uso de la memoria, defina este valor a un valor igual al
|
||||||
|
número de íconos distintos que use.
|
||||||
|
|
||||||
|
Control del Mouse por Teclado
|
||||||
|
=============================
|
||||||
|
|
||||||
|
Muchas personas preguntan sobre agregar control por teclado al mouse, como
|
||||||
|
en fvwm, pero Window Maker no tendrá tal característica. La extensión XKB
|
||||||
|
soporta simulación de mouse desde el teclado, de una manera mucho más poderosa
|
||||||
|
que cualquier otra simulación hecha por un administrador de ventanas.
|
||||||
|
|
||||||
|
Para activarlo, presione la combinación de teclas Control+Shift+NumLock o
|
||||||
|
Shift+NumLock. Debiera escuchar el beep del parlante. Para desactivarlo,
|
||||||
|
haga lo mismo.
|
||||||
|
|
||||||
|
Para controlar el mouse el teclado numérico se usa así:
|
||||||
|
- 4 (flecha izquierda), 7 (Home), 8 (flecha arriba), 9 (PgUP), 6 (flecha derecha),
|
||||||
|
3 (PgDn), 2 (flecha abajo) y 1 (Fin) mueve el mouse a la correspondiente
|
||||||
|
dirección;
|
||||||
|
- sosteniendo una de las teclas de arriba y luego sosteniendo la tecla 5 moverá
|
||||||
|
el puntero más rápido;
|
||||||
|
- / seleccionará el primer botón del mouse (botón izquierdo);
|
||||||
|
- * seleccionará el segundo botón del mouse (botón del medio);
|
||||||
|
- - seleccionará el tercer botón del mouse (botón derecho);
|
||||||
|
- 5 hará un click con el botón actualmente seleccionado del mouse;
|
||||||
|
- + hará un doble click con el botón actualmente seleccionado;
|
||||||
|
- 0 (Ins) cliqueará y mantendrá el botón seleccionado actualmente;
|
||||||
|
- . (Del) liberará el botón seleccionado actualmente que fue anteriormente
|
||||||
|
cliqueado con la tecla 0 (Ins).
|
||||||
|
|
||||||
|
Los valores anteriores de las teclas funcionarán en un servidor X XFree86 3.2
|
||||||
|
(X11R6.1) pero su alcance puede variar.
|
||||||
|
|
||||||
|
Como hacer un gdb backtrace
|
||||||
|
===========================
|
||||||
|
|
||||||
|
Backtraces pueden ayudarnos a arreglar errores que hicieron que Window Maker falle.
|
||||||
|
Si encuentra un bug que hace fallar a Window Maker, por favor envie un backtrace con su
|
||||||
|
reporte de error.
|
||||||
|
|
||||||
|
Para hacer un backtrace útil, necesita un archivo core con información de depuración
|
||||||
|
producida por Window Maker cuando falló. Debería haber sido instalado sin stripping también.
|
||||||
|
|
||||||
|
Para compilar wmaker con información de depuración:
|
||||||
|
|
||||||
|
./configure
|
||||||
|
make CFLAGS=-g
|
||||||
|
|
||||||
|
Si obtiene el cuadro de diálogo que le dice que wmaker falló y le
|
||||||
|
pregunta que hacer, respóndale "Abortar y dejar un archivo core"
|
||||||
|
|
||||||
|
script
|
||||||
|
cd src
|
||||||
|
gdb .libs/wmaker path_to_the_core_file
|
||||||
|
|
||||||
|
Luego, en el prompt gdb escriba "bt". Salga de gdb escribiendo "quit"
|
||||||
|
y luego, en el prompt del shell, scriba "exit"
|
||||||
|
|
||||||
|
El archivo llamado typescript contendrá el backtrace.
|
||||||
|
|
||||||
|
Derechos de Autor y Descargo de Responsabilidad
|
||||||
|
===============================================
|
||||||
|
|
||||||
|
Window Maker está registrado por Alfredo K. Kojima y está licensiado por la
|
||||||
|
Licensia Pública General GNU. Lea el archivo COPYING para leer la licensia
|
||||||
|
completa.
|
||||||
|
|
||||||
|
Los íconos que son distribuidos con este programa y fueron hechos por Marco
|
||||||
|
van Hylckama Vlieg, están licenciados por la Licencia Pública General GNU.
|
||||||
|
Lea el archivo COPYING para leer la licencia completa.
|
||||||
|
|
||||||
|
Los íconos listados en COPYING.WTFPL y son distribuidos en este programa
|
||||||
|
fueron hechos por Banlu Kemiyatorn (]d), están licenciados por la
|
||||||
|
"do What The Fuck you want to Public License". Lea el archivo COPYING.WTFPL
|
||||||
|
para leer la licencia completa.
|
||||||
|
|
||||||
|
NeXT, OpenStep y NEXTSTEP son marcas registradas de NeXT Computer, Inc.
|
||||||
|
Todas las otras marcas registradas son propiedad de sus respectivos dueños.
|
||||||
|
|
||||||
|
Los autores se reservan el derecho de hacer cambios en el software sin previo
|
||||||
|
aviso.
|
||||||
|
|
||||||
|
Autores
|
||||||
|
=======
|
||||||
|
|
||||||
|
Alfredo K. Kojima <kojima@windowmaker.org>
|
||||||
|
Dan Pascu <dan@windowmaker.org>
|
||||||
|
]d <id@windowmaker.org>
|
||||||
|
|
||||||
|
Por favor no nos haga preguntas antes de leer la documentación (especialmente
|
||||||
|
la FAQ, este archivo y los archivos INSTALL) y sobre cosas "cool" que ve en
|
||||||
|
las capturas de pantalla del escritorio de las personas.
|
||||||
|
|
||||||
|
El archivo AUTHORS contiene una lista de las personas que han contribuido
|
||||||
|
con el proyecto. El nombre de las personas que han ayudado con localization
|
||||||
|
(traducción) se puede encontrar en po/README y Window Maker/README
|
||||||
|
|
||||||
|
Si tiene algún comentario, arreglos y reportes de errores (complete BUGFORMs)
|
||||||
|
y enviémelos a developers@windowmaker.org
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
traducido por Efraín Maximiliano Palermo <max_drake2001@yahoo.com.ar>
|
||||||
28
README.pt
28
README.pt
@@ -210,34 +210,6 @@ Observe que voc
|
|||||||
flag --enable-sound e definindo a opção DisableSound para NO.
|
flag --enable-sound e definindo a opção DisableSound para NO.
|
||||||
|
|
||||||
|
|
||||||
Suporte ao OpenL**k
|
|
||||||
===================
|
|
||||||
|
|
||||||
Acredito que muitos usuários, principalmente os do mundo acadêmico,
|
|
||||||
tenham que usar aplicações escritas em toolkits OpenL**k, então o suporte
|
|
||||||
para estes aplicativos deve ser de algum uso.
|
|
||||||
|
|
||||||
Para ativar, use o --enable-openlook quando rodar o configure. Note
|
|
||||||
que nem tudo está implementado.
|
|
||||||
|
|
||||||
As opções implementadas incluem hints de decoração e o push-pin.
|
|
||||||
Coisas não implementadas incluem _SUN_WINDOW_STATE (the compose led
|
|
||||||
state stuff), coisas relacionadas ao "drag and drop", cabeçalho (não
|
|
||||||
tenho certeza do que é) e o string footer.
|
|
||||||
|
|
||||||
Por favor me dêem retorno se algo não funcionar. Se a opção já está
|
|
||||||
implementada, mas não está funcionando por causa de um bug, eu tentarei
|
|
||||||
corrigí-la. Se é uma característica ainda não implementada e você mencionar
|
|
||||||
que é importante (ie: não somente cosmética), eu considerarei a sua
|
|
||||||
implementação.
|
|
||||||
|
|
||||||
O estado "out" do pushpin é emulado como um botão de fechar pressionado.
|
|
||||||
Clique no botão para fazer com que ele fique despressionado, o que
|
|
||||||
corresponde ao estado "pinned-in" do pushpin. Se você pressionar de novo
|
|
||||||
o botão de fechar despressionado, ele vai agir como um botão de fechar
|
|
||||||
normal: vai fechar a janela.
|
|
||||||
|
|
||||||
|
|
||||||
Ajuste da Performance
|
Ajuste da Performance
|
||||||
====================
|
====================
|
||||||
|
|
||||||
|
|||||||
20
TODO
20
TODO
@@ -7,14 +7,17 @@ Do ASAP:
|
|||||||
- fix RemakeStackList() to account for transient windows
|
- fix RemakeStackList() to account for transient windows
|
||||||
- blink border of clients with UrgencyHint set between red and black
|
- blink border of clients with UrgencyHint set between red and black
|
||||||
- finish session stuff
|
- finish session stuff
|
||||||
- add multiline support for balloons
|
|
||||||
- remove colors_per_channel stuff from wmaker after?
|
- remove colors_per_channel stuff from wmaker after?
|
||||||
|
+ finish the ability to browse for files/dirs in the WPrefs menu editor
|
||||||
|
- check whether window states are being saved/restored properly via netwm
|
||||||
|
on restart/crash-restart (grep for XXX/TODO)
|
||||||
|
|
||||||
Need to do:
|
Need to do:
|
||||||
===========
|
===========
|
||||||
- put a "Do not save workspace state" in the exit confirmation dialog
|
- figure out a better gnustep path for wprefs.app installation
|
||||||
|
- impelment a generic pixmap type, which receives attributes
|
||||||
|
(scaled/maxscaled/centered/tiled, smoothed, size/position, ...)
|
||||||
- allow user to select/restore default root menu from wprefs
|
- allow user to select/restore default root menu from wprefs
|
||||||
- fix windoze cycle window patch
|
|
||||||
- support for X11R6.4 extension for getting extra visual info in wrlib's
|
- support for X11R6.4 extension for getting extra visual info in wrlib's
|
||||||
automatic best context guessing
|
automatic best context guessing
|
||||||
- docklet to control AccessX (keyboard accessibility) functions
|
- docklet to control AccessX (keyboard accessibility) functions
|
||||||
@@ -22,14 +25,17 @@ Need to do:
|
|||||||
- add function to directly make a thumbnail of an image, using the
|
- add function to directly make a thumbnail of an image, using the
|
||||||
functionality provided by the image libraries to load a minimal
|
functionality provided by the image libraries to load a minimal
|
||||||
amount of data.
|
amount of data.
|
||||||
+ investigate memory leaks
|
|
||||||
- rewrite defaults/wdefaults stuff to use WINGs UD stuff. Search list:
|
- rewrite defaults/wdefaults stuff to use WINGs UD stuff. Search list:
|
||||||
~/G/D/WindowMaker /u/l/s/W/D/WindowMaker built-in-defaults
|
~/G/D/WindowMaker /u/l/s/W/D/WindowMaker built-in-defaults
|
||||||
- remake internal string processing to use wchar? unicode?
|
- remake internal string processing to use wchar? unicode?
|
||||||
- add new file for stuff like default commands and dnd commands for
|
- add new file for stuff like default commands and dnd commands for
|
||||||
docked apps, balloons for the dock etc
|
docked apps, balloons for the dock etc
|
||||||
- fix the #define MIN(a,b) stuff. defined in too many places, and maybe
|
- check whether apps with name.class set to empty strings should be treated
|
||||||
replace with WMIN(a,b).
|
like if name.class is NULL.NULL
|
||||||
|
- review the defaults handling code (not to reread after we update a
|
||||||
|
domain if possible, check WINGs apps updating WMWindowAttributes after
|
||||||
|
start making screen to flash on update)
|
||||||
|
|
||||||
|
|
||||||
Maybe some day:
|
Maybe some day:
|
||||||
===============
|
===============
|
||||||
@@ -43,7 +49,7 @@ Never: (so, dont even bother to ask)
|
|||||||
with 2 CPUs ;).
|
with 2 CPUs ;).
|
||||||
- anything that requires the mouse pointer to be jumped by WindowMaker to
|
- anything that requires the mouse pointer to be jumped by WindowMaker to
|
||||||
somewhere. This is *terrible* behaviour. And it's not just IMO.
|
somewhere. This is *terrible* behaviour. And it's not just IMO.
|
||||||
- rewrite to use Gtk... I wont even explain why...
|
- rewrite to use Gtk... I wont even bother to explain why...
|
||||||
|
|
||||||
|
|
||||||
- ICCCM 2.0: ICCCM 2.0 (not 1.0, which is what everybody supports so so) is
|
- ICCCM 2.0: ICCCM 2.0 (not 1.0, which is what everybody supports so so) is
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
Makefile Makefile.in
|
Makefile Makefile.in
|
||||||
get-wings-flags get-wutil-flags
|
get-wings-flags get-wutil-flags
|
||||||
.libs
|
.libs *.pc
|
||||||
.psrc .inslog2 tca.map tca.log
|
.psrc .inslog2 tca.map tca.log pchdir *.rpt
|
||||||
*.rpt
|
|
||||||
|
|||||||
182
WINGs/ChangeLog
182
WINGs/ChangeLog
@@ -1,3 +1,181 @@
|
|||||||
|
Changes since wmaker 0.80.1:
|
||||||
|
............................
|
||||||
|
|
||||||
|
- Added WMSetConnectionShutdownOnClose()
|
||||||
|
- Added an extra member to the ConnectionDelegate: canResumeSending
|
||||||
|
see NEWS for details.
|
||||||
|
- WMDrawString() and WMDrawImageString() now take WMColor instead of GC as
|
||||||
|
arguments. WMDrawImageString() receives 2 colors (text & background).
|
||||||
|
This is to allow easy extension for Xft/Xrender and hide X low level details
|
||||||
|
Read NEWS for details since this will break backward compatibility.
|
||||||
|
- Added alpha channel to WMColor. 2 new functions also:
|
||||||
|
WMCreateRGBAColor() and WMSetColorAlpha()
|
||||||
|
- Miscelaneous code cleanups in wtext.c
|
||||||
|
- Added Xft2 support in WINGs (for drawing antialiased fonts with transparency).
|
||||||
|
- New options in WMGLOBAL: AntialiasedText. Check NEWS for details.
|
||||||
|
- Fixed some improper calls to snprintf in wfont.c
|
||||||
|
- Added double buffering when drawing a WMFrame title with an antialiased font
|
||||||
|
to avoid flickering.
|
||||||
|
- Added double buffering when drawing WMList items to avoid flickering.
|
||||||
|
Double buffering for list also works for user drawn lists. Read NEWS for
|
||||||
|
details and incompatibilities introduced by this change.
|
||||||
|
- Added WMGetColorAlpha(WMColor *color)
|
||||||
|
- Better outline when drawing balloons.
|
||||||
|
- Added WMCreateFontWithAttributes()
|
||||||
|
- You can now pass "SystemFont", "BoldSystemFont", "SystemFont-##" or
|
||||||
|
"BoldSystemFont-##", with ## being the font size to any font creating
|
||||||
|
function to create a font with the (bold) system font font specification.
|
||||||
|
- Added WMCopyFontWithChanges(). This is a more generic and powerful function
|
||||||
|
meant to replaces the obsoleted WMEmphasizeFont(), WMNormalizeFont(),
|
||||||
|
WMStrenghtenFont() and the other similar functions. To get the same effect
|
||||||
|
you pass some predefined structs to it: WFANormal, WFABold, WFAEmphasized,
|
||||||
|
etc which are declared in WINGs.h).
|
||||||
|
- Fixed a bug with empty frame titles (Alexey Voinov <voins@voins.program.ru>)
|
||||||
|
- Added WMGetWidgetBackgroundColor()
|
||||||
|
- Code cleanup in wtext.c
|
||||||
|
- Fixed a memory leak in wfontpanel.c
|
||||||
|
- Fixed WMGetTextDefaultColor() not to retain the returned color. It returns
|
||||||
|
only a reference to the internal color, which you shouldn't release
|
||||||
|
- Added wstrndup()
|
||||||
|
- Added WMGetFontName()
|
||||||
|
- Added fontpanel callback
|
||||||
|
- Added WMSetTableViewHasHorizontalScroller()
|
||||||
|
- Fixed bug that could cause SIGSEGV by accessing beyond the end of text in
|
||||||
|
a WINGs textfield widget.
|
||||||
|
- Fixed small memory leak in the font panel code.
|
||||||
|
- Fixed call to qsort in WMSortArray.
|
||||||
|
- Fixed a memleak in the file panel.
|
||||||
|
- Double/triple-click selection in text widgets
|
||||||
|
(Vitaly Ovtchinnikov <ov@rbcmail.ru>)
|
||||||
|
- Fixed bug in tableview (clicked row callback got incorrect row)
|
||||||
|
(Carlos Torres <vlaadbrain@operamail.com>)
|
||||||
|
- Fixed bug in resizing a scrollview
|
||||||
|
- Fixed bug with wrong text wrapping (Alexey Voinov <voins@voins.program.ru>)
|
||||||
|
- Added wmkrect()
|
||||||
|
- Added xdnd v3 support (Sylvain Reynal <sreynal@nerim.net>)
|
||||||
|
- Fixed and enhanced text wrapping.
|
||||||
|
|
||||||
|
|
||||||
|
Changes since wmaker 0.80.0:
|
||||||
|
............................
|
||||||
|
|
||||||
|
- fixed a bug in wfindfile() (rewrote wfindfile() with better logic).
|
||||||
|
- separated the font caches for normal fonts and fontsets in WINGs (they can
|
||||||
|
have the same names and collide in the cache giving unwanted results)
|
||||||
|
- fixed labels not to display '\n' as a character if multiple '\n' are passed
|
||||||
|
but just skip to the next line.
|
||||||
|
- better warning when importing non-digit characters in PropList Data.
|
||||||
|
- rewrote WMBox to use a WMArray for subviews. with this change fixed a bug
|
||||||
|
about arranging subviews after removing one and a memleak occuring in the
|
||||||
|
same case.
|
||||||
|
- Fixed WMGetViewScreenPosition() to consider the window decorations.
|
||||||
|
- Added ability to enable/disable individual WMTableViewItems.
|
||||||
|
- Fixed textfields regarding interpretation of special keys with modifiers.
|
||||||
|
- Fixed some functions that accept a boolean flag as a paramater, to set only
|
||||||
|
1 or 0 for the flag value, not the flag passed by the user.
|
||||||
|
- Added 2 functions to retrieve the default system fonts:
|
||||||
|
WMDefaultSystemFont(WMScreen *scr) and WMDefaultBoldSystemFont(WMScreen *scr)
|
||||||
|
- Added WMSetButtonImageDimsWhenDisabled() and WMGetButtonEnabled()
|
||||||
|
- Cleaned-up the header files of functions/vars declared but not implemented
|
||||||
|
- Added WMGetTextFieldDelegate()
|
||||||
|
|
||||||
|
|
||||||
|
Changes since wmaker 0.70.0:
|
||||||
|
............................
|
||||||
|
|
||||||
|
- added an internal strcasecmp() (only on systems where is not present)
|
||||||
|
- removed some redundant includes of ../src/config.h when wconfig.h is
|
||||||
|
included too
|
||||||
|
- removed a wsyserror() message when reading a property list from file
|
||||||
|
(the programmer should decide if to give that message or just ignore).
|
||||||
|
- added a 'Bool recursive' flag to WMMergePLDictionaries()
|
||||||
|
- added WMSubtractPLDictionaries()
|
||||||
|
|
||||||
|
|
||||||
|
Changes since wmaker 0.65.0:
|
||||||
|
............................
|
||||||
|
|
||||||
|
- fixed problem with WINGs based apps exiting with a "X_RotateProperties"
|
||||||
|
related error when text was selected in a textfiled.
|
||||||
|
- moved wstrdup(), wstrconcat() and wstrappend() from memory.c to string.c
|
||||||
|
- added property list handling code making libPropList unnecessary and
|
||||||
|
obsolete. Backward compatibility is provided through the
|
||||||
|
WINGs/proplist-compat.h header file which has #defines from old libPropList
|
||||||
|
function names to new function names with minimal changes. Read this
|
||||||
|
header file and the NEWS file for more details about this subject.
|
||||||
|
- Renamed WMGetUDAllKeys() to WMGetUDKeys()
|
||||||
|
|
||||||
|
|
||||||
|
Changes since wmaker 0.64.0:
|
||||||
|
............................
|
||||||
|
|
||||||
|
- made programmatic scroller changes send notifications
|
||||||
|
- replaced WMSetBoxExpandsToParent with WMSetViewExpands...
|
||||||
|
- added WMGetLabelFont()
|
||||||
|
- added WMAddPersistentTimerHandler()
|
||||||
|
- Moved all internal handlers (timer, idle and input) to handlers.c
|
||||||
|
- simplified wevent.c and wutil.c.
|
||||||
|
- fixed handling of input with poll (was broken)
|
||||||
|
- fixed mem leak that occured when input handling was done with poll
|
||||||
|
- simpler and more straightforward event handling for timer, idle, input
|
||||||
|
and X events (also fixed some problems the old handling logic had)
|
||||||
|
- moved timer, idle and input handler definitions and prototypes from
|
||||||
|
WINGs.h to WUtil.h because they're not GUI related.
|
||||||
|
- better and more robust handling of events (timer, idle, input, X) in
|
||||||
|
WMMaskEvent(). Also fixed a bug where input and timer events were not
|
||||||
|
treated for undefined periods of time under some circumstances.
|
||||||
|
- fixed secure textfields not to allow text selection, to avoid compromising
|
||||||
|
sensitive information by pasting it to a terminal.
|
||||||
|
- replaced wmkrange(), wmkpoint() and wmksize() functions with macros.
|
||||||
|
- added WMRemoveFromArrayMatching(array, match, cdata), which will remove the
|
||||||
|
first element in the array that is matched by match(item, cdata)==True.
|
||||||
|
- added WMArrayFirst(), WMArrayLast(), WMArrayNext() and WMArrayPrevious()
|
||||||
|
functions and also WM_ITERATE_ARRAY() and WM_ETARETI_ARRAY() macros, to make
|
||||||
|
interfaces to WMBag and WMArray similar and to make life a little simpler
|
||||||
|
when iterating through all elements of an array.
|
||||||
|
- replaced bags with arrays wherever appropriate. This will improve
|
||||||
|
performance a bit.
|
||||||
|
- replaced some recursive code with iterative code in selection.c
|
||||||
|
- added WMCreateBlendedPixmapFromRImage()
|
||||||
|
- small API change:
|
||||||
|
1. Renamed WMSetApplicationIconImage(), WMGetApplicationIconImage() and
|
||||||
|
WMSetWindowMiniwindowImage() to respectively WMSetApplicationIconPixmap(),
|
||||||
|
WMGetApplicationIconPixmap() and WMSetWindowMiniwindowPixmap()
|
||||||
|
They operate on a WMPixmap which is practically an X Pixmap with no alpha
|
||||||
|
channel information and the new name is more suggestive and also leaves
|
||||||
|
room for the new functions added for operating on images with alpha info.
|
||||||
|
2. Added WMSetApplicationIconImage() and WMGetApplicationIconImage() which
|
||||||
|
operate on an RImage and store alpha information too.
|
||||||
|
3. Added WMCreateApplicationIconBlendedPixmap() which will take the image
|
||||||
|
set by WMSetApplicationIconImage() and will combine it with a color.
|
||||||
|
If color is NULL it will blend using the default panel color (#aeaaae)
|
||||||
|
All these changes will allow WINGs to handle images with alpha blending
|
||||||
|
correctly in panels and wherever else needed. More about in NEWS.
|
||||||
|
- updated panels to use the newly available RImages if present and fallback
|
||||||
|
to old WMPixmaps if not, to properly show alpha blended images.
|
||||||
|
- replaced some still left malloc's with wmalloc's.
|
||||||
|
- fixed a bug in WMReparentWidget()
|
||||||
|
- added WMReparentWidget() to WINGs.h
|
||||||
|
- fixed a bug that made the scroller knob jump backwards when dragged (this
|
||||||
|
bug had no relation with the behavior that #define STRICT_NEXT_BEHAVIOUR
|
||||||
|
attempts to accomplish).
|
||||||
|
- fixed scrolling direction with mouse wheel for horizontal scroller.
|
||||||
|
|
||||||
|
|
||||||
|
changes since wmaker 0.63.1:
|
||||||
|
............................
|
||||||
|
- added WMRunModalLoop() and WMBreakModalLoop()
|
||||||
|
- added WMSetBoxExpandsToParent()
|
||||||
|
- added WMRemoveBoxSubview()
|
||||||
|
- moved WINGs headers in a WINGs subdirectory when installed.
|
||||||
|
use #include <WINGs/header_file_name> in your application from now on.
|
||||||
|
Also updated get-{wings|wutil}-flags.
|
||||||
|
- Fixed a mem leak in WMList.
|
||||||
|
- Fixed a bug that caused sigsegv for a WMList with more than 32767 items.
|
||||||
|
- Added an example of how to create a server type program with WMConnection.
|
||||||
|
- added WMOpenScreen()
|
||||||
|
|
||||||
|
|
||||||
changes since wmaker 0.62.1:
|
changes since wmaker 0.62.1:
|
||||||
............................
|
............................
|
||||||
- added WRuler widget
|
- added WRuler widget
|
||||||
@@ -58,6 +236,7 @@ changes since wmaker 0.62.1:
|
|||||||
the program name prepended to it. Similar to wwarning(), except that it
|
the program name prepended to it. Similar to wwarning(), except that it
|
||||||
doesn't add "warning:" in the output message.
|
doesn't add "warning:" in the output message.
|
||||||
- added WMBox widget
|
- added WMBox widget
|
||||||
|
- added WMAddTabViewItemWithView()
|
||||||
- added W_SetViewCursor()
|
- added W_SetViewCursor()
|
||||||
- made Extra widgets library
|
- made Extra widgets library
|
||||||
- added table widget in Extras library
|
- added table widget in Extras library
|
||||||
@@ -83,7 +262,8 @@ changes since wmaker 0.62.1:
|
|||||||
as a result the shaded windows didn't go away when closed. The non-shaded
|
as a result the shaded windows didn't go away when closed. The non-shaded
|
||||||
windows were unmapped on close but not destroyed either so they only
|
windows were unmapped on close but not destroyed either so they only
|
||||||
apparently went away, but continued to use memory).
|
apparently went away, but continued to use memory).
|
||||||
|
- Fixed a bug in the hashtable code which free'd the whole item instead of
|
||||||
|
just the item key in WMResetHashTable() (possible source of SIGSEGVs)
|
||||||
|
|
||||||
|
|
||||||
changes since wmaker 0.62.0:
|
changes since wmaker 0.62.0:
|
||||||
|
|||||||
@@ -1,3 +1,2 @@
|
|||||||
Makefile Makefile.in
|
Makefile Makefile.in
|
||||||
.psrc .inslog2 tca.map tca.log
|
.psrc .inslog2 tca.map tca.log pchdir *.rpt
|
||||||
*.rpt
|
|
||||||
|
|||||||
@@ -17,13 +17,16 @@ it), there are some ways to handle it:
|
|||||||
This is by far the best method, since it will assure you that if you
|
This is by far the best method, since it will assure you that if you
|
||||||
enqueue more than one notification to remove the same connection, they will
|
enqueue more than one notification to remove the same connection, they will
|
||||||
be coalesced, and called only once.
|
be coalesced, and called only once.
|
||||||
2. In your observer, put the died/closed connection in a bag, and destroy all
|
|
||||||
the connections present in the bag, in your main loop, after you call the
|
2. In your observer, put the died/closed connection in an array or bag, and
|
||||||
WHandleEvents()/WMHandleEvent(). Also closing the connection can be done
|
destroy all the connections present in the array/bag, in your main loop,
|
||||||
before putting the connection in the bag, but is optional as noted above.
|
after you call the WHandleEvents()/WMHandleEvent(). Also closing the
|
||||||
In this case you need to make sure you don't put in the bag the same
|
connection can be done before putting the connection in the array/bag, but
|
||||||
connection more than once, in case the DieNotification is sent more that
|
is optional as noted above. In this case you need to make sure you don't
|
||||||
once to you. This is automagically solved by method 1.
|
put in the array/bag the same connection more than once, in case the
|
||||||
|
DieNotification is sent more that once to you. This is automagically solved
|
||||||
|
by method 1.
|
||||||
|
|
||||||
3. In case it's your only connection, and you plan to exit if it was closed or
|
3. In case it's your only connection, and you plan to exit if it was closed or
|
||||||
died, then you can safely close/remove it, and exit. As long as you no
|
died, then you can safely close/remove it, and exit. As long as you no
|
||||||
longer access it, there is no problem.
|
longer access it, there is no problem.
|
||||||
@@ -33,10 +36,11 @@ it), there are some ways to handle it:
|
|||||||
means until your code gets back to the main loop). This is almost always
|
means until your code gets back to the main loop). This is almost always
|
||||||
very hard to achive and subject to hidden errors. I do not recommend this
|
very hard to achive and subject to hidden errors. I do not recommend this
|
||||||
way of handling the died notification. It is ugly and very complicated to
|
way of handling the died notification. It is ugly and very complicated to
|
||||||
handle. If you use it and get plenty of SIGSEGVs then you know why.
|
handle if the program is in a very deeply nested function when it finds out
|
||||||
This method was not presented here to be used, but to show what should
|
that the connection died. If you use it and get plenty of SIGSEGVs then you
|
||||||
be avoided in dealing with the died notification, in case someone gets the
|
know why. This method was not presented here to be used, but to show what
|
||||||
idea to try it this way.
|
should be avoided in dealing with the died notification, in case someone
|
||||||
|
gets the idea to try it this way.
|
||||||
|
|
||||||
|
|
||||||
Note: read/write operations means to use our read/write functions (like
|
Note: read/write operations means to use our read/write functions (like
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
Makefile Makefile.in
|
Makefile Makefile.in
|
||||||
connect fontl puzzle
|
connect server fontl puzzle UserTime.plist
|
||||||
.libs
|
.libs
|
||||||
.psrc .inslog2 tca.map tca.log
|
.psrc .inslog2 tca.map tca.log pchdir *.rpt
|
||||||
*.rpt
|
|
||||||
|
|||||||
@@ -3,12 +3,13 @@
|
|||||||
AUTOMAKE_OPTIONS = no-dependencies
|
AUTOMAKE_OPTIONS = no-dependencies
|
||||||
|
|
||||||
|
|
||||||
noinst_PROGRAMS = connect fontl puzzle
|
noinst_PROGRAMS = connect server fontl puzzle colorpick
|
||||||
|
|
||||||
|
|
||||||
LDADD= $(top_builddir)/WINGs/libWINGs.a $(top_builddir)/wrlib/libwraster.la \
|
LDADD= $(top_builddir)/WINGs/libWINGs.a $(top_builddir)/wrlib/libwraster.la \
|
||||||
@LIBPL@
|
@XFTLIBS@ @INTLIBS@
|
||||||
|
|
||||||
|
colorpick_DEPENDENCIES = $(top_builddir)/WINGs/libWINGs.a
|
||||||
|
|
||||||
fontl_DEPENDENCIES = $(top_builddir)/WINGs/libWINGs.a
|
fontl_DEPENDENCIES = $(top_builddir)/WINGs/libWINGs.a
|
||||||
|
|
||||||
@@ -17,7 +18,12 @@ puzzle_DEPENDENCIES = $(top_builddir)/WINGs/libWINGs.a
|
|||||||
connect_DEPENDENCIES = $(top_builddir)/WINGs/libWUtil.a
|
connect_DEPENDENCIES = $(top_builddir)/WINGs/libWUtil.a
|
||||||
|
|
||||||
connect_LDADD = $(top_builddir)/WINGs/libWUtil.a @LIBRARY_SEARCH_PATH@ \
|
connect_LDADD = $(top_builddir)/WINGs/libWUtil.a @LIBRARY_SEARCH_PATH@ \
|
||||||
@NETLIBS@ @LIBPL@
|
@NETLIBS@ @INTLIBS@
|
||||||
|
|
||||||
|
server_DEPENDENCIES = $(top_builddir)/WINGs/libWUtil.a
|
||||||
|
|
||||||
|
server_LDADD = $(top_builddir)/WINGs/libWUtil.a @LIBRARY_SEARCH_PATH@ \
|
||||||
|
@NETLIBS@ @INTLIBS@
|
||||||
|
|
||||||
|
|
||||||
INCLUDES = -I$(top_srcdir)/WINGs -I$(top_srcdir)/wrlib -I$(top_srcdir)/src \
|
INCLUDES = -I$(top_srcdir)/WINGs -I$(top_srcdir)/wrlib -I$(top_srcdir)/src \
|
||||||
|
|||||||
19
WINGs/Examples/README
Normal file
19
WINGs/Examples/README
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
|
||||||
|
|
||||||
|
Files:
|
||||||
|
-----
|
||||||
|
|
||||||
|
server - server example of using WMConnection. It keeps a database of
|
||||||
|
timeouts for a group of users, allowing one to add/remove
|
||||||
|
users and update the timeouts associated with them.
|
||||||
|
|
||||||
|
connect - client example of using WMConnection. Works with the server
|
||||||
|
program above. Just start both without any parameter and
|
||||||
|
type help in the client to find out how to operate them.
|
||||||
|
Rest is self explanatory.
|
||||||
|
|
||||||
|
puzzle - a nice zuPzel =)
|
||||||
|
|
||||||
|
fontl - a map of all characters with their corresponding ascii,
|
||||||
|
hex, decimal and octal representations.
|
||||||
|
|
||||||
42
WINGs/Examples/colorpick.c
Normal file
42
WINGs/Examples/colorpick.c
Normal file
@@ -0,0 +1,42 @@
|
|||||||
|
|
||||||
|
#include <stdlib.h>
|
||||||
|
#include <stdio.h>
|
||||||
|
#include <WINGs/WINGs.h>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
void showSelectedColor(void *self, void *cdata)
|
||||||
|
{
|
||||||
|
WMColorPanel *panel= (WMColorPanel*)self;
|
||||||
|
|
||||||
|
printf("Selected Color: %s\n", WMGetColorRGBDescription(WMGetColorPanelColor(panel)));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
int main(int argc, char **argv)
|
||||||
|
{
|
||||||
|
Display *dpy;
|
||||||
|
WMScreen *scr;
|
||||||
|
|
||||||
|
WMInitializeApplication("wmcolorpick", &argc, argv);
|
||||||
|
|
||||||
|
dpy = XOpenDisplay("");
|
||||||
|
if (!dpy) {
|
||||||
|
printf("could not open display\n");
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
scr = WMCreateScreen(dpy, DefaultScreen(dpy));
|
||||||
|
|
||||||
|
{
|
||||||
|
WMColorPanel *panel= WMGetColorPanel(scr);
|
||||||
|
|
||||||
|
WMSetColorPanelAction(panel, showSelectedColor, NULL);
|
||||||
|
|
||||||
|
WMShowColorPanel(panel);
|
||||||
|
}
|
||||||
|
|
||||||
|
WMScreenMainLoop(scr);
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
@@ -1,29 +1,17 @@
|
|||||||
/*
|
/*
|
||||||
* WINGs connect.c: example how to create a network client using WMConnection
|
* WINGs connect.c: example how to create a network client using WMConnection
|
||||||
*
|
*
|
||||||
* Copyright (c) 1999 Dan Pascu
|
* Copyright (c) 1999-2003 Dan Pascu
|
||||||
*
|
*
|
||||||
* 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., 675 Mass Ave, Cambridge, MA 02139, USA.
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
#include <stdlib.h>
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
|
|
||||||
#include "WINGs.h"
|
#include <WINGs/WINGs.h>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -41,6 +29,7 @@ static void didInitialize(ConnectionDelegate *self, WMConnection *cPtr);
|
|||||||
|
|
||||||
static ConnectionDelegate socketDelegate = {
|
static ConnectionDelegate socketDelegate = {
|
||||||
NULL, /* data */
|
NULL, /* data */
|
||||||
|
NULL, /* canResumeSending */
|
||||||
NULL, /* didCatchException */
|
NULL, /* didCatchException */
|
||||||
connectionDidDie, /* didDie */
|
connectionDidDie, /* didDie */
|
||||||
didInitialize, /* didInitialize */
|
didInitialize, /* didInitialize */
|
||||||
@@ -51,7 +40,7 @@ static ConnectionDelegate socketDelegate = {
|
|||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
wAbort(Bool foo) /*FOLD00*/
|
wAbort(Bool foo)
|
||||||
{
|
{
|
||||||
exit(1);
|
exit(1);
|
||||||
}
|
}
|
||||||
@@ -102,7 +91,7 @@ inputHandler(int fd, int mask, void *clientData)
|
|||||||
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
didReceiveInput(ConnectionDelegate *self, WMConnection *cPtr) /*FOLD00*/
|
didReceiveInput(ConnectionDelegate *self, WMConnection *cPtr)
|
||||||
{
|
{
|
||||||
char *buffer;
|
char *buffer;
|
||||||
|
|
||||||
@@ -119,7 +108,7 @@ didReceiveInput(ConnectionDelegate *self, WMConnection *cPtr) /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
connectionDidDie(ConnectionDelegate *self, WMConnection *cPtr) /*FOLD00*/
|
connectionDidDie(ConnectionDelegate *self, WMConnection *cPtr)
|
||||||
{
|
{
|
||||||
WMCloseConnection(cPtr);
|
WMCloseConnection(cPtr);
|
||||||
|
|
||||||
@@ -151,7 +140,7 @@ didInitialize(ConnectionDelegate *self, WMConnection *cPtr)
|
|||||||
|
|
||||||
|
|
||||||
int
|
int
|
||||||
main(int argc, char **argv) /*FOLD00*/
|
main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
char *ProgName, *host, *port;
|
char *ProgName, *host, *port;
|
||||||
int i;
|
int i;
|
||||||
@@ -168,7 +157,7 @@ main(int argc, char **argv) /*FOLD00*/
|
|||||||
ProgName++;
|
ProgName++;
|
||||||
|
|
||||||
host = NULL;
|
host = NULL;
|
||||||
port = "7000";
|
port = "34567";
|
||||||
|
|
||||||
if (argc>1) {
|
if (argc>1) {
|
||||||
for (i=1; i<argc; i++) {
|
for (i=1; i<argc; i++) {
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
/*
|
/*
|
||||||
* WINGs demo: font lister
|
* WINGs demo: font lister
|
||||||
*
|
*
|
||||||
* Copyright (c) 1998 Alfredo K. Kojima
|
* Copyright (c) 1998-2003 Alfredo K. Kojima
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* 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
|
* it under the terms of the GNU General Public License as published by
|
||||||
@@ -24,8 +24,8 @@
|
|||||||
|
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include "WINGs.h"
|
#include <WINGs/WINGs.h>
|
||||||
#include "WUtil.h"
|
#include <WINGs/WUtil.h>
|
||||||
|
|
||||||
void
|
void
|
||||||
wAbort()
|
wAbort()
|
||||||
|
|||||||
@@ -3,7 +3,7 @@
|
|||||||
|
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <WINGs.h>
|
#include <WINGs/WINGs.h>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -21,7 +21,8 @@ int MoveCount;
|
|||||||
int WinSize = 120;
|
int WinSize = 120;
|
||||||
|
|
||||||
|
|
||||||
Bool CheckWin(void)
|
Bool
|
||||||
|
CheckWin(void)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
@@ -34,15 +35,17 @@ Bool CheckWin(void)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void MoveButton(int button, int x, int y)
|
void
|
||||||
|
MoveButton(int button, int x, int y)
|
||||||
{
|
{
|
||||||
WMMoveWidget(Button[button], x*(WinSize/Size), y*(WinSize/Size));
|
WMMoveWidget(Button[button], x*(WinSize/Size), y*(WinSize/Size));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
Bool SlideButton(int button)
|
Bool
|
||||||
|
SlideButton(int button)
|
||||||
{
|
{
|
||||||
int x, y, done = 0;
|
int x=0, y=0, done = 0;
|
||||||
|
|
||||||
/* locate the button */
|
/* locate the button */
|
||||||
for (y = 0; y < Size; y++) {
|
for (y = 0; y < Size; y++) {
|
||||||
@@ -239,3 +242,4 @@ int main(int argc, char **argv)
|
|||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
740
WINGs/Examples/server.c
Normal file
740
WINGs/Examples/server.c
Normal file
@@ -0,0 +1,740 @@
|
|||||||
|
/*
|
||||||
|
* WINGs server.c: example how to create a network server using WMConnection
|
||||||
|
*
|
||||||
|
* Copyright (c) 2001-2003 Dan Pascu
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
#include <stdio.h>
|
||||||
|
#include <stdlib.h>
|
||||||
|
#include <unistd.h>
|
||||||
|
#include <string.h>
|
||||||
|
|
||||||
|
#include <WINGs/WINGs.h>
|
||||||
|
|
||||||
|
|
||||||
|
#define _(P) P
|
||||||
|
#define MAXCMD_SIZE 512
|
||||||
|
|
||||||
|
|
||||||
|
char *SEConnectionShouldBeRemovedNotification = "SEConnectionShouldBeRemovedNotification";
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
static void didReceiveInput(ConnectionDelegate *self, WMConnection *cPtr);
|
||||||
|
|
||||||
|
static void connectionDidDie(ConnectionDelegate *self, WMConnection *cPtr);
|
||||||
|
|
||||||
|
static void connectionDidTimeout(ConnectionDelegate *self, WMConnection *cPtr);
|
||||||
|
|
||||||
|
|
||||||
|
extern char *SEConnectionShouldBeRemovedNotification;
|
||||||
|
|
||||||
|
static WMUserDefaults *timeDB = NULL;
|
||||||
|
static char *ServerAddress = NULL;
|
||||||
|
static char *ServerPort = NULL;
|
||||||
|
static WMArray *allowedHostList = NULL;
|
||||||
|
static WMArray *clientConnections = NULL;
|
||||||
|
static WMConnection *serverPtr = NULL;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
static ConnectionDelegate socketDelegate = {
|
||||||
|
NULL, /* client data */
|
||||||
|
NULL, /* canResumeSending */
|
||||||
|
NULL, /* didCatchException */
|
||||||
|
connectionDidDie, /* didDie */
|
||||||
|
NULL, /* didInitialize */
|
||||||
|
didReceiveInput, /* didReceiveInput */
|
||||||
|
connectionDidTimeout /* didTimeout */
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
void
|
||||||
|
wAbort(Bool foo)
|
||||||
|
{
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static void
|
||||||
|
printHelp(char *progname)
|
||||||
|
{
|
||||||
|
printf(_("usage: %s [options]\n\n"), progname);
|
||||||
|
puts(_(" --help print this message"));
|
||||||
|
puts(_(" --listen [address:]port only listen on the specified address/port"));
|
||||||
|
puts(_(" --allow host1[,host2...] only allow connections from listed hosts\n"));
|
||||||
|
puts(_(" By default server listens on all interfaces and port 34567, unless"
|
||||||
|
" something\nelse is specified with the --listen option. If address is"
|
||||||
|
" omitted or the keyword\n'Any' is used, it will listen on all interfaces else"
|
||||||
|
" only on the specified one.\n\nFor example --listen localhost: will"
|
||||||
|
" listen on the default port 34567, but only\non connections comming"
|
||||||
|
" in through the loopback interface.\n\n Also by default the server"
|
||||||
|
" listens to incoming connections from any host,\nunless a list of"
|
||||||
|
" hosts is given with the --allow option, in which case it will\nreject"
|
||||||
|
" connections not comming from those hosts.\nThe list of hosts is comma"
|
||||||
|
" separated and should NOT contain ANY spaces."));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static void
|
||||||
|
enqueueConnectionForRemoval(WMConnection *cPtr)
|
||||||
|
{
|
||||||
|
WMNotification *notif;
|
||||||
|
|
||||||
|
/*don't release notif here. it will be released by queue after processing */
|
||||||
|
notif = WMCreateNotification(SEConnectionShouldBeRemovedNotification,
|
||||||
|
cPtr, NULL);
|
||||||
|
WMEnqueueNotification(WMGetDefaultNotificationQueue(), notif, WMPostASAP);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static int
|
||||||
|
sendMessage(WMConnection *cPtr, char *message)
|
||||||
|
{
|
||||||
|
WMData *aData;
|
||||||
|
int res;
|
||||||
|
|
||||||
|
if (WMGetConnectionState(cPtr)!=WCConnected)
|
||||||
|
return -1;
|
||||||
|
|
||||||
|
aData = WMCreateDataWithBytes(message, strlen(message));
|
||||||
|
res = WMSendConnectionData(cPtr, aData);
|
||||||
|
WMReleaseData(aData);
|
||||||
|
|
||||||
|
return res;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static Bool
|
||||||
|
enqueueMessage(WMConnection *cPtr, char *message)
|
||||||
|
{
|
||||||
|
WMData *aData;
|
||||||
|
Bool res;
|
||||||
|
|
||||||
|
if (WMGetConnectionState(cPtr)!=WCConnected)
|
||||||
|
return False;
|
||||||
|
|
||||||
|
aData = WMCreateDataWithBytes(message, strlen(message));
|
||||||
|
res = WMEnqueueConnectionData(cPtr, aData);
|
||||||
|
WMReleaseData(aData);
|
||||||
|
|
||||||
|
return res;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static unsigned char*
|
||||||
|
findDelimiter(unsigned char *data, unsigned const char *endPtr)
|
||||||
|
{
|
||||||
|
wassertrv(data < endPtr, NULL);
|
||||||
|
|
||||||
|
while (data<endPtr && *data!='\n' && *data!='\r' && *data!=';' && *data!='\0')
|
||||||
|
data++;
|
||||||
|
|
||||||
|
if (data < endPtr)
|
||||||
|
return data;
|
||||||
|
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static WMArray*
|
||||||
|
getAvailableMessages(WMConnection *cPtr)
|
||||||
|
{
|
||||||
|
char *ptr, *crtPos, *buffer;
|
||||||
|
const char *bytes, *endPtr;
|
||||||
|
WMData *aData, *receivedData, *holdData;
|
||||||
|
WMRange range;
|
||||||
|
WMArray *messages;
|
||||||
|
int length;
|
||||||
|
|
||||||
|
receivedData = WMGetConnectionAvailableData(cPtr);
|
||||||
|
if (!receivedData)
|
||||||
|
return NULL;
|
||||||
|
if ((length=WMGetDataLength(receivedData))==0) {
|
||||||
|
WMReleaseData(receivedData);
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
|
holdData = (WMData*)WMGetConnectionClientData(cPtr);
|
||||||
|
if (holdData) {
|
||||||
|
WMAppendData(holdData, receivedData);
|
||||||
|
WMReleaseData(receivedData);
|
||||||
|
WMSetConnectionClientData(cPtr, NULL);
|
||||||
|
aData = holdData;
|
||||||
|
} else {
|
||||||
|
aData = receivedData;
|
||||||
|
}
|
||||||
|
|
||||||
|
length = WMGetDataLength(aData);
|
||||||
|
bytes = (char*)WMDataBytes(aData);
|
||||||
|
endPtr = bytes + length;
|
||||||
|
|
||||||
|
messages = WMCreateArrayWithDestructor(1, wfree);
|
||||||
|
crtPos = (char*)bytes;
|
||||||
|
while (crtPos<endPtr && (ptr = findDelimiter(crtPos, endPtr))!=NULL) {
|
||||||
|
range.position = (crtPos - bytes);
|
||||||
|
range.count = (ptr - crtPos);
|
||||||
|
if (range.count > MAXCMD_SIZE) {
|
||||||
|
/* Hmmm... The message is too long. Possibly that someone is
|
||||||
|
* flooding us, or there is a dumb client which do not know
|
||||||
|
* who is talking to. */
|
||||||
|
sendMessage(cPtr, "Command too long\n\r");
|
||||||
|
WMFreeArray(messages);
|
||||||
|
WMReleaseData(aData);
|
||||||
|
WMCloseConnection(cPtr);
|
||||||
|
enqueueConnectionForRemoval(cPtr);
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
buffer = wmalloc(range.count+1);
|
||||||
|
WMGetDataBytesWithRange(aData, buffer, range);
|
||||||
|
buffer[range.count] = '\0';
|
||||||
|
WMAddToArray(messages, buffer);
|
||||||
|
crtPos = ptr;
|
||||||
|
while (crtPos<endPtr && (*crtPos=='\n' || *crtPos=='\r' ||
|
||||||
|
*crtPos=='\t' || *crtPos=='\0' ||
|
||||||
|
*crtPos==';' || *crtPos==' ')) {
|
||||||
|
crtPos++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (crtPos<endPtr) {
|
||||||
|
range.position = (crtPos - bytes);
|
||||||
|
range.count = (endPtr - crtPos);
|
||||||
|
if (range.count > MAXCMD_SIZE) {
|
||||||
|
/* Flooooooding!!!! */
|
||||||
|
sendMessage(cPtr, "Message too long\n\r");
|
||||||
|
WMFreeArray(messages);
|
||||||
|
WMReleaseData(aData);
|
||||||
|
WMCloseConnection(cPtr);
|
||||||
|
enqueueConnectionForRemoval(cPtr);
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
holdData = WMGetSubdataWithRange(aData, range);
|
||||||
|
WMSetConnectionClientData(cPtr, holdData);
|
||||||
|
}
|
||||||
|
WMReleaseData(aData);
|
||||||
|
|
||||||
|
if (WMGetArrayItemCount(messages)==0) {
|
||||||
|
WMFreeArray(messages);
|
||||||
|
messages = NULL;
|
||||||
|
}
|
||||||
|
return messages;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
static void
|
||||||
|
complainAboutBadArgs(WMConnection *cPtr, char *cmdName, char *badArgs)
|
||||||
|
{
|
||||||
|
char *buf = wmalloc(strlen(cmdName) + strlen(badArgs) + 100);
|
||||||
|
|
||||||
|
sprintf(buf, _("Invalid parameters '%s' for command %s. Use HELP for"
|
||||||
|
" a list of commands.\n"), badArgs, cmdName);
|
||||||
|
sendMessage(cPtr, buf);
|
||||||
|
wfree(buf);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static void
|
||||||
|
sendUpdateMessage(WMConnection *cPtr, char *id, int time)
|
||||||
|
{
|
||||||
|
char *buf = wmalloc(strlen(id) + 100);
|
||||||
|
|
||||||
|
sprintf(buf, "%s has %i minutes left\n", id, time);
|
||||||
|
sendMessage(cPtr, buf);
|
||||||
|
wfree(buf);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static void
|
||||||
|
showId(WMConnection *cPtr)
|
||||||
|
{
|
||||||
|
sendMessage(cPtr, "Server example based on WMConnection\n");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static void
|
||||||
|
showHelp(WMConnection *cPtr)
|
||||||
|
{
|
||||||
|
char *buf = wmalloc(strlen(WMGetApplicationName()) + 16);
|
||||||
|
|
||||||
|
sprintf(buf, _("%s commands:\n\n"), WMGetApplicationName());
|
||||||
|
|
||||||
|
enqueueMessage(cPtr, _("\n"));
|
||||||
|
enqueueMessage(cPtr, buf);
|
||||||
|
enqueueMessage(cPtr, _("GET <id>\t- return time left (in minutes) "
|
||||||
|
"for user with id <id>\n"));
|
||||||
|
enqueueMessage(cPtr, _("SET <id> <time>\t- set time limit to <time> "
|
||||||
|
"minutes for user with id <id>\n"));
|
||||||
|
enqueueMessage(cPtr, _("ADD <id> <time>\t- add <time> minutes "
|
||||||
|
"for user with id <id>\n"));
|
||||||
|
enqueueMessage(cPtr, _("SUB <id> <time>\t- subtract <time> minutes "
|
||||||
|
"for user with id <id>\n"));
|
||||||
|
enqueueMessage(cPtr, _("REMOVE <id>\t- remove time limitations for "
|
||||||
|
"user with id <id>\n"));
|
||||||
|
enqueueMessage(cPtr, _("LIST\t\t- list all users and their "
|
||||||
|
"corresponding time limit\n"));
|
||||||
|
enqueueMessage(cPtr, _("ID\t\t- returns the Time Manager "
|
||||||
|
"identification string\n"));
|
||||||
|
enqueueMessage(cPtr, _("EXIT\t\t- exits session\n"));
|
||||||
|
enqueueMessage(cPtr, _("QUIT\t\t- exits session\n"));
|
||||||
|
enqueueMessage(cPtr, _("HELP\t\t- show this message\n\n"));
|
||||||
|
/* Just flush the queue we made before */
|
||||||
|
WMFlushConnection(cPtr);
|
||||||
|
wfree(buf);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static void
|
||||||
|
listUsers(WMConnection *cPtr)
|
||||||
|
{
|
||||||
|
WMPropList *userList;
|
||||||
|
char *id;
|
||||||
|
int i, time;
|
||||||
|
|
||||||
|
userList = WMGetUDKeys(timeDB);
|
||||||
|
|
||||||
|
for (i=0; i<WMGetPropListItemCount(userList); i++) {
|
||||||
|
id = WMGetFromPLString(WMGetFromPLArray(userList, i));
|
||||||
|
time = WMGetUDIntegerForKey(timeDB, id);
|
||||||
|
sendUpdateMessage(cPtr, id, time);
|
||||||
|
}
|
||||||
|
|
||||||
|
WMReleasePropList(userList);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static void
|
||||||
|
setTimeForUser(WMConnection *cPtr, char *cmdArgs)
|
||||||
|
{
|
||||||
|
char *id;
|
||||||
|
int i, time;
|
||||||
|
|
||||||
|
id = wmalloc(strlen(cmdArgs));
|
||||||
|
if (sscanf(cmdArgs, "%s %d", id, &time)!=2) {
|
||||||
|
complainAboutBadArgs(cPtr, "SET", cmdArgs);
|
||||||
|
wfree(id);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if (time<0)
|
||||||
|
time = 0;
|
||||||
|
|
||||||
|
WMSetUDIntegerForKey(timeDB, time, id);
|
||||||
|
|
||||||
|
for (i=0; i<WMGetArrayItemCount(clientConnections); i++) {
|
||||||
|
cPtr = WMGetFromArray(clientConnections, i);
|
||||||
|
sendUpdateMessage(cPtr, id, time);
|
||||||
|
}
|
||||||
|
wfree(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static void
|
||||||
|
addTimeToUser(WMConnection *cPtr, char *cmdArgs)
|
||||||
|
{
|
||||||
|
char *id;
|
||||||
|
int i, time, newTime;
|
||||||
|
|
||||||
|
id = wmalloc(strlen(cmdArgs));
|
||||||
|
if (sscanf(cmdArgs, "%s %d", id, &time)!=2) {
|
||||||
|
complainAboutBadArgs(cPtr, "ADD", cmdArgs);
|
||||||
|
wfree(id);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
newTime = WMGetUDIntegerForKey(timeDB, id) + time;
|
||||||
|
if (newTime<0)
|
||||||
|
newTime = 0;
|
||||||
|
|
||||||
|
WMSetUDIntegerForKey(timeDB, newTime, id);
|
||||||
|
|
||||||
|
for (i=0; i<WMGetArrayItemCount(clientConnections); i++) {
|
||||||
|
cPtr = WMGetFromArray(clientConnections, i);
|
||||||
|
sendUpdateMessage(cPtr, id, newTime);
|
||||||
|
}
|
||||||
|
wfree(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static void
|
||||||
|
subTimeFromUser(WMConnection *cPtr, char *cmdArgs)
|
||||||
|
{
|
||||||
|
char *id;
|
||||||
|
int i, time, newTime;
|
||||||
|
|
||||||
|
id = wmalloc(strlen(cmdArgs));
|
||||||
|
if (sscanf(cmdArgs, "%s %d", id, &time)!=2) {
|
||||||
|
complainAboutBadArgs(cPtr, "SUB", cmdArgs);
|
||||||
|
wfree(id);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
newTime = WMGetUDIntegerForKey(timeDB, id) - time;
|
||||||
|
if (newTime<0)
|
||||||
|
newTime = 0;
|
||||||
|
|
||||||
|
WMSetUDIntegerForKey(timeDB, newTime, id);
|
||||||
|
|
||||||
|
for (i=0; i<WMGetArrayItemCount(clientConnections); i++) {
|
||||||
|
cPtr = WMGetFromArray(clientConnections, i);
|
||||||
|
sendUpdateMessage(cPtr, id, newTime);
|
||||||
|
}
|
||||||
|
wfree(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static void
|
||||||
|
removeTimeForUser(WMConnection *cPtr, char *cmdArgs)
|
||||||
|
{
|
||||||
|
char *ptr;
|
||||||
|
int i;
|
||||||
|
|
||||||
|
if (cmdArgs[0]=='\0') {
|
||||||
|
sendMessage(cPtr, _("Missing parameter for command REMOVE."
|
||||||
|
" Use HELP for a list of commands.\n"));
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
ptr = cmdArgs;
|
||||||
|
while (*ptr && *ptr!=' ' && *ptr!='\t')
|
||||||
|
ptr++;
|
||||||
|
*ptr = '\0';
|
||||||
|
|
||||||
|
WMRemoveUDObjectForKey(timeDB, cmdArgs);
|
||||||
|
|
||||||
|
for (i=0; i<WMGetArrayItemCount(clientConnections); i++) {
|
||||||
|
cPtr = WMGetFromArray(clientConnections, i);
|
||||||
|
sendUpdateMessage(cPtr, cmdArgs, -1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static void
|
||||||
|
getTimeForUser(WMConnection *cPtr, char *cmdArgs)
|
||||||
|
{
|
||||||
|
char *ptr;
|
||||||
|
int time;
|
||||||
|
|
||||||
|
if (cmdArgs[0]=='\0') {
|
||||||
|
sendMessage(cPtr, _("Missing parameter for command GET."
|
||||||
|
" Use HELP for a list of commands.\n"));
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
ptr = cmdArgs;
|
||||||
|
while (*ptr && *ptr!=' ' && *ptr!='\t')
|
||||||
|
ptr++;
|
||||||
|
*ptr = '\0';
|
||||||
|
|
||||||
|
if (WMGetUDObjectForKey(timeDB, cmdArgs)!=NULL)
|
||||||
|
time = WMGetUDIntegerForKey(timeDB, cmdArgs);
|
||||||
|
else
|
||||||
|
time = -1;
|
||||||
|
|
||||||
|
sendUpdateMessage(cPtr, cmdArgs, time);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static void
|
||||||
|
handleConnection(WMConnection *cPtr)
|
||||||
|
{
|
||||||
|
char *command, *ptr, *cmdArgs, *buffer;
|
||||||
|
WMArray *commands;
|
||||||
|
int i;
|
||||||
|
|
||||||
|
commands = getAvailableMessages(cPtr);
|
||||||
|
if (!commands)
|
||||||
|
return;
|
||||||
|
|
||||||
|
for (i=0; i<WMGetArrayItemCount(commands); i++) {
|
||||||
|
command = WMGetFromArray(commands, i);
|
||||||
|
while (*command && (*command==' ' || *command=='\t'))
|
||||||
|
command++;
|
||||||
|
ptr = command;
|
||||||
|
while(*ptr && *ptr!=' ' && *ptr!='\t')
|
||||||
|
ptr++;
|
||||||
|
if (*ptr) {
|
||||||
|
*ptr = '\0';
|
||||||
|
ptr++;
|
||||||
|
}
|
||||||
|
while (*ptr && (*ptr==' ' || *ptr=='\t'))
|
||||||
|
ptr++;
|
||||||
|
|
||||||
|
cmdArgs = ptr;
|
||||||
|
|
||||||
|
fprintf(stderr, "Command: '%s', args: '%s'\n", command, cmdArgs);
|
||||||
|
|
||||||
|
if (strcasecmp(command, "quit")==0 || strcasecmp(command, "exit")==0) {
|
||||||
|
sendMessage(cPtr, "Bye\n");
|
||||||
|
WMCloseConnection(cPtr);
|
||||||
|
enqueueConnectionForRemoval(cPtr);
|
||||||
|
WMFreeArray(commands);
|
||||||
|
return;
|
||||||
|
} else if (strcasecmp(command, "id")==0) {
|
||||||
|
showId(cPtr);
|
||||||
|
} else if (strcasecmp(command, "help")==0) {
|
||||||
|
showHelp(cPtr);
|
||||||
|
} else if (strcasecmp(command, "list")==0) {
|
||||||
|
listUsers(cPtr);
|
||||||
|
} else if (strcasecmp(command, "set")==0) {
|
||||||
|
setTimeForUser(cPtr, cmdArgs);
|
||||||
|
} else if (strcasecmp(command, "add")==0) {
|
||||||
|
addTimeToUser(cPtr, cmdArgs);
|
||||||
|
} else if (strcasecmp(command, "sub")==0) {
|
||||||
|
subTimeFromUser(cPtr, cmdArgs);
|
||||||
|
} else if (strcasecmp(command, "remove")==0) {
|
||||||
|
removeTimeForUser(cPtr, cmdArgs);
|
||||||
|
} else if (strcasecmp(command, "get")==0) {
|
||||||
|
getTimeForUser(cPtr, cmdArgs);
|
||||||
|
} else {
|
||||||
|
buffer = wmalloc(strlen(command) + 100);
|
||||||
|
sprintf(buffer, _("Unknown command '%s'. Try HELP for"
|
||||||
|
" a list of commands.\n"), command);
|
||||||
|
sendMessage(cPtr, buffer);
|
||||||
|
wfree(buffer);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
WMFreeArray(commands);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static Bool
|
||||||
|
isAllowedToConnect(WMConnection *cPtr)
|
||||||
|
{
|
||||||
|
WMHost *hPtr;
|
||||||
|
int i;
|
||||||
|
|
||||||
|
if (allowedHostList == NULL)
|
||||||
|
return True; /* No list. Allow all by default */
|
||||||
|
|
||||||
|
hPtr = WMGetHostWithAddress(WMGetConnectionAddress(cPtr));
|
||||||
|
for (i=0; i<WMGetArrayItemCount(allowedHostList); i++) {
|
||||||
|
if (WMIsHostEqualToHost(hPtr, WMGetFromArray(allowedHostList, i))) {
|
||||||
|
WMReleaseHost(hPtr);
|
||||||
|
return True;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
WMReleaseHost(hPtr);
|
||||||
|
|
||||||
|
return False;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static void
|
||||||
|
didReceiveInput(ConnectionDelegate *self, WMConnection *cPtr)
|
||||||
|
{
|
||||||
|
if (cPtr == serverPtr) {
|
||||||
|
WMConnection *newPtr = WMAcceptConnection(cPtr);
|
||||||
|
|
||||||
|
if (newPtr) {
|
||||||
|
if (isAllowedToConnect(newPtr)) {
|
||||||
|
WMSetConnectionDelegate(newPtr, &socketDelegate);
|
||||||
|
WMSetConnectionSendTimeout(newPtr, 120);
|
||||||
|
WMAddToArray(clientConnections, newPtr);
|
||||||
|
} else {
|
||||||
|
sendMessage(newPtr, "Sorry, you are not allowed to connect.\n");
|
||||||
|
WMDestroyConnection(newPtr);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
/* Data arriving on an already-connected socket */
|
||||||
|
handleConnection(cPtr);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static void
|
||||||
|
connectionDidTimeout(ConnectionDelegate *self, WMConnection *cPtr)
|
||||||
|
{
|
||||||
|
WMHost *hPtr;
|
||||||
|
|
||||||
|
if (cPtr == serverPtr) {
|
||||||
|
wfatal(_("The server listening socket did timeout. Exiting."));
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
hPtr = WMGetHostWithAddress(WMGetConnectionAddress(cPtr));
|
||||||
|
wwarning(_("Connection with %s did timeout. Closing connection."),
|
||||||
|
WMGetHostName(hPtr));
|
||||||
|
WMReleaseHost(hPtr);
|
||||||
|
|
||||||
|
enqueueConnectionForRemoval(cPtr);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static void
|
||||||
|
connectionDidDie(ConnectionDelegate *self, WMConnection *cPtr)
|
||||||
|
{
|
||||||
|
if (cPtr == serverPtr) {
|
||||||
|
/* trouble. server listening port itself died!!! */
|
||||||
|
wfatal(_("The server listening socket died. Exiting."));
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
enqueueConnectionForRemoval(cPtr);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static void
|
||||||
|
removeConnection(void *observer, WMNotification *notification)
|
||||||
|
{
|
||||||
|
WMConnection *cPtr = (WMConnection*)WMGetNotificationObject(notification);
|
||||||
|
WMData *data;
|
||||||
|
|
||||||
|
WMRemoveFromArray(clientConnections, cPtr);
|
||||||
|
if ((data = (WMData*)WMGetConnectionClientData(cPtr))!=NULL)
|
||||||
|
WMReleaseData(data);
|
||||||
|
WMDestroyConnection(cPtr);
|
||||||
|
}
|
||||||
|
|
||||||
|
static void
|
||||||
|
updatedDomain(void *observer, WMNotification *notification)
|
||||||
|
{
|
||||||
|
wmessage("defaults domain file changed on disk. synchronizing.");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
#if 0
|
||||||
|
static Bool
|
||||||
|
isDifferent(char *str1, char *str2)
|
||||||
|
{
|
||||||
|
if ((!str1 && !str2) || (str1 && str2 && strcmp(str1, str2)==0))
|
||||||
|
return False;
|
||||||
|
|
||||||
|
return True;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
int
|
||||||
|
main(int argc, char **argv)
|
||||||
|
{
|
||||||
|
int i;
|
||||||
|
|
||||||
|
wsetabort(wAbort);
|
||||||
|
|
||||||
|
WMInitializeApplication("server", &argc, argv);
|
||||||
|
|
||||||
|
if (argc>1) {
|
||||||
|
for (i=1; i<argc; i++) {
|
||||||
|
if (strcmp(argv[i], "--help")==0) {
|
||||||
|
printHelp(argv[0]);
|
||||||
|
exit(0);
|
||||||
|
} else if (strcmp(argv[i], "--listen")==0) {
|
||||||
|
char *p;
|
||||||
|
|
||||||
|
if ((p = strchr(argv[++i], ':')) != NULL) {
|
||||||
|
*p = 0;
|
||||||
|
ServerAddress = wstrdup(argv[i]);
|
||||||
|
ServerPort = wstrdup(p+1);
|
||||||
|
*p = ':';
|
||||||
|
if (ServerAddress[0] == 0) {
|
||||||
|
wfree(ServerAddress);
|
||||||
|
ServerAddress = NULL;
|
||||||
|
}
|
||||||
|
if (ServerPort[0] == 0) {
|
||||||
|
wfree(ServerPort);
|
||||||
|
ServerPort = "34567";
|
||||||
|
}
|
||||||
|
} else if (argv[i][0]!=0) {
|
||||||
|
ServerPort = argv[i];
|
||||||
|
}
|
||||||
|
} else if (strcmp(argv[i], "--allow")==0) {
|
||||||
|
char *p, *ptr;
|
||||||
|
int done;
|
||||||
|
WMHost *hPtr;
|
||||||
|
|
||||||
|
ptr = argv[++i];
|
||||||
|
done = 0;
|
||||||
|
while (!done) {
|
||||||
|
if ((p = strchr(ptr, ',')) != NULL) {
|
||||||
|
*p = 0;
|
||||||
|
}
|
||||||
|
if (*ptr != 0) {
|
||||||
|
hPtr = WMGetHostWithName(ptr);
|
||||||
|
if (hPtr) {
|
||||||
|
if (!allowedHostList)
|
||||||
|
allowedHostList = WMCreateArray(4);
|
||||||
|
WMAddToArray(allowedHostList, hPtr);
|
||||||
|
} else {
|
||||||
|
wwarning(_("Unknown host '%s'. Ignored."), ptr);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (p!=NULL) {
|
||||||
|
*p = ',';
|
||||||
|
ptr = p+1;
|
||||||
|
} else {
|
||||||
|
done = 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
printf(_("%s: invalid argument '%s'\n"), argv[0], argv[i]);
|
||||||
|
printf(_("Try '%s --help' for more information\n"), argv[0]);
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
timeDB = WMGetDefaultsFromPath("./UserTime.plist");
|
||||||
|
WMAddNotificationObserver(updatedDomain, NULL,
|
||||||
|
WMUserDefaultsDidChangeNotification, NULL);
|
||||||
|
|
||||||
|
clientConnections = WMCreateArray(4);
|
||||||
|
|
||||||
|
/* A NULL ServerAddress means to listen on any address the host has.
|
||||||
|
* Else if ServerAddress points to a specific address (like "localhost",
|
||||||
|
* "host.domain.com" or "192.168.1.1"), then it will only listen on that
|
||||||
|
* interface and ignore incoming connections on the others. */
|
||||||
|
if (ServerAddress && strcasecmp(ServerAddress, "Any")==0)
|
||||||
|
ServerAddress = NULL;
|
||||||
|
if (ServerPort==NULL)
|
||||||
|
ServerPort = "34567";
|
||||||
|
|
||||||
|
printf("Server will listen on '%s:%s'\n", ServerAddress?ServerAddress:"Any",
|
||||||
|
ServerPort);
|
||||||
|
printf("This server will allow connections from:");
|
||||||
|
if (allowedHostList) {
|
||||||
|
int i;
|
||||||
|
char *hName;
|
||||||
|
|
||||||
|
for (i=0; i<WMGetArrayItemCount(allowedHostList); i++) {
|
||||||
|
hName = WMGetHostName(WMGetFromArray(allowedHostList, i));
|
||||||
|
printf("%s'%s'", i==0?" ":", ", hName);
|
||||||
|
}
|
||||||
|
printf(".\n");
|
||||||
|
} else {
|
||||||
|
printf(" any host.\n");
|
||||||
|
}
|
||||||
|
|
||||||
|
serverPtr = WMCreateConnectionAsServerAtAddress(ServerAddress, ServerPort,
|
||||||
|
NULL);
|
||||||
|
|
||||||
|
if (!serverPtr) {
|
||||||
|
wfatal("could not create server on `%s:%s`. Exiting.",
|
||||||
|
ServerAddress ? ServerAddress : "localhost", ServerPort);
|
||||||
|
exit(1);
|
||||||
|
}
|
||||||
|
|
||||||
|
WMSetConnectionDelegate(serverPtr, &socketDelegate);
|
||||||
|
|
||||||
|
WMAddNotificationObserver(removeConnection, NULL,
|
||||||
|
SEConnectionShouldBeRemovedNotification, NULL);
|
||||||
|
|
||||||
|
while (1) {
|
||||||
|
/* The ASAP notification queue is called at the end of WHandleEvents()
|
||||||
|
* There's where died connections we get while running through
|
||||||
|
* WHandleEvents() get removed. */
|
||||||
|
WHandleEvents();
|
||||||
|
}
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -1,3 +1,4 @@
|
|||||||
Makefile Makefile.in
|
Makefile Makefile.in
|
||||||
.libs
|
.libs
|
||||||
test
|
test
|
||||||
|
.psrc .inslog2 tca.map tca.log pchdir *.rpt
|
||||||
|
|||||||
@@ -22,12 +22,13 @@ libExtraWINGs_a_SOURCES = \
|
|||||||
wtableview.h \
|
wtableview.h \
|
||||||
wtabledelegates.h
|
wtabledelegates.h
|
||||||
|
|
||||||
|
AM_CFLAGS = @NOSTRICTALIASING@
|
||||||
|
|
||||||
INCLUDES = -I$(top_srcdir)/wrlib -I$(top_srcdir)/WINGs \
|
INCLUDES = -I$(top_srcdir)/wrlib -I$(top_srcdir)/WINGs \
|
||||||
-DRESOURCE_PATH=\"$(datadir)/WINGs\" @HEADER_SEARCH_PATH@ -DDEBUG
|
-DRESOURCE_PATH=\"$(datadir)/WINGs\" @HEADER_SEARCH_PATH@ -DDEBUG
|
||||||
|
|
||||||
LDADD= $(top_builddir)/WINGs/libWINGs.a $(top_builddir)/wrlib/libwraster.la \
|
LDADD= $(top_builddir)/WINGs/libWINGs.a $(top_builddir)/wrlib/libwraster.la \
|
||||||
@LIBPL@
|
@XFTLIBS@ @INTLIBS@
|
||||||
|
|
||||||
test_LDADD = wtableview.o wtabledelegates.o $(LDADD)
|
test_LDADD = wtableview.o wtabledelegates.o $(LDADD)
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
|
|
||||||
|
|
||||||
#include <WINGs.h>
|
#include <WINGs/WINGs.h>
|
||||||
|
#include <stdio.h>
|
||||||
#include "wtableview.h"
|
#include "wtableview.h"
|
||||||
#include "wtabledelegates.h"
|
#include "wtabledelegates.h"
|
||||||
|
|
||||||
@@ -18,19 +19,25 @@ static char *options[] = {
|
|||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
int numberOfRows(WMTableViewDelegate *self, WMTableView *table)
|
int
|
||||||
|
numberOfRows(WMTableViewDelegate *self, WMTableView *table)
|
||||||
{
|
{
|
||||||
return 20;
|
return 20;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void *valueForCell(WMTableViewDelegate *self, WMTableColumn *column, int row)
|
void*
|
||||||
|
valueForCell(WMTableViewDelegate *self, WMTableColumn *column, int row)
|
||||||
{
|
{
|
||||||
WMTableView *table = (WMTableView*)WMGetTableColumnTableView(column);
|
/*WMTableView *table = (WMTableView*)WMGetTableColumnTableView(column);*/
|
||||||
int i;
|
int i;
|
||||||
if (col1[0] == 0) {
|
if (col1[0] == 0) {
|
||||||
for (i = 0; i < 20; i++) {
|
for (i = 0; i < 20; i++) {
|
||||||
col1[i] = "teste";
|
char buf[128];
|
||||||
|
|
||||||
|
sprintf(buf, "Test row %i", i);
|
||||||
|
|
||||||
|
col1[i] = wstrdup(buf);
|
||||||
col2[i] = 0;
|
col2[i] = 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -41,7 +48,8 @@ void *valueForCell(WMTableViewDelegate *self, WMTableColumn *column, int row)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void setValueForCell(WMTableViewDelegate *self, WMTableColumn *column, int row,
|
void
|
||||||
|
setValueForCell(WMTableViewDelegate *self, WMTableColumn *column, int row,
|
||||||
void *data)
|
void *data)
|
||||||
{
|
{
|
||||||
if ((int)WMGetTableColumnId(column) == 1)
|
if ((int)WMGetTableColumnId(column) == 1)
|
||||||
@@ -60,7 +68,8 @@ static WMTableViewDelegate delegate = {
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
void clickedTable(WMWidget *w, void *self)
|
void
|
||||||
|
clickedTable(WMWidget *w, void *self)
|
||||||
{
|
{
|
||||||
int row = WMGetTableViewClickedRow((WMTableView*)self);
|
int row = WMGetTableViewClickedRow((WMTableView*)self);
|
||||||
|
|
||||||
@@ -69,10 +78,9 @@ void clickedTable(WMWidget *w, void *self)
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
int
|
||||||
main(int argc, char **argv)
|
main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
Display *dpy = XOpenDisplay("");
|
|
||||||
WMScreen *scr;
|
WMScreen *scr;
|
||||||
WMWindow *win;
|
WMWindow *win;
|
||||||
WMTableView *table;
|
WMTableView *table;
|
||||||
@@ -81,24 +89,19 @@ main(int argc, char **argv)
|
|||||||
|
|
||||||
WMInitializeApplication("test", &argc, argv);
|
WMInitializeApplication("test", &argc, argv);
|
||||||
|
|
||||||
|
scr = WMOpenScreen(NULL);
|
||||||
|
|
||||||
|
XSynchronize(WMScreenDisplay(scr), 1);
|
||||||
dpy = XOpenDisplay("");
|
|
||||||
if (!dpy) {
|
|
||||||
exit(1);
|
|
||||||
}
|
|
||||||
|
|
||||||
scr = WMCreateScreen(dpy, DefaultScreen(dpy));
|
|
||||||
|
|
||||||
|
|
||||||
win = WMCreateWindow(scr, "eweq");
|
win = WMCreateWindow(scr, "eweq");
|
||||||
WMResizeWidget(win, 400, 200);
|
WMResizeWidget(win, 400, 200);
|
||||||
WMMapWidget(win);
|
WMMapWidget(win);
|
||||||
|
|
||||||
table = WMCreateTableView(win);
|
table = WMCreateTableView(win);
|
||||||
WMResizeWidget(table, 400, 200);
|
WMSetTableViewHasHorizontalScroller(table, 0);
|
||||||
|
WMSetViewExpandsToParent(WMWidgetView(table), 10, 10, 10, 10);
|
||||||
WMSetTableViewBackgroundColor(table, WMWhiteColor(scr));
|
WMSetTableViewBackgroundColor(table, WMWhiteColor(scr));
|
||||||
// WMSetTableViewGridColor(table, WMGrayColor(scr));
|
/*WMSetTableViewGridColor(table, WMGrayColor(scr));*/
|
||||||
WMSetTableViewHeaderHeight(table, 20);
|
WMSetTableViewHeaderHeight(table, 20);
|
||||||
WMSetTableViewDelegate(table, &delegate);
|
WMSetTableViewDelegate(table, &delegate);
|
||||||
WMSetTableViewAction(table, clickedTable, table);
|
WMSetTableViewAction(table, clickedTable, table);
|
||||||
@@ -120,7 +123,6 @@ main(int argc, char **argv)
|
|||||||
WMSetTableColumnDelegate(col, colDeleg);
|
WMSetTableColumnDelegate(col, colDeleg);
|
||||||
WMSetTableColumnId(col, (void*)2);
|
WMSetTableColumnId(col, (void*)2);
|
||||||
|
|
||||||
|
|
||||||
colDeleg = WTCreateBooleanSwitchDelegate(table);
|
colDeleg = WTCreateBooleanSwitchDelegate(table);
|
||||||
|
|
||||||
col = WMCreateTableColumn("Bool");
|
col = WMCreateTableColumn("Bool");
|
||||||
@@ -129,9 +131,10 @@ main(int argc, char **argv)
|
|||||||
WMSetTableColumnDelegate(col, colDeleg);
|
WMSetTableColumnDelegate(col, colDeleg);
|
||||||
WMSetTableColumnId(col, (void*)2);
|
WMSetTableColumnId(col, (void*)2);
|
||||||
|
|
||||||
|
|
||||||
WMMapWidget(table);
|
WMMapWidget(table);
|
||||||
WMRealizeWidget(win);
|
WMRealizeWidget(win);
|
||||||
WMScreenMainLoop(scr);
|
WMScreenMainLoop(scr);
|
||||||
|
|
||||||
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
|
|
||||||
|
|
||||||
#include <WINGs.h>
|
#include <WINGs/WINGsP.h>
|
||||||
|
|
||||||
#include "wtableview.h"
|
#include "wtableview.h"
|
||||||
|
|
||||||
@@ -10,8 +10,8 @@ typedef struct {
|
|||||||
WMTableView *table;
|
WMTableView *table;
|
||||||
WMFont *font;
|
WMFont *font;
|
||||||
GC gc;
|
GC gc;
|
||||||
GC selGc;
|
GC selGC;
|
||||||
GC selTextGc;
|
WMColor *textColor;
|
||||||
} StringData;
|
} StringData;
|
||||||
|
|
||||||
|
|
||||||
@@ -27,8 +27,8 @@ typedef struct {
|
|||||||
WMTableView *table;
|
WMTableView *table;
|
||||||
WMFont *font;
|
WMFont *font;
|
||||||
GC gc;
|
GC gc;
|
||||||
GC selGc;
|
GC selGC;
|
||||||
GC selTextGc;
|
WMColor *textColor;
|
||||||
} StringEditorData;
|
} StringEditorData;
|
||||||
|
|
||||||
|
|
||||||
@@ -39,8 +39,8 @@ typedef struct {
|
|||||||
char **options;
|
char **options;
|
||||||
int count;
|
int count;
|
||||||
GC gc;
|
GC gc;
|
||||||
GC selGc;
|
GC selGC;
|
||||||
GC selTextGc;
|
WMColor *textColor;
|
||||||
} EnumSelectorData;
|
} EnumSelectorData;
|
||||||
|
|
||||||
|
|
||||||
@@ -49,6 +49,7 @@ typedef struct {
|
|||||||
WMTableView *table;
|
WMTableView *table;
|
||||||
Bool state;
|
Bool state;
|
||||||
GC gc;
|
GC gc;
|
||||||
|
GC selGC;
|
||||||
} BooleanSwitchData;
|
} BooleanSwitchData;
|
||||||
|
|
||||||
|
|
||||||
@@ -56,9 +57,9 @@ static char *SelectionColor = "#bbbbcc";
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
static void stringDraw(WMScreen *scr, Drawable d, GC gc,
|
static void
|
||||||
GC sgc, GC stgc, WMFont *font, void *data,
|
stringDraw(WMScreen *scr, Drawable d, GC gc, GC sgc, WMColor *textColor,
|
||||||
WMRect rect, Bool selected)
|
WMFont *font, void *data, WMRect rect, Bool selected)
|
||||||
{
|
{
|
||||||
int x, y;
|
int x, y;
|
||||||
XRectangle rects[1];
|
XRectangle rects[1];
|
||||||
@@ -74,16 +75,14 @@ static void stringDraw(WMScreen *scr, Drawable d, GC gc,
|
|||||||
XSetClipRectangles(dpy, gc, 0, 0, rects, 1, YXSorted);
|
XSetClipRectangles(dpy, gc, 0, 0, rects, 1, YXSorted);
|
||||||
|
|
||||||
if (!selected) {
|
if (!selected) {
|
||||||
XClearArea(dpy, d, rects[0].x, rects[0].y,
|
XFillRectangles(dpy, d, gc, rects, 1);
|
||||||
rects[0].width, rects[0].height,
|
|
||||||
False);
|
|
||||||
|
|
||||||
WMDrawString(scr, d, gc, font, x, y,
|
WMDrawString(scr, d, textColor, font, x, y,
|
||||||
data, strlen(data));
|
data, strlen(data));
|
||||||
} else {
|
} else {
|
||||||
XFillRectangles(dpy, d, sgc, rects, 1);
|
XFillRectangles(dpy, d, sgc, rects, 1);
|
||||||
|
|
||||||
WMDrawString(scr, d, stgc, font, x, y,
|
WMDrawString(scr, d, textColor, font, x, y,
|
||||||
data, strlen(data));
|
data, strlen(data));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -92,8 +91,9 @@ static void stringDraw(WMScreen *scr, Drawable d, GC gc,
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
static void pixmapDraw(WMScreen *scr, Drawable d, GC gc,
|
static void
|
||||||
WMPixmap *pixmap, WMRect rect, Bool selected)
|
pixmapDraw(WMScreen *scr, Drawable d, GC gc, GC sgc, WMPixmap *pixmap,
|
||||||
|
WMRect rect, Bool selected)
|
||||||
{
|
{
|
||||||
int x, y;
|
int x, y;
|
||||||
XRectangle rects[1];
|
XRectangle rects[1];
|
||||||
@@ -107,9 +107,7 @@ static void pixmapDraw(WMScreen *scr, Drawable d, GC gc,
|
|||||||
XSetClipRectangles(dpy, gc, 0, 0, rects, 1, YXSorted);
|
XSetClipRectangles(dpy, gc, 0, 0, rects, 1, YXSorted);
|
||||||
|
|
||||||
if (!selected) {
|
if (!selected) {
|
||||||
XClearArea(dpy, d, rects[0].x, rects[0].y,
|
XFillRectangles(dpy, d, gc, rects, 1);
|
||||||
rects[0].width, rects[0].height,
|
|
||||||
False);
|
|
||||||
|
|
||||||
if (pixmap) {
|
if (pixmap) {
|
||||||
size = WMGetPixmapSize(pixmap);
|
size = WMGetPixmapSize(pixmap);
|
||||||
@@ -119,7 +117,7 @@ static void pixmapDraw(WMScreen *scr, Drawable d, GC gc,
|
|||||||
WMDrawPixmap(pixmap, d, x, y);
|
WMDrawPixmap(pixmap, d, x, y);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
XFillRectangles(dpy, d, gc, rects, 1);
|
XFillRectangles(dpy, d, sgc, rects, 1);
|
||||||
|
|
||||||
if (pixmap) {
|
if (pixmap) {
|
||||||
size = WMGetPixmapSize(pixmap);
|
size = WMGetPixmapSize(pixmap);
|
||||||
@@ -138,38 +136,38 @@ static void pixmapDraw(WMScreen *scr, Drawable d, GC gc,
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
static void SECellPainter(WMTableColumnDelegate *self,
|
static void
|
||||||
WMTableColumn *column, int row)
|
SECellPainter(WMTableColumnDelegate *self, WMTableColumn *column,
|
||||||
|
int row, Drawable d)
|
||||||
{
|
{
|
||||||
StringEditorData *strdata = (StringEditorData*)self->data;
|
StringEditorData *strdata = (StringEditorData*)self->data;
|
||||||
WMTableView *table = WMGetTableColumnTableView(column);
|
WMTableView *table = WMGetTableColumnTableView(column);
|
||||||
|
|
||||||
stringDraw(WMWidgetScreen(table),
|
stringDraw(WMWidgetScreen(table), d,
|
||||||
WMViewXID(WMGetTableViewDocumentView(table)),
|
strdata->gc, strdata->selGC, strdata->textColor, strdata->font,
|
||||||
strdata->gc, strdata->selGc, strdata->selTextGc, strdata->font,
|
|
||||||
WMTableViewDataForCell(table, column, row),
|
WMTableViewDataForCell(table, column, row),
|
||||||
WMTableViewRectForCell(table, column, row),
|
WMTableViewRectForCell(table, column, row),
|
||||||
False);
|
False);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
static void selectedSECellPainter(WMTableColumnDelegate *self,
|
static void
|
||||||
WMTableColumn *column, int row)
|
selectedSECellPainter(WMTableColumnDelegate *self, WMTableColumn *column,
|
||||||
|
int row, Drawable d)
|
||||||
{
|
{
|
||||||
StringEditorData *strdata = (StringEditorData*)self->data;
|
StringEditorData *strdata = (StringEditorData*)self->data;
|
||||||
WMTableView *table = WMGetTableColumnTableView(column);
|
WMTableView *table = WMGetTableColumnTableView(column);
|
||||||
|
|
||||||
stringDraw(WMWidgetScreen(table),
|
stringDraw(WMWidgetScreen(table), d,
|
||||||
WMViewXID(WMGetTableViewDocumentView(table)),
|
strdata->gc, strdata->selGC, strdata->textColor, strdata->font,
|
||||||
strdata->gc, strdata->selGc, strdata->selTextGc, strdata->font,
|
|
||||||
WMTableViewDataForCell(table, column, row),
|
WMTableViewDataForCell(table, column, row),
|
||||||
WMTableViewRectForCell(table, column, row),
|
WMTableViewRectForCell(table, column, row),
|
||||||
True);
|
True);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
static void beginSECellEdit(WMTableColumnDelegate *self,
|
static void
|
||||||
WMTableColumn *column, int row)
|
beginSECellEdit(WMTableColumnDelegate *self, WMTableColumn *column, int row)
|
||||||
{
|
{
|
||||||
StringEditorData *strdata = (StringEditorData*)self->data;
|
StringEditorData *strdata = (StringEditorData*)self->data;
|
||||||
WMRect rect = WMTableViewRectForCell(strdata->table, column, row);
|
WMRect rect = WMTableViewRectForCell(strdata->table, column, row);
|
||||||
@@ -183,8 +181,8 @@ static void beginSECellEdit(WMTableColumnDelegate *self,
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
static void endSECellEdit(WMTableColumnDelegate *self,
|
static void
|
||||||
WMTableColumn *column, int row)
|
endSECellEdit(WMTableColumnDelegate *self, WMTableColumn *column, int row)
|
||||||
{
|
{
|
||||||
StringEditorData *strdata = (StringEditorData*)self->data;
|
StringEditorData *strdata = (StringEditorData*)self->data;
|
||||||
char *text;
|
char *text;
|
||||||
@@ -196,7 +194,8 @@ static void endSECellEdit(WMTableColumnDelegate *self,
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
WMTableColumnDelegate *WTCreateStringEditorDelegate(WMTableView *parent)
|
WMTableColumnDelegate*
|
||||||
|
WTCreateStringEditorDelegate(WMTableView *parent)
|
||||||
{
|
{
|
||||||
WMTableColumnDelegate *delegate = wmalloc(sizeof(WMTableColumnDelegate));
|
WMTableColumnDelegate *delegate = wmalloc(sizeof(WMTableColumnDelegate));
|
||||||
WMScreen *scr = WMWidgetScreen(parent);
|
WMScreen *scr = WMWidgetScreen(parent);
|
||||||
@@ -208,9 +207,9 @@ WMTableColumnDelegate *WTCreateStringEditorDelegate(WMTableView *parent)
|
|||||||
0, 0);
|
0, 0);
|
||||||
data->table = parent;
|
data->table = parent;
|
||||||
data->font = WMSystemFontOfSize(scr, 12);
|
data->font = WMSystemFontOfSize(scr, 12);
|
||||||
data->selGc = WMColorGC(WMCreateNamedColor(scr, SelectionColor, False));
|
data->gc = WMColorGC(WMWhiteColor(scr));
|
||||||
data->selTextGc = WMColorGC(WMBlackColor(scr));
|
data->selGC = WMColorGC(WMCreateNamedColor(scr, SelectionColor, False));
|
||||||
data->gc = WMColorGC(WMBlackColor(scr));
|
data->textColor = WMBlackColor(scr);
|
||||||
|
|
||||||
delegate->data = data;
|
delegate->data = data;
|
||||||
delegate->drawCell = SECellPainter;
|
delegate->drawCell = SECellPainter;
|
||||||
@@ -226,40 +225,40 @@ WMTableColumnDelegate *WTCreateStringEditorDelegate(WMTableView *parent)
|
|||||||
/* ---------------------------------------------------------------------- */
|
/* ---------------------------------------------------------------------- */
|
||||||
|
|
||||||
|
|
||||||
static void ESCellPainter(WMTableColumnDelegate *self,
|
static void
|
||||||
WMTableColumn *column, int row)
|
ESCellPainter(WMTableColumnDelegate *self, WMTableColumn *column,
|
||||||
|
int row, Drawable d)
|
||||||
{
|
{
|
||||||
EnumSelectorData *strdata = (EnumSelectorData*)self->data;
|
EnumSelectorData *strdata = (EnumSelectorData*)self->data;
|
||||||
WMTableView *table = WMGetTableColumnTableView(column);
|
WMTableView *table = WMGetTableColumnTableView(column);
|
||||||
int i = (int)WMTableViewDataForCell(table, column, row);
|
int i = (int)WMTableViewDataForCell(table, column, row);
|
||||||
|
|
||||||
stringDraw(WMWidgetScreen(table),
|
stringDraw(WMWidgetScreen(table), d,
|
||||||
WMViewXID(WMGetTableViewDocumentView(table)),
|
strdata->gc, strdata->selGC, strdata->textColor, strdata->font,
|
||||||
strdata->gc, strdata->selGc, strdata->selTextGc, strdata->font,
|
|
||||||
strdata->options[i],
|
strdata->options[i],
|
||||||
WMTableViewRectForCell(table, column, row),
|
WMTableViewRectForCell(table, column, row),
|
||||||
False);
|
False);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
static void selectedESCellPainter(WMTableColumnDelegate *self,
|
static void
|
||||||
WMTableColumn *column, int row)
|
selectedESCellPainter(WMTableColumnDelegate *self, WMTableColumn *column,
|
||||||
|
int row, Drawable d)
|
||||||
{
|
{
|
||||||
EnumSelectorData *strdata = (EnumSelectorData*)self->data;
|
EnumSelectorData *strdata = (EnumSelectorData*)self->data;
|
||||||
WMTableView *table = WMGetTableColumnTableView(column);
|
WMTableView *table = WMGetTableColumnTableView(column);
|
||||||
int i = (int)WMTableViewDataForCell(table, column, row);
|
int i = (int)WMTableViewDataForCell(table, column, row);
|
||||||
|
|
||||||
stringDraw(WMWidgetScreen(table),
|
stringDraw(WMWidgetScreen(table), d,
|
||||||
WMViewXID(WMGetTableViewDocumentView(table)),
|
strdata->gc, strdata->selGC, strdata->textColor, strdata->font,
|
||||||
strdata->gc, strdata->selGc, strdata->selTextGc, strdata->font,
|
|
||||||
strdata->options[i],
|
strdata->options[i],
|
||||||
WMTableViewRectForCell(table, column, row),
|
WMTableViewRectForCell(table, column, row),
|
||||||
True);
|
True);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
static void beginESCellEdit(WMTableColumnDelegate *self,
|
static void
|
||||||
WMTableColumn *column, int row)
|
beginESCellEdit(WMTableColumnDelegate *self, WMTableColumn *column, int row)
|
||||||
{
|
{
|
||||||
EnumSelectorData *strdata = (EnumSelectorData*)self->data;
|
EnumSelectorData *strdata = (EnumSelectorData*)self->data;
|
||||||
WMRect rect = WMTableViewRectForCell(strdata->table, column, row);
|
WMRect rect = WMTableViewRectForCell(strdata->table, column, row);
|
||||||
@@ -276,8 +275,8 @@ static void beginESCellEdit(WMTableColumnDelegate *self,
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
static void endESCellEdit(WMTableColumnDelegate *self,
|
static void
|
||||||
WMTableColumn *column, int row)
|
endESCellEdit(WMTableColumnDelegate *self, WMTableColumn *column, int row)
|
||||||
{
|
{
|
||||||
EnumSelectorData *strdata = (EnumSelectorData*)self->data;
|
EnumSelectorData *strdata = (EnumSelectorData*)self->data;
|
||||||
int option;
|
int option;
|
||||||
@@ -289,7 +288,8 @@ static void endESCellEdit(WMTableColumnDelegate *self,
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
WMTableColumnDelegate *WTCreateEnumSelectorDelegate(WMTableView *parent)
|
WMTableColumnDelegate*
|
||||||
|
WTCreateEnumSelectorDelegate(WMTableView *parent)
|
||||||
{
|
{
|
||||||
WMTableColumnDelegate *delegate = wmalloc(sizeof(WMTableColumnDelegate));
|
WMTableColumnDelegate *delegate = wmalloc(sizeof(WMTableColumnDelegate));
|
||||||
WMScreen *scr = WMWidgetScreen(parent);
|
WMScreen *scr = WMWidgetScreen(parent);
|
||||||
@@ -301,9 +301,9 @@ WMTableColumnDelegate *WTCreateEnumSelectorDelegate(WMTableView *parent)
|
|||||||
0, 0);
|
0, 0);
|
||||||
data->table = parent;
|
data->table = parent;
|
||||||
data->font = WMSystemFontOfSize(scr, 12);
|
data->font = WMSystemFontOfSize(scr, 12);
|
||||||
data->selGc = WMColorGC(WMCreateNamedColor(scr, SelectionColor, False));
|
data->gc = WMColorGC(WMWhiteColor(scr));
|
||||||
data->selTextGc = WMColorGC(WMBlackColor(scr));
|
data->selGC = WMColorGC(WMCreateNamedColor(scr, SelectionColor, False));
|
||||||
data->gc = WMColorGC(WMBlackColor(scr));
|
data->textColor = WMBlackColor(scr);
|
||||||
data->count = 0;
|
data->count = 0;
|
||||||
data->options = NULL;
|
data->options = NULL;
|
||||||
|
|
||||||
@@ -317,8 +317,9 @@ WMTableColumnDelegate *WTCreateEnumSelectorDelegate(WMTableView *parent)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void WTSetEnumSelectorOptions(WMTableColumnDelegate *delegate,
|
void
|
||||||
char **options, int count)
|
WTSetEnumSelectorOptions(WMTableColumnDelegate *delegate, char **options,
|
||||||
|
int count)
|
||||||
{
|
{
|
||||||
EnumSelectorData *data = (EnumSelectorData*)delegate->data;
|
EnumSelectorData *data = (EnumSelectorData*)delegate->data;
|
||||||
int i;
|
int i;
|
||||||
@@ -341,8 +342,9 @@ void WTSetEnumSelectorOptions(WMTableColumnDelegate *delegate,
|
|||||||
|
|
||||||
/* ---------------------------------------------------------------------- */
|
/* ---------------------------------------------------------------------- */
|
||||||
|
|
||||||
static void BSCellPainter(WMTableColumnDelegate *self,
|
static void
|
||||||
WMTableColumn *column, int row)
|
BSCellPainter(WMTableColumnDelegate *self, WMTableColumn *column,
|
||||||
|
int row, Drawable d)
|
||||||
{
|
{
|
||||||
BooleanSwitchData *strdata = (BooleanSwitchData*)self->data;
|
BooleanSwitchData *strdata = (BooleanSwitchData*)self->data;
|
||||||
WMTableView *table = WMGetTableColumnTableView(column);
|
WMTableView *table = WMGetTableColumnTableView(column);
|
||||||
@@ -350,19 +352,20 @@ static void BSCellPainter(WMTableColumnDelegate *self,
|
|||||||
WMScreen *scr = WMWidgetScreen(table);
|
WMScreen *scr = WMWidgetScreen(table);
|
||||||
|
|
||||||
if (i) {
|
if (i) {
|
||||||
pixmapDraw(scr, WMViewXID(WMGetTableViewDocumentView(table)),
|
pixmapDraw(scr, d,
|
||||||
strdata->gc, WMGetSystemPixmap(scr, WSICheckMark),
|
strdata->gc, strdata->selGC, WMGetSystemPixmap(scr, WSICheckMark),
|
||||||
WMTableViewRectForCell(table, column, row), False);
|
WMTableViewRectForCell(table, column, row), False);
|
||||||
} else {
|
} else {
|
||||||
pixmapDraw(scr, WMViewXID(WMGetTableViewDocumentView(table)),
|
pixmapDraw(scr, d,
|
||||||
strdata->gc, NULL,
|
strdata->gc, strdata->selGC, NULL,
|
||||||
WMTableViewRectForCell(table, column, row), False);
|
WMTableViewRectForCell(table, column, row), False);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
static void selectedBSCellPainter(WMTableColumnDelegate *self,
|
static void
|
||||||
WMTableColumn *column, int row)
|
selectedBSCellPainter(WMTableColumnDelegate *self, WMTableColumn *column,
|
||||||
|
int row, Drawable d)
|
||||||
{
|
{
|
||||||
BooleanSwitchData *strdata = (BooleanSwitchData*)self->data;
|
BooleanSwitchData *strdata = (BooleanSwitchData*)self->data;
|
||||||
WMTableView *table = WMGetTableColumnTableView(column);
|
WMTableView *table = WMGetTableColumnTableView(column);
|
||||||
@@ -370,20 +373,20 @@ static void selectedBSCellPainter(WMTableColumnDelegate *self,
|
|||||||
WMScreen *scr = WMWidgetScreen(table);
|
WMScreen *scr = WMWidgetScreen(table);
|
||||||
|
|
||||||
if (i) {
|
if (i) {
|
||||||
pixmapDraw(scr, WMViewXID(WMGetTableViewDocumentView(table)),
|
pixmapDraw(scr, d,
|
||||||
strdata->gc, WMGetSystemPixmap(scr, WSICheckMark),
|
strdata->gc, strdata->selGC, WMGetSystemPixmap(scr, WSICheckMark),
|
||||||
WMTableViewRectForCell(table, column, row), True);
|
WMTableViewRectForCell(table, column, row), True);
|
||||||
} else {
|
} else {
|
||||||
pixmapDraw(scr, WMViewXID(WMGetTableViewDocumentView(table)),
|
pixmapDraw(scr, d,
|
||||||
strdata->gc, NULL,
|
strdata->gc, strdata->selGC, NULL,
|
||||||
WMTableViewRectForCell(table, column, row), True);
|
WMTableViewRectForCell(table, column, row), True);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
static void beginBSCellEdit(WMTableColumnDelegate *self,
|
static void
|
||||||
WMTableColumn *column, int row)
|
beginBSCellEdit(WMTableColumnDelegate *self, WMTableColumn *column, int row)
|
||||||
{
|
{
|
||||||
BooleanSwitchData *strdata = (BooleanSwitchData*)self->data;
|
BooleanSwitchData *strdata = (BooleanSwitchData*)self->data;
|
||||||
WMRect rect = WMTableViewRectForCell(strdata->table, column, row);
|
WMRect rect = WMTableViewRectForCell(strdata->table, column, row);
|
||||||
@@ -397,8 +400,8 @@ static void beginBSCellEdit(WMTableColumnDelegate *self,
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
static void endBSCellEdit(WMTableColumnDelegate *self,
|
static void
|
||||||
WMTableColumn *column, int row)
|
endBSCellEdit(WMTableColumnDelegate *self, WMTableColumn *column, int row)
|
||||||
{
|
{
|
||||||
BooleanSwitchData *strdata = (BooleanSwitchData*)self->data;
|
BooleanSwitchData *strdata = (BooleanSwitchData*)self->data;
|
||||||
int value;
|
int value;
|
||||||
@@ -409,7 +412,8 @@ static void endBSCellEdit(WMTableColumnDelegate *self,
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
WMTableColumnDelegate *WTCreateBooleanSwitchDelegate(WMTableView *parent)
|
WMTableColumnDelegate*
|
||||||
|
WTCreateBooleanSwitchDelegate(WMTableView *parent)
|
||||||
{
|
{
|
||||||
WMTableColumnDelegate *delegate = wmalloc(sizeof(WMTableColumnDelegate));
|
WMTableColumnDelegate *delegate = wmalloc(sizeof(WMTableColumnDelegate));
|
||||||
WMScreen *scr = WMWidgetScreen(parent);
|
WMScreen *scr = WMWidgetScreen(parent);
|
||||||
@@ -428,7 +432,8 @@ WMTableColumnDelegate *WTCreateBooleanSwitchDelegate(WMTableView *parent)
|
|||||||
data->table = parent;
|
data->table = parent;
|
||||||
color = WMCreateNamedColor(scr, SelectionColor, False);
|
color = WMCreateNamedColor(scr, SelectionColor, False);
|
||||||
WMSetWidgetBackgroundColor(data->widget, color);
|
WMSetWidgetBackgroundColor(data->widget, color);
|
||||||
data->gc = WMColorGC(color);
|
data->gc = WMColorGC(WMWhiteColor(scr));
|
||||||
|
data->selGC = WMColorGC(color);
|
||||||
|
|
||||||
delegate->data = data;
|
delegate->data = data;
|
||||||
delegate->drawCell = BSCellPainter;
|
delegate->drawCell = BSCellPainter;
|
||||||
@@ -443,37 +448,38 @@ WMTableColumnDelegate *WTCreateBooleanSwitchDelegate(WMTableView *parent)
|
|||||||
/* ---------------------------------------------------------------------- */
|
/* ---------------------------------------------------------------------- */
|
||||||
|
|
||||||
|
|
||||||
static void SCellPainter(WMTableColumnDelegate *self,
|
static void
|
||||||
WMTableColumn *column, int row)
|
SCellPainter(WMTableColumnDelegate *self, WMTableColumn *column,
|
||||||
|
int row, Drawable d)
|
||||||
{
|
{
|
||||||
StringData *strdata = (StringData*)self->data;
|
StringData *strdata = (StringData*)self->data;
|
||||||
WMTableView *table = WMGetTableColumnTableView(column);
|
WMTableView *table = WMGetTableColumnTableView(column);
|
||||||
|
|
||||||
stringDraw(WMWidgetScreen(table),
|
stringDraw(WMWidgetScreen(table), d,
|
||||||
WMViewXID(WMGetTableViewDocumentView(table)),
|
strdata->gc, strdata->selGC, strdata->textColor, strdata->font,
|
||||||
strdata->gc, strdata->selGc, strdata->selTextGc, strdata->font,
|
|
||||||
WMTableViewDataForCell(table, column, row),
|
WMTableViewDataForCell(table, column, row),
|
||||||
WMTableViewRectForCell(table, column, row),
|
WMTableViewRectForCell(table, column, row),
|
||||||
False);
|
False);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
static void selectedSCellPainter(WMTableColumnDelegate *self,
|
static void
|
||||||
WMTableColumn *column, int row)
|
selectedSCellPainter(WMTableColumnDelegate *self, WMTableColumn *column,
|
||||||
|
int row, Drawable d)
|
||||||
{
|
{
|
||||||
StringData *strdata = (StringData*)self->data;
|
StringData *strdata = (StringData*)self->data;
|
||||||
WMTableView *table = WMGetTableColumnTableView(column);
|
WMTableView *table = WMGetTableColumnTableView(column);
|
||||||
|
|
||||||
stringDraw(WMWidgetScreen(table),
|
stringDraw(WMWidgetScreen(table), d,
|
||||||
WMViewXID(WMGetTableViewDocumentView(table)),
|
strdata->gc, strdata->selGC, strdata->textColor, strdata->font,
|
||||||
strdata->gc, strdata->selGc, strdata->selTextGc, strdata->font,
|
|
||||||
WMTableViewDataForCell(table, column, row),
|
WMTableViewDataForCell(table, column, row),
|
||||||
WMTableViewRectForCell(table, column, row),
|
WMTableViewRectForCell(table, column, row),
|
||||||
True);
|
True);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
WMTableColumnDelegate *WTCreateStringDelegate(WMTableView *parent)
|
WMTableColumnDelegate*
|
||||||
|
WTCreateStringDelegate(WMTableView *parent)
|
||||||
{
|
{
|
||||||
WMTableColumnDelegate *delegate = wmalloc(sizeof(WMTableColumnDelegate));
|
WMTableColumnDelegate *delegate = wmalloc(sizeof(WMTableColumnDelegate));
|
||||||
WMScreen *scr = WMWidgetScreen(parent);
|
WMScreen *scr = WMWidgetScreen(parent);
|
||||||
@@ -481,9 +487,9 @@ WMTableColumnDelegate *WTCreateStringDelegate(WMTableView *parent)
|
|||||||
|
|
||||||
data->table = parent;
|
data->table = parent;
|
||||||
data->font = WMSystemFontOfSize(scr, 12);
|
data->font = WMSystemFontOfSize(scr, 12);
|
||||||
data->selGc = WMColorGC(WMCreateNamedColor(scr, SelectionColor, False));
|
data->gc = WMColorGC(WMWhiteColor(scr));
|
||||||
data->selTextGc = WMColorGC(WMBlackColor(scr));
|
data->selGC = WMColorGC(WMCreateNamedColor(scr, SelectionColor, False));
|
||||||
data->gc = WMColorGC(WMBlackColor(scr));
|
data->textColor = WMBlackColor(scr);
|
||||||
|
|
||||||
delegate->data = data;
|
delegate->data = data;
|
||||||
delegate->drawCell = SCellPainter;
|
delegate->drawCell = SCellPainter;
|
||||||
@@ -498,44 +504,46 @@ WMTableColumnDelegate *WTCreateStringDelegate(WMTableView *parent)
|
|||||||
/* ---------------------------------------------------------------------- */
|
/* ---------------------------------------------------------------------- */
|
||||||
|
|
||||||
|
|
||||||
static void PCellPainter(WMTableColumnDelegate *self,
|
static void
|
||||||
WMTableColumn *column, int row)
|
PCellPainter(WMTableColumnDelegate *self, WMTableColumn *column,
|
||||||
|
int row, Drawable d)
|
||||||
{
|
{
|
||||||
StringData *strdata = (StringData*)self->data;
|
StringData *strdata = (StringData*)self->data;
|
||||||
WMTableView *table = WMGetTableColumnTableView(column);
|
WMTableView *table = WMGetTableColumnTableView(column);
|
||||||
|
|
||||||
pixmapDraw(WMWidgetScreen(table),
|
pixmapDraw(WMWidgetScreen(table), d,
|
||||||
WMViewXID(WMGetTableViewDocumentView(table)),
|
strdata->gc, strdata->selGC,
|
||||||
strdata->selGc,
|
|
||||||
(WMPixmap*)WMTableViewDataForCell(table, column, row),
|
(WMPixmap*)WMTableViewDataForCell(table, column, row),
|
||||||
WMTableViewRectForCell(table, column, row),
|
WMTableViewRectForCell(table, column, row),
|
||||||
False);
|
False);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
static void selectedPCellPainter(WMTableColumnDelegate *self,
|
static void
|
||||||
WMTableColumn *column, int row)
|
selectedPCellPainter(WMTableColumnDelegate *self, WMTableColumn *column,
|
||||||
|
int row, Drawable d)
|
||||||
{
|
{
|
||||||
StringData *strdata = (StringData*)self->data;
|
StringData *strdata = (StringData*)self->data;
|
||||||
WMTableView *table = WMGetTableColumnTableView(column);
|
WMTableView *table = WMGetTableColumnTableView(column);
|
||||||
|
|
||||||
pixmapDraw(WMWidgetScreen(table),
|
pixmapDraw(WMWidgetScreen(table), d,
|
||||||
WMViewXID(WMGetTableViewDocumentView(table)),
|
strdata->gc, strdata->selGC,
|
||||||
strdata->selGc,
|
|
||||||
(WMPixmap*)WMTableViewDataForCell(table, column, row),
|
(WMPixmap*)WMTableViewDataForCell(table, column, row),
|
||||||
WMTableViewRectForCell(table, column, row),
|
WMTableViewRectForCell(table, column, row),
|
||||||
True);
|
True);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
WMTableColumnDelegate *WTCreatePixmapDelegate(WMTableView *table)
|
WMTableColumnDelegate*
|
||||||
|
WTCreatePixmapDelegate(WMTableView *table)
|
||||||
{
|
{
|
||||||
WMTableColumnDelegate *delegate = wmalloc(sizeof(WMTableColumnDelegate));
|
WMTableColumnDelegate *delegate = wmalloc(sizeof(WMTableColumnDelegate));
|
||||||
WMScreen *scr = WMWidgetScreen(table);
|
WMScreen *scr = WMWidgetScreen(table);
|
||||||
StringData *data = wmalloc(sizeof(StringData));
|
StringData *data = wmalloc(sizeof(StringData));
|
||||||
|
|
||||||
data->table = table;
|
data->table = table;
|
||||||
data->selGc = WMColorGC(WMCreateNamedColor(scr, SelectionColor, False));
|
data->gc = WMColorGC(WMWhiteColor(scr));
|
||||||
|
data->selGC = WMColorGC(WMCreateNamedColor(scr, SelectionColor, False));
|
||||||
|
|
||||||
delegate->data = data;
|
delegate->data = data;
|
||||||
delegate->drawCell = PCellPainter;
|
delegate->drawCell = PCellPainter;
|
||||||
@@ -550,8 +558,9 @@ WMTableColumnDelegate *WTCreatePixmapDelegate(WMTableView *table)
|
|||||||
/* ---------------------------------------------------------------------- */
|
/* ---------------------------------------------------------------------- */
|
||||||
|
|
||||||
|
|
||||||
static void drawPSCell(WMTableColumnDelegate *self,
|
static void
|
||||||
WMTableColumn *column, int row, Bool selected)
|
drawPSCell(WMTableColumnDelegate *self, Drawable d, WMTableColumn *column,
|
||||||
|
int row, Bool selected)
|
||||||
{
|
{
|
||||||
StringData *strdata = (StringData*)self->data;
|
StringData *strdata = (StringData*)self->data;
|
||||||
WMTableView *table = WMGetTableColumnTableView(column);
|
WMTableView *table = WMGetTableColumnTableView(column);
|
||||||
@@ -576,35 +585,36 @@ static void drawPSCell(WMTableColumnDelegate *self,
|
|||||||
|
|
||||||
pixmapDraw(WMWidgetScreen(table),
|
pixmapDraw(WMWidgetScreen(table),
|
||||||
WMViewXID(WMGetTableViewDocumentView(table)),
|
WMViewXID(WMGetTableViewDocumentView(table)),
|
||||||
strdata->selGc, pix, rect,
|
strdata->gc, strdata->selGC, pix, rect,
|
||||||
selected);
|
selected);
|
||||||
|
|
||||||
rect.pos.x += size.width-1;
|
rect.pos.x += size.width-1;
|
||||||
rect.size.width = owidth-size.width+1;
|
rect.size.width = owidth-size.width+1;
|
||||||
}
|
}
|
||||||
|
|
||||||
stringDraw(WMWidgetScreen(table),
|
stringDraw(WMWidgetScreen(table), d, strdata->gc, strdata->selGC,
|
||||||
WMViewXID(WMGetTableViewDocumentView(table)),
|
strdata->textColor, strdata->font, str, rect, selected);
|
||||||
strdata->gc, strdata->selGc, strdata->selTextGc, strdata->font,
|
|
||||||
str, rect, selected);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
static void PSCellPainter(WMTableColumnDelegate *self,
|
static void
|
||||||
WMTableColumn *column, int row)
|
PSCellPainter(WMTableColumnDelegate *self, WMTableColumn *column,
|
||||||
|
int row, Drawable d)
|
||||||
{
|
{
|
||||||
drawPSCell(self, column, row, False);
|
drawPSCell(self, d, column, row, False);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
static void selectedPSCellPainter(WMTableColumnDelegate *self,
|
static void
|
||||||
WMTableColumn *column, int row)
|
selectedPSCellPainter(WMTableColumnDelegate *self, WMTableColumn *column,
|
||||||
|
int row, Drawable d)
|
||||||
{
|
{
|
||||||
drawPSCell(self, column, row, True);
|
drawPSCell(self, d, column, row, True);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
WMTableColumnDelegate *WTCreatePixmapStringDelegate(WMTableView *parent)
|
WMTableColumnDelegate*
|
||||||
|
WTCreatePixmapStringDelegate(WMTableView *parent)
|
||||||
{
|
{
|
||||||
WMTableColumnDelegate *delegate = wmalloc(sizeof(WMTableColumnDelegate));
|
WMTableColumnDelegate *delegate = wmalloc(sizeof(WMTableColumnDelegate));
|
||||||
WMScreen *scr = WMWidgetScreen(parent);
|
WMScreen *scr = WMWidgetScreen(parent);
|
||||||
@@ -612,9 +622,9 @@ WMTableColumnDelegate *WTCreatePixmapStringDelegate(WMTableView *parent)
|
|||||||
|
|
||||||
data->table = parent;
|
data->table = parent;
|
||||||
data->font = WMSystemFontOfSize(scr, 12);
|
data->font = WMSystemFontOfSize(scr, 12);
|
||||||
data->selGc = WMColorGC(WMCreateNamedColor(scr, SelectionColor, False));
|
data->gc = WMColorGC(WMWhiteColor(scr));
|
||||||
data->selTextGc = WMColorGC(WMBlackColor(scr));
|
data->selGC = WMColorGC(WMCreateNamedColor(scr, SelectionColor, False));
|
||||||
data->gc = WMColorGC(WMBlackColor(scr));
|
data->textColor = WMBlackColor(scr);
|
||||||
|
|
||||||
delegate->data = data;
|
delegate->data = data;
|
||||||
delegate->drawCell = PSCellPainter;
|
delegate->drawCell = PSCellPainter;
|
||||||
@@ -624,3 +634,5 @@ WMTableColumnDelegate *WTCreatePixmapStringDelegate(WMTableView *parent)
|
|||||||
|
|
||||||
return delegate;
|
return delegate;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@@ -17,10 +17,11 @@ extern const char *WMTableViewSelectionDidChangeNotification;
|
|||||||
|
|
||||||
typedef struct WMTableColumnDelegate {
|
typedef struct WMTableColumnDelegate {
|
||||||
void *data;
|
void *data;
|
||||||
void (*drawCell)(struct WMTableColumnDelegate *self, WMTableColumn *column,
|
void (*drawCell)(struct WMTableColumnDelegate *self,
|
||||||
int row);
|
WMTableColumn *column, int row, Drawable d);
|
||||||
void (*drawSelectedCell)(struct WMTableColumnDelegate *self,
|
void (*drawSelectedCell)(struct WMTableColumnDelegate *self,
|
||||||
WMTableColumn *column, int row);
|
WMTableColumn *column, int row, Drawable d);
|
||||||
|
|
||||||
void (*beginCellEdit)(struct WMTableColumnDelegate *self, WMTableColumn *column,
|
void (*beginCellEdit)(struct WMTableColumnDelegate *self, WMTableColumn *column,
|
||||||
int row);
|
int row);
|
||||||
void (*endCellEdit)(struct WMTableColumnDelegate *self, WMTableColumn *column,
|
void (*endCellEdit)(struct WMTableColumnDelegate *self, WMTableColumn *column,
|
||||||
@@ -46,6 +47,9 @@ WMTableColumn *WMCreateTableColumn(char *title);
|
|||||||
|
|
||||||
void WMSetTableColumnWidth(WMTableColumn *column, unsigned width);
|
void WMSetTableColumnWidth(WMTableColumn *column, unsigned width);
|
||||||
|
|
||||||
|
void WMSetTableColumnConstraints(WMTableColumn *column,
|
||||||
|
unsigned minWidth, unsigned maxWidth);
|
||||||
|
|
||||||
void WMSetTableColumnDelegate(WMTableColumn *column,
|
void WMSetTableColumnDelegate(WMTableColumn *column,
|
||||||
WMTableColumnDelegate *delegate);
|
WMTableColumnDelegate *delegate);
|
||||||
|
|
||||||
@@ -77,6 +81,8 @@ void *WMGetTableViewClickedColumn(WMTableView *table);
|
|||||||
|
|
||||||
int WMGetTableViewClickedRow(WMTableView *table);
|
int WMGetTableViewClickedRow(WMTableView *table);
|
||||||
|
|
||||||
|
WMArray *WMGetTableViewSelectedRows(WMTableView *table);
|
||||||
|
|
||||||
WMView *WMGetTableViewDocumentView(WMTableView *table);
|
WMView *WMGetTableViewDocumentView(WMTableView *table);
|
||||||
|
|
||||||
void WMEditTableViewRow(WMTableView *table, int row);
|
void WMEditTableViewRow(WMTableView *table, int row);
|
||||||
@@ -103,6 +109,10 @@ void WMReloadTableView(WMTableView *table);
|
|||||||
void WMNoteTableViewNumberOfRowsChanged(WMTableView *table);
|
void WMNoteTableViewNumberOfRowsChanged(WMTableView *table);
|
||||||
|
|
||||||
void WMScrollTableViewRowToVisible(WMTableView *table, int row);
|
void WMScrollTableViewRowToVisible(WMTableView *table, int row);
|
||||||
|
|
||||||
|
void WMSetTableViewHasHorizontalScroller(WMTableView *tPtr, Bool flag);
|
||||||
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@@ -2,47 +2,48 @@
|
|||||||
|
|
||||||
AUTOMAKE_OPTIONS = no-dependencies
|
AUTOMAKE_OPTIONS = no-dependencies
|
||||||
|
|
||||||
SUBDIRS = . Documentation Resources Examples Extras Tests
|
SUBDIRS = WINGs . po Documentation Resources Examples Extras Tests
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#libWINGs_la_LDFLAGS = -version-info 1:1:0
|
#libWINGs_la_LDFLAGS = -version-info 1:1:0
|
||||||
|
|
||||||
# is this a kluge? if so, how should i do it?
|
|
||||||
includedir = @includedir@/WINGs
|
|
||||||
|
|
||||||
include_HEADERS = WINGs.h WUtil.h WINGsP.h
|
|
||||||
|
|
||||||
bin_SCRIPTS = get-wings-flags get-wutil-flags
|
bin_SCRIPTS = get-wings-flags get-wutil-flags
|
||||||
|
|
||||||
lib_LIBRARIES = libWINGs.a libWUtil.a
|
lib_LIBRARIES = libWINGs.a libWUtil.a
|
||||||
|
|
||||||
|
|
||||||
LDADD= libWINGs.a $(top_builddir)/wrlib/libwraster.la @LIBPL@
|
LDADD= libWINGs.a $(top_builddir)/wrlib/libwraster.la @INTLIBS@
|
||||||
|
|
||||||
|
|
||||||
EXTRA_DIST = BUGS
|
EXTRA_DIST = BUGS python/Makefile python/README python/WINGs.i \
|
||||||
|
python/WINGs.py python/setup.py python/test.py
|
||||||
|
|
||||||
|
|
||||||
# wbutton.c
|
# wbutton.c
|
||||||
libWINGs_a_SOURCES = \
|
libWINGs_a_SOURCES = \
|
||||||
WINGs.h \
|
|
||||||
WINGsP.h \
|
|
||||||
array.c \
|
array.c \
|
||||||
bagtree.c \
|
bagtree.c \
|
||||||
configuration.c \
|
configuration.c \
|
||||||
connection.c \
|
connection.c \
|
||||||
data.c \
|
data.c \
|
||||||
|
dragcommon.c \
|
||||||
dragdestination.c \
|
dragdestination.c \
|
||||||
dragsource.c \
|
dragsource.c \
|
||||||
error.c \
|
error.c \
|
||||||
findfile.c \
|
findfile.c \
|
||||||
|
handlers.c \
|
||||||
hashtable.c \
|
hashtable.c \
|
||||||
host.c \
|
host.c \
|
||||||
international.c \
|
international.c \
|
||||||
memory.c \
|
memory.c \
|
||||||
|
misc.c \
|
||||||
notification.c \
|
notification.c \
|
||||||
|
proplist.c \
|
||||||
selection.c \
|
selection.c \
|
||||||
|
snprintf.c \
|
||||||
string.c \
|
string.c \
|
||||||
|
tree.c \
|
||||||
userdefaults.c \
|
userdefaults.c \
|
||||||
usleep.c \
|
usleep.c \
|
||||||
wapplication.c \
|
wapplication.c \
|
||||||
@@ -54,12 +55,14 @@ libWINGs_a_SOURCES = \
|
|||||||
wcolor.c \
|
wcolor.c \
|
||||||
wcolorpanel.c \
|
wcolorpanel.c \
|
||||||
wcolorwell.c \
|
wcolorwell.c \
|
||||||
|
wconfig.h \
|
||||||
wevent.c \
|
wevent.c \
|
||||||
wfilepanel.c \
|
wfilepanel.c \
|
||||||
wframe.c \
|
wframe.c \
|
||||||
wfont.c \
|
wfont.c \
|
||||||
wfontpanel.c \
|
wfontpanel.c \
|
||||||
widgets.c \
|
widgets.c \
|
||||||
|
winputmethod.c \
|
||||||
wlabel.c \
|
wlabel.c \
|
||||||
wlist.c \
|
wlist.c \
|
||||||
wmenuitem.c \
|
wmenuitem.c \
|
||||||
@@ -81,29 +84,49 @@ libWINGs_a_SOURCES = \
|
|||||||
|
|
||||||
|
|
||||||
libWUtil_a_SOURCES = \
|
libWUtil_a_SOURCES = \
|
||||||
WINGs.h \
|
|
||||||
WINGsP.h \
|
|
||||||
array.c \
|
array.c \
|
||||||
bagtree.c \
|
bagtree.c \
|
||||||
connection.c \
|
connection.c \
|
||||||
data.c \
|
data.c \
|
||||||
error.c \
|
error.c \
|
||||||
findfile.c \
|
findfile.c \
|
||||||
|
handlers.c \
|
||||||
hashtable.c \
|
hashtable.c \
|
||||||
host.c \
|
host.c \
|
||||||
international.c \
|
international.c \
|
||||||
memory.c \
|
memory.c \
|
||||||
|
misc.c \
|
||||||
notification.c \
|
notification.c \
|
||||||
|
proplist.c \
|
||||||
|
snprintf.c \
|
||||||
string.c \
|
string.c \
|
||||||
|
tree.c \
|
||||||
userdefaults.c \
|
userdefaults.c \
|
||||||
usleep.c \
|
usleep.c \
|
||||||
wapplication.c \
|
wapplication.c \
|
||||||
|
wconfig.h \
|
||||||
wutil.c
|
wutil.c
|
||||||
|
|
||||||
|
|
||||||
INCLUDES = -I$(top_srcdir)/wrlib -I$(top_srcdir)/src \
|
AM_CPPFLAGS = -DLOCALEDIR=\"$(NLSDIR)\"
|
||||||
-DRESOURCE_PATH=\"$(datadir)/WINGs\" @HEADER_SEARCH_PATH@ -DDEBUG
|
|
||||||
|
AM_CFLAGS = @NOSTRICTALIASING@
|
||||||
|
|
||||||
|
INCLUDES = -I$(top_srcdir)/WINGs/WINGs -I$(top_srcdir)/wrlib -I$(top_srcdir)/src \
|
||||||
|
-DRESOURCE_PATH=\"$(datadir)/WINGs\" @XFTFLAGS@ @HEADER_SEARCH_PATH@ -DDEBUG
|
||||||
|
|
||||||
|
|
||||||
wcolorpanel.o: wcolorpanel.c
|
wcolorpanel.o: wcolorpanel.c
|
||||||
$(COMPILE) -c -DRGBTXT="\"@X_LIBRARY_PATH@/X11/rgb.txt\"" $<
|
$(COMPILE) -c -DRGBTXT="\"@X_LIBRARY_PATH@/X11/rgb.txt\"" $<
|
||||||
|
|
||||||
|
DISTCLEANFILES = WINGs.pc
|
||||||
|
|
||||||
|
install-exec-local:
|
||||||
|
@$(NORMAL_INSTALL)
|
||||||
|
$(mkinstalldirs) $(DESTDIR)$(libdir)/pkgconfig
|
||||||
|
@list='WINGs.pc'; for p in $$list; do \
|
||||||
|
if test -f $$p; then \
|
||||||
|
echo "$(INSTALL_DATA) $$p $(DESTDIR)$(libdir)/pkgconfig/"; \
|
||||||
|
$(INSTALL_DATA) $$p $(DESTDIR)$(libdir)/pkgconfig/; \
|
||||||
|
else :; fi; \
|
||||||
|
done
|
||||||
|
|||||||
293
WINGs/NEWS
Normal file
293
WINGs/NEWS
Normal file
@@ -0,0 +1,293 @@
|
|||||||
|
*** Mon Oct 14 19:42:42 EEST 2002 - Dan
|
||||||
|
|
||||||
|
Double buffering
|
||||||
|
----------------
|
||||||
|
|
||||||
|
To avoid flickering caused by redrawing the widgets on Expose events, a
|
||||||
|
double buffering tehnique was implemented for most of the widgets.
|
||||||
|
This flickering effect has gotten more vizible with the introduction
|
||||||
|
of antialiased fonts. If with normal text one can redraw the text over the
|
||||||
|
old one over and over again without any degradation of the text (new pixels
|
||||||
|
simply overwrite old pixels), with antialiased text the situation is
|
||||||
|
different and text gets quickly corrupted. To avoid this corruption, one
|
||||||
|
needs to first erase the area where the text will go, which can cause the
|
||||||
|
before mentioned flickering.
|
||||||
|
The double buffer is implemented to solve this issue.
|
||||||
|
|
||||||
|
This is a change that that will be automatically available for any WINGs
|
||||||
|
applications and will require no change in the existing code.
|
||||||
|
However there is an exception from this in case of WMList if you delegate
|
||||||
|
the drawing of items to userspace (read below for the compelte details).
|
||||||
|
|
||||||
|
|
||||||
|
*** Mon Oct 14 22:07:42 EEST 2002 - Dan
|
||||||
|
|
||||||
|
WMList change
|
||||||
|
-------------
|
||||||
|
|
||||||
|
In case of WMList there is the posibility to delegate the drawing of the
|
||||||
|
list items to the application that is linked with WINGs, and this code will
|
||||||
|
not be inside the WINGs library, but in userland. Since we use the double
|
||||||
|
buffering tehnique in this case too (to allow all widgets based on WMList
|
||||||
|
and the ones that draw their list items by themselves to benefit from the
|
||||||
|
double buffering advantage automatically), we no longer pass the window to
|
||||||
|
the user code doing item drawing, but instead pass this pixmap in which we
|
||||||
|
draw before copying to the real window.
|
||||||
|
|
||||||
|
Since one cannot use XClearWindow() or XClearArea() on pixmaps, but only on
|
||||||
|
windows, if the code drawing list items used to call these functions to clear
|
||||||
|
the item area before drawing it needs to change to using XFillRectangle()
|
||||||
|
instead.
|
||||||
|
|
||||||
|
With this change it also means that there is no longer any need to do any
|
||||||
|
double buffering in the user code, since it's already done by WINGs.
|
||||||
|
|
||||||
|
|
||||||
|
*** Mon Oct 14 19:28:35 EEST 2002 - Dan
|
||||||
|
|
||||||
|
API change
|
||||||
|
----------
|
||||||
|
|
||||||
|
WMDrawString() and WMDrawImageString() no longer take a GC as argument.
|
||||||
|
Instead WMDrawString() takes a WMColor* as the color for the string to be
|
||||||
|
drawn, while WMDrawImageString() takes 2 WMColor* arguments in place of the
|
||||||
|
old GC: first for text color and second for background color.
|
||||||
|
|
||||||
|
This change is required to support extending WMFont to allow it to handle
|
||||||
|
antialiased fonts through the XFree86 Xft2 extension.
|
||||||
|
|
||||||
|
This also has the advantage of hiding low level X11 details and use WINGs
|
||||||
|
internat objects instead.
|
||||||
|
|
||||||
|
To fix your old code to work with the new WINGs API you need to replace the
|
||||||
|
GC passed to WMDraw***String() in your code with a WMColor*.
|
||||||
|
Most of the old code used to be like this:
|
||||||
|
|
||||||
|
WMDrawString(screen, window, WMColorGC(color), font, x, y, txt, len);
|
||||||
|
|
||||||
|
for the new API it should be replaced by:
|
||||||
|
|
||||||
|
WMDrawString(screen, window, color, font, x, y, txt, len);
|
||||||
|
|
||||||
|
However if you used a particular GC created by yourself to suit your special
|
||||||
|
needs, you need to pass a color which is the same as the foreground color of
|
||||||
|
that gc.
|
||||||
|
|
||||||
|
For WMDrawImageString(), from:
|
||||||
|
|
||||||
|
WMDrawImageString(screen, window, gc, font, x, y, txt, len);
|
||||||
|
|
||||||
|
becomes
|
||||||
|
|
||||||
|
WMDrawImageString(screen, window, textColor, backColor, font, x, y, txt, len);
|
||||||
|
|
||||||
|
where textColor and backColor are declared like:
|
||||||
|
|
||||||
|
WMColor *textColor, *backColor;
|
||||||
|
|
||||||
|
and have the color of the foreground respective the background of the old gc.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
*** Wed Oct 9 07:10:04 EEST 2002 - Dan
|
||||||
|
|
||||||
|
Antialiased font support
|
||||||
|
------------------------
|
||||||
|
|
||||||
|
With the addition of Xft2 support in the WINGs library, now WINGs can display
|
||||||
|
antialiased text with TrueType or any scalable fonts.
|
||||||
|
|
||||||
|
Antialiased text is enabled by default, but can be disabled by adding
|
||||||
|
|
||||||
|
AntialiasedText = NO; in ~/GNUstep/Defaults/WMGLOBAL
|
||||||
|
|
||||||
|
This will disable antialiased text for any WINGs based application. If you
|
||||||
|
only want to disable them for a specific application only, like WindowMaker
|
||||||
|
for example, then add the same option in the applications configuration file,
|
||||||
|
in this case ~/GNUstep/Defaults/WindowMaker
|
||||||
|
|
||||||
|
Note that bitmapped fonts look much better than TrueType when antialiasing is
|
||||||
|
disabled.
|
||||||
|
|
||||||
|
|
||||||
|
*** Mon Sep 09 06:58:30 EEST 2002 - Dan
|
||||||
|
|
||||||
|
New delegate for the WMConnection class
|
||||||
|
---------------------------------------
|
||||||
|
|
||||||
|
ConnectionDelegate structure has a new member: canResumeSending.
|
||||||
|
The purpose of this callback is to notify you that you can resume sending
|
||||||
|
data over a WMConnection.
|
||||||
|
It works in the following manner:
|
||||||
|
|
||||||
|
WMSendConnectionData() can return 3 values: -1, 0, 1
|
||||||
|
|
||||||
|
-1 - means that the connection has died. you should stop sending data and
|
||||||
|
close the connection ASAP.
|
||||||
|
1 - means that the data was succesfully sent
|
||||||
|
0 - means that the data (or part of it) was not sent. however, it was saved
|
||||||
|
in a queue and the library will try to send it later when possible.
|
||||||
|
|
||||||
|
if the return value is 1, you can continue to send the next message, and so
|
||||||
|
on, until the return value of such a send call will be 0.
|
||||||
|
After it returns 0 you can continue sending, however, the data will not be
|
||||||
|
sent over the connection because the operating system cannot accept any more
|
||||||
|
data for the moment. Instead it will be queued inside the library, making your
|
||||||
|
program's memory footprint increase. If the ammount of data you need to
|
||||||
|
send is limited and not too big, this shouldn't be a problem, because your
|
||||||
|
data will be queued and sent when the operating system will notify the
|
||||||
|
library that sending is possible again.
|
||||||
|
If this is the case you can just ignore the output of WMSendConnectionData()
|
||||||
|
and not set a callback for canResumeSending.
|
||||||
|
|
||||||
|
However, if the ammount of data you have to send is undetermined and you
|
||||||
|
also want to keep a small memory footprint for your program (so that it
|
||||||
|
won't grow until it uses all your available memory ;) ), you will have to
|
||||||
|
stop sending data over the connection as soon as WMSendConnectionData()
|
||||||
|
returns with 0. Then you should somehow mark this situation in your program
|
||||||
|
to avoid it trying to send anymore data until notified that it can resume.
|
||||||
|
(You should have also set a canResumeSending callback when you initialized
|
||||||
|
your WMConnection object because else you cannot be notified when to resume.)
|
||||||
|
|
||||||
|
Now, when you receive such a 0 from the send operation, your last sent data
|
||||||
|
is put in a queue inside the library. At a later time when the operating
|
||||||
|
system notifies the library that sending is possible again, the library will
|
||||||
|
resume to send the data that is saved in the queue. After it will be able to
|
||||||
|
send all the data in the queue, the canResumeSending callback will be
|
||||||
|
called, letting you know that not only you can resume sending because the
|
||||||
|
operating system is again able to send data, but also that the queue was
|
||||||
|
completely flushed.
|
||||||
|
|
||||||
|
From the canResumeSending callback, you should again update the status of
|
||||||
|
your program marking that it can send again, and then resume sending the
|
||||||
|
data from where you were left.
|
||||||
|
|
||||||
|
|
||||||
|
*** Thu Oct 04 06:00:09 EEST 2001 -Dan
|
||||||
|
|
||||||
|
Property lists handling code
|
||||||
|
----------------------------
|
||||||
|
|
||||||
|
Code to handle property lists was added to WINGs. It is more robust
|
||||||
|
than the libPropList code, mostly because some conflicting concepts
|
||||||
|
borrowed from UserDefaults (which libPropList use) are no longer used in
|
||||||
|
the WINGs property lists code. These borrowed concepts conflicted with the
|
||||||
|
retain/release mechanism of property lists and could lead in certain cases
|
||||||
|
to segmentation faults when executing libPropList based code. But the worse
|
||||||
|
part was that these libPropList problems were practically unsolvable without
|
||||||
|
removing one of those conflicting concepts and without a complete redesign.
|
||||||
|
The new WINGs property lists code is also better integrated with the other
|
||||||
|
data types from WINGs and is actively maintained.
|
||||||
|
|
||||||
|
Practically the things that were removed from the WINGs property list
|
||||||
|
implementation compared to the old libPropList implementation, are exactly
|
||||||
|
the UserDefaults borrowed concepts that conflict with the retain/release
|
||||||
|
mechanism:
|
||||||
|
- The container of a proplist object and the associated functions are gone.
|
||||||
|
- The filename associated with a proplist object and the corresponding
|
||||||
|
functions are gone. Now the saving function needs the filename as a
|
||||||
|
parameter.
|
||||||
|
- The synchronization functions are no longer supported. They are part of
|
||||||
|
the UserDefaults and are implemented there.
|
||||||
|
- No functions related to domains/registering were implemented in the WINGs
|
||||||
|
property lists code, because they are also not part of property lists.
|
||||||
|
They are more in connection with UserDefaults and a central point of access
|
||||||
|
for domains.
|
||||||
|
|
||||||
|
The above 2 concepts: container and filename were added to libPropList just
|
||||||
|
to let it support synchronization which was borrowed from UserDefaults.
|
||||||
|
Property lists as defined in the openstep specification are just complex
|
||||||
|
data structures composed of strings, data, arrays, dictionaries and a mix of
|
||||||
|
them and are not associated with any file in particular. UserDefaults on the
|
||||||
|
other hand are property lists read from a specific file and they associate
|
||||||
|
that property list with that file and allow them to be synchronized.
|
||||||
|
|
||||||
|
Old libPropList based code can still be used by linking against the WINGs
|
||||||
|
library containing the new proplist code with minimal changes which are
|
||||||
|
described in detail in the comments at the top of the WINGs/proplist-compat.h
|
||||||
|
header file (the same file carries the #defines for mapping old libPropList
|
||||||
|
functions to the new WINGs proplist functions).
|
||||||
|
Our recommendation is to move to the new functions WINGs provide because
|
||||||
|
they better integrate with other function naming conventions in WINGs.
|
||||||
|
The proplist-compat.h header file is just a way to have old code up and
|
||||||
|
running with minimal changes so that we can remove the old and unmaintained
|
||||||
|
libPropList from systems while keeping to use old libPropList based code
|
||||||
|
without rewriting it and it should not be used for other purposes.
|
||||||
|
|
||||||
|
|
||||||
|
*** Sat Apr 21 09:12:09 EEST 2001 -Dan
|
||||||
|
|
||||||
|
API change
|
||||||
|
----------
|
||||||
|
|
||||||
|
To allow a correct display of icon images with alpha blending in panels and
|
||||||
|
other places where a WINGs based application may use them the following
|
||||||
|
changes took place:
|
||||||
|
|
||||||
|
1. The following functions were renamed:
|
||||||
|
- WMSetApplicationIconImage() --> WMSetApplicationIconPixmap()
|
||||||
|
- WMGetApplicationIconImage() --> WMGetApplicationIconPixmap()
|
||||||
|
- WMSetWindowMiniwindowImage() --> WMSetWindowMiniwindowPixmap()
|
||||||
|
2. The following functions were added:
|
||||||
|
- WMSetApplicationIconImage(WMScreen *scr, RImage *image)
|
||||||
|
- RImage* WMGetApplicationIconImage(WMScreen *scr)
|
||||||
|
- WMPixmap* WMCreateApplicationIconBlendedPixmap(WMScreen *scr, RColor *col)
|
||||||
|
|
||||||
|
As you can see the old functions that operated on WMPixmap images (which are
|
||||||
|
basically X Pixmaps that lack alpha information) were renamed to ...Pixmap()
|
||||||
|
to make them more suggestive about what they do and to make room for the
|
||||||
|
new functions that operate on RImages (that hold alpha information).
|
||||||
|
|
||||||
|
Since the corresponding WMGet... functions only retrieve the stored
|
||||||
|
image/pixmap from the application, I'll outline how the WMSet...
|
||||||
|
functions operate:
|
||||||
|
|
||||||
|
All WM...IconPixmap() functions operate on WMPixmaps
|
||||||
|
All WM...IconImage() functions operate on RImages
|
||||||
|
|
||||||
|
|
||||||
|
- WMSetApplicationIconImage() will set the RImage to be used in panels
|
||||||
|
and will also convert the RImage to a WMPixmap with a threshold of 128
|
||||||
|
and will use that pixmap for the appicon image. If that doesn't satisfy
|
||||||
|
you, you can make a call to WMSetApplicationIconPixmap() on your own to
|
||||||
|
set whatever WMPixmap you see fit for the appicon.
|
||||||
|
|
||||||
|
- WMSetApplicationIconPixmap() will set the WMPixmap to be used for the
|
||||||
|
appicon and for the panels
|
||||||
|
|
||||||
|
|
||||||
|
If you use only one of the above functions, the corresponding image/pixmap
|
||||||
|
will be used everywhere where needed (panels and appicon), but the pixmap
|
||||||
|
version will not be able to handle alpha blending correctly.
|
||||||
|
|
||||||
|
If you use both WMSetApplicationIconImage() and WMSetApplicationIconPixmap()
|
||||||
|
then the RImage will have priority in panels, and the WMPixmap will only be
|
||||||
|
used for the appicon. This allows you to better control what icon is
|
||||||
|
displayed in the appicon, in case the default conversion of the RImage to a
|
||||||
|
pixmap with a threshold of 128 is not good enough, or in case you want a
|
||||||
|
different icon to be shown in the appicon than in panels.
|
||||||
|
|
||||||
|
|
||||||
|
Also this new function was added:
|
||||||
|
|
||||||
|
- WMCreateApplicationIconBlendedPixmap() will use the RImage set with
|
||||||
|
WMSetApplicationIconImage() if available and will blend it with the color
|
||||||
|
you passed. This will make the image show well on a background of that
|
||||||
|
color. If the RImage was not set it will return NULL. You need to call
|
||||||
|
WMReleasePixmap() on it after you finish with it. Passing a NULL pointer
|
||||||
|
instead of a color will make the RImage be blended with the default color
|
||||||
|
of the WINGs widgets: '#aeaaae' making it suitable to be assigned to any
|
||||||
|
WINGs widget.
|
||||||
|
|
||||||
|
|
||||||
|
To make your existing code work as before all you need to do is to rename
|
||||||
|
the following functions:
|
||||||
|
|
||||||
|
- WMSetApplicationIconImage() --> WMSetApplicationIconPixmap()
|
||||||
|
- WMGetApplicationIconImage() --> WMGetApplicationIconPixmap()
|
||||||
|
- WMSetWindowMiniwindowImage() --> WMSetWindowMiniwindowPixmap()
|
||||||
|
|
||||||
|
But if you want to take advantage of the new abilities to show alpha
|
||||||
|
blended images you need to start using the new functions.
|
||||||
|
|
||||||
|
|
||||||
@@ -13,7 +13,7 @@ is inspired in OpenStep and it's implementation borrows some ideas
|
|||||||
from Tk. It has a reasonable set of widgets, sufficient for building
|
from Tk. It has a reasonable set of widgets, sufficient for building
|
||||||
small applications (like a CDPlayer or hacking something like rxvt). It
|
small applications (like a CDPlayer or hacking something like rxvt). It
|
||||||
also has other functions that are usefull for applications, like a
|
also has other functions that are usefull for applications, like a
|
||||||
User Defaults like configuration manager and a notification system.
|
User Defaults alike configuration manager and a notification system.
|
||||||
|
|
||||||
The library is limited and it's design is a little sloppy,
|
The library is limited and it's design is a little sloppy,
|
||||||
so it's not intended to build large or complex applications, like
|
so it's not intended to build large or complex applications, like
|
||||||
|
|||||||
@@ -1,3 +1,2 @@
|
|||||||
Makefile Makefile.in
|
Makefile Makefile.in
|
||||||
.psrc .inslog2 tca.map tca.log
|
.psrc .inslog2 tca.map tca.log pchdir *.rpt
|
||||||
*.rpt
|
|
||||||
|
|||||||
@@ -4,6 +4,9 @@
|
|||||||
Or a delegate to be called when the list selection change.
|
Or a delegate to be called when the list selection change.
|
||||||
- add some way to modify speed when scrolling WMList, depending on how
|
- add some way to modify speed when scrolling WMList, depending on how
|
||||||
far the mouse is moved outside of the list.
|
far the mouse is moved outside of the list.
|
||||||
|
- clean up header files of declared but not implemented anywhere functions
|
||||||
|
- implement a generic WMChangeFontAttribute(WMFont *font, enum attributes)
|
||||||
|
function
|
||||||
|
|
||||||
|
|
||||||
- optimize color allocation for repeated colors
|
- optimize color allocation for repeated colors
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
Makefile Makefile.in
|
Makefile Makefile.in
|
||||||
testtext testcolorpanel testmywidget wmfile wmquery wtest
|
testtext testcolorpanel testmywidget wmfile wmquery wtest
|
||||||
.libs
|
.libs
|
||||||
.psrc .inslog2 tca.map tca.log
|
.psrc .inslog2 tca.map tca.log pchdir *.rpt
|
||||||
*.rpt
|
|
||||||
|
|||||||
@@ -2,10 +2,10 @@
|
|||||||
|
|
||||||
AUTOMAKE_OPTIONS = no-dependencies
|
AUTOMAKE_OPTIONS = no-dependencies
|
||||||
|
|
||||||
noinst_PROGRAMS = wtest wmquery wmfile testmywidget testcolorpanel
|
noinst_PROGRAMS = wtest wmquery wmfile testmywidget
|
||||||
|
|
||||||
LDADD= $(top_builddir)/WINGs/libWINGs.a $(top_builddir)/wrlib/libwraster.la \
|
LDADD= $(top_builddir)/WINGs/libWINGs.a $(top_builddir)/wrlib/libwraster.la \
|
||||||
@LIBPL@
|
@XFTLIBS@ @INTLIBS@
|
||||||
|
|
||||||
|
|
||||||
testmywidget_SOURCES = testmywidget.c mywidget.c mywidget.h
|
testmywidget_SOURCES = testmywidget.c mywidget.c mywidget.h
|
||||||
@@ -16,6 +16,7 @@ wtest_DEPENDENCIES = $(top_builddir)/WINGs/libWINGs.a
|
|||||||
EXTRA_DIST = logo.xpm upbtn.xpm wm.html wm.png
|
EXTRA_DIST = logo.xpm upbtn.xpm wm.html wm.png
|
||||||
|
|
||||||
INCLUDES = -I$(top_srcdir)/WINGs -I$(top_srcdir)/wrlib -I$(top_srcdir)/src \
|
INCLUDES = -I$(top_srcdir)/WINGs -I$(top_srcdir)/wrlib -I$(top_srcdir)/src \
|
||||||
-DRESOURCE_PATH=\"$(datadir)/WINGs\" @HEADER_SEARCH_PATH@ -DDEBUG
|
-DRESOURCE_PATH=\"$(datadir)/WINGs\" @XFTFLAGS@ @HEADER_SEARCH_PATH@ \
|
||||||
|
-DDEBUG
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -14,7 +14,7 @@
|
|||||||
*
|
*
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
#include "WINGsP.h"
|
#include <WINGs/WINGsP.h>
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Our public header.
|
* Our public header.
|
||||||
@@ -150,7 +150,7 @@ paintMyWidget(_MyWidget *mPtr)
|
|||||||
color = WMWhiteColor(scr);
|
color = WMWhiteColor(scr);
|
||||||
|
|
||||||
W_PaintText(mPtr->view, mPtr->view->window, scr->normalFont, 0, 0,
|
W_PaintText(mPtr->view, mPtr->view->window, scr->normalFont, 0, 0,
|
||||||
mPtr->view->size.width, WACenter, WMColorGC(color),
|
mPtr->view->size.width, WACenter, color,
|
||||||
False, mPtr->text, strlen(mPtr->text));
|
False, mPtr->text, strlen(mPtr->text));
|
||||||
|
|
||||||
WMReleaseColor(color);
|
WMReleaseColor(color);
|
||||||
|
|||||||
@@ -1,81 +0,0 @@
|
|||||||
/*
|
|
||||||
* Author: Pascal Hofstee <daeron@shadowmere.student.utwente.nl>
|
|
||||||
*/
|
|
||||||
|
|
||||||
|
|
||||||
#include "WINGs.h"
|
|
||||||
|
|
||||||
#include <unistd.h>
|
|
||||||
#include <stdio.h>
|
|
||||||
|
|
||||||
#include "logo.xpm"
|
|
||||||
|
|
||||||
void
|
|
||||||
wAbort()
|
|
||||||
{
|
|
||||||
exit(1);
|
|
||||||
}
|
|
||||||
|
|
||||||
char *ProgName;
|
|
||||||
|
|
||||||
|
|
||||||
int main(int argc, char **argv)
|
|
||||||
{
|
|
||||||
Display *dpy = XOpenDisplay("");
|
|
||||||
WMScreen *scr;
|
|
||||||
WMPixmap *pixmap;
|
|
||||||
WMColorPanel *panel;
|
|
||||||
WMColor *startcolor;
|
|
||||||
char *colorname = NULL;
|
|
||||||
int i;
|
|
||||||
|
|
||||||
#if 0
|
|
||||||
XSynchronize(dpy, True);
|
|
||||||
fprintf(stderr, "...Running Synchronous...\n");
|
|
||||||
#endif
|
|
||||||
|
|
||||||
WMInitializeApplication("WMColorPicker", &argc, argv);
|
|
||||||
|
|
||||||
ProgName = argv[0];
|
|
||||||
|
|
||||||
if (!dpy) {
|
|
||||||
puts("could not open display");
|
|
||||||
exit(1);
|
|
||||||
}
|
|
||||||
|
|
||||||
for (i = 1; i < argc; i++) {
|
|
||||||
if (strcmp(argv[i], "-h")==0 || strcmp(argv[i], "--help")==0) {
|
|
||||||
printf("testcolorpanel [-h] [--help] [-c <color>]"
|
|
||||||
"[--color <color>]\n");
|
|
||||||
exit(0);
|
|
||||||
}
|
|
||||||
if (strcmp(argv[i], "-c")==0 || strcmp(argv[i], "--color")==0) {
|
|
||||||
i++;
|
|
||||||
if (i >= argc) {
|
|
||||||
printf("%s: missing argument for option '%s'\n",
|
|
||||||
argv[0], argv[i-1]);
|
|
||||||
exit(1);
|
|
||||||
}
|
|
||||||
colorname = argv[i];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
scr = WMCreateSimpleApplicationScreen(dpy);
|
|
||||||
|
|
||||||
pixmap = WMCreatePixmapFromXPMData(scr, GNUSTEP_XPM);
|
|
||||||
WMSetApplicationIconImage(scr, pixmap);
|
|
||||||
WMReleasePixmap(pixmap);
|
|
||||||
|
|
||||||
panel = WMGetColorPanel(scr);
|
|
||||||
|
|
||||||
if (colorname) {
|
|
||||||
startcolor = WMCreateNamedColor(scr, colorname, False);
|
|
||||||
WMSetColorPanelColor(panel, startcolor);
|
|
||||||
WMReleaseColor(startcolor);
|
|
||||||
}
|
|
||||||
|
|
||||||
WMShowColorPanel(panel);
|
|
||||||
|
|
||||||
WMScreenMainLoop(scr);
|
|
||||||
return 0;
|
|
||||||
}
|
|
||||||
@@ -1,7 +1,7 @@
|
|||||||
|
|
||||||
|
|
||||||
#include <WINGs.h>
|
#include <WINGs/WINGs.h>
|
||||||
#include <WUtil.h>
|
#include <stdlib.h>
|
||||||
|
|
||||||
#include "mywidget.h"
|
#include "mywidget.h"
|
||||||
|
|
||||||
@@ -49,3 +49,4 @@ int main(int argc, char **argv)
|
|||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ ftp.windowmaker.org</u></font><Br>
|
|||||||
<b><i>Window Maker</b>
|
<b><i>Window Maker</b>
|
||||||
<Img src=upbtn.xpm></i>is the GNU window manager
|
<Img src=upbtn.xpm></i>is the GNU window manager
|
||||||
for the X Window System. It was
|
for the X Window System. It was
|
||||||
designed to emulate the look and feel of part of the NEXTSTEP(tm) GUI. It's
|
designed to emulate the look and feel of part of the NEXTSTEP(tm) GUI. Its
|
||||||
supposed to be relatively fast and small, feature rich, easy to configure and
|
supposed to be relatively fast and small, feature rich, easy to configure and
|
||||||
easy to use, with a simple and elegant appearance borrowed from NEXTSTEP(tm).
|
easy to use, with a simple and elegant appearance borrowed from NEXTSTEP(tm).
|
||||||
<p>
|
<p>
|
||||||
|
|||||||
@@ -13,10 +13,11 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
#include "WINGs.h"
|
#include <WINGs/WINGs.h>
|
||||||
|
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
#include <stdlib.h>
|
||||||
|
|
||||||
#include "logo.xpm"
|
#include "logo.xpm"
|
||||||
|
|
||||||
@@ -70,14 +71,15 @@ int main(int argc, char **argv)
|
|||||||
extern char *optarg;
|
extern char *optarg;
|
||||||
extern int optind;
|
extern int optind;
|
||||||
|
|
||||||
WMInitializeApplication("WMFile", &argc, argv);
|
|
||||||
|
|
||||||
ProgName = argv[0];
|
|
||||||
|
|
||||||
if (!dpy) {
|
if (!dpy) {
|
||||||
puts("could not open display");
|
puts("could not open display");
|
||||||
exit(1);
|
exit(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
WMInitializeApplication("WMFile", &argc, argv);
|
||||||
|
|
||||||
|
ProgName = argv[0];
|
||||||
|
|
||||||
while((ch = getopt(argc, argv, "si:ht:")) != -1)
|
while((ch = getopt(argc, argv, "si:ht:")) != -1)
|
||||||
switch(ch)
|
switch(ch)
|
||||||
{
|
{
|
||||||
@@ -102,7 +104,7 @@ int main(int argc, char **argv)
|
|||||||
|
|
||||||
|
|
||||||
pixmap = WMCreatePixmapFromXPMData(scr, GNUSTEP_XPM);
|
pixmap = WMCreatePixmapFromXPMData(scr, GNUSTEP_XPM);
|
||||||
WMSetApplicationIconImage(scr, pixmap);
|
WMSetApplicationIconPixmap(scr, pixmap);
|
||||||
WMReleasePixmap(pixmap);
|
WMReleasePixmap(pixmap);
|
||||||
if (panelType == SAVE_PANEL_TYPE) {
|
if (panelType == SAVE_PANEL_TYPE) {
|
||||||
sPanel = WMGetSavePanel(scr);
|
sPanel = WMGetSavePanel(scr);
|
||||||
@@ -121,3 +123,4 @@ int main(int argc, char **argv)
|
|||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -4,10 +4,11 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#include "WINGs.h"
|
#include <WINGs/WINGs.h>
|
||||||
|
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
#include <stdlib.h>
|
||||||
|
|
||||||
#include "logo.xpm"
|
#include "logo.xpm"
|
||||||
|
|
||||||
@@ -22,7 +23,8 @@ wAbort()
|
|||||||
|
|
||||||
char *ProgName;
|
char *ProgName;
|
||||||
|
|
||||||
void usage(void)
|
void
|
||||||
|
usage(void)
|
||||||
{
|
{
|
||||||
fprintf(stderr,
|
fprintf(stderr,
|
||||||
"usage:\n"
|
"usage:\n"
|
||||||
@@ -43,7 +45,8 @@ void usage(void)
|
|||||||
exit(0);
|
exit(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
int main(int argc, char **argv)
|
int
|
||||||
|
main(int argc, char **argv)
|
||||||
{
|
{
|
||||||
Display *dpy = XOpenDisplay("");
|
Display *dpy = XOpenDisplay("");
|
||||||
WMScreen *scr;
|
WMScreen *scr;
|
||||||
@@ -89,7 +92,7 @@ int main(int argc, char **argv)
|
|||||||
|
|
||||||
pixmap = WMCreatePixmapFromXPMData(scr, GNUSTEP_XPM);
|
pixmap = WMCreatePixmapFromXPMData(scr, GNUSTEP_XPM);
|
||||||
|
|
||||||
WMSetApplicationIconImage(scr, pixmap); WMReleasePixmap(pixmap);
|
WMSetApplicationIconPixmap(scr, pixmap); WMReleasePixmap(pixmap);
|
||||||
|
|
||||||
if ((result = WMRunInputPanel(scr, NULL, title, prompt, initial, "OK", "Cancel")) != NULL)
|
if ((result = WMRunInputPanel(scr, NULL, title, prompt, initial, "OK", "Cancel")) != NULL)
|
||||||
printf("%s\n", result);
|
printf("%s\n", result);
|
||||||
@@ -97,3 +100,4 @@ int main(int argc, char **argv)
|
|||||||
printf("\n");
|
printf("\n");
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -2,16 +2,17 @@
|
|||||||
* WINGs test application
|
* WINGs test application
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "WINGs.h"
|
#include <WINGs/WINGs.h>
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
#include <stdlib.h>
|
||||||
|
#include <string.h>
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* You need to define this function to link any program to WINGs.
|
* You need to define this function to link any program to WINGs.
|
||||||
|
* (this is no longer required as there is a default abort handler in WINGs)
|
||||||
* This will be called when the application will be terminated because
|
* This will be called when the application will be terminated because
|
||||||
* on a fatal error.
|
* of a fatal error (only for memory allocation failures ATM).
|
||||||
*/
|
*/
|
||||||
void
|
void
|
||||||
wAbort()
|
wAbort()
|
||||||
@@ -115,13 +116,14 @@ testFrame(WMScreen *scr)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
static void resizedWindow(void *self, WMNotification *notif)
|
/*static void
|
||||||
|
resizedWindow(void *self, WMNotification *notif)
|
||||||
{
|
{
|
||||||
WMView *view = (WMView*)WMGetNotificationObject(notif);
|
WMView *view = (WMView*)WMGetNotificationObject(notif);
|
||||||
WMSize size = WMGetViewSize(view);
|
WMSize size = WMGetViewSize(view);
|
||||||
|
|
||||||
WMResizeWidget((WMWidget*)self, size.width, size.height);
|
WMResizeWidget((WMWidget*)self, size.width, size.height);
|
||||||
}
|
}*/
|
||||||
|
|
||||||
void
|
void
|
||||||
testBox(WMScreen *scr)
|
testBox(WMScreen *scr)
|
||||||
@@ -137,17 +139,11 @@ testBox(WMScreen *scr)
|
|||||||
win = WMCreateWindow(scr, "testBox");
|
win = WMCreateWindow(scr, "testBox");
|
||||||
WMSetWindowTitle(win, "Box");
|
WMSetWindowTitle(win, "Box");
|
||||||
WMSetWindowCloseAction(win, closeAction, NULL);
|
WMSetWindowCloseAction(win, closeAction, NULL);
|
||||||
|
WMResizeWidget(win, 400, 300);
|
||||||
WMSetViewNotifySizeChanges(WMWidgetView(win), True);
|
|
||||||
|
|
||||||
box = WMCreateBox(win);
|
box = WMCreateBox(win);
|
||||||
WMSetBoxBorderWidth(box, 5);
|
WMSetBoxBorderWidth(box, 5);
|
||||||
|
WMSetViewExpandsToParent(WMWidgetView(box), 0, 0, 0, 0);
|
||||||
WMAddNotificationObserver(resizedWindow, box,
|
|
||||||
WMViewSizeDidChangeNotification,
|
|
||||||
WMWidgetView(win));
|
|
||||||
WMResizeWidget(win, 400, 300);
|
|
||||||
|
|
||||||
|
|
||||||
/*WMSetBoxHorizontal(box, True);*/
|
/*WMSetBoxHorizontal(box, True);*/
|
||||||
for (i = 0; i < 4; i++) {
|
for (i = 0; i < 4; i++) {
|
||||||
@@ -193,11 +189,7 @@ singleClick(WMWidget *self, void *data)
|
|||||||
static void
|
static void
|
||||||
doubleClick(WMWidget *self, void *data)
|
doubleClick(WMWidget *self, void *data)
|
||||||
{
|
{
|
||||||
WMLabel *label = (WMLabel*)data;
|
WMSelectAllListItems((WMList*)self);
|
||||||
WMList *lPtr = (WMList*)self;
|
|
||||||
char buf[255];
|
|
||||||
|
|
||||||
WMSelectAllListItems(lPtr);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -249,7 +241,7 @@ testList(WMScreen *scr)
|
|||||||
list = WMCreateList(win);
|
list = WMCreateList(win);
|
||||||
/*WMSetListAllowEmptySelection(list, True);*/
|
/*WMSetListAllowEmptySelection(list, True);*/
|
||||||
WMMoveWidget(list, 10, 40);
|
WMMoveWidget(list, 10, 40);
|
||||||
for (i=0; i<50; i++) {
|
for (i=0; i<105; i++) {
|
||||||
sprintf(text, "Item %i", i);
|
sprintf(text, "Item %i", i);
|
||||||
WMAddListItem(list, text);
|
WMAddListItem(list, text);
|
||||||
}
|
}
|
||||||
@@ -346,6 +338,9 @@ testGradientButtons(WMScreen *scr)
|
|||||||
WMSetWindowTitle(win, "Gradiented Button Demo");
|
WMSetWindowTitle(win, "Gradiented Button Demo");
|
||||||
WMResizeWidget(win, 300, 200);
|
WMResizeWidget(win, 300, 200);
|
||||||
|
|
||||||
|
WMSetWindowCloseAction(win, closeAction, NULL);
|
||||||
|
|
||||||
|
|
||||||
light.red = 0x90;
|
light.red = 0x90;
|
||||||
light.green = 0x85;
|
light.green = 0x85;
|
||||||
light.blue = 0x90;
|
light.blue = 0x90;
|
||||||
@@ -360,12 +355,12 @@ testGradientButtons(WMScreen *scr)
|
|||||||
back = RRenderGradient(60, 24, &dark, &light, RGRD_DIAGONAL);
|
back = RRenderGradient(60, 24, &dark, &light, RGRD_DIAGONAL);
|
||||||
RBevelImage(back, RBEV_RAISED2);
|
RBevelImage(back, RBEV_RAISED2);
|
||||||
pix1 = WMCreatePixmapFromRImage(scr, back, 0);
|
pix1 = WMCreatePixmapFromRImage(scr, back, 0);
|
||||||
RDestroyImage(back);
|
RReleaseImage(back);
|
||||||
|
|
||||||
back = RRenderGradient(60, 24, &dark, &light, RGRD_DIAGONAL);
|
back = RRenderGradient(60, 24, &dark, &light, RGRD_DIAGONAL);
|
||||||
RBevelImage(back, RBEV_SUNKEN);
|
RBevelImage(back, RBEV_SUNKEN);
|
||||||
pix2 = WMCreatePixmapFromRImage(scr, back, 0);
|
pix2 = WMCreatePixmapFromRImage(scr, back, 0);
|
||||||
RDestroyImage(back);
|
RReleaseImage(back);
|
||||||
|
|
||||||
color = WMWhiteColor(scr);
|
color = WMWhiteColor(scr);
|
||||||
altColor = WMCreateNamedColor(scr, "red", True);
|
altColor = WMCreateNamedColor(scr, "red", True);
|
||||||
@@ -507,6 +502,21 @@ testColorWell(WMScreen *scr)
|
|||||||
WMMapWidget(win);
|
WMMapWidget(win);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void
|
||||||
|
testColorPanel(WMScreen *scr)
|
||||||
|
{
|
||||||
|
WMColorPanel *panel = WMGetColorPanel(scr);
|
||||||
|
|
||||||
|
/*if (colorname) {
|
||||||
|
startcolor = WMCreateNamedColor(scr, colorname, False);
|
||||||
|
WMSetColorPanelColor(panel, startcolor);
|
||||||
|
WMReleaseColor(startcolor);
|
||||||
|
}*/
|
||||||
|
|
||||||
|
WMShowColorPanel(panel);
|
||||||
|
}
|
||||||
|
|
||||||
void
|
void
|
||||||
sliderCallback(WMWidget *w, void *data)
|
sliderCallback(WMWidget *w, void *data)
|
||||||
{
|
{
|
||||||
@@ -545,6 +555,7 @@ testSlider(WMScreen *scr)
|
|||||||
WMMapWidget(win);
|
WMMapWidget(win);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
testTextField(WMScreen *scr)
|
testTextField(WMScreen *scr)
|
||||||
{
|
{
|
||||||
@@ -579,7 +590,9 @@ testText(WMScreen *scr)
|
|||||||
{
|
{
|
||||||
WMWindow *win;
|
WMWindow *win;
|
||||||
WMText *text;
|
WMText *text;
|
||||||
FILE *file = fopen("wm.html", "r");
|
WMFont *font;
|
||||||
|
void *tb;
|
||||||
|
FILE *file = fopen("wm.html", "rb");
|
||||||
|
|
||||||
windowCount++;
|
windowCount++;
|
||||||
|
|
||||||
@@ -593,8 +606,22 @@ testText(WMScreen *scr)
|
|||||||
WMMoveWidget(text, 10, 10);
|
WMMoveWidget(text, 10, 10);
|
||||||
WMSetTextHasVerticalScroller(text, True);
|
WMSetTextHasVerticalScroller(text, True);
|
||||||
WMSetTextEditable(text, False);
|
WMSetTextEditable(text, False);
|
||||||
|
WMSetTextIgnoresNewline(text, False);
|
||||||
|
|
||||||
if(file) {
|
#define FNAME "Verdana,Luxi Sans:pixelsize=12"
|
||||||
|
#define MSG \
|
||||||
|
"Window Maker is the GNU window manager for the " \
|
||||||
|
"X Window System. It was designed to emulate the " \
|
||||||
|
"look and feel of part of the NEXTSTEP(tm) GUI. It's " \
|
||||||
|
"supposed to be relatively fast and small, feature " \
|
||||||
|
"rich, easy to configure and easy to use, with a simple " \
|
||||||
|
"and elegant appearance borrowed from NEXTSTEP(tm)."
|
||||||
|
|
||||||
|
font = WMCreateFont(scr, FNAME":autohint=false");
|
||||||
|
WMSetTextDefaultFont(text, font);
|
||||||
|
WMReleaseFont(font);
|
||||||
|
|
||||||
|
if (0 && file) {
|
||||||
char buf[1024];
|
char buf[1024];
|
||||||
|
|
||||||
WMFreezeText(text);
|
WMFreezeText(text);
|
||||||
@@ -604,7 +631,16 @@ testText(WMScreen *scr)
|
|||||||
fclose(file);
|
fclose(file);
|
||||||
WMThawText(text);
|
WMThawText(text);
|
||||||
} else {
|
} else {
|
||||||
WMAppendTextStream(text, "<HTML><i>Where's</i> the <b>README</b>?");
|
WMAppendTextStream(text, "First paragraph has autohinting turned off, "
|
||||||
|
"while the second has it turned on:");
|
||||||
|
WMAppendTextStream(text, "\n\n\n");
|
||||||
|
WMAppendTextStream(text, MSG);
|
||||||
|
WMAppendTextStream(text, "\n\n\n");
|
||||||
|
font = WMCreateFont(scr, FNAME":autohint=true");
|
||||||
|
tb = WMCreateTextBlockWithText(text, MSG, font, WMBlackColor(scr),
|
||||||
|
0, strlen(MSG));
|
||||||
|
WMAppendTextBlock(text, tb);
|
||||||
|
WMReleaseFont(font);
|
||||||
}
|
}
|
||||||
|
|
||||||
WMRealizeWidget(win);
|
WMRealizeWidget(win);
|
||||||
@@ -938,276 +974,6 @@ testSplitView(WMScreen *scr)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
/*******************************************************************/
|
|
||||||
|
|
||||||
#include <sys/types.h>
|
|
||||||
#include <dirent.h>
|
|
||||||
#include <string.h>
|
|
||||||
|
|
||||||
|
|
||||||
typedef struct {
|
|
||||||
int x, y;
|
|
||||||
Bool mouseDown;
|
|
||||||
char *filename;
|
|
||||||
} DNDStuff;
|
|
||||||
|
|
||||||
WMPixmap*
|
|
||||||
getImage(WMScreen *scr, char *file)
|
|
||||||
{
|
|
||||||
char buffer[1000];
|
|
||||||
WMPixmap *pix;
|
|
||||||
|
|
||||||
sprintf(buffer, "../../WindowMaker/Icons/%s", file);
|
|
||||||
pix = WMCreatePixmapFromFile(scr, buffer);
|
|
||||||
|
|
||||||
return pix;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
static void
|
|
||||||
iconMouseStuff(XEvent *event, void *cdata)
|
|
||||||
{
|
|
||||||
WMLabel *label = (WMLabel*)cdata;
|
|
||||||
DNDStuff *stuff = WMGetHangedData(label);
|
|
||||||
WMPoint where;
|
|
||||||
|
|
||||||
switch (event->type) {
|
|
||||||
case ButtonPress:
|
|
||||||
stuff->x = event->xbutton.x;
|
|
||||||
stuff->y = event->xbutton.y;
|
|
||||||
stuff->mouseDown = True;
|
|
||||||
break;
|
|
||||||
case ButtonRelease:
|
|
||||||
stuff->mouseDown = False;
|
|
||||||
break;
|
|
||||||
case MotionNotify:
|
|
||||||
if (!stuff->mouseDown)
|
|
||||||
break;
|
|
||||||
|
|
||||||
if (abs(stuff->x - event->xmotion.x)>4
|
|
||||||
|| abs(stuff->y - event->xmotion.y)>4) {
|
|
||||||
|
|
||||||
where = WMGetViewScreenPosition(WMWidgetView(label));
|
|
||||||
|
|
||||||
WMDragImageFromView(WMWidgetView(label),
|
|
||||||
WMGetLabelImage(label),
|
|
||||||
NULL, /* XXX */
|
|
||||||
where,
|
|
||||||
wmksize(stuff->x, stuff->y),
|
|
||||||
event, True);
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
static void
|
|
||||||
endedDragImage(WMView *self, WMPixmap *image, WMPoint point, Bool deposited)
|
|
||||||
{
|
|
||||||
DNDStuff *stuff = WMGetHangedData(WMWidgetOfView(self));
|
|
||||||
|
|
||||||
if (deposited) {
|
|
||||||
WMDestroyWidget(WMWidgetOfView(self));
|
|
||||||
}
|
|
||||||
|
|
||||||
stuff->mouseDown = False;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
static WMData*
|
|
||||||
fetchDragData(WMView *self, char *type)
|
|
||||||
{
|
|
||||||
DNDStuff *stuff = WMGetHangedData(WMWidgetOfView(self));
|
|
||||||
|
|
||||||
return WMCreateDataWithBytes(stuff->filename, strlen(stuff->filename)+1);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
WMDragSourceProcs dragSourceProcs = {
|
|
||||||
NULL,
|
|
||||||
NULL,
|
|
||||||
endedDragImage,
|
|
||||||
fetchDragData
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
/************************/
|
|
||||||
|
|
||||||
|
|
||||||
unsigned
|
|
||||||
draggingEntered(WMView *self, WMDraggingInfo *info)
|
|
||||||
{
|
|
||||||
return WDOperationCopy;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
unsigned
|
|
||||||
draggingUpdated(WMView *self, WMDraggingInfo *info)
|
|
||||||
{
|
|
||||||
return WDOperationCopy;
|
|
||||||
}
|
|
||||||
|
|
||||||
/*
|
|
||||||
void (*draggingExited)(WMView *self, WMDraggingInfo *info);
|
|
||||||
*/
|
|
||||||
char*
|
|
||||||
prepareForDragOperation(WMView *self, WMDraggingInfo *info)
|
|
||||||
{
|
|
||||||
return "application/X-WINGs-Bla";
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
WMLabel* makeDraggableLabel(WMWidget *w, char *file, int x, int y);
|
|
||||||
|
|
||||||
Bool
|
|
||||||
performDragOperation(WMView *self, WMDraggingInfo *info, WMData *data)
|
|
||||||
{
|
|
||||||
char *file = (char*)WMDataBytes(data);
|
|
||||||
WMPoint pos;
|
|
||||||
|
|
||||||
pos = WMGetDraggingInfoImageLocation(info);
|
|
||||||
|
|
||||||
if (file!=NULL) {
|
|
||||||
WMLabel *label;
|
|
||||||
WMPoint pos2 = WMGetViewScreenPosition(self);
|
|
||||||
|
|
||||||
|
|
||||||
label = makeDraggableLabel(WMWidgetOfView(self), file,
|
|
||||||
pos.x-pos2.x, pos.y-pos2.y);
|
|
||||||
WMRealizeWidget(label);
|
|
||||||
WMMapWidget(label);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
return True;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
void
|
|
||||||
concludeDragOperation(WMView *self, WMDraggingInfo *info)
|
|
||||||
{
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
WMDragDestinationProcs dragDestProcs = {
|
|
||||||
draggingEntered,
|
|
||||||
draggingUpdated,
|
|
||||||
NULL,
|
|
||||||
prepareForDragOperation,
|
|
||||||
performDragOperation,
|
|
||||||
concludeDragOperation
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
WMLabel*
|
|
||||||
makeDraggableLabel(WMWidget *w, char *file, int x, int y)
|
|
||||||
{
|
|
||||||
DNDStuff *stuff;
|
|
||||||
WMLabel *label;
|
|
||||||
WMPixmap *image = getImage(WMWidgetScreen(w), file);
|
|
||||||
|
|
||||||
stuff = wmalloc(sizeof(DNDStuff));
|
|
||||||
stuff->mouseDown = False;
|
|
||||||
|
|
||||||
stuff->filename = wstrdup(file);
|
|
||||||
|
|
||||||
label = WMCreateLabel(w);
|
|
||||||
WMResizeWidget(label, 48, 48);
|
|
||||||
WMMoveWidget(label, x, y);
|
|
||||||
|
|
||||||
WMSetViewDragSourceProcs(WMWidgetView(label), &dragSourceProcs);
|
|
||||||
|
|
||||||
WMHangData(label, stuff);
|
|
||||||
|
|
||||||
WMCreateEventHandler(WMWidgetView(label),
|
|
||||||
ButtonPressMask|ButtonReleaseMask|ButtonMotionMask,
|
|
||||||
iconMouseStuff, label);
|
|
||||||
|
|
||||||
|
|
||||||
if (image != NULL) {
|
|
||||||
WMSetLabelImagePosition(label, WIPImageOnly);
|
|
||||||
WMSetLabelImage(label, image);
|
|
||||||
WMReleasePixmap(image);
|
|
||||||
} else puts(file);
|
|
||||||
|
|
||||||
return label;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
void
|
|
||||||
testDragAndDrop(WMScreen *scr)
|
|
||||||
{
|
|
||||||
WMWindow *win;
|
|
||||||
WMFrame *frame;
|
|
||||||
WMLabel *label;
|
|
||||||
int i, j;
|
|
||||||
DIR *dir;
|
|
||||||
struct dirent *ent;
|
|
||||||
char *types[] = {
|
|
||||||
"application/X-WINGs-Bla",
|
|
||||||
NULL
|
|
||||||
};
|
|
||||||
|
|
||||||
windowCount++;
|
|
||||||
|
|
||||||
win = WMCreateWindow(scr, "dragDrop");
|
|
||||||
WMResizeWidget(win, 300, 300);
|
|
||||||
WMSetWindowCloseAction(win, closeAction, NULL);
|
|
||||||
WMSetWindowTitle(win, "Drag and Drop");
|
|
||||||
|
|
||||||
|
|
||||||
frame = WMCreateFrame(win);
|
|
||||||
WMSetFrameRelief(frame, WRSunken);
|
|
||||||
WMResizeWidget(frame, 250, 250);
|
|
||||||
WMMoveWidget(frame, 25, 25);
|
|
||||||
|
|
||||||
WMRegisterViewForDraggedTypes(WMWidgetView(frame), types);
|
|
||||||
WMSetViewDragDestinationProcs(WMWidgetView(frame), &dragDestProcs);
|
|
||||||
|
|
||||||
dir = opendir("../../WindowMaker/Icons");
|
|
||||||
if (!dir) {
|
|
||||||
perror("../../WindowMaker/Icons");
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
for (i = 0, j=0; j < 8; i++) {
|
|
||||||
ent = readdir(dir);
|
|
||||||
if (!ent)
|
|
||||||
break;
|
|
||||||
|
|
||||||
if (strstr(ent->d_name, ".xpm")==NULL) {
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
|
|
||||||
label = makeDraggableLabel(frame, ent->d_name,4+(j/4)*64, 4+(j%4)*64);
|
|
||||||
|
|
||||||
j++;
|
|
||||||
}
|
|
||||||
|
|
||||||
closedir(dir);
|
|
||||||
|
|
||||||
WMMapSubwidgets(frame);
|
|
||||||
|
|
||||||
WMMapSubwidgets(win);
|
|
||||||
WMRealizeWidget(win);
|
|
||||||
WMMapWidget(win);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/*******************************************************************/
|
|
||||||
|
|
||||||
#include "WUtil.h"
|
|
||||||
|
|
||||||
void
|
void
|
||||||
testUD()
|
testUD()
|
||||||
{
|
{
|
||||||
@@ -1249,7 +1015,7 @@ main(int argc, char **argv)
|
|||||||
* Do NOT use it unless when debugging. It will cause a major
|
* Do NOT use it unless when debugging. It will cause a major
|
||||||
* slowdown in your application
|
* slowdown in your application
|
||||||
*/
|
*/
|
||||||
#if 1
|
#if 0
|
||||||
XSynchronize(dpy, True);
|
XSynchronize(dpy, True);
|
||||||
#endif
|
#endif
|
||||||
/*
|
/*
|
||||||
@@ -1265,7 +1031,10 @@ main(int argc, char **argv)
|
|||||||
/*
|
/*
|
||||||
* Makes the logo be used in standard dialog panels.
|
* Makes the logo be used in standard dialog panels.
|
||||||
*/
|
*/
|
||||||
WMSetApplicationIconImage(scr, pixmap); WMReleasePixmap(pixmap);
|
if (pixmap) {
|
||||||
|
WMSetApplicationIconPixmap(scr, pixmap);
|
||||||
|
WMReleasePixmap(pixmap);
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Do some test stuff.
|
* Do some test stuff.
|
||||||
@@ -1273,41 +1042,29 @@ main(int argc, char **argv)
|
|||||||
* Put the testSomething() function you want to test here.
|
* Put the testSomething() function you want to test here.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
testTabView(scr);
|
|
||||||
#if 0
|
|
||||||
testBox(scr);
|
|
||||||
testText(scr);
|
testText(scr);
|
||||||
testList(scr);
|
|
||||||
|
|
||||||
testProgressIndicator(scr);
|
|
||||||
|
|
||||||
testColorWell(scr);
|
|
||||||
|
|
||||||
testTextField(scr);
|
|
||||||
|
|
||||||
testDragAndDrop(scr);
|
|
||||||
testDragAndDrop(scr);
|
|
||||||
testFontPanel(scr);
|
testFontPanel(scr);
|
||||||
|
|
||||||
testScrollView(scr);
|
testColorPanel(scr);
|
||||||
|
|
||||||
|
#if 0
|
||||||
|
|
||||||
|
testBox(scr);
|
||||||
testButton(scr);
|
testButton(scr);
|
||||||
|
testColorPanel(scr);
|
||||||
|
testColorWell(scr);
|
||||||
|
testDragAndDrop(scr);
|
||||||
testFrame(scr);
|
testFrame(scr);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
testSplitView(scr);
|
|
||||||
|
|
||||||
testGradientButtons(scr);
|
testGradientButtons(scr);
|
||||||
|
testList(scr);
|
||||||
|
|
||||||
testOpenFilePanel(scr);
|
testOpenFilePanel(scr);
|
||||||
|
testProgressIndicator(scr);
|
||||||
testSlider(scr);
|
|
||||||
testPullDown(scr);
|
testPullDown(scr);
|
||||||
|
testScrollView(scr);
|
||||||
|
testSlider(scr);
|
||||||
|
testSplitView(scr);
|
||||||
|
testTabView(scr);
|
||||||
|
testTextField(scr);
|
||||||
#endif
|
#endif
|
||||||
/*
|
/*
|
||||||
* The main event loop.
|
* The main event loop.
|
||||||
@@ -1317,3 +1074,4 @@ main(int argc, char **argv)
|
|||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
1
WINGs/WINGs/.cvsignore
Normal file
1
WINGs/WINGs/.cvsignore
Normal file
@@ -0,0 +1 @@
|
|||||||
|
Makefile Makefile.in
|
||||||
9
WINGs/WINGs/Makefile.am
Normal file
9
WINGs/WINGs/Makefile.am
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
## automake input file for WINGs - Headers subdir
|
||||||
|
|
||||||
|
AUTOMAKE_OPTIONS = no-dependencies
|
||||||
|
|
||||||
|
# is this a kluge? if so, how should i do it?
|
||||||
|
includedir = @includedir@/WINGs
|
||||||
|
|
||||||
|
include_HEADERS = WINGs.h WUtil.h WINGsP.h proplist-compat.h
|
||||||
|
|
||||||
@@ -4,10 +4,10 @@
|
|||||||
#define _WINGS_H_
|
#define _WINGS_H_
|
||||||
|
|
||||||
#include <wraster.h>
|
#include <wraster.h>
|
||||||
#include <WUtil.h>
|
#include <WINGs/WUtil.h>
|
||||||
#include <X11/Xlib.h>
|
#include <X11/Xlib.h>
|
||||||
|
|
||||||
#define WINGS_H_VERSION 20000521
|
#define WINGS_H_VERSION 20040406
|
||||||
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
@@ -37,28 +37,49 @@ typedef struct {
|
|||||||
} WMRect;
|
} WMRect;
|
||||||
|
|
||||||
|
|
||||||
/* WMRange was moved in WUtil.h */
|
|
||||||
|
|
||||||
|
|
||||||
#define ClientMessageMask (1L<<30)
|
#define ClientMessageMask (1L<<30)
|
||||||
|
|
||||||
|
|
||||||
/* window stacking level */
|
#ifndef _DEFINED_GNUSTEP_WINDOW_INFO
|
||||||
|
#define _DEFINED_GNUSTEP_WINDOW_INFO
|
||||||
|
/*
|
||||||
|
* Window levels are taken from GNUstep (gui/AppKit/NSWindow.h)
|
||||||
|
* NSDesktopWindowLevel intended to be the level at which things
|
||||||
|
* on the desktop sit ... so you should be able
|
||||||
|
* to put a desktop background just below it.
|
||||||
|
*
|
||||||
|
* Applications are actually permitted to use any value in the
|
||||||
|
* range INT_MIN+1 to INT_MAX
|
||||||
|
*/
|
||||||
enum {
|
enum {
|
||||||
|
WMDesktopWindowLevel = -1000, /* GNUstep addition */
|
||||||
WMNormalWindowLevel = 0,
|
WMNormalWindowLevel = 0,
|
||||||
WMFloatingWindowLevel = 3,
|
WMFloatingWindowLevel = 3,
|
||||||
WMDockWindowLevel = 5,
|
WMSubmenuWindowLevel = 3,
|
||||||
WMSubmenuWindowLevel = 10,
|
WMTornOffMenuWindowLevel = 3,
|
||||||
WMMainMenuWindowLevel = 20
|
WMMainMenuWindowLevel = 20,
|
||||||
|
WMDockWindowLevel = 21, /* Deprecated - use NSStatusWindowLevel */
|
||||||
|
WMStatusWindowLevel = 21,
|
||||||
|
WMModalPanelWindowLevel = 100,
|
||||||
|
WMPopUpMenuWindowLevel = 101,
|
||||||
|
WMScreenSaverWindowLevel = 1000
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
/* window attributes */
|
/* window attributes */
|
||||||
enum {
|
enum {
|
||||||
WMBorderlessWindowMask = 0,
|
WMBorderlessWindowMask = 0,
|
||||||
WMTitledWindowMask = 1,
|
WMTitledWindowMask = 1,
|
||||||
WMClosableWindowMask = 2,
|
WMClosableWindowMask = 2,
|
||||||
WMMiniaturizableWindowMask = 4,
|
WMMiniaturizableWindowMask = 4,
|
||||||
WMResizableWindowMask = 8
|
WMResizableWindowMask = 8,
|
||||||
|
WMIconWindowMask = 64,
|
||||||
|
WMMiniWindowMask = 128
|
||||||
};
|
};
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
/* button types */
|
/* button types */
|
||||||
@@ -202,7 +223,7 @@ enum {
|
|||||||
|
|
||||||
/* drag operations */
|
/* drag operations */
|
||||||
typedef enum {
|
typedef enum {
|
||||||
WDOperationNone,
|
WDOperationNone = 0,
|
||||||
WDOperationCopy,
|
WDOperationCopy,
|
||||||
WDOperationMove,
|
WDOperationMove,
|
||||||
WDOperationLink,
|
WDOperationLink,
|
||||||
@@ -363,6 +384,8 @@ typedef struct WMListItem {
|
|||||||
/* struct for message panel */
|
/* struct for message panel */
|
||||||
typedef struct WMAlertPanel {
|
typedef struct WMAlertPanel {
|
||||||
WMWindow *win; /* window */
|
WMWindow *win; /* window */
|
||||||
|
WMBox *vbox;
|
||||||
|
WMBox *hbox;
|
||||||
WMButton *defBtn; /* default button */
|
WMButton *defBtn; /* default button */
|
||||||
WMButton *altBtn; /* alternative button */
|
WMButton *altBtn; /* alternative button */
|
||||||
WMButton *othBtn; /* other button */
|
WMButton *othBtn; /* other button */
|
||||||
@@ -371,13 +394,28 @@ typedef struct WMAlertPanel {
|
|||||||
WMLabel *mLbl; /* message label */
|
WMLabel *mLbl; /* message label */
|
||||||
WMFrame *line; /* separator */
|
WMFrame *line; /* separator */
|
||||||
short result; /* button that was pushed */
|
short result; /* button that was pushed */
|
||||||
short done;
|
|
||||||
|
|
||||||
KeyCode retKey;
|
|
||||||
KeyCode escKey;
|
|
||||||
} WMAlertPanel;
|
} WMAlertPanel;
|
||||||
|
|
||||||
|
|
||||||
|
typedef struct WMGenericPanel {
|
||||||
|
WMWindow *win;
|
||||||
|
WMBox *vbox;
|
||||||
|
|
||||||
|
WMLabel *iLbl;
|
||||||
|
WMLabel *tLbl;
|
||||||
|
|
||||||
|
WMFrame *line;
|
||||||
|
|
||||||
|
WMFrame *content;
|
||||||
|
|
||||||
|
WMBox *buttonBox;
|
||||||
|
WMButton *defBtn;
|
||||||
|
WMButton *altBtn;
|
||||||
|
|
||||||
|
short result;
|
||||||
|
} WMGenericPanel;
|
||||||
|
|
||||||
|
|
||||||
typedef struct WMInputPanel {
|
typedef struct WMInputPanel {
|
||||||
WMWindow *win; /* window */
|
WMWindow *win; /* window */
|
||||||
WMButton *defBtn; /* default button */
|
WMButton *defBtn; /* default button */
|
||||||
@@ -386,13 +424,16 @@ typedef struct WMInputPanel {
|
|||||||
WMLabel *mLbl; /* message label */
|
WMLabel *mLbl; /* message label */
|
||||||
WMTextField *text; /* text field */
|
WMTextField *text; /* text field */
|
||||||
short result; /* button that was pushed */
|
short result; /* button that was pushed */
|
||||||
short done;
|
|
||||||
|
|
||||||
KeyCode retKey;
|
|
||||||
KeyCode escKey;
|
|
||||||
} WMInputPanel;
|
} WMInputPanel;
|
||||||
|
|
||||||
|
|
||||||
|
/* Basic font styles. Used to easily get one style from another */
|
||||||
|
typedef enum WMFontStyle {
|
||||||
|
WFSNormal = 0,
|
||||||
|
WFSBold = 1,
|
||||||
|
WFSItalic = 2,
|
||||||
|
WFSBoldItalic = 3
|
||||||
|
} WMFontStyle;
|
||||||
|
|
||||||
|
|
||||||
/* WMRuler: */
|
/* WMRuler: */
|
||||||
@@ -407,10 +448,6 @@ typedef struct {
|
|||||||
/* All indentation and tab markers are _relative_ to the left margin marker */
|
/* All indentation and tab markers are _relative_ to the left margin marker */
|
||||||
|
|
||||||
|
|
||||||
typedef void *WMHandlerID;
|
|
||||||
|
|
||||||
typedef void WMInputProc(int fd, int mask, void *clientData);
|
|
||||||
|
|
||||||
typedef void WMEventProc(XEvent *event, void *clientData);
|
typedef void WMEventProc(XEvent *event, void *clientData);
|
||||||
|
|
||||||
typedef void WMEventHook(XEvent *event);
|
typedef void WMEventHook(XEvent *event);
|
||||||
@@ -423,14 +460,11 @@ typedef void WMAction(WMWidget *self, void *clientData);
|
|||||||
typedef void WMAction2(void *self, void *clientData);
|
typedef void WMAction2(void *self, void *clientData);
|
||||||
|
|
||||||
|
|
||||||
typedef void WMCallback(void *data);
|
|
||||||
|
|
||||||
typedef void WMDropDataCallback(WMView *view, WMData *data);
|
|
||||||
|
|
||||||
/* delegate method like stuff */
|
/* delegate method like stuff */
|
||||||
typedef void WMListDrawProc(WMList *lPtr, int index, Drawable d, char *text,
|
typedef void WMListDrawProc(WMList *lPtr, int index, Drawable d, char *text,
|
||||||
int state, WMRect *rect);
|
int state, WMRect *rect);
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
typedef void WMSplitViewResizeSubviewsProc(WMSplitView *sPtr,
|
typedef void WMSplitViewResizeSubviewsProc(WMSplitView *sPtr,
|
||||||
unsigned int oldWidth,
|
unsigned int oldWidth,
|
||||||
@@ -525,11 +559,17 @@ typedef struct WMSelectionProcs {
|
|||||||
typedef struct W_DraggingInfo WMDraggingInfo;
|
typedef struct W_DraggingInfo WMDraggingInfo;
|
||||||
|
|
||||||
|
|
||||||
|
/* links a label to a dnd operation. */
|
||||||
|
typedef struct W_DragOperationtItem WMDragOperationItem;
|
||||||
|
|
||||||
|
|
||||||
typedef struct W_DragSourceProcs {
|
typedef struct W_DragSourceProcs {
|
||||||
unsigned (*draggingSourceOperation)(WMView *self, Bool local);
|
WMArray* (*dropDataTypes)(WMView *self);
|
||||||
void (*beganDragImage)(WMView *self, WMPixmap *image, WMPoint point);
|
WMDragOperationType (*wantedDropOperation)(WMView *self);
|
||||||
void (*endedDragImage)(WMView *self, WMPixmap *image, WMPoint point,
|
WMArray* (*askedOperations)(WMView *self);
|
||||||
Bool deposited);
|
Bool (*acceptDropOperation)(WMView *self, WMDragOperationType operation);
|
||||||
|
void (*beganDrag)(WMView *self, WMPoint *point);
|
||||||
|
void (*endedDrag)(WMView *self, WMPoint *point, Bool deposited);
|
||||||
WMData* (*fetchDragData)(WMView *self, char *type);
|
WMData* (*fetchDragData)(WMView *self, char *type);
|
||||||
/*Bool (*ignoreModifierKeysWhileDragging)(WMView *view);*/
|
/*Bool (*ignoreModifierKeysWhileDragging)(WMView *view);*/
|
||||||
} WMDragSourceProcs;
|
} WMDragSourceProcs;
|
||||||
@@ -537,25 +577,32 @@ typedef struct W_DragSourceProcs {
|
|||||||
|
|
||||||
|
|
||||||
typedef struct W_DragDestinationProcs {
|
typedef struct W_DragDestinationProcs {
|
||||||
unsigned (*draggingEntered)(WMView *self, WMDraggingInfo *info);
|
void (*prepareForDragOperation)(WMView *self);
|
||||||
unsigned (*draggingUpdated)(WMView *self, WMDraggingInfo *info);
|
WMArray* (*requiredDataTypes)(WMView *self, WMDragOperationType request,
|
||||||
void (*draggingExited)(WMView *self, WMDraggingInfo *info);
|
WMArray *sourceDataTypes);
|
||||||
Bool (*prepareForDragOperation)(WMView *self, WMDraggingInfo *info);
|
WMDragOperationType (*allowedOperation)(WMView *self,
|
||||||
Bool (*performDragOperation)(WMView *self, WMDraggingInfo *info);
|
WMDragOperationType request,
|
||||||
void (*concludeDragOperation)(WMView *self, WMDraggingInfo *info);
|
WMArray *sourceDataTypes);
|
||||||
|
Bool (*inspectDropData)(WMView *self, WMArray *dropData);
|
||||||
|
void (*performDragOperation)(WMView *self, WMArray *dropData,
|
||||||
|
WMArray *operations, WMPoint *dropLocation);
|
||||||
|
void (*concludeDragOperation)(WMView *self);
|
||||||
} WMDragDestinationProcs;
|
} WMDragDestinationProcs;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/* ...................................................................... */
|
/* ...................................................................... */
|
||||||
|
|
||||||
|
|
||||||
WMRange wmkrange(int start, int count);
|
|
||||||
|
|
||||||
WMPoint wmkpoint(int x, int y);
|
WMPoint wmkpoint(int x, int y);
|
||||||
|
|
||||||
WMSize wmksize(unsigned int width, unsigned int height);
|
WMSize wmksize(unsigned int width, unsigned int height);
|
||||||
|
|
||||||
|
WMRect wmkrect(int x, int y, unsigned int width, unsigned int height);
|
||||||
|
|
||||||
|
#ifdef ANSI_C_DOESNT_LIKE_IT_THIS_WAY
|
||||||
|
#define wmksize(width, height) (WMSize){(width), (height)}
|
||||||
|
#define wmkpoint(x, y) (WMPoint){(x), (y)}
|
||||||
|
#endif
|
||||||
|
|
||||||
/* ....................................................................... */
|
/* ....................................................................... */
|
||||||
|
|
||||||
@@ -571,6 +618,9 @@ char *WMGetApplicationName();
|
|||||||
/* Try to locate resource file. ext may be NULL */
|
/* Try to locate resource file. ext may be NULL */
|
||||||
char* WMPathForResourceOfType(char *resource, char *ext);
|
char* WMPathForResourceOfType(char *resource, char *ext);
|
||||||
|
|
||||||
|
|
||||||
|
WMScreen* WMOpenScreen(const char *display);
|
||||||
|
|
||||||
WMScreen* WMCreateScreenWithRContext(Display *display, int screen,
|
WMScreen* WMCreateScreenWithRContext(Display *display, int screen,
|
||||||
RContext *context);
|
RContext *context);
|
||||||
|
|
||||||
@@ -580,6 +630,9 @@ WMScreen *WMCreateSimpleApplicationScreen(Display *display);
|
|||||||
|
|
||||||
void WMScreenMainLoop(WMScreen *scr);
|
void WMScreenMainLoop(WMScreen *scr);
|
||||||
|
|
||||||
|
void WMBreakModalLoop(WMScreen *scr);
|
||||||
|
|
||||||
|
void WMRunModalLoop(WMScreen *scr, WMView *view);
|
||||||
|
|
||||||
RContext* WMScreenRContext(WMScreen *scr);
|
RContext* WMScreenRContext(WMScreen *scr);
|
||||||
|
|
||||||
@@ -589,9 +642,16 @@ int WMScreenDepth(WMScreen *scr);
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
void WMSetApplicationIconImage(WMScreen *app, WMPixmap *icon);
|
void WMSetApplicationIconImage(WMScreen *app, RImage *image);
|
||||||
|
|
||||||
WMPixmap *WMGetApplicationIconImage(WMScreen *app);
|
RImage* WMGetApplicationIconImage(WMScreen *app);
|
||||||
|
|
||||||
|
void WMSetApplicationIconPixmap(WMScreen *app, WMPixmap *icon);
|
||||||
|
|
||||||
|
WMPixmap* WMGetApplicationIconPixmap(WMScreen *app);
|
||||||
|
|
||||||
|
/* If color==NULL it will use the default color for panels: ae/aa/ae */
|
||||||
|
WMPixmap* WMCreateApplicationIconBlendedPixmap(WMScreen *scr, RColor *color);
|
||||||
|
|
||||||
void WMSetApplicationIconWindow(WMScreen *scr, Window window);
|
void WMSetApplicationIconWindow(WMScreen *scr, Window window);
|
||||||
|
|
||||||
@@ -611,28 +671,14 @@ void WMDeleteEventHandler(WMView *view, unsigned long mask,
|
|||||||
|
|
||||||
int WMIsDoubleClick(XEvent *event);
|
int WMIsDoubleClick(XEvent *event);
|
||||||
|
|
||||||
int WMIsTripleClick(XEvent *event);
|
/*int WMIsTripleClick(XEvent *event);*/
|
||||||
|
|
||||||
void WMNextEvent(Display *dpy, XEvent *event);
|
void WMNextEvent(Display *dpy, XEvent *event);
|
||||||
|
|
||||||
void WMMaskEvent(Display *dpy, long mask, XEvent *event);
|
void WMMaskEvent(Display *dpy, long mask, XEvent *event);
|
||||||
|
|
||||||
WMHandlerID WMAddTimerHandler(int milliseconds, WMCallback *callback,
|
|
||||||
void *cdata);
|
|
||||||
|
|
||||||
void WMDeleteTimerWithClientData(void *cdata);
|
|
||||||
|
|
||||||
void WMDeleteTimerHandler(WMHandlerID handlerID);
|
|
||||||
|
|
||||||
WMHandlerID WMAddIdleHandler(WMCallback *callback, void *cdata);
|
|
||||||
|
|
||||||
void WMDeleteIdleHandler(WMHandlerID handlerID);
|
|
||||||
|
|
||||||
WMHandlerID WMAddInputHandler(int fd, int condition, WMInputProc *proc,
|
|
||||||
void *clientData);
|
|
||||||
|
|
||||||
void WMDeleteInputHandler(WMHandlerID handlerID);
|
|
||||||
|
|
||||||
|
/* ....................................................................... */
|
||||||
|
|
||||||
|
|
||||||
Bool WMCreateSelectionHandler(WMView *view, Atom selection, Time timestamp,
|
Bool WMCreateSelectionHandler(WMView *view, Atom selection, Time timestamp,
|
||||||
@@ -645,66 +691,75 @@ Bool WMRequestSelection(WMView *view, Atom selection, Atom target,
|
|||||||
void *cdata);
|
void *cdata);
|
||||||
|
|
||||||
|
|
||||||
|
extern char *WMSelectionOwnerDidChangeNotification;
|
||||||
|
|
||||||
/* ....................................................................... */
|
/* ....................................................................... */
|
||||||
|
|
||||||
|
WMArray* WMCreateDragOperationArray(int initialSize);
|
||||||
|
|
||||||
|
WMDragOperationItem* WMCreateDragOperationItem(WMDragOperationType type,
|
||||||
|
char* text);
|
||||||
|
|
||||||
|
WMDragOperationType WMGetDragOperationItemType(WMDragOperationItem* item);
|
||||||
|
|
||||||
|
char* WMGetDragOperationItemText(WMDragOperationItem* item);
|
||||||
|
|
||||||
|
void WMSetViewDragImage(WMView* view, WMPixmap *dragImage);
|
||||||
|
|
||||||
|
void WMReleaseViewDragImage(WMView* view);
|
||||||
|
|
||||||
void WMSetViewDragSourceProcs(WMView *view, WMDragSourceProcs *procs);
|
void WMSetViewDragSourceProcs(WMView *view, WMDragSourceProcs *procs);
|
||||||
|
|
||||||
void WMDragImageFromView(WMView *view, WMPixmap *image, char *dataTypes[],
|
Bool WMIsDraggingFromView(WMView *view);
|
||||||
WMPoint atLocation, WMSize mouseOffset, XEvent *event,
|
|
||||||
Bool slideBack);
|
|
||||||
|
|
||||||
void WMRegisterViewForDraggedTypes(WMView *view, char *acceptedTypes[]);
|
void WMDragImageFromView(WMView *view, XEvent *event);
|
||||||
|
|
||||||
|
/* Create a drag handler, associating drag event masks with dragEventProc */
|
||||||
|
void WMCreateDragHandler(WMView *view, WMEventProc *dragEventProc, void *clientData);
|
||||||
|
|
||||||
|
void WMDeleteDragHandler(WMView *view, WMEventProc *dragEventProc, void *clientData);
|
||||||
|
|
||||||
|
/* set default drag handler for view */
|
||||||
|
void WMSetViewDraggable(WMView *view, WMDragSourceProcs *procs, WMPixmap *dragImage);
|
||||||
|
|
||||||
|
void WMUnsetViewDraggable(WMView *view);
|
||||||
|
|
||||||
|
void WMRegisterViewForDraggedTypes(WMView *view, WMArray *acceptedTypes);
|
||||||
|
|
||||||
void WMUnregisterViewDraggedTypes(WMView *view);
|
void WMUnregisterViewDraggedTypes(WMView *view);
|
||||||
|
|
||||||
void WMSetViewDragDestinationProcs(WMView *view, WMDragDestinationProcs *procs);
|
void WMSetViewDragDestinationProcs(WMView *view, WMDragDestinationProcs *procs);
|
||||||
|
|
||||||
|
/* ....................................................................... */
|
||||||
|
|
||||||
WMPoint WMGetDraggingInfoImageLocation(WMDraggingInfo *info);
|
Bool WMIsAntialiasingEnabled(WMScreen *scrPtr);
|
||||||
|
|
||||||
/* ....................................................................... */
|
/* ....................................................................... */
|
||||||
|
|
||||||
WMFont *WMCreateFontSet(WMScreen *scrPtr, char *fontName);
|
|
||||||
|
|
||||||
WMFont *WMCreateNormalFont(WMScreen *scrPtr, char *fontName);
|
|
||||||
|
|
||||||
WMFont* WMCreateFont(WMScreen *scrPtr, char *fontName);
|
WMFont* WMCreateFont(WMScreen *scrPtr, char *fontName);
|
||||||
|
|
||||||
|
WMFont* WMCopyFontWithStyle(WMScreen *scrPtr, WMFont *font, WMFontStyle style);
|
||||||
|
|
||||||
WMFont* WMRetainFont(WMFont *font);
|
WMFont* WMRetainFont(WMFont *font);
|
||||||
|
|
||||||
void WMReleaseFont(WMFont *font);
|
void WMReleaseFont(WMFont *font);
|
||||||
|
|
||||||
|
char* WMGetFontName(WMFont *font);
|
||||||
|
|
||||||
unsigned int WMFontHeight(WMFont *font);
|
unsigned int WMFontHeight(WMFont *font);
|
||||||
|
|
||||||
/*
|
|
||||||
WMFont *WMUserFontOfSize(WMScreen *scrPtr, int size);
|
|
||||||
|
|
||||||
WMFont *WMUserFixedPitchFontOfSize(WMScreen *scrPtr, int size);
|
|
||||||
*/
|
|
||||||
|
|
||||||
|
|
||||||
void WMSetWidgetDefaultFont(WMScreen *scr, WMFont *font);
|
void WMSetWidgetDefaultFont(WMScreen *scr, WMFont *font);
|
||||||
|
|
||||||
void WMSetWidgetDefaultBoldFont(WMScreen *scr, WMFont *font);
|
void WMSetWidgetDefaultBoldFont(WMScreen *scr, WMFont *font);
|
||||||
|
|
||||||
|
WMFont* WMDefaultSystemFont(WMScreen *scrPtr);
|
||||||
|
|
||||||
|
WMFont* WMDefaultBoldSystemFont(WMScreen *scrPtr);
|
||||||
|
|
||||||
WMFont* WMSystemFontOfSize(WMScreen *scrPtr, int size);
|
WMFont* WMSystemFontOfSize(WMScreen *scrPtr, int size);
|
||||||
|
|
||||||
WMFont* WMBoldSystemFontOfSize(WMScreen *scrPtr, int size);
|
WMFont* WMBoldSystemFontOfSize(WMScreen *scrPtr, int size);
|
||||||
|
|
||||||
XFontSet WMGetFontFontSet(WMFont *font);
|
|
||||||
|
|
||||||
WMFont * WMNormalizeFont(WMScreen *scr, WMFont *font);
|
|
||||||
|
|
||||||
WMFont * WMStrengthenFont(WMScreen *scr, WMFont *font);
|
|
||||||
|
|
||||||
WMFont * WMUnstrengthenFont(WMScreen *scr, WMFont *font);
|
|
||||||
|
|
||||||
WMFont * WMEmphasizeFont(WMScreen *scr, WMFont *font);
|
|
||||||
|
|
||||||
WMFont * WMUnemphasizeFont(WMScreen *scr, WMFont *font);
|
|
||||||
|
|
||||||
WMFont * WMGetFontOfSize(WMScreen *scr, WMFont *font, int size);
|
|
||||||
|
|
||||||
/* ....................................................................... */
|
/* ....................................................................... */
|
||||||
|
|
||||||
WMPixmap* WMRetainPixmap(WMPixmap *pixmap);
|
WMPixmap* WMRetainPixmap(WMPixmap *pixmap);
|
||||||
@@ -727,6 +782,9 @@ WMSize WMGetPixmapSize(WMPixmap *pixmap);
|
|||||||
|
|
||||||
WMPixmap* WMCreatePixmapFromFile(WMScreen *scrPtr, char *fileName);
|
WMPixmap* WMCreatePixmapFromFile(WMScreen *scrPtr, char *fileName);
|
||||||
|
|
||||||
|
WMPixmap* WMCreateBlendedPixmapFromRImage(WMScreen *scrPtr, RImage *image,
|
||||||
|
RColor *color);
|
||||||
|
|
||||||
WMPixmap* WMCreateBlendedPixmapFromFile(WMScreen *scrPtr, char *fileName,
|
WMPixmap* WMCreateBlendedPixmapFromFile(WMScreen *scrPtr, char *fileName,
|
||||||
RColor *color);
|
RColor *color);
|
||||||
|
|
||||||
@@ -766,24 +824,33 @@ WMColor *WMCreateRGBColor(WMScreen *scr, unsigned short red,
|
|||||||
unsigned short green, unsigned short blue,
|
unsigned short green, unsigned short blue,
|
||||||
Bool exact);
|
Bool exact);
|
||||||
|
|
||||||
|
WMColor* WMCreateRGBAColor(WMScreen *scr, unsigned short red,
|
||||||
|
unsigned short green, unsigned short blue,
|
||||||
|
unsigned short alpha, Bool exact);
|
||||||
|
|
||||||
WMColor* WMCreateNamedColor(WMScreen *scr, char *name, Bool exact);
|
WMColor* WMCreateNamedColor(WMScreen *scr, char *name, Bool exact);
|
||||||
|
|
||||||
|
void WMSetColorAlpha(WMColor *color, unsigned short alpha);
|
||||||
|
|
||||||
unsigned short WMRedComponentOfColor(WMColor *color);
|
unsigned short WMRedComponentOfColor(WMColor *color);
|
||||||
|
|
||||||
unsigned short WMGreenComponentOfColor(WMColor *color);
|
unsigned short WMGreenComponentOfColor(WMColor *color);
|
||||||
|
|
||||||
unsigned short WMBlueComponentOfColor(WMColor *color);
|
unsigned short WMBlueComponentOfColor(WMColor *color);
|
||||||
|
|
||||||
|
unsigned short WMGetColorAlpha(WMColor *color);
|
||||||
|
|
||||||
char* WMGetColorRGBDescription(WMColor *color);
|
char* WMGetColorRGBDescription(WMColor *color);
|
||||||
|
|
||||||
/* ....................................................................... */
|
/* ....................................................................... */
|
||||||
|
|
||||||
|
|
||||||
void WMDrawString(WMScreen *scr, Drawable d, GC gc, WMFont *font, int x,
|
void WMDrawString(WMScreen *scr, Drawable d, WMColor *color, WMFont *font,
|
||||||
int y, char *text, int length);
|
int x, int y, char *text, int length);
|
||||||
|
|
||||||
void WMDrawImageString(WMScreen *scr, Drawable d, GC gc, WMFont *font, int x,
|
void WMDrawImageString(WMScreen *scr, Drawable d, WMColor *color,
|
||||||
int y, char *text, int length);
|
WMColor *background, WMFont *font, int x, int y,
|
||||||
|
char *text, int length);
|
||||||
|
|
||||||
int WMWidthOfString(WMFont *font, char *text, int length);
|
int WMWidthOfString(WMFont *font, char *text, int length);
|
||||||
|
|
||||||
@@ -813,12 +880,16 @@ void WMResizeWidget(WMWidget *w, unsigned int width, unsigned int height);
|
|||||||
|
|
||||||
void WMSetWidgetBackgroundColor(WMWidget *w, WMColor *color);
|
void WMSetWidgetBackgroundColor(WMWidget *w, WMColor *color);
|
||||||
|
|
||||||
|
WMColor* WMGetWidgetBackgroundColor(WMWidget *w);
|
||||||
|
|
||||||
void WMMapSubwidgets(WMWidget *w);
|
void WMMapSubwidgets(WMWidget *w);
|
||||||
|
|
||||||
void WMUnmapSubwidgets(WMWidget *w);
|
void WMUnmapSubwidgets(WMWidget *w);
|
||||||
|
|
||||||
void WMRealizeWidget(WMWidget *w);
|
void WMRealizeWidget(WMWidget *w);
|
||||||
|
|
||||||
|
void WMReparentWidget(WMWidget *w, WMWidget *newParent, int x, int y);
|
||||||
|
|
||||||
void WMDestroyWidget(WMWidget *widget);
|
void WMDestroyWidget(WMWidget *widget);
|
||||||
|
|
||||||
void WMHangData(WMWidget *widget, void *data);
|
void WMHangData(WMWidget *widget, void *data);
|
||||||
@@ -837,6 +908,9 @@ void WMRedisplayWidget(WMWidget *w);
|
|||||||
|
|
||||||
void WMSetViewNotifySizeChanges(WMView *view, Bool flag);
|
void WMSetViewNotifySizeChanges(WMView *view, Bool flag);
|
||||||
|
|
||||||
|
void WMSetViewExpandsToParent(WMView *view, int topOffs, int leftOffs,
|
||||||
|
int rightOffs, int bottomOffs);
|
||||||
|
|
||||||
WMSize WMGetViewSize(WMView *view);
|
WMSize WMGetViewSize(WMView *view);
|
||||||
|
|
||||||
WMPoint WMGetViewPosition(WMView *view);
|
WMPoint WMGetViewPosition(WMView *view);
|
||||||
@@ -845,12 +919,16 @@ WMPoint WMGetViewScreenPosition(WMView *view);
|
|||||||
|
|
||||||
WMWidget* WMWidgetOfView(WMView *view);
|
WMWidget* WMWidgetOfView(WMView *view);
|
||||||
|
|
||||||
|
void WMSetViewNextResponder(WMView *view, WMView *responder);
|
||||||
|
|
||||||
|
void WMRelayToNextResponder(WMView *view, XEvent *event);
|
||||||
|
|
||||||
/* notifications */
|
/* notifications */
|
||||||
extern char *WMViewSizeDidChangeNotification;
|
extern char *WMViewSizeDidChangeNotification;
|
||||||
|
|
||||||
extern char *WMViewRealizedNotification;
|
extern char *WMViewFocusDidChangeNotification;
|
||||||
|
|
||||||
extern char *WMFontPanelDidChangeNotification;
|
extern char *WMViewRealizedNotification;
|
||||||
|
|
||||||
|
|
||||||
/* ....................................................................... */
|
/* ....................................................................... */
|
||||||
@@ -885,7 +963,7 @@ void WMSetWindowTitle(WMWindow *wPtr, char *title);
|
|||||||
|
|
||||||
void WMSetWindowMiniwindowTitle(WMWindow *win, char *title);
|
void WMSetWindowMiniwindowTitle(WMWindow *win, char *title);
|
||||||
|
|
||||||
void WMSetWindowMiniwindowImage(WMWindow *win, WMPixmap *pixmap);
|
void WMSetWindowMiniwindowPixmap(WMWindow *win, WMPixmap *pixmap);
|
||||||
|
|
||||||
void WMSetWindowCloseAction(WMWindow *win, WMAction *action, void *clientData);
|
void WMSetWindowCloseAction(WMWindow *win, WMAction *action, void *clientData);
|
||||||
|
|
||||||
@@ -960,6 +1038,8 @@ void WMSetButtonBordered(WMButton *bPtr, int isBordered);
|
|||||||
|
|
||||||
void WMSetButtonEnabled(WMButton *bPtr, Bool flag);
|
void WMSetButtonEnabled(WMButton *bPtr, Bool flag);
|
||||||
|
|
||||||
|
int WMGetButtonEnabled(WMButton *bPtr);
|
||||||
|
|
||||||
void WMSetButtonImageDimsWhenDisabled(WMButton *bPtr, Bool flag);
|
void WMSetButtonImageDimsWhenDisabled(WMButton *bPtr, Bool flag);
|
||||||
|
|
||||||
void WMSetButtonTag(WMButton *bPtr, int tag);
|
void WMSetButtonTag(WMButton *bPtr, int tag);
|
||||||
@@ -982,6 +1062,8 @@ void WMSetLabelImage(WMLabel *lPtr, WMPixmap *image);
|
|||||||
|
|
||||||
WMPixmap* WMGetLabelImage(WMLabel *lPtr);
|
WMPixmap* WMGetLabelImage(WMLabel *lPtr);
|
||||||
|
|
||||||
|
char* WMGetLabelText(WMLabel *lPtr);
|
||||||
|
|
||||||
void WMSetLabelImagePosition(WMLabel *lPtr, WMImagePosition position);
|
void WMSetLabelImagePosition(WMLabel *lPtr, WMImagePosition position);
|
||||||
|
|
||||||
void WMSetLabelTextAlignment(WMLabel *lPtr, WMAlignment alignment);
|
void WMSetLabelTextAlignment(WMLabel *lPtr, WMAlignment alignment);
|
||||||
@@ -990,6 +1072,8 @@ void WMSetLabelRelief(WMLabel *lPtr, WMReliefType relief);
|
|||||||
|
|
||||||
void WMSetLabelText(WMLabel *lPtr, char *text);
|
void WMSetLabelText(WMLabel *lPtr, char *text);
|
||||||
|
|
||||||
|
WMFont* WMGetLabelFont(WMLabel *lPtr);
|
||||||
|
|
||||||
void WMSetLabelFont(WMLabel *lPtr, WMFont *font);
|
void WMSetLabelFont(WMLabel *lPtr, WMFont *font);
|
||||||
|
|
||||||
void WMSetLabelTextColor(WMLabel *lPtr, WMColor *color);
|
void WMSetLabelTextColor(WMLabel *lPtr, WMColor *color);
|
||||||
@@ -1043,6 +1127,7 @@ void WMSetTextFieldPrevTextField(WMTextField *tPtr, WMTextField *prev);
|
|||||||
|
|
||||||
void WMSetTextFieldDelegate(WMTextField *tPtr, WMTextFieldDelegate *delegate);
|
void WMSetTextFieldDelegate(WMTextField *tPtr, WMTextFieldDelegate *delegate);
|
||||||
|
|
||||||
|
WMTextFieldDelegate* WMGetTextFieldDelegate(WMTextField *tPtr);
|
||||||
|
|
||||||
extern char *WMTextDidChangeNotification;
|
extern char *WMTextDidChangeNotification;
|
||||||
extern char *WMTextDidBeginEditingNotification;
|
extern char *WMTextDidBeginEditingNotification;
|
||||||
@@ -1310,7 +1395,6 @@ char *WMGetPopUpButtonItem(WMPopUpButton *bPtr, int index);
|
|||||||
|
|
||||||
WMMenuItem* WMGetPopUpButtonMenuItem(WMPopUpButton *bPtr, int index);
|
WMMenuItem* WMGetPopUpButtonMenuItem(WMPopUpButton *bPtr, int index);
|
||||||
|
|
||||||
|
|
||||||
int WMGetPopUpButtonNumberOfItems(WMPopUpButton *bPtr);
|
int WMGetPopUpButtonNumberOfItems(WMPopUpButton *bPtr);
|
||||||
|
|
||||||
void WMSetPopUpButtonEnabled(WMPopUpButton *bPtr, Bool flag);
|
void WMSetPopUpButtonEnabled(WMPopUpButton *bPtr, Bool flag);
|
||||||
@@ -1383,8 +1467,6 @@ void WMSetScrollViewContentView(WMScrollView *sPtr, WMView *view);
|
|||||||
|
|
||||||
void WMSetScrollViewRelief(WMScrollView *sPtr, WMReliefType type);
|
void WMSetScrollViewRelief(WMScrollView *sPtr, WMReliefType type);
|
||||||
|
|
||||||
void WMSetScrollViewContentView(WMScrollView *sPtr, WMView *view);
|
|
||||||
|
|
||||||
WMRect WMGetScrollViewVisibleRect(WMScrollView *sPtr);
|
WMRect WMGetScrollViewVisibleRect(WMScrollView *sPtr);
|
||||||
|
|
||||||
WMScroller* WMGetScrollViewHorizontalScroller(WMScrollView *sPtr);
|
WMScroller* WMGetScrollViewHorizontalScroller(WMScrollView *sPtr);
|
||||||
@@ -1423,7 +1505,9 @@ void WMSetSliderImage(WMSlider *sPtr, WMPixmap *pixmap);
|
|||||||
|
|
||||||
|
|
||||||
WMSplitView* WMCreateSplitView(WMWidget *parent);
|
WMSplitView* WMCreateSplitView(WMWidget *parent);
|
||||||
|
|
||||||
Bool WMGetSplitViewVertical(WMSplitView *sPtr);
|
Bool WMGetSplitViewVertical(WMSplitView *sPtr);
|
||||||
|
|
||||||
void WMSetSplitViewVertical(WMSplitView *sPtr, Bool flag);
|
void WMSetSplitViewVertical(WMSplitView *sPtr, Bool flag);
|
||||||
|
|
||||||
int WMGetSplitViewSubviewsCount(WMSplitView *sPtr); /* ??? remove ??? */
|
int WMGetSplitViewSubviewsCount(WMSplitView *sPtr); /* ??? remove ??? */
|
||||||
@@ -1458,8 +1542,7 @@ WMRulerMargins *WMGetRulerMargins(WMRuler *rPtr);
|
|||||||
|
|
||||||
void WMSetRulerMargins(WMRuler *rPtr, WMRulerMargins margins);
|
void WMSetRulerMargins(WMRuler *rPtr, WMRulerMargins margins);
|
||||||
|
|
||||||
Bool WMIsMarginEqualToMargin(WMRulerMargins *aMargin,
|
Bool WMIsMarginEqualToMargin(WMRulerMargins *aMargin, WMRulerMargins *anotherMargin);
|
||||||
WMRulerMargins *anotherMargin);
|
|
||||||
|
|
||||||
int WMGetGrabbedRulerMargin(WMRuler *rPtr);
|
int WMGetGrabbedRulerMargin(WMRuler *rPtr);
|
||||||
|
|
||||||
@@ -1479,8 +1562,8 @@ void WMSetRulerReleaseAction(WMRuler *rPtr, WMAction *action, void *clientData);
|
|||||||
#define WMCreateText(parent) WMCreateTextForDocumentType \
|
#define WMCreateText(parent) WMCreateTextForDocumentType \
|
||||||
((parent), (NULL), (NULL))
|
((parent), (NULL), (NULL))
|
||||||
|
|
||||||
WMText *WMCreateTextForDocumentType(WMWidget *parent,
|
WMText* WMCreateTextForDocumentType(WMWidget *parent, WMAction *parser,
|
||||||
WMAction *parser, WMAction *writer);
|
WMAction *writer);
|
||||||
|
|
||||||
void WMSetTextDelegate(WMText *tPtr, WMTextDelegate *delegate);
|
void WMSetTextDelegate(WMText *tPtr, WMTextDelegate *delegate);
|
||||||
|
|
||||||
@@ -1538,6 +1621,9 @@ void WMPrependTextStream(WMText *tPtr, char *text);
|
|||||||
|
|
||||||
void WMAppendTextStream(WMText *tPtr, char *text);
|
void WMAppendTextStream(WMText *tPtr, char *text);
|
||||||
|
|
||||||
|
#define WMClearText(tPtr) WMAppendTextStream \
|
||||||
|
((tPtr), (NULL))
|
||||||
|
|
||||||
/* free the text */
|
/* free the text */
|
||||||
char* WMGetTextStream(WMText *tPtr);
|
char* WMGetTextStream(WMText *tPtr);
|
||||||
|
|
||||||
@@ -1573,30 +1659,33 @@ Bool WMReplaceTextSelection(WMText *tPtr, char *replacement);
|
|||||||
/* parser related stuff... use only if implementing a new parser */
|
/* parser related stuff... use only if implementing a new parser */
|
||||||
|
|
||||||
void* WMCreateTextBlockWithObject(WMText *tPtr, WMWidget *w, char *description,
|
void* WMCreateTextBlockWithObject(WMText *tPtr, WMWidget *w, char *description,
|
||||||
WMColor *color, unsigned short first, unsigned short extraInfo);
|
WMColor *color, unsigned short first,
|
||||||
|
unsigned short extraInfo);
|
||||||
|
|
||||||
void* WMCreateTextBlockWithPixmap(WMText *tPtr, WMPixmap *p, char *description,
|
void* WMCreateTextBlockWithPixmap(WMText *tPtr, WMPixmap *p, char *description,
|
||||||
WMColor *color, unsigned short first, unsigned short extraInfo);
|
WMColor *color, unsigned short first,
|
||||||
|
unsigned short extraInfo);
|
||||||
|
|
||||||
void* WMCreateTextBlockWithText(WMText *tPtr, char *text, WMFont *font,
|
void* WMCreateTextBlockWithText(WMText *tPtr, char *text, WMFont *font,
|
||||||
WMColor *color, unsigned short first, unsigned short length);
|
WMColor *color, unsigned short first,
|
||||||
|
unsigned short length);
|
||||||
|
|
||||||
void WMSetTextBlockProperties(WMText *tPtr, void *vtb, unsigned int first,
|
void WMSetTextBlockProperties(WMText *tPtr, void *vtb, unsigned int first,
|
||||||
unsigned int kanji, unsigned int underlined, int script,
|
unsigned int kanji, unsigned int underlined,
|
||||||
WMRulerMargins *margins);
|
int script, WMRulerMargins *margins);
|
||||||
|
|
||||||
/* do NOT free the margins */
|
/* do NOT free the margins */
|
||||||
void WMGetTextBlockProperties(WMText *tPtr, void *vtb, unsigned int *first,
|
void WMGetTextBlockProperties(WMText *tPtr, void *vtb, unsigned int *first,
|
||||||
unsigned int *kanji, unsigned int *underlined, int *script,
|
unsigned int *kanji, unsigned int *underlined,
|
||||||
WMRulerMargins *margins);
|
int *script, WMRulerMargins *margins);
|
||||||
|
|
||||||
int WMGetTextInsertType(WMText *tPtr);
|
int WMGetTextInsertType(WMText *tPtr);
|
||||||
|
|
||||||
int WMGetTextBlocks(WMText *tPtr);
|
/*int WMGetTextBlocks(WMText *tPtr);
|
||||||
|
|
||||||
void WMSetCurrentTextBlock(WMText *tPtr, int current);
|
void WMSetCurrentTextBlock(WMText *tPtr, int current);
|
||||||
|
|
||||||
int WMGetCurrentTextBlock(WMText *tPtr);
|
int WMGetCurrentTextBlock(WMText *tPtr);*/
|
||||||
|
|
||||||
void WMPrependTextBlock(WMText *tPtr, void *vtb);
|
void WMPrependTextBlock(WMText *tPtr, void *vtb);
|
||||||
|
|
||||||
@@ -1613,6 +1702,8 @@ WMTabView *WMCreateTabView(WMWidget *parent);
|
|||||||
|
|
||||||
void WMSetTabViewType(WMTabView *tPtr, WMTabViewType type);
|
void WMSetTabViewType(WMTabView *tPtr, WMTabViewType type);
|
||||||
|
|
||||||
|
void WMSetTabViewEnabled(WMTabView *tPtr, Bool flag);
|
||||||
|
|
||||||
void WMSetTabViewFont(WMTabView *tPtr, WMFont *font);
|
void WMSetTabViewFont(WMTabView *tPtr, WMFont *font);
|
||||||
|
|
||||||
void WMAddItemInTabView(WMTabView *tPtr, WMTabViewItem *item);
|
void WMAddItemInTabView(WMTabView *tPtr, WMTabViewItem *item);
|
||||||
@@ -1645,6 +1736,8 @@ void WMSetTabViewDelegate(WMTabView *tPtr, WMTabViewDelegate *delegate);
|
|||||||
|
|
||||||
WMTabViewItem* WMCreateTabViewItemWithIdentifier(int identifier);
|
WMTabViewItem* WMCreateTabViewItemWithIdentifier(int identifier);
|
||||||
|
|
||||||
|
void WMSetTabViewItemEnabled(WMTabViewItem *tPtr, Bool flag);
|
||||||
|
|
||||||
int WMGetTabViewItemIdentifier(WMTabViewItem *item);
|
int WMGetTabViewItemIdentifier(WMTabViewItem *item);
|
||||||
|
|
||||||
void WMSetTabViewItemLabel(WMTabViewItem *item, char *label);
|
void WMSetTabViewItemLabel(WMTabViewItem *item, char *label);
|
||||||
@@ -1670,6 +1763,8 @@ void WMAddBoxSubview(WMBox *bPtr, WMView *view, Bool expand, Bool fill,
|
|||||||
void WMAddBoxSubviewAtEnd(WMBox *bPtr, WMView *view, Bool expand, Bool fill,
|
void WMAddBoxSubviewAtEnd(WMBox *bPtr, WMView *view, Bool expand, Bool fill,
|
||||||
int minSize, int maxSize, int space);
|
int minSize, int maxSize, int space);
|
||||||
|
|
||||||
|
void WMRemoveBoxSubview(WMBox *bPtr, WMView *view);
|
||||||
|
|
||||||
void WMSetBoxHorizontal(WMBox *box, Bool flag);
|
void WMSetBoxHorizontal(WMBox *box, Bool flag);
|
||||||
|
|
||||||
/* ....................................................................... */
|
/* ....................................................................... */
|
||||||
@@ -1690,10 +1785,17 @@ WMInputPanel *WMCreateInputPanel(WMScreen *app, WMWindow *owner, char *title,
|
|||||||
char *msg, char *defaultText, char *okButton,
|
char *msg, char *defaultText, char *okButton,
|
||||||
char *cancelButton);
|
char *cancelButton);
|
||||||
|
|
||||||
|
|
||||||
|
WMGenericPanel* WMCreateGenericPanel(WMScreen *scrPtr, WMWindow *owner,
|
||||||
|
char *title, char *defaultButton,
|
||||||
|
char *alternateButton);
|
||||||
|
|
||||||
void WMDestroyAlertPanel(WMAlertPanel *panel);
|
void WMDestroyAlertPanel(WMAlertPanel *panel);
|
||||||
|
|
||||||
void WMDestroyInputPanel(WMInputPanel *panel);
|
void WMDestroyInputPanel(WMInputPanel *panel);
|
||||||
|
|
||||||
|
void WMDestroyGenericPanel(WMGenericPanel *panel);
|
||||||
|
|
||||||
/* ....................................................................... */
|
/* ....................................................................... */
|
||||||
|
|
||||||
/* only 1 instance per WMScreen */
|
/* only 1 instance per WMScreen */
|
||||||
@@ -1731,10 +1833,11 @@ void WMShowFontPanel(WMFontPanel *panel);
|
|||||||
|
|
||||||
void WMHideFontPanel(WMFontPanel *panel);
|
void WMHideFontPanel(WMFontPanel *panel);
|
||||||
|
|
||||||
void WMSetFontPanelFont(WMFontPanel *panel, WMFont *font);
|
void WMFreeFontPanel(WMFontPanel *panel);
|
||||||
|
|
||||||
/* you can free the returned string */
|
void WMSetFontPanelAction(WMFontPanel *panel, WMAction2 *action, void *data);
|
||||||
char *WMGetFontPanelFontName(WMFontPanel *panel);
|
|
||||||
|
void WMSetFontPanelFont(WMFontPanel *panel, char *fontName);
|
||||||
|
|
||||||
WMFont* WMGetFontPanelFont(WMFontPanel *panel);
|
WMFont* WMGetFontPanelFont(WMFontPanel *panel);
|
||||||
|
|
||||||
@@ -6,9 +6,9 @@
|
|||||||
#include <X11/Xutil.h>
|
#include <X11/Xutil.h>
|
||||||
|
|
||||||
|
|
||||||
#include "WINGs.h"
|
#include <WINGs/WINGs.h>
|
||||||
|
|
||||||
#if WINGS_H_VERSION < 20000521
|
#if WINGS_H_VERSION < 20040406
|
||||||
#error There_is_an_old_WINGs.h_file_somewhere_in_your_system._Please_remove_it.
|
#error There_is_an_old_WINGs.h_file_somewhere_in_your_system._Please_remove_it.
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@@ -22,18 +22,13 @@
|
|||||||
extern "C" {
|
extern "C" {
|
||||||
#endif /* __cplusplus */
|
#endif /* __cplusplus */
|
||||||
|
|
||||||
#define DOUBLE_BUFFER
|
|
||||||
|
|
||||||
|
|
||||||
|
#define DOUBLE_BUFFER 1
|
||||||
|
|
||||||
#define WC_UserWidget 128
|
#define WC_UserWidget 128
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#define SCROLLER_WIDTH 20
|
#define SCROLLER_WIDTH 20
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#define XDND_VERSION 4
|
#define XDND_VERSION 4
|
||||||
|
|
||||||
|
|
||||||
@@ -48,15 +43,12 @@ typedef struct W_Application {
|
|||||||
typedef struct W_Font {
|
typedef struct W_Font {
|
||||||
struct W_Screen *screen;
|
struct W_Screen *screen;
|
||||||
|
|
||||||
union {
|
struct _XftFont *font;
|
||||||
XFontSet set;
|
|
||||||
XFontStruct *normal;
|
|
||||||
} font;
|
|
||||||
short height;
|
short height;
|
||||||
short y;
|
short y;
|
||||||
short refCount;
|
short refCount;
|
||||||
char *name;
|
char *name;
|
||||||
unsigned int notFontSet:1;
|
|
||||||
} W_Font;
|
} W_Font;
|
||||||
|
|
||||||
|
|
||||||
@@ -75,6 +67,7 @@ typedef struct W_Color {
|
|||||||
struct W_Screen *screen;
|
struct W_Screen *screen;
|
||||||
|
|
||||||
XColor color;
|
XColor color;
|
||||||
|
unsigned short alpha;
|
||||||
short refCount;
|
short refCount;
|
||||||
GC gc;
|
GC gc;
|
||||||
struct {
|
struct {
|
||||||
@@ -91,28 +84,51 @@ typedef struct W_FocusInfo {
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
struct W_DraggingInfo {
|
typedef void* W_DndState(WMView *destView, XClientMessageEvent *event,
|
||||||
|
WMDraggingInfo *info);
|
||||||
|
|
||||||
|
|
||||||
|
typedef struct W_DragOperationItem {
|
||||||
|
WMDragOperationType type;
|
||||||
|
char* text;
|
||||||
|
} W_DragOperationItem;
|
||||||
|
|
||||||
|
|
||||||
|
typedef struct W_DragSourceInfo {
|
||||||
|
WMView *sourceView;
|
||||||
Window destinationWindow;
|
Window destinationWindow;
|
||||||
Window sourceWindow;
|
W_DndState *state;
|
||||||
|
WMSelectionProcs *selectionProcs;
|
||||||
WMPoint location;
|
Window icon;
|
||||||
|
|
||||||
unsigned sourceOperation;
|
|
||||||
WMPixmap *image;
|
|
||||||
WMPoint imageLocation;
|
WMPoint imageLocation;
|
||||||
|
WMPoint mouseOffset; /* mouse pos in icon */
|
||||||
|
Cursor dragCursor;
|
||||||
|
WMRect noPositionMessageZone;
|
||||||
|
Atom firstThreeTypes[3];
|
||||||
|
} W_DragSourceInfo;
|
||||||
|
|
||||||
char **types;
|
|
||||||
|
|
||||||
|
typedef struct W_DragDestinationInfo {
|
||||||
|
WMView *destView;
|
||||||
|
Window sourceWindow;
|
||||||
|
W_DndState *state;
|
||||||
|
WMArray *sourceTypes;
|
||||||
|
WMArray *requiredTypes;
|
||||||
|
Bool typeListAvailable;
|
||||||
|
WMArray *dropDatas;
|
||||||
|
} W_DragDestinationInfo;
|
||||||
|
|
||||||
|
|
||||||
|
struct W_DraggingInfo {
|
||||||
|
unsigned char protocolVersion;
|
||||||
Time timestamp;
|
Time timestamp;
|
||||||
|
|
||||||
int protocolVersion;
|
Atom sourceAction;
|
||||||
|
Atom destinationAction;
|
||||||
|
|
||||||
/* should be treated as internal data */
|
W_DragSourceInfo* sourceInfo; /* infos needed by source */
|
||||||
WMView *sourceView;
|
W_DragDestinationInfo* destInfo; /* infos needed by destination */
|
||||||
WMView *destView;
|
} W_DraggingInfo;
|
||||||
WMSize mouseOffset;
|
|
||||||
unsigned finished:1;
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
typedef struct W_Screen {
|
typedef struct W_Screen {
|
||||||
@@ -132,11 +148,16 @@ typedef struct W_Screen {
|
|||||||
|
|
||||||
RContext *rcontext;
|
RContext *rcontext;
|
||||||
|
|
||||||
|
struct W_IMContext *imctx;
|
||||||
|
|
||||||
|
struct _XftDraw *xftdraw; /* shared XftDraw */
|
||||||
|
|
||||||
/* application related */
|
/* application related */
|
||||||
|
|
||||||
W_FocusInfo *focusInfo;
|
W_FocusInfo *focusInfo;
|
||||||
|
|
||||||
struct W_Pixmap *applicationIcon;
|
RImage *applicationIconImage; /* image (can have alpha channel) */
|
||||||
|
struct W_Pixmap *applicationIconPixmap; /* pixmap - no alpha channel */
|
||||||
Window applicationIconWindow;
|
Window applicationIconWindow;
|
||||||
|
|
||||||
struct W_Window *windowList; /* list of windows in the app */
|
struct W_Window *windowList; /* list of windows in the app */
|
||||||
@@ -180,7 +201,9 @@ typedef struct W_Screen {
|
|||||||
|
|
||||||
GC ixorGC; /* IncludeInferiors XOR */
|
GC ixorGC; /* IncludeInferiors XOR */
|
||||||
|
|
||||||
GC textFieldGC;
|
GC drawStringGC; /* for WMDrawString() */
|
||||||
|
|
||||||
|
GC drawImStringGC; /* for WMDrawImageString() */
|
||||||
|
|
||||||
W_Font *normalFont;
|
W_Font *normalFont;
|
||||||
|
|
||||||
@@ -188,7 +211,9 @@ typedef struct W_Screen {
|
|||||||
|
|
||||||
WMHashTable *fontCache;
|
WMHashTable *fontCache;
|
||||||
|
|
||||||
Bool useMultiByte;
|
Bool antialiasedText;
|
||||||
|
|
||||||
|
unsigned int ignoredModifierMask; /* modifiers to ignore when typing txt */
|
||||||
|
|
||||||
struct W_Balloon *balloon;
|
struct W_Balloon *balloon;
|
||||||
|
|
||||||
@@ -267,6 +292,8 @@ typedef struct W_Screen {
|
|||||||
Atom xdndDropAtom;
|
Atom xdndDropAtom;
|
||||||
Atom xdndFinishedAtom;
|
Atom xdndFinishedAtom;
|
||||||
Atom xdndTypeListAtom;
|
Atom xdndTypeListAtom;
|
||||||
|
Atom xdndActionListAtom;
|
||||||
|
Atom xdndActionDescriptionAtom;
|
||||||
Atom xdndStatusAtom;
|
Atom xdndStatusAtom;
|
||||||
|
|
||||||
Atom xdndActionCopy;
|
Atom xdndActionCopy;
|
||||||
@@ -284,7 +311,7 @@ typedef struct W_Screen {
|
|||||||
Window lastClickWindow; /* window of the last mousedown */
|
Window lastClickWindow; /* window of the last mousedown */
|
||||||
|
|
||||||
struct W_View *modalView;
|
struct W_View *modalView;
|
||||||
unsigned modal:1;
|
unsigned modalLoop:1;
|
||||||
unsigned ignoreNextDoubleClick:1;
|
unsigned ignoreNextDoubleClick:1;
|
||||||
} W_Screen;
|
} W_Screen;
|
||||||
|
|
||||||
@@ -317,18 +344,25 @@ typedef struct W_View {
|
|||||||
|
|
||||||
WMSize size;
|
WMSize size;
|
||||||
|
|
||||||
|
short topOffs;
|
||||||
|
short leftOffs;
|
||||||
|
short bottomOffs;
|
||||||
|
short rightOffs;
|
||||||
|
|
||||||
WMPoint pos;
|
WMPoint pos;
|
||||||
|
|
||||||
struct W_View *nextFocusChain; /* next/prev in focus chain */
|
struct W_View *nextFocusChain; /* next/prev in focus chain */
|
||||||
struct W_View *prevFocusChain;
|
struct W_View *prevFocusChain;
|
||||||
|
|
||||||
|
struct W_View *nextResponder; /* next to receive keyboard events */
|
||||||
|
|
||||||
struct W_View *parent; /* parent WMView */
|
struct W_View *parent; /* parent WMView */
|
||||||
|
|
||||||
struct W_View *childrenList; /* first in list of child windows */
|
struct W_View *childrenList; /* first in list of child windows */
|
||||||
|
|
||||||
struct W_View *nextSister; /* next on parent's children list */
|
struct W_View *nextSister; /* next on parent's children list */
|
||||||
|
|
||||||
WMBag *eventHandlers; /* event handlers for this window */
|
WMArray *eventHandlers; /* event handlers for this window */
|
||||||
|
|
||||||
unsigned long attribFlags;
|
unsigned long attribFlags;
|
||||||
XSetWindowAttributes attribs;
|
XSetWindowAttributes attribs;
|
||||||
@@ -342,6 +376,7 @@ typedef struct W_View {
|
|||||||
Atom *droppableTypes;
|
Atom *droppableTypes;
|
||||||
struct W_DragSourceProcs *dragSourceProcs;
|
struct W_DragSourceProcs *dragSourceProcs;
|
||||||
struct W_DragDestinationProcs *dragDestinationProcs;
|
struct W_DragDestinationProcs *dragDestinationProcs;
|
||||||
|
WMPixmap *dragImage;
|
||||||
int helpContext;
|
int helpContext;
|
||||||
|
|
||||||
|
|
||||||
@@ -357,8 +392,8 @@ typedef struct W_View {
|
|||||||
|
|
||||||
unsigned int dontCompressMotion:1; /* motion notify event compress */
|
unsigned int dontCompressMotion:1; /* motion notify event compress */
|
||||||
unsigned int notifySizeChanged:1;
|
unsigned int notifySizeChanged:1;
|
||||||
unsigned int dontCompressExpose:1; /* will compress all expose
|
unsigned int dontCompressExpose:1; /* expose event compress */
|
||||||
events into one */
|
|
||||||
/* toplevel only */
|
/* toplevel only */
|
||||||
unsigned int worksWhenModal:1;
|
unsigned int worksWhenModal:1;
|
||||||
unsigned int pendingRelease1:1;
|
unsigned int pendingRelease1:1;
|
||||||
@@ -388,7 +423,7 @@ typedef struct _WINGsConfiguration {
|
|||||||
char *systemFont;
|
char *systemFont;
|
||||||
char *boldSystemFont;
|
char *boldSystemFont;
|
||||||
int defaultFontSize;
|
int defaultFontSize;
|
||||||
Bool useMultiByte;
|
Bool antialiasedText;
|
||||||
char *floppyPath;
|
char *floppyPath;
|
||||||
unsigned doubleClickDelay;
|
unsigned doubleClickDelay;
|
||||||
unsigned mouseWheelUp;
|
unsigned mouseWheelUp;
|
||||||
@@ -472,17 +507,15 @@ void W_DrawReliefWithGC(W_Screen *scr, Drawable d, int x, int y,
|
|||||||
WMReliefType relief,
|
WMReliefType relief,
|
||||||
GC black, GC dark, GC light, GC white);
|
GC black, GC dark, GC light, GC white);
|
||||||
|
|
||||||
void W_CleanUpEvents(W_View *view);
|
|
||||||
|
|
||||||
void W_CallDestroyHandlers(W_View *view);
|
void W_CallDestroyHandlers(W_View *view);
|
||||||
|
|
||||||
void W_PaintTextAndImage(W_View *view, int wrap, GC textGC, W_Font *font,
|
void W_PaintTextAndImage(W_View *view, int wrap, WMColor *textColor,
|
||||||
WMReliefType relief, char *text,
|
W_Font *font, WMReliefType relief, char *text,
|
||||||
WMAlignment alignment, W_Pixmap *image,
|
WMAlignment alignment, W_Pixmap *image,
|
||||||
WMImagePosition position, GC backGC, int ofs);
|
WMImagePosition position, WMColor *backColor, int ofs);
|
||||||
|
|
||||||
void W_PaintText(W_View *view, Drawable d, WMFont *font, int x, int y,
|
void W_PaintText(W_View *view, Drawable d, WMFont *font, int x, int y,
|
||||||
int width, WMAlignment alignment, GC gc,
|
int width, WMAlignment alignment, WMColor *color,
|
||||||
int wrap, char *text, int length);
|
int wrap, char *text, int length);
|
||||||
|
|
||||||
int W_GetTextHeight(WMFont *font, char *text, int width, int wrap);
|
int W_GetTextHeight(WMFont *font, char *text, int width, int wrap);
|
||||||
@@ -519,9 +552,9 @@ void W_HandleSelectionEvent(XEvent *event);
|
|||||||
|
|
||||||
void W_HandleDNDClientMessage(WMView *toplevel, XClientMessageEvent *event);
|
void W_HandleDNDClientMessage(WMView *toplevel, XClientMessageEvent *event);
|
||||||
|
|
||||||
void W_FlushASAPNotificationQueue();
|
void W_FlushASAPNotificationQueue(void);
|
||||||
|
|
||||||
void W_FlushIdleNotificationQueue();
|
void W_FlushIdleNotificationQueue(void);
|
||||||
|
|
||||||
struct W_Balloon *W_CreateBalloon(WMScreen *scr);
|
struct W_Balloon *W_CreateBalloon(WMScreen *scr);
|
||||||
|
|
||||||
@@ -529,8 +562,53 @@ void W_BalloonHandleEnterView(WMView *view);
|
|||||||
|
|
||||||
void W_BalloonHandleLeaveView(WMView *view);
|
void W_BalloonHandleLeaveView(WMView *view);
|
||||||
|
|
||||||
|
Bool W_CheckIdleHandlers(void);
|
||||||
|
|
||||||
|
void W_CheckTimerHandlers(void);
|
||||||
|
|
||||||
|
Bool W_HandleInputEvents(Bool waitForInput, int inputfd);
|
||||||
|
|
||||||
|
/* XDnD */
|
||||||
|
Atom W_OperationToAction(WMScreen *scr, WMDragOperationType operation);
|
||||||
|
|
||||||
|
WMDragOperationType W_ActionToOperation(WMScreen *scr, Atom action);
|
||||||
|
|
||||||
|
void W_FreeDragOperationItem(void* item);
|
||||||
|
|
||||||
|
Bool W_SendDnDClientMessage(Display *dpy, Window win, Atom message,
|
||||||
|
unsigned long data1, unsigned long data2,
|
||||||
|
unsigned long data3, unsigned long data4,
|
||||||
|
unsigned long data5);
|
||||||
|
|
||||||
|
void W_DragSourceStartTimer(WMDraggingInfo *info);
|
||||||
|
|
||||||
|
void W_DragSourceStopTimer();
|
||||||
|
|
||||||
|
void W_DragSourceStateHandler(WMDraggingInfo *info, XClientMessageEvent *event);
|
||||||
|
|
||||||
|
void W_DragDestinationStartTimer(WMDraggingInfo *info);
|
||||||
|
|
||||||
|
void W_DragDestinationStopTimer();
|
||||||
|
|
||||||
|
void W_DragDestinationStoreEnterMsgInfo(WMDraggingInfo *info, WMView *toplevel,
|
||||||
|
XClientMessageEvent *event);
|
||||||
|
|
||||||
|
void W_DragDestinationStorePositionMsgInfo(WMDraggingInfo *info,
|
||||||
|
WMView *toplevel,
|
||||||
|
XClientMessageEvent *event);
|
||||||
|
|
||||||
|
void W_DragDestinationCancelDropOnEnter(WMView *toplevel, WMDraggingInfo *info);
|
||||||
|
|
||||||
|
void W_DragDestinationStateHandler(WMDraggingInfo *info,
|
||||||
|
XClientMessageEvent *event);
|
||||||
|
|
||||||
|
void W_DragDestinationInfoClear(WMDraggingInfo *info);
|
||||||
|
|
||||||
|
void W_FreeViewXdndPart(WMView *view);
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
#endif /* __cplusplus */
|
#endif /* __cplusplus */
|
||||||
|
|
||||||
#endif /* _WINGSP_H_ */
|
#endif /* _WINGSP_H_ */
|
||||||
|
|
||||||
@@ -10,14 +10,6 @@
|
|||||||
#define NULL ((void*)0)
|
#define NULL ((void*)0)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/*
|
|
||||||
* Warning: proplist.h #defines BOOL which will clash with the
|
|
||||||
* typedef BOOL in Xmd.h
|
|
||||||
* proplist.h should use Bool (which is a #define in Xlib.h) instead.
|
|
||||||
*
|
|
||||||
*/
|
|
||||||
#include <proplist.h>
|
|
||||||
|
|
||||||
|
|
||||||
#ifndef WMAX
|
#ifndef WMAX
|
||||||
# define WMAX(a,b) ((a)>(b) ? (a) : (b))
|
# define WMAX(a,b) ((a)>(b) ? (a) : (b))
|
||||||
@@ -27,12 +19,14 @@
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
#if (!defined (__GNUC__) || __GNUC__ < 2 || \
|
#ifndef __ASSERT_FUNCTION
|
||||||
__GNUC_MINOR__ < (defined (__cplusplus) ? 6 : 4))
|
# if (!defined (__GNUC__) || (__GNUC__ < 2 && \
|
||||||
|
__GNUC_MINOR__ < (defined (__cplusplus) ? 6 : 4)))
|
||||||
# define __ASSERT_FUNCTION ((char *) 0)
|
# define __ASSERT_FUNCTION ((char *) 0)
|
||||||
# else
|
# else
|
||||||
# define __ASSERT_FUNCTION __PRETTY_FUNCTION__
|
# define __ASSERT_FUNCTION __PRETTY_FUNCTION__
|
||||||
# endif
|
# endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
#ifdef NDEBUG
|
#ifdef NDEBUG
|
||||||
@@ -120,12 +114,23 @@ enum {
|
|||||||
typedef struct W_Array WMArray;
|
typedef struct W_Array WMArray;
|
||||||
typedef struct W_Bag WMBag;
|
typedef struct W_Bag WMBag;
|
||||||
typedef struct W_Data WMData;
|
typedef struct W_Data WMData;
|
||||||
|
typedef struct W_TreeNode WMTreeNode;
|
||||||
typedef struct W_HashTable WMHashTable;
|
typedef struct W_HashTable WMHashTable;
|
||||||
typedef struct W_UserDefaults WMUserDefaults;
|
typedef struct W_UserDefaults WMUserDefaults;
|
||||||
typedef struct W_Notification WMNotification;
|
typedef struct W_Notification WMNotification;
|
||||||
typedef struct W_NotificationQueue WMNotificationQueue;
|
typedef struct W_NotificationQueue WMNotificationQueue;
|
||||||
typedef struct W_Host WMHost;
|
typedef struct W_Host WMHost;
|
||||||
typedef struct W_Connection WMConnection;
|
typedef struct W_Connection WMConnection;
|
||||||
|
typedef struct W_PropList WMPropList;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/* Some typedefs for the handler stuff */
|
||||||
|
typedef void *WMHandlerID;
|
||||||
|
|
||||||
|
typedef void WMCallback(void *data);
|
||||||
|
|
||||||
|
typedef void WMInputProc(int fd, int mask, void *clientData);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -138,7 +143,6 @@ typedef int WMMatchDataProc(void *item, void *cdata);
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
int position;
|
int position;
|
||||||
int count;
|
int count;
|
||||||
@@ -166,6 +170,7 @@ typedef struct {
|
|||||||
} WMHashTableCallbacks;
|
} WMHashTableCallbacks;
|
||||||
|
|
||||||
|
|
||||||
|
typedef int WMArrayIterator;
|
||||||
typedef void *WMBagIterator;
|
typedef void *WMBagIterator;
|
||||||
|
|
||||||
|
|
||||||
@@ -181,8 +186,9 @@ typedef struct {
|
|||||||
typedef struct ConnectionDelegate {
|
typedef struct ConnectionDelegate {
|
||||||
void *data;
|
void *data;
|
||||||
|
|
||||||
void (*didCatchException)(struct ConnectionDelegate *self,
|
void (*canResumeSending)(struct ConnectionDelegate *self, WMConnection *cPtr);
|
||||||
WMConnection *cPtr);
|
|
||||||
|
void (*didCatchException)(struct ConnectionDelegate *self, WMConnection *cPtr);
|
||||||
|
|
||||||
void (*didDie)(struct ConnectionDelegate *self, WMConnection *cPtr);
|
void (*didDie)(struct ConnectionDelegate *self, WMConnection *cPtr);
|
||||||
|
|
||||||
@@ -202,9 +208,9 @@ typedef void WMNotificationObserverAction(void *observerData,
|
|||||||
|
|
||||||
/*......................................................................*/
|
/*......................................................................*/
|
||||||
|
|
||||||
typedef void (waborthandler)(int);
|
typedef void waborthandler(int);
|
||||||
|
|
||||||
waborthandler* wsetabort(waborthandler*);
|
waborthandler* wsetabort(waborthandler* handler);
|
||||||
|
|
||||||
|
|
||||||
/* don't free the returned string */
|
/* don't free the returned string */
|
||||||
@@ -220,7 +226,7 @@ char* wfindfile(char *paths, char *file);
|
|||||||
|
|
||||||
char* wfindfileinlist(char **path_list, char *file);
|
char* wfindfileinlist(char **path_list, char *file);
|
||||||
|
|
||||||
char* wfindfileinarray(proplist_t array, char *file);
|
char* wfindfileinarray(WMPropList* array, char *file);
|
||||||
|
|
||||||
char* wexpandpath(char *path);
|
char* wexpandpath(char *path);
|
||||||
|
|
||||||
@@ -236,6 +242,7 @@ void wrelease(void *ptr);
|
|||||||
void* wretain(void *ptr);
|
void* wretain(void *ptr);
|
||||||
|
|
||||||
char* wstrdup(char *str);
|
char* wstrdup(char *str);
|
||||||
|
char* wstrndup(char *str, size_t len);
|
||||||
|
|
||||||
/* Concatenate str1 with str2 and return that in a newly malloc'ed string.
|
/* Concatenate str1 with str2 and return that in a newly malloc'ed string.
|
||||||
* str1 and str2 can be any strings including static and constant strings.
|
* str1 and str2 can be any strings including static and constant strings.
|
||||||
@@ -264,6 +271,11 @@ void wtokenfree(char **tokens, int count);
|
|||||||
char* wtrimspace(char *s);
|
char* wtrimspace(char *s);
|
||||||
|
|
||||||
|
|
||||||
|
WMRange wmkrange(int start, int count);
|
||||||
|
#ifdef ANSI_C_DOESNT_LIKE_IT_THIS_WAY
|
||||||
|
#define wmkrange(position, count) (WMRange){(position), (count)}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
char* wusergnusteppath();
|
char* wusergnusteppath();
|
||||||
|
|
||||||
@@ -278,7 +290,29 @@ int wsprintesc(char *buffer, int length, char *format, WMSEscapes **escapes,
|
|||||||
|
|
||||||
/*......................................................................*/
|
/*......................................................................*/
|
||||||
|
|
||||||
/* This function is used _only_ if you create a NON-GUI program.
|
/* Event handlers: timer, idle, input */
|
||||||
|
|
||||||
|
WMHandlerID WMAddTimerHandler(int milliseconds, WMCallback *callback,
|
||||||
|
void *cdata);
|
||||||
|
|
||||||
|
WMHandlerID WMAddPersistentTimerHandler(int milliseconds, WMCallback *callback,
|
||||||
|
void *cdata);
|
||||||
|
|
||||||
|
void WMDeleteTimerWithClientData(void *cdata);
|
||||||
|
|
||||||
|
void WMDeleteTimerHandler(WMHandlerID handlerID);
|
||||||
|
|
||||||
|
WMHandlerID WMAddIdleHandler(WMCallback *callback, void *cdata);
|
||||||
|
|
||||||
|
void WMDeleteIdleHandler(WMHandlerID handlerID);
|
||||||
|
|
||||||
|
WMHandlerID WMAddInputHandler(int fd, int condition, WMInputProc *proc,
|
||||||
|
void *clientData);
|
||||||
|
|
||||||
|
void WMDeleteInputHandler(WMHandlerID handlerID);
|
||||||
|
|
||||||
|
|
||||||
|
/* This function is used _only_ if you create a non-GUI program.
|
||||||
* For GUI based programs use WMNextEvent()/WMHandleEvent() instead.
|
* For GUI based programs use WMNextEvent()/WMHandleEvent() instead.
|
||||||
* This function will handle all input/timer/idle events, then return.
|
* This function will handle all input/timer/idle events, then return.
|
||||||
*/
|
*/
|
||||||
@@ -294,20 +328,41 @@ void WMFreeHashTable(WMHashTable *table);
|
|||||||
|
|
||||||
void WMResetHashTable(WMHashTable *table);
|
void WMResetHashTable(WMHashTable *table);
|
||||||
|
|
||||||
|
unsigned WMCountHashTable(WMHashTable *table);
|
||||||
|
|
||||||
void* WMHashGet(WMHashTable *table, const void *key);
|
void* WMHashGet(WMHashTable *table, const void *key);
|
||||||
|
|
||||||
|
/* Returns True if there is a value associated with <key> in the table, in
|
||||||
|
* which case <retKey> and <retItem> will contain the item's internal key
|
||||||
|
* address and the item's value respectively.
|
||||||
|
* If there is no value associated with <key> it will return False and in
|
||||||
|
* this case <retKey> and <retItem> will be undefined.
|
||||||
|
* Use this when you need to perform your own custom retain/release mechanism
|
||||||
|
* which requires access to the keys too.
|
||||||
|
*/
|
||||||
|
Bool WMHashGetItemAndKey(WMHashTable *table, const void *key,
|
||||||
|
void **retItem, void **retKey);
|
||||||
|
|
||||||
/* put data in table, replacing already existing data and returning
|
/* put data in table, replacing already existing data and returning
|
||||||
* the old value */
|
* the old value */
|
||||||
void* WMHashInsert(WMHashTable *table, const void *key, const void *data);
|
void* WMHashInsert(WMHashTable *table, const void *key, const void *data);
|
||||||
|
|
||||||
void WMHashRemove(WMHashTable *table, const void *key);
|
void WMHashRemove(WMHashTable *table, const void *key);
|
||||||
|
|
||||||
/* warning: do not manipulate the table while using these functions */
|
/* warning: do not manipulate the table while using the enumerator functions */
|
||||||
WMHashEnumerator WMEnumerateHashTable(WMHashTable *table);
|
WMHashEnumerator WMEnumerateHashTable(WMHashTable *table);
|
||||||
|
|
||||||
void* WMNextHashEnumeratorItem(WMHashEnumerator *enumerator);
|
void* WMNextHashEnumeratorItem(WMHashEnumerator *enumerator);
|
||||||
|
|
||||||
unsigned WMCountHashTable(WMHashTable *table);
|
void* WMNextHashEnumeratorKey(WMHashEnumerator *enumerator);
|
||||||
|
|
||||||
|
/* Returns True if there is a next element, in which case key and item
|
||||||
|
* will contain the next element's key and value respectively.
|
||||||
|
* If there is no next element available it will return False and in this
|
||||||
|
* case key and item will be undefined.
|
||||||
|
*/
|
||||||
|
Bool WMNextHashEnumeratorItemAndKey(WMHashEnumerator *enumerator,
|
||||||
|
void **item, void **key);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -322,7 +377,7 @@ extern const WMHashTableCallbacks WMStringHashCallbacks;
|
|||||||
* and freed with wfree() */
|
* and freed with wfree() */
|
||||||
|
|
||||||
extern const WMHashTableCallbacks WMStringPointerHashCallbacks;
|
extern const WMHashTableCallbacks WMStringPointerHashCallbacks;
|
||||||
/* keys are strings, bug they are not copied */
|
/* keys are strings, but they are not copied */
|
||||||
|
|
||||||
|
|
||||||
/*......................................................................*/
|
/*......................................................................*/
|
||||||
@@ -379,7 +434,9 @@ void* WMReplaceInArray(WMArray *array, int index, void *item);
|
|||||||
*/
|
*/
|
||||||
int WMDeleteFromArray(WMArray *array, int index);
|
int WMDeleteFromArray(WMArray *array, int index);
|
||||||
|
|
||||||
int WMRemoveFromArray(WMArray *array, void *item);
|
#define WMRemoveFromArray(array, item) WMRemoveFromArrayMatching(array, NULL, item)
|
||||||
|
|
||||||
|
int WMRemoveFromArrayMatching(WMArray *array, WMMatchDataProc *match, void *cdata);
|
||||||
|
|
||||||
void* WMGetFromArray(WMArray *array, int index);
|
void* WMGetFromArray(WMArray *array, int index);
|
||||||
|
|
||||||
@@ -406,6 +463,24 @@ void WMMapArray(WMArray *array, void (*function)(void*, void*), void *data);
|
|||||||
|
|
||||||
WMArray* WMGetSubarrayWithRange(WMArray* array, WMRange aRange);
|
WMArray* WMGetSubarrayWithRange(WMArray* array, WMRange aRange);
|
||||||
|
|
||||||
|
void* WMArrayFirst(WMArray *array, WMArrayIterator *iter);
|
||||||
|
|
||||||
|
void* WMArrayLast(WMArray *array, WMArrayIterator *iter);
|
||||||
|
|
||||||
|
/* The following 2 functions assume that the array doesn't change between calls */
|
||||||
|
void* WMArrayNext(WMArray *array, WMArrayIterator *iter);
|
||||||
|
|
||||||
|
void* WMArrayPrevious(WMArray *array, WMArrayIterator *iter);
|
||||||
|
|
||||||
|
|
||||||
|
/* The following 2 macros assume that the array doesn't change in the for loop */
|
||||||
|
#define WM_ITERATE_ARRAY(array, var, i) \
|
||||||
|
for (var = WMArrayFirst(array, &(i)); (i) != WANotFound; \
|
||||||
|
var = WMArrayNext(array, &(i)))
|
||||||
|
|
||||||
|
#define WM_ETARETI_ARRAY(array, var, i) \
|
||||||
|
for (var = WMArrayLast(array, &(i)); (i) != WANotFound; \
|
||||||
|
var = WMArrayPrevious(array, &(i)))
|
||||||
|
|
||||||
/*..........................................................................*/
|
/*..........................................................................*/
|
||||||
|
|
||||||
@@ -439,7 +514,6 @@ void WMPutInBag(WMBag *bag, void *item);
|
|||||||
/* insert will increment the index of elements after it by 1 */
|
/* insert will increment the index of elements after it by 1 */
|
||||||
void WMInsertInBag(WMBag *bag, int index, void *item);
|
void WMInsertInBag(WMBag *bag, int index, void *item);
|
||||||
|
|
||||||
/* this is slow */
|
|
||||||
/* erase will remove the element from the bag,
|
/* erase will remove the element from the bag,
|
||||||
* but will keep the index of the other elements unchanged */
|
* but will keep the index of the other elements unchanged */
|
||||||
int WMEraseFromBag(WMBag *bag, int index);
|
int WMEraseFromBag(WMBag *bag, int index);
|
||||||
@@ -479,6 +553,7 @@ void* WMBagFirst(WMBag *bag, WMBagIterator *ptr);
|
|||||||
|
|
||||||
void* WMBagLast(WMBag *bag, WMBagIterator *ptr);
|
void* WMBagLast(WMBag *bag, WMBagIterator *ptr);
|
||||||
|
|
||||||
|
/* The following 4 functions assume that the bag doesn't change between calls */
|
||||||
void* WMBagNext(WMBag *bag, WMBagIterator *ptr);
|
void* WMBagNext(WMBag *bag, WMBagIterator *ptr);
|
||||||
|
|
||||||
void* WMBagPrevious(WMBag *bag, WMBagIterator *ptr);
|
void* WMBagPrevious(WMBag *bag, WMBagIterator *ptr);
|
||||||
@@ -488,6 +563,7 @@ void* WMBagIteratorAtIndex(WMBag *bag, int index, WMBagIterator *ptr);
|
|||||||
int WMBagIndexForIterator(WMBag *bag, WMBagIterator ptr);
|
int WMBagIndexForIterator(WMBag *bag, WMBagIterator ptr);
|
||||||
|
|
||||||
|
|
||||||
|
/* The following 2 macros assume that the bag doesn't change in the for loop */
|
||||||
#define WM_ITERATE_BAG(bag, var, i) \
|
#define WM_ITERATE_BAG(bag, var, i) \
|
||||||
for (var = WMBagFirst(bag, &(i)); (i) != NULL; \
|
for (var = WMBagFirst(bag, &(i)); (i) != NULL; \
|
||||||
var = WMBagNext(bag, &(i)))
|
var = WMBagNext(bag, &(i)))
|
||||||
@@ -568,6 +644,49 @@ unsigned WMGetDataFormat(WMData *aData);
|
|||||||
/* Storing data */
|
/* Storing data */
|
||||||
|
|
||||||
|
|
||||||
|
/*--------------------------------------------------------------------------*/
|
||||||
|
|
||||||
|
/* Generic Tree and TreeNode */
|
||||||
|
|
||||||
|
WMTreeNode* WMCreateTreeNode(void *data);
|
||||||
|
|
||||||
|
WMTreeNode* WMCreateTreeNodeWithDestructor(void *data, WMFreeDataProc *destructor);
|
||||||
|
|
||||||
|
WMTreeNode* WMInsertItemInTree(WMTreeNode *parent, int index, void *item);
|
||||||
|
|
||||||
|
#define WMAddItemToTree(parent, item) WMInsertItemInTree(parent, -1, item)
|
||||||
|
|
||||||
|
WMTreeNode* WMInsertNodeInTree(WMTreeNode *parent, int index, WMTreeNode *aNode);
|
||||||
|
|
||||||
|
#define WMAddNodeToTree(parent, aNode) WMInsertNodeInTree(parent, -1, aNode)
|
||||||
|
|
||||||
|
void WMDestroyTreeNode(WMTreeNode *aNode);
|
||||||
|
|
||||||
|
void WMDeleteLeafForTreeNode(WMTreeNode *aNode, int index);
|
||||||
|
|
||||||
|
void WMRemoveLeafForTreeNode(WMTreeNode *aNode, void *leaf);
|
||||||
|
|
||||||
|
void* WMReplaceDataForTreeNode(WMTreeNode *aNode, void *newData);
|
||||||
|
|
||||||
|
void* WMGetDataForTreeNode(WMTreeNode *aNode);
|
||||||
|
|
||||||
|
int WMGetTreeNodeDepth(WMTreeNode *aNode);
|
||||||
|
|
||||||
|
WMTreeNode* WMGetParentForTreeNode(WMTreeNode *aNode);
|
||||||
|
|
||||||
|
/* Sort only the leaves of the passed node */
|
||||||
|
void WMSortLeavesForTreeNode(WMTreeNode *aNode, WMCompareDataProc *comparer);
|
||||||
|
|
||||||
|
/* Sort all tree recursively starting from the passed node */
|
||||||
|
void WMSortTree(WMTreeNode *aNode, WMCompareDataProc *comparer);
|
||||||
|
|
||||||
|
/* Returns the first node which matches node's data with cdata by 'match' */
|
||||||
|
WMTreeNode* WMFindInTree(WMTreeNode *aTree, WMMatchDataProc *match, void *cdata);
|
||||||
|
|
||||||
|
/* Returns first tree node that has data == cdata */
|
||||||
|
#define WMGetFirstInTree(aTree, cdata) WMFindInTree(aTree, NULL, cdata)
|
||||||
|
|
||||||
|
|
||||||
/*--------------------------------------------------------------------------*/
|
/*--------------------------------------------------------------------------*/
|
||||||
|
|
||||||
|
|
||||||
@@ -614,6 +733,108 @@ void WMEnqueueCoalesceNotification(WMNotificationQueue *queue,
|
|||||||
unsigned coalesceMask);
|
unsigned coalesceMask);
|
||||||
|
|
||||||
|
|
||||||
|
/*......................................................................*/
|
||||||
|
|
||||||
|
/* Property Lists handling */
|
||||||
|
|
||||||
|
void WMPLSetCaseSensitive(Bool caseSensitive);
|
||||||
|
|
||||||
|
WMPropList* WMCreatePLString(char *str);
|
||||||
|
|
||||||
|
WMPropList* WMCreatePLData(WMData *data);
|
||||||
|
|
||||||
|
WMPropList* WMCreatePLDataWithBytes(unsigned char *bytes, unsigned int length);
|
||||||
|
|
||||||
|
WMPropList* WMCreatePLDataWithBytesNoCopy(unsigned char *bytes,
|
||||||
|
unsigned int length,
|
||||||
|
WMFreeDataProc *destructor);
|
||||||
|
|
||||||
|
WMPropList* WMCreatePLArray(WMPropList *elem, ...);
|
||||||
|
|
||||||
|
WMPropList* WMCreatePLDictionary(WMPropList *key, WMPropList *value, ...);
|
||||||
|
|
||||||
|
WMPropList* WMRetainPropList(WMPropList *plist);
|
||||||
|
|
||||||
|
void WMReleasePropList(WMPropList *plist);
|
||||||
|
|
||||||
|
/* Objects inserted in arrays and dictionaries will be retained,
|
||||||
|
* so you can safely release them after insertion.
|
||||||
|
* For dictionaries both the key and value are retained.
|
||||||
|
* Objects removed from arrays or dictionaries are released */
|
||||||
|
void WMInsertInPLArray(WMPropList *plist, int index, WMPropList *item);
|
||||||
|
|
||||||
|
void WMAddToPLArray(WMPropList *plist, WMPropList *item);
|
||||||
|
|
||||||
|
void WMDeleteFromPLArray(WMPropList *plist, int index);
|
||||||
|
|
||||||
|
void WMRemoveFromPLArray(WMPropList *plist, WMPropList *item);
|
||||||
|
|
||||||
|
void WMPutInPLDictionary(WMPropList *plist, WMPropList *key, WMPropList *value);
|
||||||
|
|
||||||
|
void WMRemoveFromPLDictionary(WMPropList *plist, WMPropList *key);
|
||||||
|
|
||||||
|
/* It will insert all key/value pairs from source into dest, overwriting
|
||||||
|
* the values with the same keys from dest, keeping all values with keys
|
||||||
|
* only present in dest unchanged */
|
||||||
|
WMPropList* WMMergePLDictionaries(WMPropList *dest, WMPropList *source,
|
||||||
|
Bool recursive);
|
||||||
|
|
||||||
|
/* It will remove all key/value pairs from dest for which there is an
|
||||||
|
* identical key/value present in source. Entires only present in dest, or
|
||||||
|
* which have different values in dest than in source will be preserved. */
|
||||||
|
WMPropList* WMSubtractPLDictionaries(WMPropList *dest, WMPropList *source,
|
||||||
|
Bool recursive);
|
||||||
|
|
||||||
|
int WMGetPropListItemCount(WMPropList *plist);
|
||||||
|
|
||||||
|
Bool WMIsPLString(WMPropList *plist);
|
||||||
|
|
||||||
|
Bool WMIsPLData(WMPropList *plist);
|
||||||
|
|
||||||
|
Bool WMIsPLArray(WMPropList *plist);
|
||||||
|
|
||||||
|
Bool WMIsPLDictionary(WMPropList *plist);
|
||||||
|
|
||||||
|
Bool WMIsPropListEqualTo(WMPropList *plist, WMPropList *other);
|
||||||
|
|
||||||
|
/* Returns a reference. Do not free it! */
|
||||||
|
char* WMGetFromPLString(WMPropList *plist);
|
||||||
|
|
||||||
|
/* Returns a reference. Do not free it! */
|
||||||
|
WMData* WMGetFromPLData(WMPropList *plist);
|
||||||
|
|
||||||
|
/* Returns a reference. Do not free it! */
|
||||||
|
const unsigned char* WMGetPLDataBytes(WMPropList *plist);
|
||||||
|
|
||||||
|
int WMGetPLDataLength(WMPropList *plist);
|
||||||
|
|
||||||
|
/* Returns a reference. */
|
||||||
|
WMPropList* WMGetFromPLArray(WMPropList *plist, int index);
|
||||||
|
|
||||||
|
/* Returns a reference. */
|
||||||
|
WMPropList* WMGetFromPLDictionary(WMPropList *plist, WMPropList *key);
|
||||||
|
|
||||||
|
/* Returns a PropList array with all the dictionary keys. Release it when
|
||||||
|
* you're done. Keys in array are retained from the original dictionary
|
||||||
|
* not copied and need NOT to be released individually. */
|
||||||
|
WMPropList* WMGetPLDictionaryKeys(WMPropList *plist);
|
||||||
|
|
||||||
|
/* Creates only the first level deep object. All the elements inside are
|
||||||
|
* retained from the original */
|
||||||
|
WMPropList* WMShallowCopyPropList(WMPropList *plist);
|
||||||
|
|
||||||
|
/* Makes a completely separate replica of the original proplist */
|
||||||
|
WMPropList* WMDeepCopyPropList(WMPropList *plist);
|
||||||
|
|
||||||
|
WMPropList* WMCreatePropListFromDescription(char *desc);
|
||||||
|
|
||||||
|
/* Free the returned string when you no longer need it */
|
||||||
|
char* WMGetPropListDescription(WMPropList *plist, Bool indented);
|
||||||
|
|
||||||
|
WMPropList* WMReadPropListFromFile(char *file);
|
||||||
|
|
||||||
|
Bool WMWritePropListToFile(WMPropList *plist, char *path, Bool atomically);
|
||||||
|
|
||||||
/*......................................................................*/
|
/*......................................................................*/
|
||||||
|
|
||||||
WMUserDefaults* WMGetStandardUserDefaults(void);
|
WMUserDefaults* WMGetStandardUserDefaults(void);
|
||||||
@@ -626,14 +847,14 @@ void WMSaveUserDefaults(WMUserDefaults *database);
|
|||||||
|
|
||||||
void WMEnableUDPeriodicSynchronization(WMUserDefaults *database, Bool enable);
|
void WMEnableUDPeriodicSynchronization(WMUserDefaults *database, Bool enable);
|
||||||
|
|
||||||
/* Returns a PLArray with all keys in the user defaults database.
|
/* Returns a WMPropList array with all the keys in the user defaults database.
|
||||||
* Free the returned array with PLRelease() when no longer needed,
|
* Free the array with WMReleasePropList() when no longer needed.
|
||||||
* but do not free the elements of the array! They're just references. */
|
* Keys in array are just retained references to the original keys */
|
||||||
proplist_t WMGetUDAllKeys(WMUserDefaults *database);
|
WMPropList* WMGetUDKeys(WMUserDefaults *database);
|
||||||
|
|
||||||
proplist_t WMGetUDObjectForKey(WMUserDefaults *database, char *defaultName);
|
WMPropList* WMGetUDObjectForKey(WMUserDefaults *database, char *defaultName);
|
||||||
|
|
||||||
void WMSetUDObjectForKey(WMUserDefaults *database, proplist_t object,
|
void WMSetUDObjectForKey(WMUserDefaults *database, WMPropList *object,
|
||||||
char *defaultName);
|
char *defaultName);
|
||||||
|
|
||||||
void WMRemoveUDObjectForKey(WMUserDefaults *database, char *defaultName);
|
void WMRemoveUDObjectForKey(WMUserDefaults *database, char *defaultName);
|
||||||
@@ -658,9 +879,9 @@ void WMSetUDFloatForKey(WMUserDefaults *database, float value,
|
|||||||
void WMSetUDBoolForKey(WMUserDefaults *database, Bool value,
|
void WMSetUDBoolForKey(WMUserDefaults *database, Bool value,
|
||||||
char *defaultName);
|
char *defaultName);
|
||||||
|
|
||||||
proplist_t WMGetUDSearchList(WMUserDefaults *database);
|
WMPropList* WMGetUDSearchList(WMUserDefaults *database);
|
||||||
|
|
||||||
void WMSetUDSearchList(WMUserDefaults *database, proplist_t list);
|
void WMSetUDSearchList(WMUserDefaults *database, WMPropList *list);
|
||||||
|
|
||||||
extern char *WMUserDefaultsDidChangeNotification;
|
extern char *WMUserDefaultsDidChangeNotification;
|
||||||
|
|
||||||
@@ -760,6 +981,8 @@ Bool WMSetConnectionNonBlocking(WMConnection *cPtr, Bool flag);
|
|||||||
|
|
||||||
Bool WMSetConnectionCloseOnExec(WMConnection *cPtr, Bool flag);
|
Bool WMSetConnectionCloseOnExec(WMConnection *cPtr, Bool flag);
|
||||||
|
|
||||||
|
void WMSetConnectionShutdownOnClose(WMConnection *cPtr, Bool flag);
|
||||||
|
|
||||||
void* WMGetConnectionClientData(WMConnection *cPtr);
|
void* WMGetConnectionClientData(WMConnection *cPtr);
|
||||||
|
|
||||||
void WMSetConnectionClientData(WMConnection *cPtr, void *data);
|
void WMSetConnectionClientData(WMConnection *cPtr, void *data);
|
||||||
138
WINGs/WINGs/proplist-compat.h
Normal file
138
WINGs/WINGs/proplist-compat.h
Normal file
@@ -0,0 +1,138 @@
|
|||||||
|
/*
|
||||||
|
* This header file is provided for old libPropList compatibility.
|
||||||
|
* DO _NOT_ USE this except for letting your old libPropList-based code to
|
||||||
|
* work with the new property list code from WINGs, with minimal changes.
|
||||||
|
*
|
||||||
|
* All code written with old libPropList functions should work, given
|
||||||
|
* that the following changes are made:
|
||||||
|
*
|
||||||
|
* 1. Replace all
|
||||||
|
* #include <proplist.h>
|
||||||
|
* with
|
||||||
|
* #include <WINGs/proplist-compat.h>
|
||||||
|
* in your code.
|
||||||
|
*
|
||||||
|
* 2. Change all calls to PLSave() to have the extra filename parameter like:
|
||||||
|
* PLSave(proplist_t proplist, char* filename, Bool atomically)
|
||||||
|
*
|
||||||
|
* 3. The PLSetStringCmpHook() function is no longer available. There is a
|
||||||
|
* similar but simpler function provided which is enough for practical
|
||||||
|
* purposes:
|
||||||
|
* PLSetCaseSensitive(Bool caseSensitive)
|
||||||
|
*
|
||||||
|
* 4. The following functions do no longer exist. They were removed because
|
||||||
|
* they were based on concepts borrowed from UserDefaults which conflict
|
||||||
|
* with the retain/release mechanism:
|
||||||
|
* PLSynchronize(), PLDeepSynchronize(), PLShallowSynchronize()
|
||||||
|
* PLSetFilename(), PLGetFilename()
|
||||||
|
* PLGetContainer()
|
||||||
|
* You should change your code to not use them anymore.
|
||||||
|
*
|
||||||
|
* 5. The following functions are no longer available. They were removed
|
||||||
|
* because they also used borrowed concepts which have no place in a
|
||||||
|
* property list as defined in the OpenStep specifications. Also these
|
||||||
|
* functions were hardly ever used in programs to our knowledge.
|
||||||
|
* PLGetDomainNames(), PLGetDomain(), PLSetDomain(), PLDeleteDomain()
|
||||||
|
* PLRegister(), PLUnregister()
|
||||||
|
* You should also change your code to not use them anymore (in case you
|
||||||
|
* ever used them anyway ;-) ).
|
||||||
|
*
|
||||||
|
* 6. Link your program with libWINGs or libWUtil instead of libPropList.
|
||||||
|
* (libWINGs should be used for GUI apps, while libWUtil for non-GUI apps)
|
||||||
|
*
|
||||||
|
*
|
||||||
|
* Our recommandation is to rewrite your code to use the new functions and
|
||||||
|
* link against libWINGs/libWUtil. We do not recommend you to keep using old
|
||||||
|
* libPropList function names. This file is provided just to allow existing
|
||||||
|
* libropList based applications to run with minimal changes with the new
|
||||||
|
* proplist code from WINGs before their authors get the time to rewrite
|
||||||
|
* them. New proplist code from WINGs provide a better integration with the
|
||||||
|
* other data types from WINGs, not to mention that the proplist code in WINGs
|
||||||
|
* is actively maintained while the old libPropList is dead.
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
#ifndef _PROPLIST_COMPAT_H_
|
||||||
|
#define _PROPLIST_COMPAT_H_
|
||||||
|
|
||||||
|
#include <WINGs/WUtil.h>
|
||||||
|
|
||||||
|
|
||||||
|
typedef WMPropList* proplist_t;
|
||||||
|
|
||||||
|
|
||||||
|
#ifndef YES
|
||||||
|
#define YES True
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef NO
|
||||||
|
#define NO False
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
#define PLSetCaseSensitive(c) WMPLSetCaseSensitive(c)
|
||||||
|
|
||||||
|
#define PLMakeString(bytes) WMCreatePLString(bytes)
|
||||||
|
#define PLMakeData(bytes, length) WMCreatePLDataWithBytes(bytes, length)
|
||||||
|
#define PLMakeArrayFromElements WMCreatePLArray
|
||||||
|
#define PLMakeDictionaryFromEntries WMCreatePLDictionary
|
||||||
|
|
||||||
|
#define PLRetain(pl) WMRetainPropList(pl)
|
||||||
|
#define PLRelease(pl) WMReleasePropList(pl)
|
||||||
|
|
||||||
|
#define PLInsertArrayElement(array, pl, pos) WMInsertInPLArray(array, pos, pl)
|
||||||
|
#define PLAppendArrayElement(array, pl) WMAddToPLArray(array, pl)
|
||||||
|
#define PLRemoveArrayElement(array, pos) WMDeleteFromPLArray(array, pos)
|
||||||
|
#define PLInsertDictionaryEntry(dict, key, value) WMPutInPLDictionary(dict, key, value)
|
||||||
|
#define PLRemoveDictionaryEntry(dict, key) WMRemoveFromPLDictionary(dict, key)
|
||||||
|
#define PLMergeDictionaries(dest, source) WMMergePLDictionaries(dest, source, False)
|
||||||
|
|
||||||
|
#define PLGetNumberOfElements(pl) WMGetPropListItemCount(pl)
|
||||||
|
|
||||||
|
#define PLIsString(pl) WMIsPLString(pl)
|
||||||
|
#define PLIsData(pl) WMIsPLData(pl)
|
||||||
|
#define PLIsArray(pl) WMIsPLArray(pl)
|
||||||
|
#define PLIsDictionary(pl) WMIsPLDictionary(pl)
|
||||||
|
#define PLIsSimple(pl) (WMIsPLString(pl) || WMIsPLData(pl))
|
||||||
|
#define PLIsCompound(pl) (WMIsPLArray(pl) || WMIsPLDictionary(pl))
|
||||||
|
#define PLIsEqual(pl1, pl2) WMIsPropListEqualTo(pl1, pl2)
|
||||||
|
|
||||||
|
#define PLGetString(pl) WMGetFromPLString(pl)
|
||||||
|
#define PLGetDataBytes(pl) WMGetPLDataBytes(pl)
|
||||||
|
#define PLGetDataLength(pl) WMGetPLDataLength(pl)
|
||||||
|
#define PLGetArrayElement(pl, index) WMGetFromPLArray(pl, index)
|
||||||
|
#define PLGetDictionaryEntry(pl, key) WMGetFromPLDictionary(pl, key)
|
||||||
|
#define PLGetAllDictionaryKeys(pl) WMGetPLDictionaryKeys(pl)
|
||||||
|
|
||||||
|
#define PLShallowCopy(pl) WMShallowCopyPropList(pl)
|
||||||
|
#define PLDeepCopy(pl) WMDeepCopyPropList(pl)
|
||||||
|
|
||||||
|
#define PLGetProplistWithDescription(desc) WMCreatePropListFromDescription(desc)
|
||||||
|
#define PLGetDescriptionIndent(pl, level) WMGetPropListDescription(pl, True)
|
||||||
|
#define PLGetDescription(pl) WMGetPropListDescription(pl, False)
|
||||||
|
#define PLGetStringDescription(pl) WMGetPropListDescription(pl, False)
|
||||||
|
#define PLGetDataDescription(pl) WMGetPropListDescription(pl, False)
|
||||||
|
|
||||||
|
#define PLGetProplistWithPath(file) WMReadPropListFromFile(file)
|
||||||
|
#define PLSave(pl, file, atm) WMWritePropListToFile(pl, file, atm)
|
||||||
|
|
||||||
|
|
||||||
|
/* Unsupported functions. Do not ask for them. They're evil :P */
|
||||||
|
#define PLSetStringCmpHook(fn) error_PLSetStringCmpHook_is_not_supported
|
||||||
|
#define PLDeepSynchronize(pl) error_PLDeepSynchronize_is_not_supported
|
||||||
|
#define PLSynchronize(pl) error_PLSynchronize_is_not_supported
|
||||||
|
#define PLShallowSynchronize(pl) error_PLShallowSynchronize_is_not_supported
|
||||||
|
#define PLSetFilename(pl, filename) error_PLSetFilename_is_not_supported
|
||||||
|
#define PLGetFilename(pl, filename) error_PLGetFilename_is_not_supported
|
||||||
|
#define PLGetContainer(pl) error_PLGetContainer_is_not_supported
|
||||||
|
|
||||||
|
#define PLGetDomainNames error_PLGetDomainNames_is_not_supported
|
||||||
|
#define PLGetDomain(name) error_PLGetDomain_is_not_supported
|
||||||
|
#define PLSetDomain(name, value, kickme) error_PLSetDomain_is_not_supported
|
||||||
|
#define PLDeleteDomain(name, kickme) error_PLDeleteDomain_is_not_supported
|
||||||
|
#define PLRegister(name, callback) error_PLRegister_is_not_supported
|
||||||
|
#define PLUnregister(name) error_PLUnregister_is_not_supported
|
||||||
|
|
||||||
|
|
||||||
|
#endif
|
||||||
@@ -193,16 +193,25 @@ WMDeleteFromArray(WMArray *array, int index)
|
|||||||
|
|
||||||
|
|
||||||
int
|
int
|
||||||
WMRemoveFromArray(WMArray *array, void *item)
|
WMRemoveFromArrayMatching(WMArray *array, WMMatchDataProc *match, void *cdata)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
|
if (match != NULL) {
|
||||||
for (i = 0; i < array->itemCount; i++) {
|
for (i = 0; i < array->itemCount; i++) {
|
||||||
if (array->items[i] == item) {
|
if ((*match)(array->items[i], cdata)) {
|
||||||
WMDeleteFromArray(array, i);
|
WMDeleteFromArray(array, i);
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
for (i = 0; i < array->itemCount; i++) {
|
||||||
|
if (array->items[i] == cdata) {
|
||||||
|
WMDeleteFromArray(array, i);
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
@@ -265,8 +274,10 @@ WMCountInArray(WMArray *array, void *item)
|
|||||||
void
|
void
|
||||||
WMSortArray(WMArray *array, WMCompareDataProc *comparer)
|
WMSortArray(WMArray *array, WMCompareDataProc *comparer)
|
||||||
{
|
{
|
||||||
|
if (array->itemCount > 1) { /* Don't sort empty or single element arrays */
|
||||||
qsort(array->items, array->itemCount, sizeof(void*), comparer);
|
qsort(array->items, array->itemCount, sizeof(void*), comparer);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
@@ -304,3 +315,54 @@ WMGetSubarrayWithRange(WMArray* array, WMRange aRange)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void*
|
||||||
|
WMArrayFirst(WMArray *array, WMArrayIterator *iter)
|
||||||
|
{
|
||||||
|
if (array->itemCount == 0) {
|
||||||
|
*iter = WANotFound;
|
||||||
|
return NULL;
|
||||||
|
} else {
|
||||||
|
*iter = 0;
|
||||||
|
return array->items[0];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void*
|
||||||
|
WMArrayLast(WMArray *array, WMArrayIterator *iter)
|
||||||
|
{
|
||||||
|
if (array->itemCount == 0) {
|
||||||
|
*iter = WANotFound;
|
||||||
|
return NULL;
|
||||||
|
} else {
|
||||||
|
*iter = array->itemCount-1;
|
||||||
|
return array->items[*iter];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void*
|
||||||
|
WMArrayNext(WMArray *array, WMArrayIterator *iter)
|
||||||
|
{
|
||||||
|
if (*iter >= 0 && *iter < array->itemCount-1) {
|
||||||
|
return array->items[++(*iter)];
|
||||||
|
} else {
|
||||||
|
*iter = WANotFound;
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void*
|
||||||
|
WMArrayPrevious(WMArray *array, WMArrayIterator *iter)
|
||||||
|
{
|
||||||
|
if (*iter > 0 && *iter < array->itemCount) {
|
||||||
|
return array->items[--(*iter)];
|
||||||
|
} else {
|
||||||
|
*iter = WANotFound;
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,19 +1,18 @@
|
|||||||
|
|
||||||
|
|
||||||
#include "WINGsP.h"
|
#include "WINGsP.h"
|
||||||
|
#include "wconfig.h"
|
||||||
|
|
||||||
#include <X11/Xlocale.h>
|
#include <X11/Xlocale.h>
|
||||||
|
|
||||||
#include <proplist.h>
|
|
||||||
|
|
||||||
|
|
||||||
_WINGsConfiguration WINGsConfiguration;
|
_WINGsConfiguration WINGsConfiguration;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#define SYSTEM_FONT "-*-helvetica-medium-r-normal-*-%d-*-*-*-*-*-*-*,-*-*-medium-r-*-*-%d-*-*-*-*-*-*-*"
|
#define SYSTEM_FONT "Trebuchet MS,Luxi Sans"
|
||||||
|
#define BOLD_SYSTEM_FONT "Trebuchet MS,Luxi Sans:bold"
|
||||||
#define BOLD_SYSTEM_FONT "-*-helvetica-bold-r-normal-*-%d-*-*-*-*-*-*-*,-*-*-bold-r-*-*-%d-*-*-*-*-*-*-*"
|
#define DEFAULT_FONT_SIZE 12
|
||||||
|
|
||||||
#define FLOPPY_PATH "/floppy"
|
#define FLOPPY_PATH "/floppy"
|
||||||
|
|
||||||
@@ -62,26 +61,8 @@ W_ReadConfigurations(void)
|
|||||||
WINGsConfiguration.boldSystemFont =
|
WINGsConfiguration.boldSystemFont =
|
||||||
WMGetUDStringForKey(defaults, "BoldSystemFont");
|
WMGetUDStringForKey(defaults, "BoldSystemFont");
|
||||||
|
|
||||||
WINGsConfiguration.useMultiByte = False;
|
WINGsConfiguration.antialiasedText =
|
||||||
str = WMGetUDStringForKey(defaults, "MultiByteText");
|
WMGetUDBoolForKey(defaults, "AntialiasedText");
|
||||||
if (str) {
|
|
||||||
if (strcasecmp(str, "YES") == 0) {
|
|
||||||
WINGsConfiguration.useMultiByte = True;
|
|
||||||
} else if (strcasecmp(str, "AUTO") == 0) {
|
|
||||||
char *locale;
|
|
||||||
|
|
||||||
/* if it's a multibyte language (japanese, chinese or korean)
|
|
||||||
* then set it to True */
|
|
||||||
locale = setlocale(LC_CTYPE, NULL);
|
|
||||||
if (locale != NULL
|
|
||||||
&& (strncmp(locale, "ja", 2) == 0
|
|
||||||
|| strncmp(locale, "zh", 2) == 0
|
|
||||||
|| strncmp(locale, "ko", 2) == 0)) {
|
|
||||||
|
|
||||||
WINGsConfiguration.useMultiByte = True;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
WINGsConfiguration.doubleClickDelay =
|
WINGsConfiguration.doubleClickDelay =
|
||||||
WMGetUDIntegerForKey(defaults, "DoubleClickTime");
|
WMGetUDIntegerForKey(defaults, "DoubleClickTime");
|
||||||
@@ -116,13 +97,15 @@ W_ReadConfigurations(void)
|
|||||||
WMGetUDIntegerForKey(defaults, "DefaultFontSize");
|
WMGetUDIntegerForKey(defaults, "DefaultFontSize");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
if (!WINGsConfiguration.systemFont) {
|
if (!WINGsConfiguration.systemFont) {
|
||||||
WINGsConfiguration.systemFont = SYSTEM_FONT;
|
WINGsConfiguration.systemFont = SYSTEM_FONT;
|
||||||
}
|
}
|
||||||
if (!WINGsConfiguration.boldSystemFont) {
|
if (!WINGsConfiguration.boldSystemFont) {
|
||||||
WINGsConfiguration.boldSystemFont = BOLD_SYSTEM_FONT;
|
WINGsConfiguration.boldSystemFont = BOLD_SYSTEM_FONT;
|
||||||
}
|
}
|
||||||
|
if (WINGsConfiguration.defaultFontSize == 0) {
|
||||||
|
WINGsConfiguration.defaultFontSize = DEFAULT_FONT_SIZE;
|
||||||
|
}
|
||||||
if (!WINGsConfiguration.floppyPath) {
|
if (!WINGsConfiguration.floppyPath) {
|
||||||
WINGsConfiguration.floppyPath = FLOPPY_PATH;
|
WINGsConfiguration.floppyPath = FLOPPY_PATH;
|
||||||
}
|
}
|
||||||
@@ -135,9 +118,6 @@ W_ReadConfigurations(void)
|
|||||||
if (WINGsConfiguration.mouseWheelDown == 0) {
|
if (WINGsConfiguration.mouseWheelDown == 0) {
|
||||||
WINGsConfiguration.mouseWheelDown = Button5;
|
WINGsConfiguration.mouseWheelDown = Button5;
|
||||||
}
|
}
|
||||||
if (WINGsConfiguration.defaultFontSize == 0) {
|
|
||||||
WINGsConfiguration.defaultFontSize = 12;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
/*
|
/*
|
||||||
* WINGs WMConnection function library
|
* WINGs WMConnection function library
|
||||||
*
|
*
|
||||||
* Copyright (c) 1999-2000 Dan Pascu
|
* Copyright (c) 1999-2003 Dan Pascu
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* 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
|
* it under the terms of the GNU General Public License as published by
|
||||||
@@ -23,13 +23,12 @@
|
|||||||
* TODO:
|
* TODO:
|
||||||
* - decide if we want to support connections with external sockets, else
|
* - decide if we want to support connections with external sockets, else
|
||||||
* clean up the structure of the unneeded members.
|
* clean up the structure of the unneeded members.
|
||||||
* - decide what to do with all wsyserror() and wwarning() calls that are
|
* - decide what to do with all wwarning() calls that are still there.
|
||||||
* still there.
|
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#include "../src/config.h"
|
#include "wconfig.h"
|
||||||
|
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <fcntl.h>
|
#include <fcntl.h>
|
||||||
@@ -66,11 +65,13 @@
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* Stuff for setting the sockets into non-blocking mode. */
|
/* Stuff for setting the sockets into non-blocking mode. */
|
||||||
/*#ifdef __POSIX_SOURCE
|
/*
|
||||||
|
#ifdef __POSIX_SOURCE
|
||||||
# define NONBLOCK_OPT O_NONBLOCK
|
# define NONBLOCK_OPT O_NONBLOCK
|
||||||
#else
|
#else
|
||||||
# define NONBLOCK_OPT FNDELAY
|
# define NONBLOCK_OPT FNDELAY
|
||||||
#endif*/
|
#endif
|
||||||
|
*/
|
||||||
|
|
||||||
#define NONBLOCK_OPT O_NONBLOCK
|
#define NONBLOCK_OPT O_NONBLOCK
|
||||||
|
|
||||||
@@ -122,6 +123,7 @@ typedef struct W_Connection {
|
|||||||
char *protocol;
|
char *protocol;
|
||||||
|
|
||||||
Bool closeOnRelease;
|
Bool closeOnRelease;
|
||||||
|
Bool shutdownOnClose;
|
||||||
Bool wasNonBlocking;
|
Bool wasNonBlocking;
|
||||||
Bool isNonBlocking;
|
Bool isNonBlocking;
|
||||||
|
|
||||||
@@ -130,7 +132,7 @@ typedef struct W_Connection {
|
|||||||
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
clearOutputQueue(WMConnection *cPtr) /*FOLD00*/
|
clearOutputQueue(WMConnection *cPtr)
|
||||||
{
|
{
|
||||||
cPtr->bufPos = 0;
|
cPtr->bufPos = 0;
|
||||||
WMEmptyArray(cPtr->outputQueue);
|
WMEmptyArray(cPtr->outputQueue);
|
||||||
@@ -138,7 +140,7 @@ clearOutputQueue(WMConnection *cPtr) /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
openTimeout(void *cdata) /*FOLD00*/
|
openTimeout(void *cdata)
|
||||||
{
|
{
|
||||||
WMConnection *cPtr = (WMConnection*) cdata;
|
WMConnection *cPtr = (WMConnection*) cdata;
|
||||||
|
|
||||||
@@ -161,7 +163,7 @@ openTimeout(void *cdata) /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
sendTimeout(void *cdata) /*FOLD00*/
|
sendTimeout(void *cdata)
|
||||||
{
|
{
|
||||||
WMConnection *cPtr = (WMConnection*) cdata;
|
WMConnection *cPtr = (WMConnection*) cdata;
|
||||||
|
|
||||||
@@ -174,6 +176,8 @@ sendTimeout(void *cdata) /*FOLD00*/
|
|||||||
clearOutputQueue(cPtr);
|
clearOutputQueue(cPtr);
|
||||||
cPtr->state = WCTimedOut;
|
cPtr->state = WCTimedOut;
|
||||||
cPtr->timeoutState = WCTWhileSending;
|
cPtr->timeoutState = WCTWhileSending;
|
||||||
|
/* // should we close it no matter what (after calling the didTimeout
|
||||||
|
// delegate)? -Dan */
|
||||||
if (cPtr->delegate && cPtr->delegate->didTimeout) {
|
if (cPtr->delegate && cPtr->delegate->didTimeout) {
|
||||||
(*cPtr->delegate->didTimeout)(cPtr->delegate, cPtr);
|
(*cPtr->delegate->didTimeout)(cPtr->delegate, cPtr);
|
||||||
} else {
|
} else {
|
||||||
@@ -185,7 +189,7 @@ sendTimeout(void *cdata) /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
inputHandler(int fd, int mask, void *clientData) /*FOLD00*/
|
inputHandler(int fd, int mask, void *clientData)
|
||||||
{
|
{
|
||||||
WMConnection *cPtr = (WMConnection*)clientData;
|
WMConnection *cPtr = (WMConnection*)clientData;
|
||||||
|
|
||||||
@@ -193,9 +197,10 @@ inputHandler(int fd, int mask, void *clientData) /*FOLD00*/
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
if ((mask & WIWriteMask)) {
|
if ((mask & WIWriteMask)) {
|
||||||
|
int result;
|
||||||
|
|
||||||
if (cPtr->state == WCInProgress) {
|
if (cPtr->state == WCInProgress) {
|
||||||
Bool failed;
|
Bool failed;
|
||||||
int result;
|
|
||||||
int len = sizeof(result);
|
int len = sizeof(result);
|
||||||
|
|
||||||
WCErrorCode = 0;
|
WCErrorCode = 0;
|
||||||
@@ -229,7 +234,10 @@ inputHandler(int fd, int mask, void *clientData) /*FOLD00*/
|
|||||||
if (failed)
|
if (failed)
|
||||||
return;
|
return;
|
||||||
} else if (cPtr->state == WCConnected) {
|
} else if (cPtr->state == WCConnected) {
|
||||||
WMFlushConnection(cPtr);
|
result = WMFlushConnection(cPtr);
|
||||||
|
if (result>0 && cPtr->delegate && cPtr->delegate->canResumeSending) {
|
||||||
|
(*cPtr->delegate->canResumeSending)(cPtr->delegate, cPtr);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -250,7 +258,7 @@ inputHandler(int fd, int mask, void *clientData) /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
static Bool
|
static Bool
|
||||||
setSocketNonBlocking(int sock, Bool flag) /*FOLD00*/
|
setSocketNonBlocking(int sock, Bool flag)
|
||||||
{
|
{
|
||||||
int state;
|
int state;
|
||||||
Bool isNonBlock;
|
Bool isNonBlock;
|
||||||
@@ -284,7 +292,7 @@ setSocketNonBlocking(int sock, Bool flag) /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
setConnectionAddress(WMConnection *cPtr, struct sockaddr_in *socketaddr) /*FOLD00*/
|
setConnectionAddress(WMConnection *cPtr, struct sockaddr_in *socketaddr)
|
||||||
{
|
{
|
||||||
wassertr(cPtr->address==NULL);
|
wassertr(cPtr->address==NULL);
|
||||||
|
|
||||||
@@ -296,7 +304,7 @@ setConnectionAddress(WMConnection *cPtr, struct sockaddr_in *socketaddr) /*FOLD0
|
|||||||
|
|
||||||
|
|
||||||
static struct sockaddr_in*
|
static struct sockaddr_in*
|
||||||
getSocketAddress(char* name, char* service, char* protocol) /*FOLD00*/
|
getSocketAddress(char* name, char* service, char* protocol)
|
||||||
{
|
{
|
||||||
static struct sockaddr_in socketaddr;
|
static struct sockaddr_in socketaddr;
|
||||||
struct servent *sp;
|
struct servent *sp;
|
||||||
@@ -353,8 +361,14 @@ getSocketAddress(char* name, char* service, char* protocol) /*FOLD00*/
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static void
|
||||||
|
dummyHandler(int signum)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
static WMConnection*
|
static WMConnection*
|
||||||
createConnectionWithSocket(int sock, Bool closeOnRelease) /*FOLD00*/
|
createConnectionWithSocket(int sock, Bool closeOnRelease)
|
||||||
{
|
{
|
||||||
WMConnection *cPtr;
|
WMConnection *cPtr;
|
||||||
struct sigaction sig_action;
|
struct sigaction sig_action;
|
||||||
@@ -371,6 +385,7 @@ createConnectionWithSocket(int sock, Bool closeOnRelease) /*FOLD00*/
|
|||||||
cPtr->sendTimeout.timeout = DefaultTimeout;
|
cPtr->sendTimeout.timeout = DefaultTimeout;
|
||||||
cPtr->sendTimeout.handler = NULL;
|
cPtr->sendTimeout.handler = NULL;
|
||||||
cPtr->closeOnRelease = closeOnRelease;
|
cPtr->closeOnRelease = closeOnRelease;
|
||||||
|
cPtr->shutdownOnClose = 1;
|
||||||
cPtr->outputQueue =
|
cPtr->outputQueue =
|
||||||
WMCreateArrayWithDestructor(16, (WMFreeDataProc*)WMReleaseData);
|
WMCreateArrayWithDestructor(16, (WMFreeDataProc*)WMReleaseData);
|
||||||
cPtr->state = WCNotConnected;
|
cPtr->state = WCNotConnected;
|
||||||
@@ -378,7 +393,11 @@ createConnectionWithSocket(int sock, Bool closeOnRelease) /*FOLD00*/
|
|||||||
|
|
||||||
/* ignore dead pipe */
|
/* ignore dead pipe */
|
||||||
if (!SigInitialized) {
|
if (!SigInitialized) {
|
||||||
sig_action.sa_handler = SIG_IGN;
|
/* Because POSIX mandates that only signal with handlers are reset
|
||||||
|
* accross an exec*(), we do not want to propagate ignoring SIGPIPEs
|
||||||
|
* to children. Hence the dummy handler. Philippe Troin <phil@fifi.org>
|
||||||
|
*/
|
||||||
|
sig_action.sa_handler = &dummyHandler;
|
||||||
sig_action.sa_flags = SA_RESTART;
|
sig_action.sa_flags = SA_RESTART;
|
||||||
sigaction(SIGPIPE, &sig_action, NULL);
|
sigaction(SIGPIPE, &sig_action, NULL);
|
||||||
SigInitialized = True;
|
SigInitialized = True;
|
||||||
@@ -390,11 +409,12 @@ createConnectionWithSocket(int sock, Bool closeOnRelease) /*FOLD00*/
|
|||||||
|
|
||||||
#if 0
|
#if 0
|
||||||
WMConnection*
|
WMConnection*
|
||||||
WMCreateConnectionWithSocket(int sock, Bool closeOnRelease) /*FOLD00*/
|
WMCreateConnectionWithSocket(int sock, Bool closeOnRelease)
|
||||||
{
|
{
|
||||||
WMConnection *cPtr;
|
WMConnection *cPtr;
|
||||||
struct sockaddr_in clientname;
|
struct sockaddr_in clientname;
|
||||||
int size, n;
|
int size;
|
||||||
|
int n;
|
||||||
|
|
||||||
cPtr = createConnectionWithSocket(sock, closeOnRelease);
|
cPtr = createConnectionWithSocket(sock, closeOnRelease);
|
||||||
cPtr->wasNonBlocking = WMIsConnectionNonBlocking(cPtr);
|
cPtr->wasNonBlocking = WMIsConnectionNonBlocking(cPtr);
|
||||||
@@ -438,16 +458,17 @@ WMCreateConnectionWithSocket(int sock, Bool closeOnRelease) /*FOLD00*/
|
|||||||
* currently only "tcp" is supported.
|
* currently only "tcp" is supported.
|
||||||
*/
|
*/
|
||||||
WMConnection*
|
WMConnection*
|
||||||
WMCreateConnectionAsServerAtAddress(char *host, char *service, char *protocol) /*FOLD00*/
|
WMCreateConnectionAsServerAtAddress(char *host, char *service, char *protocol)
|
||||||
{
|
{
|
||||||
WMConnection *cPtr;
|
WMConnection *cPtr;
|
||||||
struct sockaddr_in *socketaddr;
|
struct sockaddr_in *socketaddr;
|
||||||
int sock, size, on;
|
int sock, on;
|
||||||
|
int size;
|
||||||
|
|
||||||
WCErrorCode = 0;
|
WCErrorCode = 0;
|
||||||
|
|
||||||
if ((socketaddr = getSocketAddress(host, service, protocol)) == NULL) {
|
if ((socketaddr = getSocketAddress(host, service, protocol)) == NULL) {
|
||||||
wwarning("Bad address-service-protocol combination");
|
wwarning(_("Bad address-service-protocol combination"));
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -498,7 +519,7 @@ WMCreateConnectionAsServerAtAddress(char *host, char *service, char *protocol) /
|
|||||||
|
|
||||||
|
|
||||||
WMConnection*
|
WMConnection*
|
||||||
WMCreateConnectionToAddress(char *host, char *service, char *protocol) /*FOLD00*/
|
WMCreateConnectionToAddress(char *host, char *service, char *protocol)
|
||||||
{
|
{
|
||||||
WMConnection *cPtr;
|
WMConnection *cPtr;
|
||||||
struct sockaddr_in *socketaddr;
|
struct sockaddr_in *socketaddr;
|
||||||
@@ -512,7 +533,7 @@ WMCreateConnectionToAddress(char *host, char *service, char *protocol) /*FOLD00*
|
|||||||
host = "localhost";
|
host = "localhost";
|
||||||
|
|
||||||
if ((socketaddr = getSocketAddress(host, service, protocol)) == NULL) {
|
if ((socketaddr = getSocketAddress(host, service, protocol)) == NULL) {
|
||||||
wwarning("Bad address-service-protocol combination");
|
wwarning(_("Bad address-service-protocol combination"));
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -540,7 +561,7 @@ WMCreateConnectionToAddress(char *host, char *service, char *protocol) /*FOLD00*
|
|||||||
|
|
||||||
|
|
||||||
WMConnection*
|
WMConnection*
|
||||||
WMCreateConnectionToAddressAndNotify(char *host, char *service, char *protocol) /*FOLD00*/
|
WMCreateConnectionToAddressAndNotify(char *host, char *service, char *protocol)
|
||||||
{
|
{
|
||||||
WMConnection *cPtr;
|
WMConnection *cPtr;
|
||||||
struct sockaddr_in *socketaddr;
|
struct sockaddr_in *socketaddr;
|
||||||
@@ -555,7 +576,7 @@ WMCreateConnectionToAddressAndNotify(char *host, char *service, char *protocol)
|
|||||||
host = "localhost";
|
host = "localhost";
|
||||||
|
|
||||||
if ((socketaddr = getSocketAddress(host, service, protocol)) == NULL) {
|
if ((socketaddr = getSocketAddress(host, service, protocol)) == NULL) {
|
||||||
wwarning("Bad address-service-protocol combination");
|
wwarning(_("Bad address-service-protocol combination"));
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -591,7 +612,7 @@ WMCreateConnectionToAddressAndNotify(char *host, char *service, char *protocol)
|
|||||||
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
removeAllHandlers(WMConnection *cPtr) /*FOLD00*/
|
removeAllHandlers(WMConnection *cPtr)
|
||||||
{
|
{
|
||||||
if (cPtr->handler.read)
|
if (cPtr->handler.read)
|
||||||
WMDeleteInputHandler(cPtr->handler.read);
|
WMDeleteInputHandler(cPtr->handler.read);
|
||||||
@@ -613,10 +634,12 @@ removeAllHandlers(WMConnection *cPtr) /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
WMDestroyConnection(WMConnection *cPtr) /*FOLD00*/
|
WMDestroyConnection(WMConnection *cPtr)
|
||||||
{
|
{
|
||||||
if (cPtr->closeOnRelease && cPtr->sock>=0) {
|
if (cPtr->closeOnRelease && cPtr->sock>=0) {
|
||||||
|
if (cPtr->shutdownOnClose) {
|
||||||
shutdown(cPtr->sock, SHUT_RDWR);
|
shutdown(cPtr->sock, SHUT_RDWR);
|
||||||
|
}
|
||||||
close(cPtr->sock);
|
close(cPtr->sock);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -634,10 +657,12 @@ WMDestroyConnection(WMConnection *cPtr) /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
WMCloseConnection(WMConnection *cPtr) /*FOLD00*/
|
WMCloseConnection(WMConnection *cPtr)
|
||||||
{
|
{
|
||||||
if (cPtr->sock>=0) {
|
if (cPtr->sock>=0) {
|
||||||
|
if (cPtr->shutdownOnClose) {
|
||||||
shutdown(cPtr->sock, SHUT_RDWR);
|
shutdown(cPtr->sock, SHUT_RDWR);
|
||||||
|
}
|
||||||
close(cPtr->sock);
|
close(cPtr->sock);
|
||||||
cPtr->sock = -1;
|
cPtr->sock = -1;
|
||||||
}
|
}
|
||||||
@@ -650,7 +675,7 @@ WMCloseConnection(WMConnection *cPtr) /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
WMConnection*
|
WMConnection*
|
||||||
WMAcceptConnection(WMConnection *listener) /*FOLD00*/
|
WMAcceptConnection(WMConnection *listener)
|
||||||
{
|
{
|
||||||
struct sockaddr_in clientname;
|
struct sockaddr_in clientname;
|
||||||
int size;
|
int size;
|
||||||
@@ -677,49 +702,49 @@ WMAcceptConnection(WMConnection *listener) /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
char*
|
char*
|
||||||
WMGetConnectionAddress(WMConnection *cPtr) /*FOLD00*/
|
WMGetConnectionAddress(WMConnection *cPtr)
|
||||||
{
|
{
|
||||||
return cPtr->address;
|
return cPtr->address;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
char*
|
char*
|
||||||
WMGetConnectionService(WMConnection *cPtr) /*FOLD00*/
|
WMGetConnectionService(WMConnection *cPtr)
|
||||||
{
|
{
|
||||||
return cPtr->service;
|
return cPtr->service;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
char*
|
char*
|
||||||
WMGetConnectionProtocol(WMConnection *cPtr) /*FOLD00*/
|
WMGetConnectionProtocol(WMConnection *cPtr)
|
||||||
{
|
{
|
||||||
return cPtr->protocol;
|
return cPtr->protocol;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
int
|
int
|
||||||
WMGetConnectionSocket(WMConnection *cPtr) /*FOLD00*/
|
WMGetConnectionSocket(WMConnection *cPtr)
|
||||||
{
|
{
|
||||||
return cPtr->sock;
|
return cPtr->sock;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
WMConnectionState
|
WMConnectionState
|
||||||
WMGetConnectionState(WMConnection *cPtr) /*FOLD00*/
|
WMGetConnectionState(WMConnection *cPtr)
|
||||||
{
|
{
|
||||||
return cPtr->state;
|
return cPtr->state;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
WMConnectionTimeoutState
|
WMConnectionTimeoutState
|
||||||
WMGetConnectionTimeoutState(WMConnection *cPtr) /*FOLD00*/
|
WMGetConnectionTimeoutState(WMConnection *cPtr)
|
||||||
{
|
{
|
||||||
return cPtr->timeoutState;
|
return cPtr->timeoutState;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
Bool
|
Bool
|
||||||
WMEnqueueConnectionData(WMConnection *cPtr, WMData *data) /*FOLD00*/
|
WMEnqueueConnectionData(WMConnection *cPtr, WMData *data)
|
||||||
{
|
{
|
||||||
wassertrv(cPtr->state!=WCNotConnected && cPtr->state!=WCListening, False);
|
wassertrv(cPtr->state!=WCNotConnected && cPtr->state!=WCListening, False);
|
||||||
wassertrv(cPtr->state!=WCInProgress && cPtr->state!=WCFailed, False);
|
wassertrv(cPtr->state!=WCInProgress && cPtr->state!=WCFailed, False);
|
||||||
@@ -732,10 +757,18 @@ WMEnqueueConnectionData(WMConnection *cPtr, WMData *data) /*FOLD00*/
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Return value:
|
||||||
|
* -1 - not connected or connection died while sending
|
||||||
|
* 0 - couldn't send the data (or part of it). data is saved in a queue
|
||||||
|
* and will be sent when possible. after it is sent the canResumeSending
|
||||||
|
* callback will be called.
|
||||||
|
* 1 - data was succesfully sent
|
||||||
|
*/
|
||||||
int
|
int
|
||||||
WMSendConnectionData(WMConnection *cPtr, WMData *data) /*FOLD00*/
|
WMSendConnectionData(WMConnection *cPtr, WMData *data)
|
||||||
{
|
{
|
||||||
int bytes, pos, len, totalTransfer;
|
int bytes, pos, len;
|
||||||
TimeoutData *tPtr = &cPtr->sendTimeout;
|
TimeoutData *tPtr = &cPtr->sendTimeout;
|
||||||
const unsigned char *dataBytes;
|
const unsigned char *dataBytes;
|
||||||
|
|
||||||
@@ -756,8 +789,6 @@ WMSendConnectionData(WMConnection *cPtr, WMData *data) /*FOLD00*/
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
totalTransfer = 0;
|
|
||||||
|
|
||||||
while (WMGetArrayItemCount(cPtr->outputQueue) > 0) {
|
while (WMGetArrayItemCount(cPtr->outputQueue) > 0) {
|
||||||
data = WMGetFromArray(cPtr->outputQueue, 0);
|
data = WMGetFromArray(cPtr->outputQueue, 0);
|
||||||
dataBytes = (const unsigned char *)WMDataBytes(data);
|
dataBytes = (const unsigned char *)WMDataBytes(data);
|
||||||
@@ -782,7 +813,7 @@ WMSendConnectionData(WMConnection *cPtr, WMData *data) /*FOLD00*/
|
|||||||
WMAddInputHandler(cPtr->sock, WIWriteMask,
|
WMAddInputHandler(cPtr->sock, WIWriteMask,
|
||||||
inputHandler, cPtr);
|
inputHandler, cPtr);
|
||||||
}
|
}
|
||||||
return totalTransfer;
|
return 0;
|
||||||
default:
|
default:
|
||||||
WCErrorCode = errno;
|
WCErrorCode = errno;
|
||||||
cPtr->state = WCDied;
|
cPtr->state = WCDied;
|
||||||
@@ -793,7 +824,6 @@ WMSendConnectionData(WMConnection *cPtr, WMData *data) /*FOLD00*/
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
pos += bytes;
|
pos += bytes;
|
||||||
totalTransfer += bytes;
|
|
||||||
}
|
}
|
||||||
WMDeleteFromArray(cPtr->outputQueue, 0);
|
WMDeleteFromArray(cPtr->outputQueue, 0);
|
||||||
cPtr->bufPos = 0;
|
cPtr->bufPos = 0;
|
||||||
@@ -801,13 +831,18 @@ WMSendConnectionData(WMConnection *cPtr, WMData *data) /*FOLD00*/
|
|||||||
WMDeleteTimerHandler(tPtr->handler);
|
WMDeleteTimerHandler(tPtr->handler);
|
||||||
tPtr->handler = NULL;
|
tPtr->handler = NULL;
|
||||||
}
|
}
|
||||||
|
/*if (cPtr->handler.write) {
|
||||||
|
WMDeleteInputHandler(cPtr->handler.write);
|
||||||
|
cPtr->handler.write = NULL;
|
||||||
|
}*/
|
||||||
|
}
|
||||||
|
|
||||||
if (cPtr->handler.write) {
|
if (cPtr->handler.write) {
|
||||||
WMDeleteInputHandler(cPtr->handler.write);
|
WMDeleteInputHandler(cPtr->handler.write);
|
||||||
cPtr->handler.write = NULL;
|
cPtr->handler.write = NULL;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
return totalTransfer;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -824,7 +859,7 @@ WMSendConnectionData(WMConnection *cPtr, WMData *data) /*FOLD00*/
|
|||||||
* considered to be an error condition, and will return NULL.
|
* considered to be an error condition, and will return NULL.
|
||||||
*/
|
*/
|
||||||
WMData*
|
WMData*
|
||||||
WMGetConnectionAvailableData(WMConnection *cPtr) /*FOLD00*/
|
WMGetConnectionAvailableData(WMConnection *cPtr)
|
||||||
{
|
{
|
||||||
char buffer[NETBUF_SIZE];
|
char buffer[NETBUF_SIZE];
|
||||||
int nbytes;
|
int nbytes;
|
||||||
@@ -869,7 +904,7 @@ again:
|
|||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
WMSetConnectionDelegate(WMConnection *cPtr, ConnectionDelegate *delegate) /*FOLD00*/
|
WMSetConnectionDelegate(WMConnection *cPtr, ConnectionDelegate *delegate)
|
||||||
{
|
{
|
||||||
wassertr(cPtr->sock >= 0);
|
wassertr(cPtr->sock >= 0);
|
||||||
/* Don't try to set the delegate multiple times */
|
/* Don't try to set the delegate multiple times */
|
||||||
@@ -887,7 +922,7 @@ WMSetConnectionDelegate(WMConnection *cPtr, ConnectionDelegate *delegate) /*FOLD
|
|||||||
|
|
||||||
#if 0
|
#if 0
|
||||||
Bool
|
Bool
|
||||||
WMIsConnectionNonBlocking(WMConnection *cPtr) /*FOLD00*/
|
WMIsConnectionNonBlocking(WMConnection *cPtr)
|
||||||
{
|
{
|
||||||
#if 1
|
#if 1
|
||||||
int state;
|
int state;
|
||||||
@@ -910,10 +945,12 @@ WMIsConnectionNonBlocking(WMConnection *cPtr) /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
Bool
|
Bool
|
||||||
WMSetConnectionNonBlocking(WMConnection *cPtr, Bool flag) /*FOLD00*/
|
WMSetConnectionNonBlocking(WMConnection *cPtr, Bool flag)
|
||||||
{
|
{
|
||||||
wassertrv(cPtr!=NULL && cPtr->sock>=0, False);
|
wassertrv(cPtr!=NULL && cPtr->sock>=0, False);
|
||||||
|
|
||||||
|
flag = ((flag==0) ? 0 : 1);
|
||||||
|
|
||||||
if (cPtr->isNonBlocking == flag)
|
if (cPtr->isNonBlocking == flag)
|
||||||
return True;
|
return True;
|
||||||
|
|
||||||
@@ -931,7 +968,7 @@ WMSetConnectionCloseOnExec(WMConnection *cPtr, Bool flag)
|
|||||||
{
|
{
|
||||||
wassertrv(cPtr!=NULL && cPtr->sock>=0, False);
|
wassertrv(cPtr!=NULL && cPtr->sock>=0, False);
|
||||||
|
|
||||||
if (fcntl(cPtr->sock, F_SETFD, (flag ? FD_CLOEXEC : 0)) < 0) {
|
if (fcntl(cPtr->sock, F_SETFD, ((flag==0) ? 0 : FD_CLOEXEC)) < 0) {
|
||||||
return False;
|
return False;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -939,29 +976,36 @@ WMSetConnectionCloseOnExec(WMConnection *cPtr, Bool flag)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void
|
||||||
|
WMSetConnectionShutdownOnClose(WMConnection *cPtr, Bool flag)
|
||||||
|
{
|
||||||
|
cPtr->shutdownOnClose = ((flag==0) ? 0 : 1);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
void*
|
void*
|
||||||
WMGetConnectionClientData(WMConnection *cPtr) /*FOLD00*/
|
WMGetConnectionClientData(WMConnection *cPtr)
|
||||||
{
|
{
|
||||||
return cPtr->clientData;
|
return cPtr->clientData;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
WMSetConnectionClientData(WMConnection *cPtr, void *data) /*FOLD00*/
|
WMSetConnectionClientData(WMConnection *cPtr, void *data)
|
||||||
{
|
{
|
||||||
cPtr->clientData = data;
|
cPtr->clientData = data;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
unsigned int
|
unsigned int
|
||||||
WMGetConnectionFlags(WMConnection *cPtr) /*FOLD00*/
|
WMGetConnectionFlags(WMConnection *cPtr)
|
||||||
{
|
{
|
||||||
return cPtr->uflags;
|
return cPtr->uflags;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
WMSetConnectionFlags(WMConnection *cPtr, unsigned int flags) /*FOLD00*/
|
WMSetConnectionFlags(WMConnection *cPtr, unsigned int flags)
|
||||||
{
|
{
|
||||||
cPtr->uflags = flags;
|
cPtr->uflags = flags;
|
||||||
}
|
}
|
||||||
@@ -975,7 +1019,7 @@ WMGetConnectionUnsentData(WMConnection *cPtr)
|
|||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
WMSetConnectionDefaultTimeout(unsigned int timeout) /*FOLD00*/
|
WMSetConnectionDefaultTimeout(unsigned int timeout)
|
||||||
{
|
{
|
||||||
if (timeout == 0) {
|
if (timeout == 0) {
|
||||||
DefaultTimeout = DEF_TIMEOUT;
|
DefaultTimeout = DEF_TIMEOUT;
|
||||||
@@ -986,7 +1030,7 @@ WMSetConnectionDefaultTimeout(unsigned int timeout) /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
WMSetConnectionOpenTimeout(unsigned int timeout) /*FOLD00*/
|
WMSetConnectionOpenTimeout(unsigned int timeout)
|
||||||
{
|
{
|
||||||
if (timeout == 0) {
|
if (timeout == 0) {
|
||||||
OpenTimeout = DefaultTimeout;
|
OpenTimeout = DefaultTimeout;
|
||||||
@@ -997,7 +1041,7 @@ WMSetConnectionOpenTimeout(unsigned int timeout) /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
WMSetConnectionSendTimeout(WMConnection *cPtr, unsigned int timeout) /*FOLD00*/
|
WMSetConnectionSendTimeout(WMConnection *cPtr, unsigned int timeout)
|
||||||
{
|
{
|
||||||
if (timeout == 0) {
|
if (timeout == 0) {
|
||||||
cPtr->sendTimeout.timeout = DefaultTimeout;
|
cPtr->sendTimeout.timeout = DefaultTimeout;
|
||||||
|
|||||||
46
WINGs/data.c
46
WINGs/data.c
@@ -1,7 +1,7 @@
|
|||||||
/*
|
/*
|
||||||
* WINGs WMData function library
|
* WINGs WMData function library
|
||||||
*
|
*
|
||||||
* Copyright (c) 1999-2000 Dan Pascu
|
* Copyright (c) 1999-2003 Dan Pascu
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* 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
|
* it under the terms of the GNU General Public License as published by
|
||||||
@@ -40,7 +40,7 @@ typedef struct W_Data {
|
|||||||
/* Creating and destroying data objects */
|
/* Creating and destroying data objects */
|
||||||
|
|
||||||
WMData*
|
WMData*
|
||||||
WMCreateDataWithCapacity(unsigned capacity) /*FOLD00*/
|
WMCreateDataWithCapacity(unsigned capacity)
|
||||||
{
|
{
|
||||||
WMData *aData;
|
WMData *aData;
|
||||||
|
|
||||||
@@ -63,7 +63,7 @@ WMCreateDataWithCapacity(unsigned capacity) /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
WMData*
|
WMData*
|
||||||
WMCreateDataWithLength(unsigned length) /*FOLD00*/
|
WMCreateDataWithLength(unsigned length)
|
||||||
{
|
{
|
||||||
WMData *aData;
|
WMData *aData;
|
||||||
|
|
||||||
@@ -78,7 +78,7 @@ WMCreateDataWithLength(unsigned length) /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
WMData*
|
WMData*
|
||||||
WMCreateDataWithBytes(void *bytes, unsigned length) /*FOLD00*/
|
WMCreateDataWithBytes(void *bytes, unsigned length)
|
||||||
{
|
{
|
||||||
WMData *aData;
|
WMData *aData;
|
||||||
|
|
||||||
@@ -91,7 +91,7 @@ WMCreateDataWithBytes(void *bytes, unsigned length) /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
WMData*
|
WMData*
|
||||||
WMCreateDataWithBytesNoCopy(void *bytes, unsigned length, /*FOLD00*/
|
WMCreateDataWithBytesNoCopy(void *bytes, unsigned length,
|
||||||
WMFreeDataProc *destructor)
|
WMFreeDataProc *destructor)
|
||||||
{
|
{
|
||||||
WMData *aData;
|
WMData *aData;
|
||||||
@@ -110,7 +110,7 @@ WMCreateDataWithBytesNoCopy(void *bytes, unsigned length, /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
WMData*
|
WMData*
|
||||||
WMCreateDataWithData(WMData *aData) /*FOLD00*/
|
WMCreateDataWithData(WMData *aData)
|
||||||
{
|
{
|
||||||
WMData *newData;
|
WMData *newData;
|
||||||
|
|
||||||
@@ -126,7 +126,7 @@ WMCreateDataWithData(WMData *aData) /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
WMData*
|
WMData*
|
||||||
WMRetainData(WMData *aData) /*FOLD00*/
|
WMRetainData(WMData *aData)
|
||||||
{
|
{
|
||||||
aData->retainCount++;
|
aData->retainCount++;
|
||||||
return aData;
|
return aData;
|
||||||
@@ -134,7 +134,7 @@ WMRetainData(WMData *aData) /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
WMReleaseData(WMData *aData) /*FOLD00*/
|
WMReleaseData(WMData *aData)
|
||||||
{
|
{
|
||||||
aData->retainCount--;
|
aData->retainCount--;
|
||||||
if (aData->retainCount > 0)
|
if (aData->retainCount > 0)
|
||||||
@@ -150,7 +150,7 @@ WMReleaseData(WMData *aData) /*FOLD00*/
|
|||||||
/* Adjusting capacity */
|
/* Adjusting capacity */
|
||||||
|
|
||||||
void
|
void
|
||||||
WMSetDataCapacity(WMData *aData, unsigned capacity) /*FOLD00*/
|
WMSetDataCapacity(WMData *aData, unsigned capacity)
|
||||||
{
|
{
|
||||||
if (aData->capacity != capacity) {
|
if (aData->capacity != capacity) {
|
||||||
aData->bytes = wrealloc(aData->bytes, capacity);
|
aData->bytes = wrealloc(aData->bytes, capacity);
|
||||||
@@ -164,7 +164,7 @@ WMSetDataCapacity(WMData *aData, unsigned capacity) /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
WMSetDataLength(WMData *aData, unsigned length) /*FOLD00*/
|
WMSetDataLength(WMData *aData, unsigned length)
|
||||||
{
|
{
|
||||||
if (length > aData->capacity) {
|
if (length > aData->capacity) {
|
||||||
WMSetDataCapacity(aData, length);
|
WMSetDataCapacity(aData, length);
|
||||||
@@ -185,7 +185,7 @@ WMSetDataFormat(WMData *aData, unsigned format)
|
|||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
WMIncreaseDataLengthBy(WMData *aData, unsigned extraLength) /*FOLD00*/
|
WMIncreaseDataLengthBy(WMData *aData, unsigned extraLength)
|
||||||
{
|
{
|
||||||
WMSetDataLength(aData, aData->length + extraLength);
|
WMSetDataLength(aData, aData->length + extraLength);
|
||||||
}
|
}
|
||||||
@@ -194,14 +194,14 @@ WMIncreaseDataLengthBy(WMData *aData, unsigned extraLength) /*FOLD00*/
|
|||||||
/* Accessing data */
|
/* Accessing data */
|
||||||
|
|
||||||
const void*
|
const void*
|
||||||
WMDataBytes(WMData *aData) /*FOLD00*/
|
WMDataBytes(WMData *aData)
|
||||||
{
|
{
|
||||||
return aData->bytes;
|
return aData->bytes;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
WMGetDataBytes(WMData *aData, void *buffer) /*FOLD00*/
|
WMGetDataBytes(WMData *aData, void *buffer)
|
||||||
{
|
{
|
||||||
wassertr(aData->length > 0);
|
wassertr(aData->length > 0);
|
||||||
|
|
||||||
@@ -217,7 +217,7 @@ WMGetDataFormat(WMData *aData)
|
|||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
WMGetDataBytesWithLength(WMData *aData, void *buffer, unsigned length) /*FOLD00*/
|
WMGetDataBytesWithLength(WMData *aData, void *buffer, unsigned length)
|
||||||
{
|
{
|
||||||
wassertr(aData->length > 0);
|
wassertr(aData->length > 0);
|
||||||
wassertr(length <= aData->length);
|
wassertr(length <= aData->length);
|
||||||
@@ -227,7 +227,7 @@ WMGetDataBytesWithLength(WMData *aData, void *buffer, unsigned length) /*FOLD00*
|
|||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
WMGetDataBytesWithRange(WMData *aData, void *buffer, WMRange aRange) /*FOLD00*/
|
WMGetDataBytesWithRange(WMData *aData, void *buffer, WMRange aRange)
|
||||||
{
|
{
|
||||||
wassertr(aRange.position < aData->length);
|
wassertr(aRange.position < aData->length);
|
||||||
wassertr(aRange.count <= aData->length-aRange.position);
|
wassertr(aRange.count <= aData->length-aRange.position);
|
||||||
@@ -238,7 +238,7 @@ WMGetDataBytesWithRange(WMData *aData, void *buffer, WMRange aRange) /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
WMData*
|
WMData*
|
||||||
WMGetSubdataWithRange(WMData *aData, WMRange aRange) /*FOLD00*/
|
WMGetSubdataWithRange(WMData *aData, WMRange aRange)
|
||||||
{
|
{
|
||||||
void *buffer;
|
void *buffer;
|
||||||
WMData *newData;
|
WMData *newData;
|
||||||
@@ -258,7 +258,7 @@ WMGetSubdataWithRange(WMData *aData, WMRange aRange) /*FOLD00*/
|
|||||||
/* Testing data */
|
/* Testing data */
|
||||||
|
|
||||||
Bool
|
Bool
|
||||||
WMIsDataEqualToData(WMData *aData, WMData *anotherData) /*FOLD00*/
|
WMIsDataEqualToData(WMData *aData, WMData *anotherData)
|
||||||
{
|
{
|
||||||
if (aData->length != anotherData->length)
|
if (aData->length != anotherData->length)
|
||||||
return False;
|
return False;
|
||||||
@@ -271,7 +271,7 @@ WMIsDataEqualToData(WMData *aData, WMData *anotherData) /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
unsigned
|
unsigned
|
||||||
WMGetDataLength(WMData *aData) /*FOLD00*/
|
WMGetDataLength(WMData *aData)
|
||||||
{
|
{
|
||||||
return aData->length;
|
return aData->length;
|
||||||
}
|
}
|
||||||
@@ -279,7 +279,7 @@ WMGetDataLength(WMData *aData) /*FOLD00*/
|
|||||||
|
|
||||||
/* Adding data */
|
/* Adding data */
|
||||||
void
|
void
|
||||||
WMAppendDataBytes(WMData *aData, void *bytes, unsigned length) /*FOLD00*/
|
WMAppendDataBytes(WMData *aData, void *bytes, unsigned length)
|
||||||
{
|
{
|
||||||
unsigned oldLength = aData->length;
|
unsigned oldLength = aData->length;
|
||||||
unsigned newLength = oldLength + length;
|
unsigned newLength = oldLength + length;
|
||||||
@@ -303,7 +303,7 @@ WMAppendDataBytes(WMData *aData, void *bytes, unsigned length) /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
WMAppendData(WMData *aData, WMData *anotherData) /*FOLD00*/
|
WMAppendData(WMData *aData, WMData *anotherData)
|
||||||
{
|
{
|
||||||
if (anotherData->length > 0)
|
if (anotherData->length > 0)
|
||||||
WMAppendDataBytes(aData, anotherData->bytes, anotherData->length);
|
WMAppendDataBytes(aData, anotherData->bytes, anotherData->length);
|
||||||
@@ -314,7 +314,7 @@ WMAppendData(WMData *aData, WMData *anotherData) /*FOLD00*/
|
|||||||
/* Modifying data */
|
/* Modifying data */
|
||||||
|
|
||||||
void
|
void
|
||||||
WMReplaceDataBytesInRange(WMData *aData, WMRange aRange, void *bytes) /*FOLD00*/
|
WMReplaceDataBytesInRange(WMData *aData, WMRange aRange, void *bytes)
|
||||||
{
|
{
|
||||||
wassertr(aRange.position < aData->length);
|
wassertr(aRange.position < aData->length);
|
||||||
wassertr(aRange.count <= aData->length-aRange.position);
|
wassertr(aRange.count <= aData->length-aRange.position);
|
||||||
@@ -324,7 +324,7 @@ WMReplaceDataBytesInRange(WMData *aData, WMRange aRange, void *bytes) /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
WMResetDataBytesInRange(WMData *aData, WMRange aRange) /*FOLD00*/
|
WMResetDataBytesInRange(WMData *aData, WMRange aRange)
|
||||||
{
|
{
|
||||||
wassertr(aRange.position < aData->length);
|
wassertr(aRange.position < aData->length);
|
||||||
wassertr(aRange.count <= aData->length-aRange.position);
|
wassertr(aRange.count <= aData->length-aRange.position);
|
||||||
@@ -334,7 +334,7 @@ WMResetDataBytesInRange(WMData *aData, WMRange aRange) /*FOLD00*/
|
|||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
WMSetData(WMData *aData, WMData *anotherData) /*FOLD00*/
|
WMSetData(WMData *aData, WMData *anotherData)
|
||||||
{
|
{
|
||||||
unsigned length = anotherData->length;
|
unsigned length = anotherData->length;
|
||||||
|
|
||||||
|
|||||||
275
WINGs/dragcommon.c
Normal file
275
WINGs/dragcommon.c
Normal file
@@ -0,0 +1,275 @@
|
|||||||
|
/* #include <X11/Xatom.h> */
|
||||||
|
#include "WINGsP.h"
|
||||||
|
|
||||||
|
#define VERSION_INFO(dragInfo) dragInfo->protocolVersion
|
||||||
|
#define XDND_DEST_INFO(dragInfo) dragInfo->destInfo
|
||||||
|
#define XDND_DEST_VIEW(dragInfo) dragInfo->destInfo->destView
|
||||||
|
#define XDND_DEST_VIEW_STORED(dragInfo) ((dragInfo->destInfo) != NULL)\
|
||||||
|
&& ((dragInfo->destInfo->destView) != NULL)
|
||||||
|
|
||||||
|
|
||||||
|
static Bool _WindowExists;
|
||||||
|
|
||||||
|
|
||||||
|
Atom
|
||||||
|
W_OperationToAction(WMScreen *scr, WMDragOperationType operation)
|
||||||
|
{
|
||||||
|
switch (operation) {
|
||||||
|
case WDOperationNone:
|
||||||
|
return None;
|
||||||
|
|
||||||
|
case WDOperationCopy:
|
||||||
|
return scr->xdndActionCopy;
|
||||||
|
|
||||||
|
case WDOperationMove:
|
||||||
|
return scr->xdndActionMove;
|
||||||
|
|
||||||
|
case WDOperationLink:
|
||||||
|
return scr->xdndActionLink;
|
||||||
|
|
||||||
|
case WDOperationAsk:
|
||||||
|
return scr->xdndActionAsk;
|
||||||
|
|
||||||
|
case WDOperationPrivate:
|
||||||
|
return scr->xdndActionPrivate;
|
||||||
|
|
||||||
|
default:
|
||||||
|
return None;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
WMDragOperationType
|
||||||
|
W_ActionToOperation(WMScreen *scr, Atom action)
|
||||||
|
{
|
||||||
|
if (action == scr->xdndActionCopy) {
|
||||||
|
return WDOperationCopy;
|
||||||
|
|
||||||
|
} else if (action == scr->xdndActionMove) {
|
||||||
|
return WDOperationMove;
|
||||||
|
|
||||||
|
} else if (action == scr->xdndActionLink) {
|
||||||
|
return WDOperationLink;
|
||||||
|
|
||||||
|
} else if (action == scr->xdndActionAsk) {
|
||||||
|
return WDOperationAsk;
|
||||||
|
|
||||||
|
} else if (action == scr->xdndActionPrivate) {
|
||||||
|
return WDOperationPrivate;
|
||||||
|
|
||||||
|
} else if (action == None) {
|
||||||
|
|
||||||
|
return WDOperationNone;
|
||||||
|
} else {
|
||||||
|
char *tmp = XGetAtomName(scr->display, action);
|
||||||
|
|
||||||
|
wwarning("unknown XDND action %s ", tmp);
|
||||||
|
XFree(tmp);
|
||||||
|
|
||||||
|
return WDOperationCopy;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static void
|
||||||
|
freeDragOperationItem(void* item)
|
||||||
|
{
|
||||||
|
wfree(item);
|
||||||
|
}
|
||||||
|
|
||||||
|
WMArray*
|
||||||
|
WMCreateDragOperationArray(int initialSize)
|
||||||
|
{
|
||||||
|
return WMCreateArrayWithDestructor(initialSize, freeDragOperationItem);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
WMDragOperationItem*
|
||||||
|
WMCreateDragOperationItem(WMDragOperationType type, char* text)
|
||||||
|
{
|
||||||
|
W_DragOperationItem *result = wmalloc(sizeof(W_DragOperationItem));
|
||||||
|
|
||||||
|
result->type = type;
|
||||||
|
result->text = text;
|
||||||
|
|
||||||
|
return (WMDragOperationItem*) result;
|
||||||
|
}
|
||||||
|
|
||||||
|
WMDragOperationType
|
||||||
|
WMGetDragOperationItemType(WMDragOperationItem* item)
|
||||||
|
{
|
||||||
|
return ((W_DragOperationItem*)item)->type;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
char*
|
||||||
|
WMGetDragOperationItemText(WMDragOperationItem* item)
|
||||||
|
{
|
||||||
|
return ((W_DragOperationItem*)item)->text;
|
||||||
|
}
|
||||||
|
|
||||||
|
static int
|
||||||
|
handleNoWindowXError(Display *dpy, XErrorEvent *errEvt)
|
||||||
|
{
|
||||||
|
if (errEvt->error_code == BadWindow
|
||||||
|
|| errEvt->error_code == BadDrawable) {
|
||||||
|
_WindowExists = False;
|
||||||
|
return Success;
|
||||||
|
}
|
||||||
|
|
||||||
|
return errEvt->error_code;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static Bool
|
||||||
|
windowExists(Display *dpy, Window win)
|
||||||
|
{
|
||||||
|
void* previousErrorHandler;
|
||||||
|
XWindowAttributes attr;
|
||||||
|
|
||||||
|
XSynchronize(dpy, True);
|
||||||
|
previousErrorHandler = XSetErrorHandler(handleNoWindowXError);
|
||||||
|
_WindowExists = True;
|
||||||
|
|
||||||
|
/* can generate BadDrawable or BadWindow */
|
||||||
|
XGetWindowAttributes(dpy, win, &attr);
|
||||||
|
|
||||||
|
XSetErrorHandler(previousErrorHandler);
|
||||||
|
XSynchronize(dpy, False);
|
||||||
|
return _WindowExists;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Bool
|
||||||
|
W_SendDnDClientMessage(Display *dpy, Window win, Atom message,
|
||||||
|
unsigned long data0,
|
||||||
|
unsigned long data1,
|
||||||
|
unsigned long data2,
|
||||||
|
unsigned long data3,
|
||||||
|
unsigned long data4)
|
||||||
|
{
|
||||||
|
XEvent ev;
|
||||||
|
|
||||||
|
if (! windowExists(dpy, win)) {
|
||||||
|
wwarning("xdnd message target %d does no longer exist.", win);
|
||||||
|
return False; /* message not sent */
|
||||||
|
}
|
||||||
|
|
||||||
|
ev.type = ClientMessage;
|
||||||
|
ev.xclient.message_type = message;
|
||||||
|
ev.xclient.format = 32;
|
||||||
|
ev.xclient.window = win;
|
||||||
|
ev.xclient.data.l[0] = data0;
|
||||||
|
ev.xclient.data.l[1] = data1;
|
||||||
|
ev.xclient.data.l[2] = data2;
|
||||||
|
ev.xclient.data.l[3] = data3;
|
||||||
|
ev.xclient.data.l[4] = data4;
|
||||||
|
|
||||||
|
|
||||||
|
XSendEvent(dpy, win, False, 0, &ev);
|
||||||
|
XFlush(dpy);
|
||||||
|
|
||||||
|
return True; /* message sent */
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static void
|
||||||
|
handleLeaveMessage(WMDraggingInfo *info)
|
||||||
|
{
|
||||||
|
if (XDND_DEST_INFO(info) != NULL) {
|
||||||
|
if (XDND_DEST_VIEW(info) != NULL) {
|
||||||
|
XDND_DEST_VIEW(info)->dragDestinationProcs->concludeDragOperation(
|
||||||
|
XDND_DEST_VIEW(info));
|
||||||
|
}
|
||||||
|
W_DragDestinationInfoClear(info);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void
|
||||||
|
W_HandleDNDClientMessage(WMView *toplevel, XClientMessageEvent *event)
|
||||||
|
{
|
||||||
|
WMScreen *scr = W_VIEW_SCREEN(toplevel);
|
||||||
|
WMDraggingInfo *info = &scr->dragInfo;
|
||||||
|
Atom messageType = event->message_type;
|
||||||
|
|
||||||
|
#ifdef XDND_DEBUG
|
||||||
|
{
|
||||||
|
char* msgTypeName = XGetAtomName(scr->display, messageType);
|
||||||
|
|
||||||
|
if (msgTypeName != NULL)
|
||||||
|
printf("event type = %s\n", msgTypeName);
|
||||||
|
else
|
||||||
|
printf("pb with event type !\n");
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
/* Messages from destination to source */
|
||||||
|
if (messageType == scr->xdndStatusAtom
|
||||||
|
|| messageType == scr->xdndFinishedAtom) {
|
||||||
|
W_DragSourceStopTimer();
|
||||||
|
W_DragSourceStateHandler(info, event);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Messages from source to destination */
|
||||||
|
if (messageType == scr->xdndEnterAtom) {
|
||||||
|
W_DragDestinationStopTimer();
|
||||||
|
W_DragDestinationStoreEnterMsgInfo(info, toplevel, event);
|
||||||
|
|
||||||
|
if (VERSION_INFO(info) <= XDND_VERSION) {
|
||||||
|
if (XDND_DEST_VIEW_STORED(info)) {
|
||||||
|
/* xdndPosition previously received on xdnd aware view */
|
||||||
|
W_DragDestinationStateHandler(info, event);
|
||||||
|
return;
|
||||||
|
} else {
|
||||||
|
W_DragDestinationStartTimer(info);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
wwarning("received dnd enter msg with unsupported version %i",
|
||||||
|
VERSION_INFO(info));
|
||||||
|
W_DragDestinationCancelDropOnEnter(toplevel, info);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (messageType == scr->xdndPositionAtom) {
|
||||||
|
W_DragDestinationStopTimer();
|
||||||
|
W_DragDestinationStorePositionMsgInfo(info, toplevel, event);
|
||||||
|
W_DragDestinationStateHandler(info, event);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (messageType == scr->xdndSelectionAtom
|
||||||
|
|| messageType == scr->xdndDropAtom) {
|
||||||
|
W_DragDestinationStopTimer();
|
||||||
|
W_DragDestinationStateHandler(info, event);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (messageType == scr->xdndLeaveAtom) {
|
||||||
|
/* conclude drop operation, and clear dragging info */
|
||||||
|
W_DragDestinationStopTimer();
|
||||||
|
handleLeaveMessage(info);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* called in destroyView (wview.c) */
|
||||||
|
void
|
||||||
|
W_FreeViewXdndPart(WMView *view)
|
||||||
|
{
|
||||||
|
WMUnregisterViewDraggedTypes(view);
|
||||||
|
|
||||||
|
if (view->dragSourceProcs)
|
||||||
|
wfree(view->dragSourceProcs);
|
||||||
|
|
||||||
|
if (view->dragDestinationProcs)
|
||||||
|
wfree(view->dragDestinationProcs);
|
||||||
|
|
||||||
|
if (view->dragImage)
|
||||||
|
WMReleasePixmap(view->dragImage);
|
||||||
|
}
|
||||||
|
|
||||||
File diff suppressed because it is too large
Load Diff
2284
WINGs/dragsource.c
2284
WINGs/dragsource.c
File diff suppressed because it is too large
Load Diff
@@ -1,7 +1,7 @@
|
|||||||
/*
|
/*
|
||||||
* Window Maker miscelaneous function library
|
* Window Maker miscelaneous function library
|
||||||
*
|
*
|
||||||
* Copyright (c) 1997 Alfredo K. Kojima
|
* Copyright (c) 1997-2003 Alfredo K. Kojima
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* 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
|
* it under the terms of the GNU General Public License as published by
|
||||||
@@ -19,7 +19,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#include "../src/config.h"
|
#include "wconfig.h"
|
||||||
|
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
@@ -51,12 +51,12 @@ wstrerror(int errnum)
|
|||||||
if (errno < sys_nerr)
|
if (errno < sys_nerr)
|
||||||
return sys_errlist[errnum];
|
return sys_errlist[errnum];
|
||||||
|
|
||||||
sprintf (buf, "Unknown error %d", errnum);
|
sprintf (buf, _("Unknown error %d"), errnum);
|
||||||
return buf;
|
return buf;
|
||||||
#else /* no strerror() and no sys_errlist[] */
|
#else /* no strerror() and no sys_errlist[] */
|
||||||
static char buf[] = "Error 12345678901234567890";
|
static char buf[] = "Error 12345678901234567890";
|
||||||
|
|
||||||
sprintf(buf, "Error %d", errnum);
|
sprintf(buf, _("Error %d"), errnum);
|
||||||
return buf;
|
return buf;
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
@@ -79,7 +79,7 @@ wmessage(const char *msg, ...)
|
|||||||
vsnprintf(buf, MAXLINE-3, msg, args);
|
vsnprintf(buf, MAXLINE-3, msg, args);
|
||||||
strcat(buf,"\n");
|
strcat(buf,"\n");
|
||||||
fflush(stdout);
|
fflush(stdout);
|
||||||
fputs(_WINGS_progname, stderr);
|
fputs(_WINGS_progname ? _WINGS_progname : "WINGs", stderr);
|
||||||
fputs(": ",stderr);
|
fputs(": ",stderr);
|
||||||
fputs(buf, stderr);
|
fputs(buf, stderr);
|
||||||
fflush(stdout);
|
fflush(stdout);
|
||||||
@@ -106,8 +106,8 @@ wwarning(const char *msg, ...)
|
|||||||
vsnprintf(buf, MAXLINE-3, msg, args);
|
vsnprintf(buf, MAXLINE-3, msg, args);
|
||||||
strcat(buf,"\n");
|
strcat(buf,"\n");
|
||||||
fflush(stdout);
|
fflush(stdout);
|
||||||
fputs(_WINGS_progname, stderr);
|
fputs(_WINGS_progname ? _WINGS_progname : "WINGs", stderr);
|
||||||
fputs(" warning: ",stderr);
|
fputs(_(" warning: "),stderr);
|
||||||
fputs(buf, stderr);
|
fputs(buf, stderr);
|
||||||
fflush(stdout);
|
fflush(stdout);
|
||||||
fflush(stderr);
|
fflush(stderr);
|
||||||
@@ -133,8 +133,8 @@ wfatal(const char *msg, ...)
|
|||||||
vsnprintf(buf, MAXLINE-3, msg, args);
|
vsnprintf(buf, MAXLINE-3, msg, args);
|
||||||
strcat(buf,"\n");
|
strcat(buf,"\n");
|
||||||
fflush(stdout);
|
fflush(stdout);
|
||||||
fputs(_WINGS_progname, stderr);
|
fputs(_WINGS_progname ? _WINGS_progname : "WINGs", stderr);
|
||||||
fputs(" fatal error: ",stderr);
|
fputs(_(" fatal error: "),stderr);
|
||||||
fputs(buf, stderr);
|
fputs(buf, stderr);
|
||||||
fflush(stdout);
|
fflush(stdout);
|
||||||
fflush(stderr);
|
fflush(stderr);
|
||||||
@@ -159,8 +159,8 @@ wsyserror(const char *msg, ...)
|
|||||||
va_start(args, msg);
|
va_start(args, msg);
|
||||||
vsnprintf(buf, MAXLINE-3, msg, args);
|
vsnprintf(buf, MAXLINE-3, msg, args);
|
||||||
fflush(stdout);
|
fflush(stdout);
|
||||||
fputs(_WINGS_progname, stderr);
|
fputs(_WINGS_progname ? _WINGS_progname : "WINGs", stderr);
|
||||||
fputs(" error: ", stderr);
|
fputs(_(" error: "), stderr);
|
||||||
fputs(buf, stderr);
|
fputs(buf, stderr);
|
||||||
fputs(": ", stderr);
|
fputs(": ", stderr);
|
||||||
fputs(wstrerror(error), stderr);
|
fputs(wstrerror(error), stderr);
|
||||||
@@ -188,8 +188,8 @@ wsyserrorwithcode(int error, const char *msg, ...)
|
|||||||
va_start(args, msg);
|
va_start(args, msg);
|
||||||
vsnprintf(buf, MAXLINE-3, msg, args);
|
vsnprintf(buf, MAXLINE-3, msg, args);
|
||||||
fflush(stdout);
|
fflush(stdout);
|
||||||
fputs(_WINGS_progname, stderr);
|
fputs(_WINGS_progname ? _WINGS_progname : "WINGs", stderr);
|
||||||
fputs(" error: ", stderr);
|
fputs(_(" error: "), stderr);
|
||||||
fputs(buf, stderr);
|
fputs(buf, stderr);
|
||||||
fputs(": ", stderr);
|
fputs(": ", stderr);
|
||||||
fputs(wstrerror(error), stderr);
|
fputs(wstrerror(error), stderr);
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
/*
|
/*
|
||||||
* Window Maker miscelaneous function library
|
* Window Maker miscelaneous function library
|
||||||
*
|
*
|
||||||
* Copyright (c) 1997 Alfredo K. Kojima
|
* Copyright (c) 1997-2003 Alfredo K. Kojima
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* 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
|
* it under the terms of the GNU General Public License as published by
|
||||||
@@ -19,7 +19,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#include "../src/config.h"
|
#include "wconfig.h"
|
||||||
|
|
||||||
#include "WUtil.h"
|
#include "WUtil.h"
|
||||||
|
|
||||||
@@ -45,7 +45,7 @@ wgethomedir()
|
|||||||
|
|
||||||
user = getpwuid(getuid());
|
user = getpwuid(getuid());
|
||||||
if (!user) {
|
if (!user) {
|
||||||
wsyserror("could not get password entry for UID %i", getuid());
|
wsyserror(_("could not get password entry for UID %i"), getuid());
|
||||||
return "/";
|
return "/";
|
||||||
}
|
}
|
||||||
if (!user->pw_dir) {
|
if (!user->pw_dir) {
|
||||||
@@ -63,7 +63,7 @@ getuserhomedir(char *username)
|
|||||||
|
|
||||||
user = getpwnam(username);
|
user = getpwnam(username);
|
||||||
if (!user) {
|
if (!user) {
|
||||||
wsyserror("could not get password entry for user %s", username);
|
wsyserror(_("could not get password entry for user %s"), username);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
if (!user->pw_dir) {
|
if (!user->pw_dir) {
|
||||||
@@ -160,6 +160,27 @@ wexpandpath(char *path)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* return address of next char != tok or end of string whichever comes first */
|
||||||
|
static char*
|
||||||
|
skipchar(char *string, char tok)
|
||||||
|
{
|
||||||
|
while(*string!=0 && *string==tok)
|
||||||
|
string++;
|
||||||
|
|
||||||
|
return string;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* return address of next char == tok or end of string whichever comes first */
|
||||||
|
static char*
|
||||||
|
nextchar(char *string, char tok)
|
||||||
|
{
|
||||||
|
while(*string!=0 && *string!=tok)
|
||||||
|
string++;
|
||||||
|
|
||||||
|
return string;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
*----------------------------------------------------------------------
|
*----------------------------------------------------------------------
|
||||||
@@ -180,15 +201,14 @@ char*
|
|||||||
wfindfile(char *paths, char *file)
|
wfindfile(char *paths, char *file)
|
||||||
{
|
{
|
||||||
char *path;
|
char *path;
|
||||||
char *tmp;
|
char *tmp, *tmp2;
|
||||||
int done;
|
|
||||||
int len, flen;
|
int len, flen;
|
||||||
char *fullpath;
|
char *fullpath;
|
||||||
|
|
||||||
if (!file)
|
if (!file)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
if (*file=='/' || *file=='~' || *file=='$' || !paths) {
|
if (*file=='/' || *file=='~' || *file=='$' || !paths || *paths==0) {
|
||||||
if (access(file, F_OK)<0) {
|
if (access(file, F_OK)<0) {
|
||||||
fullpath = wexpandpath(file);
|
fullpath = wexpandpath(file);
|
||||||
if (!fullpath)
|
if (!fullpath)
|
||||||
@@ -207,13 +227,16 @@ wfindfile(char *paths, char *file)
|
|||||||
|
|
||||||
flen = strlen(file);
|
flen = strlen(file);
|
||||||
tmp = paths;
|
tmp = paths;
|
||||||
done = 0;
|
while (*tmp) {
|
||||||
while (!done) {
|
tmp = skipchar(tmp, ':');
|
||||||
len = strcspn(tmp, ":");
|
if (*tmp==0)
|
||||||
if (len==0) done=1;
|
break;
|
||||||
|
tmp2 = nextchar(tmp, ':');
|
||||||
|
len = tmp2 - tmp;
|
||||||
path = wmalloc(len+flen+2);
|
path = wmalloc(len+flen+2);
|
||||||
path = memcpy(path, tmp, len);
|
path = memcpy(path, tmp, len);
|
||||||
path[len]=0;
|
path[len]=0;
|
||||||
|
if (path[len-1] != '/')
|
||||||
strcat(path, "/");
|
strcat(path, "/");
|
||||||
strcat(path, file);
|
strcat(path, file);
|
||||||
fullpath = wexpandpath(path);
|
fullpath = wexpandpath(path);
|
||||||
@@ -224,9 +247,9 @@ wfindfile(char *paths, char *file)
|
|||||||
}
|
}
|
||||||
wfree(fullpath);
|
wfree(fullpath);
|
||||||
}
|
}
|
||||||
tmp=&(tmp[len+1]);
|
tmp = tmp2;
|
||||||
if (*tmp==0) break;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -284,7 +307,7 @@ wfindfileinlist(char **path_list, char *file)
|
|||||||
|
|
||||||
|
|
||||||
char*
|
char*
|
||||||
wfindfileinarray(proplist_t array, char *file)
|
wfindfileinarray(WMPropList *array, char *file)
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
char *path;
|
char *path;
|
||||||
@@ -312,14 +335,14 @@ wfindfileinarray(proplist_t array, char *file)
|
|||||||
}
|
}
|
||||||
|
|
||||||
flen = strlen(file);
|
flen = strlen(file);
|
||||||
for (i=0; i<PLGetNumberOfElements(array); i++) {
|
for (i=0; i<WMGetPropListItemCount(array); i++) {
|
||||||
proplist_t prop;
|
WMPropList *prop;
|
||||||
char *p;
|
char *p;
|
||||||
|
|
||||||
prop = PLGetArrayElement(array, i);
|
prop = WMGetFromPLArray(array, i);
|
||||||
if (!prop)
|
if (!prop)
|
||||||
continue;
|
continue;
|
||||||
p = PLGetString(prop);
|
p = WMGetFromPLString(prop);
|
||||||
|
|
||||||
len = strlen(p);
|
len = strlen(p);
|
||||||
path = wmalloc(len+flen+2);
|
path = wmalloc(len+flen+2);
|
||||||
|
|||||||
614
WINGs/handlers.c
Normal file
614
WINGs/handlers.c
Normal file
@@ -0,0 +1,614 @@
|
|||||||
|
|
||||||
|
/*
|
||||||
|
* WINGs internal handlers: timer, idle and input handlers
|
||||||
|
*/
|
||||||
|
|
||||||
|
#include "WINGsP.h"
|
||||||
|
|
||||||
|
#include "../src/config.h"
|
||||||
|
|
||||||
|
#include <sys/types.h>
|
||||||
|
#include <unistd.h>
|
||||||
|
|
||||||
|
#include <X11/Xos.h>
|
||||||
|
|
||||||
|
#ifdef HAVE_SYS_SELECT_H
|
||||||
|
# include <sys/select.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#include <time.h>
|
||||||
|
|
||||||
|
#ifndef X_GETTIMEOFDAY
|
||||||
|
#define X_GETTIMEOFDAY(t) gettimeofday(t, (struct timezone*)0)
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
typedef struct TimerHandler {
|
||||||
|
WMCallback *callback; /* procedure to call */
|
||||||
|
struct timeval when; /* when to call the callback */
|
||||||
|
void *clientData;
|
||||||
|
struct TimerHandler *next;
|
||||||
|
int nextDelay; /* 0 if it's one-shot */
|
||||||
|
} TimerHandler;
|
||||||
|
|
||||||
|
|
||||||
|
typedef struct IdleHandler {
|
||||||
|
WMCallback *callback;
|
||||||
|
void *clientData;
|
||||||
|
} IdleHandler;
|
||||||
|
|
||||||
|
|
||||||
|
typedef struct InputHandler {
|
||||||
|
WMInputProc *callback;
|
||||||
|
void *clientData;
|
||||||
|
int fd;
|
||||||
|
int mask;
|
||||||
|
} InputHandler;
|
||||||
|
|
||||||
|
|
||||||
|
/* queue of timer event handlers */
|
||||||
|
static TimerHandler *timerHandler=NULL;
|
||||||
|
|
||||||
|
static WMArray *idleHandler=NULL;
|
||||||
|
|
||||||
|
static WMArray *inputHandler=NULL;
|
||||||
|
|
||||||
|
#define timerPending() (timerHandler)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
static void
|
||||||
|
rightNow(struct timeval *tv)
|
||||||
|
{
|
||||||
|
X_GETTIMEOFDAY(tv);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* is t1 after t2 ? */
|
||||||
|
#define IS_AFTER(t1, t2) (((t1).tv_sec > (t2).tv_sec) || \
|
||||||
|
(((t1).tv_sec == (t2).tv_sec) \
|
||||||
|
&& ((t1).tv_usec > (t2).tv_usec)))
|
||||||
|
|
||||||
|
#define IS_ZERO(tv) (tv.tv_sec == 0 && tv.tv_usec == 0)
|
||||||
|
|
||||||
|
#define SET_ZERO(tv) tv.tv_sec = 0, tv.tv_usec = 0
|
||||||
|
|
||||||
|
static void
|
||||||
|
addmillisecs(struct timeval *tv, int milliseconds)
|
||||||
|
{
|
||||||
|
tv->tv_usec += milliseconds*1000;
|
||||||
|
|
||||||
|
tv->tv_sec += tv->tv_usec/1000000;
|
||||||
|
tv->tv_usec = tv->tv_usec%1000000;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static void
|
||||||
|
enqueueTimerHandler(TimerHandler *handler)
|
||||||
|
{
|
||||||
|
TimerHandler *tmp;
|
||||||
|
|
||||||
|
/* insert callback in queue, sorted by time left */
|
||||||
|
if (!timerHandler || !IS_AFTER(handler->when, timerHandler->when)) {
|
||||||
|
/* first in the queue */
|
||||||
|
handler->next = timerHandler;
|
||||||
|
timerHandler = handler;
|
||||||
|
} else {
|
||||||
|
tmp = timerHandler;
|
||||||
|
while (tmp->next && IS_AFTER(handler->when, tmp->next->when)) {
|
||||||
|
tmp = tmp->next;
|
||||||
|
}
|
||||||
|
handler->next = tmp->next;
|
||||||
|
tmp->next = handler;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static void
|
||||||
|
delayUntilNextTimerEvent(struct timeval *delay)
|
||||||
|
{
|
||||||
|
struct timeval now;
|
||||||
|
TimerHandler *handler;
|
||||||
|
|
||||||
|
handler = timerHandler;
|
||||||
|
while (handler && IS_ZERO(handler->when)) handler = handler->next;
|
||||||
|
|
||||||
|
if (!handler) {
|
||||||
|
/* The return value of this function is only valid if there _are_
|
||||||
|
timers active. */
|
||||||
|
delay->tv_sec = 0;
|
||||||
|
delay->tv_usec = 0;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
rightNow(&now);
|
||||||
|
if (IS_AFTER(now, handler->when)) {
|
||||||
|
delay->tv_sec = 0;
|
||||||
|
delay->tv_usec = 0;
|
||||||
|
} else {
|
||||||
|
delay->tv_sec = handler->when.tv_sec - now.tv_sec;
|
||||||
|
delay->tv_usec = handler->when.tv_usec - now.tv_usec;
|
||||||
|
if (delay->tv_usec < 0) {
|
||||||
|
delay->tv_usec += 1000000;
|
||||||
|
delay->tv_sec--;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
WMHandlerID
|
||||||
|
WMAddTimerHandler(int milliseconds, WMCallback *callback, void *cdata)
|
||||||
|
{
|
||||||
|
TimerHandler *handler;
|
||||||
|
|
||||||
|
handler = malloc(sizeof(TimerHandler));
|
||||||
|
if (!handler)
|
||||||
|
return NULL;
|
||||||
|
|
||||||
|
rightNow(&handler->when);
|
||||||
|
addmillisecs(&handler->when, milliseconds);
|
||||||
|
handler->callback = callback;
|
||||||
|
handler->clientData = cdata;
|
||||||
|
handler->nextDelay = 0;
|
||||||
|
|
||||||
|
enqueueTimerHandler(handler);
|
||||||
|
|
||||||
|
return handler;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
WMHandlerID
|
||||||
|
WMAddPersistentTimerHandler(int milliseconds, WMCallback *callback, void *cdata)
|
||||||
|
{
|
||||||
|
TimerHandler *handler = WMAddTimerHandler(milliseconds, callback, cdata);
|
||||||
|
|
||||||
|
if (handler != NULL)
|
||||||
|
handler->nextDelay = milliseconds;
|
||||||
|
|
||||||
|
return handler;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
void
|
||||||
|
WMDeleteTimerWithClientData(void *cdata)
|
||||||
|
{
|
||||||
|
TimerHandler *handler, *tmp;
|
||||||
|
|
||||||
|
if (!cdata || !timerHandler)
|
||||||
|
return;
|
||||||
|
|
||||||
|
tmp = timerHandler;
|
||||||
|
if (tmp->clientData==cdata) {
|
||||||
|
tmp->nextDelay = 0;
|
||||||
|
if (!IS_ZERO(tmp->when)) {
|
||||||
|
timerHandler = tmp->next;
|
||||||
|
wfree(tmp);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
while (tmp->next) {
|
||||||
|
if (tmp->next->clientData==cdata) {
|
||||||
|
handler = tmp->next;
|
||||||
|
handler->nextDelay = 0;
|
||||||
|
if (IS_ZERO(handler->when))
|
||||||
|
break;
|
||||||
|
tmp->next = handler->next;
|
||||||
|
wfree(handler);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
tmp = tmp->next;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
void
|
||||||
|
WMDeleteTimerHandler(WMHandlerID handlerID)
|
||||||
|
{
|
||||||
|
TimerHandler *tmp, *handler=(TimerHandler*)handlerID;
|
||||||
|
|
||||||
|
if (!handler || !timerHandler)
|
||||||
|
return;
|
||||||
|
|
||||||
|
tmp = timerHandler;
|
||||||
|
|
||||||
|
handler->nextDelay = 0;
|
||||||
|
|
||||||
|
if (IS_ZERO(handler->when))
|
||||||
|
return;
|
||||||
|
|
||||||
|
if (tmp==handler) {
|
||||||
|
timerHandler = handler->next;
|
||||||
|
wfree(handler);
|
||||||
|
} else {
|
||||||
|
while (tmp->next) {
|
||||||
|
if (tmp->next==handler) {
|
||||||
|
tmp->next=handler->next;
|
||||||
|
wfree(handler);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
tmp = tmp->next;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
WMHandlerID
|
||||||
|
WMAddIdleHandler(WMCallback *callback, void *cdata)
|
||||||
|
{
|
||||||
|
IdleHandler *handler;
|
||||||
|
|
||||||
|
handler = malloc(sizeof(IdleHandler));
|
||||||
|
if (!handler)
|
||||||
|
return NULL;
|
||||||
|
|
||||||
|
handler->callback = callback;
|
||||||
|
handler->clientData = cdata;
|
||||||
|
/* add handler at end of queue */
|
||||||
|
if (!idleHandler) {
|
||||||
|
idleHandler = WMCreateArrayWithDestructor(16, wfree);
|
||||||
|
}
|
||||||
|
WMAddToArray(idleHandler, handler);
|
||||||
|
|
||||||
|
return handler;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void
|
||||||
|
WMDeleteIdleHandler(WMHandlerID handlerID)
|
||||||
|
{
|
||||||
|
IdleHandler *handler = (IdleHandler*)handlerID;
|
||||||
|
|
||||||
|
if (!handler || !idleHandler)
|
||||||
|
return;
|
||||||
|
|
||||||
|
WMRemoveFromArray(idleHandler, handler);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
WMHandlerID
|
||||||
|
WMAddInputHandler(int fd, int condition, WMInputProc *proc, void *clientData)
|
||||||
|
{
|
||||||
|
InputHandler *handler;
|
||||||
|
|
||||||
|
handler = wmalloc(sizeof(InputHandler));
|
||||||
|
|
||||||
|
handler->fd = fd;
|
||||||
|
handler->mask = condition;
|
||||||
|
handler->callback = proc;
|
||||||
|
handler->clientData = clientData;
|
||||||
|
|
||||||
|
if (!inputHandler)
|
||||||
|
inputHandler = WMCreateArrayWithDestructor(16, wfree);
|
||||||
|
WMAddToArray(inputHandler, handler);
|
||||||
|
|
||||||
|
return handler;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
void
|
||||||
|
WMDeleteInputHandler(WMHandlerID handlerID)
|
||||||
|
{
|
||||||
|
InputHandler *handler = (InputHandler*)handlerID;
|
||||||
|
|
||||||
|
if (!handler || !inputHandler)
|
||||||
|
return;
|
||||||
|
|
||||||
|
WMRemoveFromArray(inputHandler, handler);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Bool
|
||||||
|
W_CheckIdleHandlers(void)
|
||||||
|
{
|
||||||
|
IdleHandler *handler;
|
||||||
|
WMArray *handlerCopy;
|
||||||
|
WMArrayIterator iter;
|
||||||
|
|
||||||
|
if (!idleHandler || WMGetArrayItemCount(idleHandler)==0) {
|
||||||
|
W_FlushIdleNotificationQueue();
|
||||||
|
/* make sure an observer in queue didn't added an idle handler */
|
||||||
|
return (idleHandler!=NULL && WMGetArrayItemCount(idleHandler)>0);
|
||||||
|
}
|
||||||
|
|
||||||
|
handlerCopy = WMDuplicateArray(idleHandler);
|
||||||
|
|
||||||
|
WM_ITERATE_ARRAY(handlerCopy, handler, iter) {
|
||||||
|
/* check if the handler still exist or was removed by a callback */
|
||||||
|
if (WMGetFirstInArray(idleHandler, handler) == WANotFound)
|
||||||
|
continue;
|
||||||
|
|
||||||
|
(*handler->callback)(handler->clientData);
|
||||||
|
WMDeleteIdleHandler(handler);
|
||||||
|
}
|
||||||
|
|
||||||
|
WMFreeArray(handlerCopy);
|
||||||
|
|
||||||
|
W_FlushIdleNotificationQueue();
|
||||||
|
|
||||||
|
/* this is not necesarrily False, because one handler can re-add itself */
|
||||||
|
return (WMGetArrayItemCount(idleHandler)>0);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
void
|
||||||
|
W_CheckTimerHandlers(void)
|
||||||
|
{
|
||||||
|
TimerHandler *handler;
|
||||||
|
struct timeval now;
|
||||||
|
|
||||||
|
if (!timerHandler) {
|
||||||
|
W_FlushASAPNotificationQueue();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
rightNow(&now);
|
||||||
|
|
||||||
|
handler = timerHandler;
|
||||||
|
while (handler && IS_AFTER(now, handler->when)) {
|
||||||
|
if (!IS_ZERO(handler->when)) {
|
||||||
|
SET_ZERO(handler->when);
|
||||||
|
(*handler->callback)(handler->clientData);
|
||||||
|
}
|
||||||
|
handler = handler->next;
|
||||||
|
}
|
||||||
|
|
||||||
|
while (timerHandler && IS_ZERO(timerHandler->when)) {
|
||||||
|
handler = timerHandler;
|
||||||
|
timerHandler = timerHandler->next;
|
||||||
|
|
||||||
|
if (handler->nextDelay > 0) {
|
||||||
|
handler->when = now;
|
||||||
|
addmillisecs(&handler->when, handler->nextDelay);
|
||||||
|
enqueueTimerHandler(handler);
|
||||||
|
} else {
|
||||||
|
wfree(handler);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
W_FlushASAPNotificationQueue();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/*
|
||||||
|
* This functions will handle input events on all registered file descriptors.
|
||||||
|
* Input:
|
||||||
|
* - waitForInput - True if we want the function to wait until an event
|
||||||
|
* appears on a file descriptor we watch, False if we
|
||||||
|
* want the function to immediately return if there is
|
||||||
|
* no data available on the file descriptors we watch.
|
||||||
|
* - inputfd - Extra input file descriptor to watch for input.
|
||||||
|
* This is only used when called from wevent.c to watch
|
||||||
|
* on ConnectionNumber(dpy) to avoid blocking of X events
|
||||||
|
* if we wait for input from other file handlers.
|
||||||
|
* Output:
|
||||||
|
* if waitForInput is False, the function will return False if there are no
|
||||||
|
* input handlers registered, or if there is no data
|
||||||
|
* available on the registered ones, and will return True
|
||||||
|
* if there is at least one input handler that has data
|
||||||
|
* available.
|
||||||
|
* if waitForInput is True, the function will return False if there are no
|
||||||
|
* input handlers registered, else it will block until an
|
||||||
|
* event appears on one of the file descriptors it watches
|
||||||
|
* and then it will return True.
|
||||||
|
*
|
||||||
|
* If the retured value is True, the input handlers for the corresponding file
|
||||||
|
* descriptors are also called.
|
||||||
|
*
|
||||||
|
* Parametersshould be passed like this:
|
||||||
|
* - from wevent.c:
|
||||||
|
* waitForInput - apropriate value passed by the function who called us
|
||||||
|
* inputfd = ConnectionNumber(dpy)
|
||||||
|
* - from wutil.c:
|
||||||
|
* waitForInput - apropriate value passed by the function who called us
|
||||||
|
* inputfd = -1
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
Bool
|
||||||
|
W_HandleInputEvents(Bool waitForInput, int inputfd)
|
||||||
|
{
|
||||||
|
#if defined(HAVE_POLL) && defined(HAVE_POLL_H) && !defined(HAVE_SELECT)
|
||||||
|
struct poll fd *fds;
|
||||||
|
InputHandler *handler;
|
||||||
|
int count, timeout, nfds, i, extrafd;
|
||||||
|
|
||||||
|
extrafd = (inputfd < 0) ? 0 : 1;
|
||||||
|
|
||||||
|
if (inputHandler)
|
||||||
|
nfds = WMGetArrayItemCount(inputHandler);
|
||||||
|
else
|
||||||
|
nfds = 0;
|
||||||
|
|
||||||
|
if (!extrafd && nfds==0) {
|
||||||
|
W_FlushASAPNotificationQueue();
|
||||||
|
return False;
|
||||||
|
}
|
||||||
|
|
||||||
|
fds = wmalloc((nfds+extrafd) * sizeof(struct pollfd));
|
||||||
|
if (extrafd) {
|
||||||
|
/* put this to the end of array to avoid using ranges from 1 to nfds+1 */
|
||||||
|
fds[nfds].fd = inputfd;
|
||||||
|
fds[nfds].events = POLLIN;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* use WM_ITERATE_ARRAY() here */
|
||||||
|
for (i = 0; i<nfds; i++) {
|
||||||
|
handler = WMGetFromArray(inputHandler, i);
|
||||||
|
fds[i].fd = handler->fd;
|
||||||
|
fds[i].events = 0;
|
||||||
|
if (handler->mask & WIReadMask)
|
||||||
|
fds[i].events |= POLLIN;
|
||||||
|
|
||||||
|
if (handler->mask & WIWriteMask)
|
||||||
|
fds[i].events |= POLLOUT;
|
||||||
|
|
||||||
|
#if 0 /* FIXME */
|
||||||
|
if (handler->mask & WIExceptMask)
|
||||||
|
FD_SET(handler->fd, &eset);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Setup the timeout to the estimated time until the
|
||||||
|
* next timer expires.
|
||||||
|
*/
|
||||||
|
if (!waitForInput) {
|
||||||
|
timeout = 0;
|
||||||
|
} else if (timerPending()) {
|
||||||
|
struct timeval tv;
|
||||||
|
delayUntilNextTimerEvent(&tv);
|
||||||
|
timeout = tv.tv_sec * 1000 + tv.tv_usec / 1000;
|
||||||
|
} else {
|
||||||
|
timeout = -1;
|
||||||
|
}
|
||||||
|
|
||||||
|
count = poll(fds, nfds+extrafd, timeout);
|
||||||
|
|
||||||
|
if (count>0 && nfds>0) {
|
||||||
|
WMArray *handlerCopy = WMDuplicateArray(inputHandler);
|
||||||
|
int mask;
|
||||||
|
|
||||||
|
/* use WM_ITERATE_ARRAY() here */
|
||||||
|
for (i=0; i<nfds; i++) {
|
||||||
|
handler = WMGetFromArray(handlerCopy, i);
|
||||||
|
/* check if the handler still exist or was removed by a callback */
|
||||||
|
if (WMGetFirstInArray(inputHandler, handler) == WANotFound)
|
||||||
|
continue;
|
||||||
|
|
||||||
|
mask = 0;
|
||||||
|
|
||||||
|
if ((handler->mask & WIReadMask) &&
|
||||||
|
(fds[i].revents & (POLLIN|POLLRDNORM|POLLRDBAND|POLLPRI)))
|
||||||
|
mask |= WIReadMask;
|
||||||
|
|
||||||
|
if ((handler->mask & WIWriteMask) &&
|
||||||
|
(fds[i].revents & (POLLOUT | POLLWRBAND)))
|
||||||
|
mask |= WIWriteMask;
|
||||||
|
|
||||||
|
if ((handler->mask & WIExceptMask) &&
|
||||||
|
(fds[i].revents & (POLLHUP | POLLNVAL | POLLERR)))
|
||||||
|
mask |= WIExceptMask;
|
||||||
|
|
||||||
|
if (mask!=0 && handler->callback) {
|
||||||
|
(*handler->callback)(handler->fd, mask,
|
||||||
|
handler->clientData);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
WMFreeArray(handlerCopy);
|
||||||
|
}
|
||||||
|
|
||||||
|
wfree(fds);
|
||||||
|
|
||||||
|
W_FlushASAPNotificationQueue();
|
||||||
|
|
||||||
|
return (count > 0);
|
||||||
|
#else
|
||||||
|
#ifdef HAVE_SELECT
|
||||||
|
struct timeval timeout;
|
||||||
|
struct timeval *timeoutPtr;
|
||||||
|
fd_set rset, wset, eset;
|
||||||
|
int maxfd, nfds, i;
|
||||||
|
int count;
|
||||||
|
InputHandler *handler;
|
||||||
|
|
||||||
|
if (inputHandler)
|
||||||
|
nfds = WMGetArrayItemCount(inputHandler);
|
||||||
|
else
|
||||||
|
nfds = 0;
|
||||||
|
|
||||||
|
if (inputfd<0 && nfds==0) {
|
||||||
|
W_FlushASAPNotificationQueue();
|
||||||
|
return False;
|
||||||
|
}
|
||||||
|
|
||||||
|
FD_ZERO(&rset);
|
||||||
|
FD_ZERO(&wset);
|
||||||
|
FD_ZERO(&eset);
|
||||||
|
|
||||||
|
if (inputfd < 0) {
|
||||||
|
maxfd = 0;
|
||||||
|
} else {
|
||||||
|
FD_SET(inputfd, &rset);
|
||||||
|
maxfd = inputfd;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* use WM_ITERATE_ARRAY() here */
|
||||||
|
for (i=0; i<nfds; i++) {
|
||||||
|
handler = WMGetFromArray(inputHandler, i);
|
||||||
|
if (handler->mask & WIReadMask)
|
||||||
|
FD_SET(handler->fd, &rset);
|
||||||
|
|
||||||
|
if (handler->mask & WIWriteMask)
|
||||||
|
FD_SET(handler->fd, &wset);
|
||||||
|
|
||||||
|
if (handler->mask & WIExceptMask)
|
||||||
|
FD_SET(handler->fd, &eset);
|
||||||
|
|
||||||
|
if (maxfd < handler->fd)
|
||||||
|
maxfd = handler->fd;
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Setup the timeout to the estimated time until the
|
||||||
|
* next timer expires.
|
||||||
|
*/
|
||||||
|
if (!waitForInput) {
|
||||||
|
SET_ZERO(timeout);
|
||||||
|
timeoutPtr = &timeout;
|
||||||
|
} else if (timerPending()) {
|
||||||
|
delayUntilNextTimerEvent(&timeout);
|
||||||
|
timeoutPtr = &timeout;
|
||||||
|
} else {
|
||||||
|
timeoutPtr = (struct timeval*)0;
|
||||||
|
}
|
||||||
|
|
||||||
|
count = select(1 + maxfd, &rset, &wset, &eset, timeoutPtr);
|
||||||
|
|
||||||
|
if (count>0 && nfds>0) {
|
||||||
|
WMArray *handlerCopy = WMDuplicateArray(inputHandler);
|
||||||
|
int mask;
|
||||||
|
|
||||||
|
/* use WM_ITERATE_ARRAY() here */
|
||||||
|
for (i=0; i<nfds; i++) {
|
||||||
|
handler = WMGetFromArray(handlerCopy, i);
|
||||||
|
/* check if the handler still exist or was removed by a callback */
|
||||||
|
if (WMGetFirstInArray(inputHandler, handler) == WANotFound)
|
||||||
|
continue;
|
||||||
|
|
||||||
|
mask = 0;
|
||||||
|
|
||||||
|
if ((handler->mask & WIReadMask) && FD_ISSET(handler->fd, &rset))
|
||||||
|
mask |= WIReadMask;
|
||||||
|
|
||||||
|
if ((handler->mask & WIWriteMask) && FD_ISSET(handler->fd, &wset))
|
||||||
|
mask |= WIWriteMask;
|
||||||
|
|
||||||
|
if ((handler->mask & WIExceptMask) && FD_ISSET(handler->fd, &eset))
|
||||||
|
mask |= WIExceptMask;
|
||||||
|
|
||||||
|
if (mask!=0 && handler->callback) {
|
||||||
|
(*handler->callback)(handler->fd, mask,
|
||||||
|
handler->clientData);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
WMFreeArray(handlerCopy);
|
||||||
|
}
|
||||||
|
|
||||||
|
W_FlushASAPNotificationQueue();
|
||||||
|
|
||||||
|
return (count > 0);
|
||||||
|
#else /* not HAVE_SELECT, not HAVE_POLL */
|
||||||
|
# error Neither select nor poll. You lose.
|
||||||
|
#endif /* HAVE_SELECT */
|
||||||
|
#endif /* HAVE_POLL */
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -148,7 +148,7 @@ WMResetHashTable(WMHashTable *table)
|
|||||||
item = table->table[i];
|
item = table->table[i];
|
||||||
while (item) {
|
while (item) {
|
||||||
tmp = item->next;
|
tmp = item->next;
|
||||||
RELKEY(table, item);
|
RELKEY(table, item->key);
|
||||||
wfree(item);
|
wfree(item);
|
||||||
item = tmp;
|
item = tmp;
|
||||||
}
|
}
|
||||||
@@ -185,6 +185,12 @@ WMFreeHashTable(WMHashTable *table)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
unsigned
|
||||||
|
WMCountHashTable(WMHashTable *table)
|
||||||
|
{
|
||||||
|
return table->itemCount;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
void*
|
void*
|
||||||
WMHashGet(WMHashTable *table, const void *key)
|
WMHashGet(WMHashTable *table, const void *key)
|
||||||
@@ -217,6 +223,43 @@ WMHashGet(WMHashTable *table, const void *key)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Bool
|
||||||
|
WMHashGetItemAndKey(WMHashTable *table, const void *key,
|
||||||
|
void **retItem, void **retKey)
|
||||||
|
{
|
||||||
|
unsigned h;
|
||||||
|
HashItem *item;
|
||||||
|
|
||||||
|
h = HASH(table, key);
|
||||||
|
item = table->table[h];
|
||||||
|
|
||||||
|
if (table->callbacks.keyIsEqual) {
|
||||||
|
while (item) {
|
||||||
|
if ((*table->callbacks.keyIsEqual)(key, item->key)) {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
item = item->next;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
while (item) {
|
||||||
|
if (key == item->key) {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
item = item->next;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (item) {
|
||||||
|
if (retKey)
|
||||||
|
*retKey = (void*)item->key;
|
||||||
|
if (retItem)
|
||||||
|
*retItem = (void*)item->data;
|
||||||
|
return True;
|
||||||
|
} else {
|
||||||
|
return False;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
void*
|
void*
|
||||||
WMHashInsert(WMHashTable *table, const void *key, const void *data)
|
WMHashInsert(WMHashTable *table, const void *key, const void *data)
|
||||||
@@ -361,10 +404,61 @@ WMNextHashEnumeratorItem(WMHashEnumerator *enumerator)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
unsigned
|
void*
|
||||||
WMCountHashTable(WMHashTable *table)
|
WMNextHashEnumeratorKey(WMHashEnumerator *enumerator)
|
||||||
{
|
{
|
||||||
return table->itemCount;
|
const void *key = NULL;
|
||||||
|
|
||||||
|
/* this assumes the table doesn't change between
|
||||||
|
* WMEnumerateHashTable() and WMNextHashEnumeratorKey() calls */
|
||||||
|
|
||||||
|
if (enumerator->nextItem==NULL) {
|
||||||
|
HashTable *table = enumerator->table;
|
||||||
|
while (++enumerator->index < table->size) {
|
||||||
|
if (table->table[enumerator->index]!=NULL) {
|
||||||
|
enumerator->nextItem = table->table[enumerator->index];
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (enumerator->nextItem) {
|
||||||
|
key = ((HashItem*)enumerator->nextItem)->key;
|
||||||
|
enumerator->nextItem = ((HashItem*)enumerator->nextItem)->next;
|
||||||
|
}
|
||||||
|
|
||||||
|
return (void*)key;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Bool
|
||||||
|
WMNextHashEnumeratorItemAndKey(WMHashEnumerator *enumerator,
|
||||||
|
void **item, void **key)
|
||||||
|
{
|
||||||
|
/* this assumes the table doesn't change between
|
||||||
|
* WMEnumerateHashTable() and WMNextHashEnumeratorItemAndKey() calls */
|
||||||
|
|
||||||
|
if (enumerator->nextItem==NULL) {
|
||||||
|
HashTable *table = enumerator->table;
|
||||||
|
while (++enumerator->index < table->size) {
|
||||||
|
if (table->table[enumerator->index]!=NULL) {
|
||||||
|
enumerator->nextItem = table->table[enumerator->index];
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (enumerator->nextItem) {
|
||||||
|
if (item)
|
||||||
|
*item = (void*)((HashItem*)enumerator->nextItem)->data;
|
||||||
|
if (key)
|
||||||
|
*key = (void*)((HashItem*)enumerator->nextItem)->key;
|
||||||
|
enumerator->nextItem = ((HashItem*)enumerator->nextItem)->next;
|
||||||
|
|
||||||
|
return True;
|
||||||
|
}
|
||||||
|
|
||||||
|
return False;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
27
WINGs/host.c
27
WINGs/host.c
@@ -1,7 +1,7 @@
|
|||||||
/*
|
/*
|
||||||
* WINGs WMHost function library
|
* WINGs WMHost function library
|
||||||
*
|
*
|
||||||
* Copyright (c) 1999-2000 Dan Pascu
|
* Copyright (c) 1999-2003 Dan Pascu
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* 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
|
* it under the terms of the GNU General Public License as published by
|
||||||
@@ -19,7 +19,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
#include "../src/config.h"
|
#include "wconfig.h"
|
||||||
|
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
@@ -111,7 +111,7 @@ WMGetCurrentHost()
|
|||||||
char name[W_MAXHOSTNAMELEN+1];
|
char name[W_MAXHOSTNAMELEN+1];
|
||||||
|
|
||||||
if (gethostname(name, W_MAXHOSTNAMELEN) < 0) {
|
if (gethostname(name, W_MAXHOSTNAMELEN) < 0) {
|
||||||
wsyserror("Cannot get current host name");
|
wsyserror(_("Cannot get current host name"));
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -193,8 +193,6 @@ WMRetainHost(WMHost *hPtr)
|
|||||||
void
|
void
|
||||||
WMReleaseHost(WMHost *hPtr)
|
WMReleaseHost(WMHost *hPtr)
|
||||||
{
|
{
|
||||||
int i;
|
|
||||||
|
|
||||||
hPtr->refCount--;
|
hPtr->refCount--;
|
||||||
|
|
||||||
if (hPtr->refCount > 0)
|
if (hPtr->refCount > 0)
|
||||||
@@ -215,7 +213,7 @@ WMReleaseHost(WMHost *hPtr)
|
|||||||
void
|
void
|
||||||
WMSetHostCacheEnabled(Bool flag)
|
WMSetHostCacheEnabled(Bool flag)
|
||||||
{
|
{
|
||||||
hostCacheEnabled = flag;
|
hostCacheEnabled = ((flag==0) ? 0 : 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -248,11 +246,18 @@ WMFlushHostCache()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static int
|
||||||
|
matchAddress(void *item, void *cdata)
|
||||||
|
{
|
||||||
|
return (strcmp((char*) item, (char*) cdata)==0);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
Bool
|
Bool
|
||||||
WMIsHostEqualToHost(WMHost* hPtr, WMHost* aPtr)
|
WMIsHostEqualToHost(WMHost* hPtr, WMHost* aPtr)
|
||||||
{
|
{
|
||||||
int i, j;
|
char *adr;
|
||||||
char *adr1, *adr2;
|
int i;
|
||||||
|
|
||||||
wassertrv(hPtr!=NULL && aPtr!=NULL, False);
|
wassertrv(hPtr!=NULL && aPtr!=NULL, False);
|
||||||
|
|
||||||
@@ -260,10 +265,8 @@ WMIsHostEqualToHost(WMHost* hPtr, WMHost* aPtr)
|
|||||||
return True;
|
return True;
|
||||||
|
|
||||||
for (i=0; i<WMGetArrayItemCount(aPtr->addresses); i++) {
|
for (i=0; i<WMGetArrayItemCount(aPtr->addresses); i++) {
|
||||||
adr1 = WMGetFromArray(aPtr->addresses, i);
|
adr = WMGetFromArray(aPtr->addresses, i);
|
||||||
for (j=0; j<WMGetArrayItemCount(hPtr->addresses); j++) {
|
if (WMFindInArray(hPtr->addresses, matchAddress, adr) != WANotFound) {
|
||||||
adr2 = WMGetFromArray(hPtr->addresses, j);
|
|
||||||
if (strcmp(adr1, adr2)==0)
|
|
||||||
return True;
|
return True;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
/*
|
/*
|
||||||
* Window Maker miscelaneous function library
|
* Window Maker miscelaneous function library
|
||||||
*
|
*
|
||||||
* Copyright (c) 1997 Alfredo K. Kojima
|
* Copyright (c) 1997-2003 Alfredo K. Kojima
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* 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
|
* it under the terms of the GNU General Public License as published by
|
||||||
@@ -220,45 +220,3 @@ wrelease(void *ptr)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
char*
|
|
||||||
wstrdup(char *str)
|
|
||||||
{
|
|
||||||
assert(str!=NULL);
|
|
||||||
|
|
||||||
return strcpy(wmalloc(strlen(str)+1), str);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
char*
|
|
||||||
wstrconcat(char *str1, char *str2)
|
|
||||||
{
|
|
||||||
char *str;
|
|
||||||
|
|
||||||
if (!str1)
|
|
||||||
return wstrdup(str2);
|
|
||||||
else if (!str2)
|
|
||||||
return wstrdup(str1);
|
|
||||||
|
|
||||||
str = wmalloc(strlen(str1)+strlen(str2)+1);
|
|
||||||
strcpy(str, str1);
|
|
||||||
strcat(str, str2);
|
|
||||||
|
|
||||||
return str;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
char*
|
|
||||||
wstrappend(char *dst, char *src)
|
|
||||||
{
|
|
||||||
if (!dst)
|
|
||||||
return wstrdup(src);
|
|
||||||
else if (!src || *src==0)
|
|
||||||
return dst;
|
|
||||||
|
|
||||||
dst = wrealloc(dst, strlen(dst)+strlen(src)+1);
|
|
||||||
strcat(dst, src);
|
|
||||||
|
|
||||||
return dst;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
18
WINGs/misc.c
Normal file
18
WINGs/misc.c
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
|
||||||
|
/* Miscelaneous helper functions */
|
||||||
|
|
||||||
|
#include "WINGsP.h"
|
||||||
|
|
||||||
|
|
||||||
|
WMRange
|
||||||
|
wmkrange(int start, int count)
|
||||||
|
{
|
||||||
|
WMRange range;
|
||||||
|
|
||||||
|
range.position = start;
|
||||||
|
range.count = count;
|
||||||
|
|
||||||
|
return range;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -385,8 +385,8 @@ WMPostNotificationName(const char *name, void *object, void *clientData)
|
|||||||
|
|
||||||
|
|
||||||
typedef struct W_NotificationQueue {
|
typedef struct W_NotificationQueue {
|
||||||
WMBag *asapQueue;
|
WMArray *asapQueue;
|
||||||
WMBag *idleQueue;
|
WMArray *idleQueue;
|
||||||
|
|
||||||
struct W_NotificationQueue *next;
|
struct W_NotificationQueue *next;
|
||||||
} NotificationQueue;
|
} NotificationQueue;
|
||||||
@@ -415,8 +415,10 @@ WMCreateNotificationQueue(void)
|
|||||||
|
|
||||||
queue = wmalloc(sizeof(NotificationQueue));
|
queue = wmalloc(sizeof(NotificationQueue));
|
||||||
|
|
||||||
queue->asapQueue = WMCreateBag(8);
|
queue->asapQueue =
|
||||||
queue->idleQueue = WMCreateBag(8);
|
WMCreateArrayWithDestructor(8, (WMFreeDataProc*)WMReleaseNotification);
|
||||||
|
queue->idleQueue =
|
||||||
|
WMCreateArrayWithDestructor(8, (WMFreeDataProc*)WMReleaseNotification);
|
||||||
queue->next = notificationQueueList;
|
queue->next = notificationQueueList;
|
||||||
|
|
||||||
notificationQueueList = queue;
|
notificationQueueList = queue;
|
||||||
@@ -435,62 +437,50 @@ WMEnqueueNotification(WMNotificationQueue *queue, WMNotification *notification,
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
#define NOTIF ((WMNotification*)cdata)
|
||||||
|
#define ITEM ((WMNotification*)item)
|
||||||
|
|
||||||
|
static int
|
||||||
|
matchSenderAndName(void *item, void *cdata)
|
||||||
|
{
|
||||||
|
return (NOTIF->object==ITEM->object && strcmp(NOTIF->name, ITEM->name)==0);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static int
|
||||||
|
matchSender(void *item, void *cdata)
|
||||||
|
{
|
||||||
|
return (NOTIF->object == ITEM->object);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static int
|
||||||
|
matchName(void *item, void *cdata)
|
||||||
|
{
|
||||||
|
return (strcmp(NOTIF->name, ITEM->name)==0);
|
||||||
|
}
|
||||||
|
|
||||||
|
#undef NOTIF
|
||||||
|
#undef ITEM
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
WMDequeueNotificationMatching(WMNotificationQueue *queue,
|
WMDequeueNotificationMatching(WMNotificationQueue *queue,
|
||||||
WMNotification *notification, unsigned mask)
|
WMNotification *notification, unsigned mask)
|
||||||
{
|
{
|
||||||
WMBagIterator i;
|
WMMatchDataProc *matchFunc;
|
||||||
WMNotification *tmp;
|
|
||||||
|
|
||||||
if ((mask & WNCOnName) && (mask & WNCOnSender)) {
|
if ((mask & WNCOnName) && (mask & WNCOnSender))
|
||||||
WM_ITERATE_BAG(queue->asapQueue, tmp, i) {
|
matchFunc = matchSenderAndName;
|
||||||
if (notification->object == tmp->object &&
|
else if (mask & WNCOnName)
|
||||||
strcmp(notification->name, tmp->name) == 0) {
|
matchFunc = matchName;
|
||||||
WMRemoveFromBag(queue->asapQueue, tmp);
|
else if (mask & WNCOnSender)
|
||||||
WMReleaseNotification(tmp);
|
matchFunc = matchSender;
|
||||||
break;
|
else
|
||||||
}
|
return;
|
||||||
}
|
|
||||||
WM_ITERATE_BAG(queue->idleQueue, tmp, i) {
|
WMRemoveFromArrayMatching(queue->asapQueue, matchFunc, notification);
|
||||||
if (notification->object == tmp->object &&
|
WMRemoveFromArrayMatching(queue->idleQueue, matchFunc, notification);
|
||||||
strcmp(notification->name, tmp->name) == 0) {
|
|
||||||
WMRemoveFromBag(queue->idleQueue, tmp);
|
|
||||||
WMReleaseNotification(tmp);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} else if (mask & WNCOnName) {
|
|
||||||
WM_ITERATE_BAG(queue->asapQueue, tmp, i) {
|
|
||||||
if (strcmp(notification->name, tmp->name) == 0) {
|
|
||||||
WMRemoveFromBag(queue->asapQueue, tmp);
|
|
||||||
WMReleaseNotification(tmp);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
WM_ITERATE_BAG(queue->idleQueue, tmp, i) {
|
|
||||||
if (strcmp(notification->name, tmp->name) == 0) {
|
|
||||||
WMRemoveFromBag(queue->idleQueue, tmp);
|
|
||||||
WMReleaseNotification(tmp);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} else if (mask & WNCOnSender) {
|
|
||||||
WM_ITERATE_BAG(queue->asapQueue, tmp, i) {
|
|
||||||
if (notification->object == tmp->object) {
|
|
||||||
WMRemoveFromBag(queue->asapQueue, tmp);
|
|
||||||
WMReleaseNotification(tmp);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
WM_ITERATE_BAG(queue->idleQueue, tmp, i) {
|
|
||||||
if (notification->object == tmp->object) {
|
|
||||||
WMRemoveFromBag(queue->idleQueue, tmp);
|
|
||||||
WMReleaseNotification(tmp);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -510,11 +500,11 @@ WMEnqueueCoalesceNotification(WMNotificationQueue *queue,
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
case WMPostASAP:
|
case WMPostASAP:
|
||||||
WMPutInBag(queue->asapQueue, notification);
|
WMAddToArray(queue->asapQueue, notification);
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case WMPostWhenIdle:
|
case WMPostWhenIdle:
|
||||||
WMPutInBag(queue->idleQueue, notification);
|
WMAddToArray(queue->idleQueue, notification);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -526,12 +516,9 @@ W_FlushASAPNotificationQueue()
|
|||||||
WMNotificationQueue *queue = notificationQueueList;
|
WMNotificationQueue *queue = notificationQueueList;
|
||||||
|
|
||||||
while (queue) {
|
while (queue) {
|
||||||
while (WMGetBagItemCount(queue->asapQueue)) {
|
while (WMGetArrayItemCount(queue->asapQueue)) {
|
||||||
WMNotification *tmp = WMGetFromBag(queue->asapQueue, 0);
|
WMPostNotification(WMGetFromArray(queue->asapQueue, 0));
|
||||||
|
WMDeleteFromArray(queue->asapQueue, 0);
|
||||||
WMPostNotification(tmp);
|
|
||||||
WMReleaseNotification(tmp);
|
|
||||||
WMDeleteFromBag(queue->asapQueue, 0);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
queue = queue->next;
|
queue = queue->next;
|
||||||
@@ -545,12 +532,9 @@ W_FlushIdleNotificationQueue()
|
|||||||
WMNotificationQueue *queue = notificationQueueList;
|
WMNotificationQueue *queue = notificationQueueList;
|
||||||
|
|
||||||
while (queue) {
|
while (queue) {
|
||||||
while (WMGetBagItemCount(queue->idleQueue)) {
|
while (WMGetArrayItemCount(queue->idleQueue)) {
|
||||||
WMNotification *tmp = WMGetFromBag(queue->idleQueue, 0);
|
WMPostNotification(WMGetFromArray(queue->idleQueue, 0));
|
||||||
|
WMDeleteFromArray(queue->idleQueue, 0);
|
||||||
WMPostNotification(tmp);
|
|
||||||
WMReleaseNotification(tmp);
|
|
||||||
WMDeleteFromBag(queue->idleQueue, 0);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
queue = queue->next;
|
queue = queue->next;
|
||||||
|
|||||||
4
WINGs/po/.cvsignore
Normal file
4
WINGs/po/.cvsignore
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
Makefile Makefile.in
|
||||||
|
.psrc .inslog2 tca.map tca.log pchdir *.rpt
|
||||||
|
*.pot
|
||||||
|
*.mo
|
||||||
52
WINGs/po/Makefile.am
Normal file
52
WINGs/po/Makefile.am
Normal file
@@ -0,0 +1,52 @@
|
|||||||
|
nlsdir = $(NLSDIR)
|
||||||
|
|
||||||
|
CATALOGS = @WINGSMOFILES@
|
||||||
|
|
||||||
|
CLEANFILES = $(CATALOGS) WINGs.pot
|
||||||
|
|
||||||
|
EXTRA_DIST = bg.po ca.po cs.po de.po fr.po sk.po
|
||||||
|
|
||||||
|
POTFILES = \
|
||||||
|
$(top_builddir)/WINGs/connection.c \
|
||||||
|
$(top_builddir)/WINGs/error.c \
|
||||||
|
$(top_builddir)/WINGs/findfile.c \
|
||||||
|
$(top_builddir)/WINGs/host.c \
|
||||||
|
$(top_builddir)/WINGs/proplist.c \
|
||||||
|
$(top_builddir)/WINGs/userdefaults.c \
|
||||||
|
$(top_builddir)/WINGs/wcolor.c \
|
||||||
|
$(top_builddir)/WINGs/wcolorpanel.c \
|
||||||
|
$(top_builddir)/WINGs/wfilepanel.c \
|
||||||
|
$(top_builddir)/WINGs/wfont.c \
|
||||||
|
$(top_builddir)/WINGs/wfontpanel.c \
|
||||||
|
$(top_builddir)/WINGs/widgets.c \
|
||||||
|
$(top_builddir)/WINGs/wruler.c
|
||||||
|
|
||||||
|
SUFFIXES = .po .mo
|
||||||
|
|
||||||
|
.po.mo:
|
||||||
|
msgfmt -o $@ $<
|
||||||
|
|
||||||
|
|
||||||
|
all-local: $(CATALOGS)
|
||||||
|
|
||||||
|
WINGs.pot: $(POTFILES)
|
||||||
|
xgettext --default-domain=WINGs \
|
||||||
|
--add-comments --keyword=_ $(POTFILES)
|
||||||
|
if cmp -s WINGs.po WINGs.pot; then \
|
||||||
|
rm -f WINGs.po; \
|
||||||
|
else \
|
||||||
|
mv -f WINGs.po WINGs.pot; \
|
||||||
|
fi
|
||||||
|
|
||||||
|
install-data-local: $(CATALOGS)
|
||||||
|
$(mkinstalldirs) $(DESTDIR)$(nlsdir)
|
||||||
|
chmod 755 $(DESTDIR)$(nlsdir)
|
||||||
|
for n in $(CATALOGS) __DuMmY ; do \
|
||||||
|
if test "$$n" -a "$$n" != "__DuMmY" ; then \
|
||||||
|
l=`basename $$n .mo`; \
|
||||||
|
$(mkinstalldirs) $(DESTDIR)$(nlsdir)/$$l/LC_MESSAGES; \
|
||||||
|
chmod 755 $(DESTDIR)$(nlsdir)/$$l; \
|
||||||
|
chmod 755 $(DESTDIR)$(nlsdir)/$$l/LC_MESSAGES; \
|
||||||
|
$(INSTALL_DATA) -m 644 $$n $(DESTDIR)$(nlsdir)/$$l/LC_MESSAGES/WINGs.mo; \
|
||||||
|
fi; \
|
||||||
|
done
|
||||||
19
WINGs/po/README
Normal file
19
WINGs/po/README
Normal file
@@ -0,0 +1,19 @@
|
|||||||
|
|
||||||
|
Instructions for translating po files can be found in the po/README directory
|
||||||
|
in the top of the WindowMaker source tree.
|
||||||
|
|
||||||
|
All files are in UTF-8
|
||||||
|
|
||||||
|
File Language Note Current Maintainer
|
||||||
|
------------------------------------------------------------------------------
|
||||||
|
ca.po Catalan Ernest Adrogué <eadrogue@gmx.net>
|
||||||
|
cs.po Czech Jiri Hnidek <Jiri.Hnidek@vslib.cz
|
||||||
|
de.po German Guido Scholz <guido.scholz@bayernline.de>
|
||||||
|
fr.po French Emmanuel Benoit <tseeker@neptune.fr>
|
||||||
|
Antoine Hulin <antoine@origan.fdn.org>
|
||||||
|
sk.po Slovak Jan 'judas' Tomka <judas@linux.sk>
|
||||||
|
bg.po Bulgarian Anton Zinoviev <zinoviev@debian.org>
|
||||||
|
|
||||||
|
Notes
|
||||||
|
-----
|
||||||
|
|
||||||
660
WINGs/po/bg.po
Normal file
660
WINGs/po/bg.po
Normal file
@@ -0,0 +1,660 @@
|
|||||||
|
# Message catalog for WINGs
|
||||||
|
# Copyright (C) 2003 Free Software Foundation, Inc.
|
||||||
|
# Anton Zinoviev <zinoviev@debian.org>, 2003
|
||||||
|
#
|
||||||
|
msgid ""
|
||||||
|
msgstr ""
|
||||||
|
"Project-Id-Version: WINGs 0.80.0\n"
|
||||||
|
"POT-Creation-Date: 2003-02-08 21:42+0200\n"
|
||||||
|
"PO-Revision-Date: 2003-02-09 12:10+0200\n"
|
||||||
|
"Last-Translator: Anton Zinoviev <zinoviev@debian.org>\n"
|
||||||
|
"Language-Team: Bulgarian <dict@linux.zonebg.com>\n"
|
||||||
|
"MIME-Version: 1.0\n"
|
||||||
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/connection.c:461 ../../WINGs/connection.c:526
|
||||||
|
#: ../../WINGs/connection.c:569
|
||||||
|
msgid "Bad address-service-protocol combination"
|
||||||
|
msgstr "Неправилна комбинация адрес-услуга-протокол"
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:54
|
||||||
|
#, c-format
|
||||||
|
msgid "Unknown error %d"
|
||||||
|
msgstr "Непозната грешка %d"
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:59
|
||||||
|
#, c-format
|
||||||
|
msgid "Error %d"
|
||||||
|
msgstr "Грешка %d"
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:110
|
||||||
|
msgid " warning: "
|
||||||
|
msgstr "внимание: "
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:137
|
||||||
|
msgid " fatal error: "
|
||||||
|
msgstr " критична грешка: "
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:163 ../../WINGs/error.c:192
|
||||||
|
msgid " error: "
|
||||||
|
msgstr " грешка: "
|
||||||
|
|
||||||
|
#: ../../WINGs/findfile.c:48
|
||||||
|
#, c-format
|
||||||
|
msgid "could not get password entry for UID %i"
|
||||||
|
msgstr "не може да се получи записът за парола на потребител с номер %i"
|
||||||
|
|
||||||
|
#: ../../WINGs/findfile.c:66
|
||||||
|
#, c-format
|
||||||
|
msgid "could not get password entry for user %s"
|
||||||
|
msgstr "не може да се получи записът за парола на потребител %s<"
|
||||||
|
|
||||||
|
#: ../../WINGs/host.c:114
|
||||||
|
msgid "Cannot get current host name"
|
||||||
|
msgstr "Не може да се получи името на хоста"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:91
|
||||||
|
#, c-format
|
||||||
|
msgid "syntax error in %s %s, line %i: %s"
|
||||||
|
msgstr "синтактична грешка в %s %s, ред %i: %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:150
|
||||||
|
msgid "Only string or data is supported for a proplist dictionary key"
|
||||||
|
msgstr "Като ключ за достъп до proplist се поддържат само низове или данни"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:184 ../../WINGs/proplist.c:236
|
||||||
|
#: ../../WINGs/proplist.c:394 ../../WINGs/proplist.c:474
|
||||||
|
#: ../../WINGs/proplist.c:1075 ../../WINGs/proplist.c:1127
|
||||||
|
#: ../../WINGs/proplist.c:1293 ../../WINGs/proplist.c:1372
|
||||||
|
#: ../../WINGs/proplist.c:1493 ../../WINGs/proplist.c:1540
|
||||||
|
msgid "Used proplist functions on non-WMPropLists objects"
|
||||||
|
msgstr "Ползват се proplist-функции за обекти, които не са от тип WMPropLists"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:630
|
||||||
|
msgid "unterminated PropList string"
|
||||||
|
msgstr "незавършен низ PropList"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:670
|
||||||
|
msgid "unterminated PropList data"
|
||||||
|
msgstr "незавършени данни PropList"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:678
|
||||||
|
msgid "unterminated PropList data (missing hexdigit)"
|
||||||
|
msgstr "незавършени данни PropList (липсва шестнадесетично число)"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:690 ../../WINGs/proplist.c:695
|
||||||
|
msgid "non hexdigit character in PropList data"
|
||||||
|
msgstr "знак, който не е шестнадесетично число, в данни PropList"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:729
|
||||||
|
msgid "unterminated PropList array"
|
||||||
|
msgstr "незавършен масив PropList"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:737
|
||||||
|
msgid "missing or unterminated PropList array"
|
||||||
|
msgstr "липсващ или незавършен масив Proplist"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:747
|
||||||
|
msgid "could not get PropList array element"
|
||||||
|
msgstr "не може да се получи елемент от масив PropList"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:776
|
||||||
|
msgid "unterminated PropList dictionary"
|
||||||
|
msgstr "незавършен речник PropList"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:793
|
||||||
|
msgid "missing PropList dictionary key"
|
||||||
|
msgstr "липсващ ключ за достъп до PropList"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:795
|
||||||
|
msgid "missing PropList dictionary entry key or unterminated dictionary"
|
||||||
|
msgstr "липсващ ключ за достъп до PropList или незавършен речник"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:803
|
||||||
|
msgid "error parsing PropList dictionary key"
|
||||||
|
msgstr "грешка при разбор на ключ в PropList"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:811
|
||||||
|
msgid "missing = in PropList dictionary entry"
|
||||||
|
msgstr "липсва знак за равенство в елемент на PropList"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:819
|
||||||
|
msgid "error parsing PropList dictionary entry value"
|
||||||
|
msgstr "грешка при разбор на стойност на елемент в PropList"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:827
|
||||||
|
msgid "missing ; in PropList dictionary entry"
|
||||||
|
msgstr "липсва знак точка и запетая в елемент на PropList"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:888
|
||||||
|
msgid ""
|
||||||
|
"was expecting a string, data, array or dictionary. If it's a string, try "
|
||||||
|
"enclosing it with \"."
|
||||||
|
msgstr "очакваха се низ, данни, масив или речник. Ако е речник, пробвайте да го оградите с \"."
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:892
|
||||||
|
msgid "Comments are not allowed inside WindowMaker owned domain files."
|
||||||
|
msgstr "Не се позволяват коментари във файлове с области, собственост на Уиндоу Мейкър"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1563 ../../WINGs/proplist.c:1628
|
||||||
|
msgid "extra data after end of property list"
|
||||||
|
msgstr "данни в повече след края на списък свойства"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1606
|
||||||
|
#, c-format
|
||||||
|
msgid "could not get size for file '%s'"
|
||||||
|
msgstr "не може да се получи размерът за файл \"%s\""
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1618
|
||||||
|
#, c-format
|
||||||
|
msgid "error reading from file '%s'"
|
||||||
|
msgstr "грешка при четене от файл \"%s\""
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1669
|
||||||
|
#, c-format
|
||||||
|
msgid "mkstemp (%s) failed"
|
||||||
|
msgstr "mkstemp (%s) не успя"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1680
|
||||||
|
#, c-format
|
||||||
|
msgid "mktemp (%s) failed"
|
||||||
|
msgstr "mktemp (%s) не успя"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1691
|
||||||
|
#, c-format
|
||||||
|
msgid "open (%s) failed"
|
||||||
|
msgstr "open (%s) не успя"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1698
|
||||||
|
#, c-format
|
||||||
|
msgid "writing to file: %s failed"
|
||||||
|
msgstr "записът във файл %s не успя"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1706
|
||||||
|
#, c-format
|
||||||
|
msgid "fclose (%s) failed"
|
||||||
|
msgstr "fclose (%s) не успя"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1715
|
||||||
|
#, c-format
|
||||||
|
msgid "rename ('%s' to '%s') failed"
|
||||||
|
msgstr "преименуването (от \"%s\" на \"%s\") не успя"
|
||||||
|
|
||||||
|
#. something happened with the file. just overwrite it
|
||||||
|
#: ../../WINGs/userdefaults.c:192 ../../WINGs/userdefaults.c:208
|
||||||
|
#, c-format
|
||||||
|
msgid "cannot read domain from file '%s' when syncing"
|
||||||
|
msgstr "не може да се прочете областта от файл \"%s\" при синхронизиране"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:198 ../../WINGs/wcolor.c:211 ../../WINGs/wcolor.c:250
|
||||||
|
#: ../../WINGs/wcolor.c:291
|
||||||
|
#, c-format
|
||||||
|
msgid "could not allocate %s color"
|
||||||
|
msgstr "не може да се задели цвят %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:198
|
||||||
|
msgid "white"
|
||||||
|
msgstr "бял"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:211
|
||||||
|
msgid "black"
|
||||||
|
msgstr "черен"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:250
|
||||||
|
msgid "gray"
|
||||||
|
msgstr "сив"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:291
|
||||||
|
msgid "dark gray"
|
||||||
|
msgstr "тъмносив"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:415
|
||||||
|
msgid "Colors"
|
||||||
|
msgstr "Цветове"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:605 ../../WINGs/wcolorpanel.c:2824
|
||||||
|
msgid "Brightness"
|
||||||
|
msgstr "Яркост"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:607 ../../WINGs/wcolorpanel.c:683
|
||||||
|
#: ../../WINGs/wcolorpanel.c:716 ../../WINGs/wcolorpanel.c:750
|
||||||
|
#: ../../WINGs/wcolorpanel.c:810 ../../WINGs/wcolorpanel.c:844
|
||||||
|
#: ../../WINGs/wcolorpanel.c:878 ../../WINGs/wcolorpanel.c:913
|
||||||
|
#: ../../WINGs/wcolorpanel.c:2164 ../../WINGs/wcolorpanel.c:2826
|
||||||
|
#: ../../WINGs/wcolorpanel.c:2862 ../../WINGs/wcolorpanel.c:2898
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3746
|
||||||
|
msgid "Color Panel: Could not allocate memory"
|
||||||
|
msgstr "Color Panel: не може да се задели памет"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:680 ../../WINGs/wcolorpanel.c:681
|
||||||
|
msgid "Red"
|
||||||
|
msgstr "Червен"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:713 ../../WINGs/wcolorpanel.c:714
|
||||||
|
msgid "Green"
|
||||||
|
msgstr "Зелен"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:747 ../../WINGs/wcolorpanel.c:748
|
||||||
|
msgid "Blue"
|
||||||
|
msgstr "Син"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:807 ../../WINGs/wcolorpanel.c:808
|
||||||
|
msgid "Cyan"
|
||||||
|
msgstr "Синьозелен"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:841 ../../WINGs/wcolorpanel.c:842
|
||||||
|
msgid "Magenta"
|
||||||
|
msgstr "Пурпурен"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:875 ../../WINGs/wcolorpanel.c:876
|
||||||
|
msgid "Yellow"
|
||||||
|
msgstr "Жълт"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:910 ../../WINGs/wcolorpanel.c:911
|
||||||
|
msgid "Black"
|
||||||
|
msgstr "Черен"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:991
|
||||||
|
msgid "Spectrum"
|
||||||
|
msgstr "Спектър"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1021
|
||||||
|
msgid "Palette"
|
||||||
|
msgstr "Палитра"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1027
|
||||||
|
msgid "New from File..."
|
||||||
|
msgstr "Нова от файл..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1028 ../../WINGs/wcolorpanel.c:1076
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1093
|
||||||
|
msgid "Rename..."
|
||||||
|
msgstr "Преименувай..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1029 ../../WINGs/wcolorpanel.c:1077
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1094 ../../WINGs/wcolorpanel.c:3321
|
||||||
|
msgid "Remove"
|
||||||
|
msgstr "Премахни"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1030
|
||||||
|
msgid "Copy"
|
||||||
|
msgstr "Копирай"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1031
|
||||||
|
#, fuzzy
|
||||||
|
msgid "New from Clipboard"
|
||||||
|
msgstr "Нова от Clipboard"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1052
|
||||||
|
msgid "X11-Colors"
|
||||||
|
msgstr "Цветове от X11"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1069
|
||||||
|
msgid "Color"
|
||||||
|
msgstr "Цвят"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1075
|
||||||
|
msgid "Add..."
|
||||||
|
msgstr "Добави..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1085
|
||||||
|
msgid "List"
|
||||||
|
msgstr "Списък"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1092
|
||||||
|
msgid "New..."
|
||||||
|
msgstr "Нов..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1231
|
||||||
|
#, c-format
|
||||||
|
msgid ""
|
||||||
|
"Color Panel: Could not create directory %s needed to store configurations"
|
||||||
|
msgstr "Color Panel: Не може да се създаде директория %s, необходима за да се запазят настройките"
|
||||||
|
|
||||||
|
#. Delete the file, it doesn't belong here
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1237 ../../WINGs/wcolorpanel.c:3207
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3211
|
||||||
|
msgid "File Error"
|
||||||
|
msgstr "Файлова грешка"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1238
|
||||||
|
msgid "Could not create ColorPanel configuration directory"
|
||||||
|
msgstr "Не може да се създаде конфигурационна директория за ColorPanel"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1239 ../../WINGs/wcolorpanel.c:3208
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3213 ../../WINGs/wcolorpanel.c:3240
|
||||||
|
#: ../../WINGs/wfilepanel.c:250 ../../WINGs/wfilepanel.c:647
|
||||||
|
#: ../../WINGs/wfilepanel.c:659 ../../WINGs/wfilepanel.c:760
|
||||||
|
#: ../../WINGs/wfilepanel.c:971 ../../WINGs/wfontpanel.c:709
|
||||||
|
msgid "OK"
|
||||||
|
msgstr "Приемам"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1245 ../../WINGs/wcolorpanel.c:1281
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1299
|
||||||
|
msgid "Color Panel: Could not find file"
|
||||||
|
msgstr "Color Panel: Не може да се открие файла"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1486 ../../WINGs/wcolorpanel.c:1551
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1615
|
||||||
|
msgid "Color Panel: X failed request"
|
||||||
|
msgstr "Color Panel: не успя заявка към X"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:2860
|
||||||
|
msgid "Saturation"
|
||||||
|
msgstr "Наситеност"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:2896
|
||||||
|
msgid "Hue"
|
||||||
|
msgstr "Нюанс"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3146
|
||||||
|
msgid "Open Palette"
|
||||||
|
msgstr "Отваряне на палитра"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3208
|
||||||
|
msgid "Invalid file format !"
|
||||||
|
msgstr "Неправилен файлов формат!"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3210
|
||||||
|
#, c-format
|
||||||
|
msgid "can't remove file %s"
|
||||||
|
msgstr "не може да се изтрие файлът %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3212
|
||||||
|
msgid "Couldn't remove file from Configuration Directory !"
|
||||||
|
msgstr "Не може да се изтрие файл от директорията за настройки!"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3239
|
||||||
|
msgid "Rename"
|
||||||
|
msgstr "Преименуване"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3239
|
||||||
|
msgid "Rename palette to:"
|
||||||
|
msgstr "Преименувай палитрата на "
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3240 ../../WINGs/wfilepanel.c:259
|
||||||
|
#: ../../WINGs/wfilepanel.c:659 ../../WINGs/wfilepanel.c:760
|
||||||
|
msgid "Cancel"
|
||||||
|
msgstr "Отменям"
|
||||||
|
|
||||||
|
#. Careful, this palette exists already
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3256 ../../WINGs/wfilepanel.c:760
|
||||||
|
msgid "Warning"
|
||||||
|
msgstr "Внимание"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3257
|
||||||
|
msgid ""
|
||||||
|
"Palette already exists !\n"
|
||||||
|
"\n"
|
||||||
|
"Overwrite ?"
|
||||||
|
msgstr ""
|
||||||
|
"Такава палитра вече съществува!\n"
|
||||||
|
"\n"
|
||||||
|
"Да бъде ли заменена с новата?"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3257 ../../WINGs/wcolorpanel.c:3321
|
||||||
|
msgid "No"
|
||||||
|
msgstr "Не"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3257 ../../WINGs/wcolorpanel.c:3321
|
||||||
|
msgid "Yes"
|
||||||
|
msgstr "Да"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3289
|
||||||
|
#, c-format
|
||||||
|
msgid "Couldn't rename palette %s to %s\n"
|
||||||
|
msgstr "Палитрата %s не може да се преименува на %s\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3315
|
||||||
|
msgid "This will permanently remove the palette "
|
||||||
|
msgstr "Това ще отстрани палитрата необратимо "
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3318
|
||||||
|
msgid ""
|
||||||
|
".\n"
|
||||||
|
"\n"
|
||||||
|
"Are you sure you want to remove this palette ?"
|
||||||
|
msgstr ""
|
||||||
|
".\n"
|
||||||
|
"\n"
|
||||||
|
"Убедени ли сте, че искате да отстраните тази палитра?"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3343
|
||||||
|
#, c-format
|
||||||
|
msgid "Couldn't remove palette %s\n"
|
||||||
|
msgstr "Палитрата %s не може да бъде отстранена\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3648
|
||||||
|
#, c-format
|
||||||
|
msgid "Could not open %s"
|
||||||
|
msgstr "Не може да бъде отворен %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3655
|
||||||
|
#, c-format
|
||||||
|
msgid "Could not create %s"
|
||||||
|
msgstr "Не може да бъде създаден %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3666
|
||||||
|
#, c-format
|
||||||
|
msgid "Write error on file %s"
|
||||||
|
msgstr "Грешка при запис във файл %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3711
|
||||||
|
msgid "Color Panel: Color unspecified"
|
||||||
|
msgstr "Color Panel: Не е посочен цвят"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:235
|
||||||
|
msgid "Name:"
|
||||||
|
msgstr "Име:"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:332 ../../WINGs/wfilepanel.c:396
|
||||||
|
msgid "Open"
|
||||||
|
msgstr "Отвори"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:350 ../../WINGs/wfilepanel.c:402
|
||||||
|
msgid "Save"
|
||||||
|
msgstr "Запази"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:562
|
||||||
|
#, c-format
|
||||||
|
msgid "WINGs: could not open directory %s\n"
|
||||||
|
msgstr "WINGs: директорията %s не може да се отвори\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:580
|
||||||
|
#, c-format
|
||||||
|
msgid "WINGs: could not stat %s\n"
|
||||||
|
msgstr "WINGs: не могат да се получат атрибутите (stat) за %s\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:647 ../../WINGs/wfilepanel.c:970
|
||||||
|
#: ../../WINGs/wfontpanel.c:708
|
||||||
|
msgid "Error"
|
||||||
|
msgstr "Грешка"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:658
|
||||||
|
msgid "Create Directory"
|
||||||
|
msgstr "Създаване на директория"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:659
|
||||||
|
msgid "Enter directory name"
|
||||||
|
msgstr "Въведете името на директорията"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:695 ../../WINGs/wfilepanel.c:734
|
||||||
|
#: ../../WINGs/wfilepanel.c:765 ../../WINGs/wfilepanel.c:793
|
||||||
|
msgid "Permission denied."
|
||||||
|
msgstr "Отказан достъп"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:698
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' already exists."
|
||||||
|
msgstr "вече съществува \"%s\"."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:701
|
||||||
|
msgid "Path does not exist."
|
||||||
|
msgstr "Пътят не съществува."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:731 ../../WINGs/wfilepanel.c:790
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' does not exist."
|
||||||
|
msgstr "Не съществува \"%s\"."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:738 ../../WINGs/wfilepanel.c:797
|
||||||
|
msgid "Insufficient memory available."
|
||||||
|
msgstr "Не е достъпна достатъчно памет."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:742 ../../WINGs/wfilepanel.c:801
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' is on a read-only filesystem."
|
||||||
|
msgstr "\"%s\" се намира във файлова система с достъп само за четене."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:745 ../../WINGs/wfilepanel.c:777
|
||||||
|
#: ../../WINGs/wfilepanel.c:804
|
||||||
|
#, c-format
|
||||||
|
msgid "Can not delete '%s'."
|
||||||
|
msgstr "\"%s\" не може да бъде изтрит."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:752
|
||||||
|
#, c-format
|
||||||
|
msgid "Delete directory %s ?"
|
||||||
|
msgstr "Да се изтрие ли директорията %s?"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:756
|
||||||
|
#, c-format
|
||||||
|
msgid "Delete file %s ?"
|
||||||
|
msgstr "Да се изтрие ли файлът %s?"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:768
|
||||||
|
#, c-format
|
||||||
|
msgid "Directory '%s' does not exist."
|
||||||
|
msgstr "Директорията \"%s\" не съществува."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:771
|
||||||
|
#, c-format
|
||||||
|
msgid "Directory '%s' is not empty."
|
||||||
|
msgstr "Директорията \"%s\" не е празна."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:774
|
||||||
|
#, c-format
|
||||||
|
msgid "Directory '%s' is busy."
|
||||||
|
msgstr "Директорията \"%s е заета."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:787
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' is a directory."
|
||||||
|
msgstr "\"%s\" е директория."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:829
|
||||||
|
#, c-format
|
||||||
|
msgid "An error occured browsing '%s'."
|
||||||
|
msgstr "Настъпи грешка при показване на \"%s\"."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:833
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' is not a directory."
|
||||||
|
msgstr "\"%s\" не е директория."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:970
|
||||||
|
msgid "File does not exist."
|
||||||
|
msgstr "Файлът не съществува."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:129
|
||||||
|
#, c-format
|
||||||
|
msgid "the following character sets are missing in %s:"
|
||||||
|
msgstr "в %s липсват следните кодирания:"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:136
|
||||||
|
#, c-format
|
||||||
|
msgid ""
|
||||||
|
"the string \"%s\" will be used in place of any characters from those sets."
|
||||||
|
msgstr "Вместо кой да е символ от тези кодирания ще се използва низът \"%s\"."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:300 ../../WINGs/wfont.c:336
|
||||||
|
#, c-format
|
||||||
|
msgid "could not load font set %s. Trying fixed."
|
||||||
|
msgstr "не може да се зареди шрифтова комбинация %s. Опит за шрифт fixed."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:306 ../../WINGs/wfont.c:342
|
||||||
|
#, c-format
|
||||||
|
msgid "could not load font %s. Trying fixed."
|
||||||
|
msgstr "не може да се зареди шрифт %s. Опит за шрифт fixed."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:310 ../../WINGs/wfont.c:346
|
||||||
|
msgid "could not load fixed font!"
|
||||||
|
msgstr "не може да се зареди шрифтът fixed!"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:441
|
||||||
|
#, c-format
|
||||||
|
msgid "font description %s is too large."
|
||||||
|
msgstr "шрифтовото описание %s е твърде дълго."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:205
|
||||||
|
msgid "Test!!!"
|
||||||
|
msgstr "Проба!!! Test!!!"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:211
|
||||||
|
msgid "Family"
|
||||||
|
msgstr "Гарнитура"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:222
|
||||||
|
msgid "Typeface"
|
||||||
|
msgstr "Стил"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:233
|
||||||
|
msgid "Size"
|
||||||
|
msgstr "Размер"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:252
|
||||||
|
msgid "Set"
|
||||||
|
msgstr "Установи"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:257
|
||||||
|
msgid "Revert"
|
||||||
|
msgstr "Предишното"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:709
|
||||||
|
msgid "Could not retrieve font list"
|
||||||
|
msgstr "Не може да се получи списъка от шрифтове"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:721
|
||||||
|
#, c-format
|
||||||
|
msgid "font name %s is longer than 256, which is invalid."
|
||||||
|
msgstr "името на шрифта %s е по-дълго от 256 символа, което е недопустимо."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:868
|
||||||
|
msgid "Roman"
|
||||||
|
msgstr "Изправен"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:871
|
||||||
|
msgid "Italic"
|
||||||
|
msgstr "Курсив"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:873
|
||||||
|
msgid "Oblique"
|
||||||
|
msgstr "Наклонен"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:875
|
||||||
|
msgid "Rev Italic"
|
||||||
|
msgstr "Обратен курсив"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:877
|
||||||
|
msgid "Rev Oblique"
|
||||||
|
msgstr "Обратно наклонен"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:883
|
||||||
|
msgid "Normal"
|
||||||
|
msgstr "Нормален"
|
||||||
|
|
||||||
|
#: ../../WINGs/widgets.c:415
|
||||||
|
#, c-format
|
||||||
|
msgid "WINGs: could not load widget images file: %s"
|
||||||
|
msgstr "WINGs: не може да се зареди изображението %s на библиотеката."
|
||||||
|
|
||||||
|
#: ../../WINGs/widgets.c:763
|
||||||
|
msgid ""
|
||||||
|
"could not load any fonts. Make sure your font installation and locale "
|
||||||
|
"settings are correct."
|
||||||
|
msgstr "не може да се зареди никакъв шрифт. Убедете се, че имате правилно инсталирани шрифтове и посочен езиков локал."
|
||||||
|
|
||||||
|
#: ../../WINGs/wruler.c:189
|
||||||
|
msgid "0 inches"
|
||||||
|
msgstr "0 цола"
|
||||||
736
WINGs/po/ca.po
Normal file
736
WINGs/po/ca.po
Normal file
@@ -0,0 +1,736 @@
|
|||||||
|
# Catalan messages for WINGs.
|
||||||
|
# Copyright (C) 2003 Ernest Adrogué <eadrogue@gmx.net>.
|
||||||
|
# This file is distributed under the terms of the GNU General Public License.
|
||||||
|
#
|
||||||
|
# Version history:
|
||||||
|
# WM-ver author email date
|
||||||
|
# 0.80.2 Ernest Adrogué eadrogue@gmx.net 23 Feb 2003
|
||||||
|
# CVS-20030914 Ernest Adrogué eadrogue@gmx.net 15 Set 2003
|
||||||
|
#
|
||||||
|
msgid ""
|
||||||
|
msgstr ""
|
||||||
|
"Project-Id-Version: WINGs 0.80.2\n"
|
||||||
|
"POT-Creation-Date: 2003-09-16 22:59+0200\n"
|
||||||
|
"PO-Revision-Date: 2003-09-16 23:16+0200\n"
|
||||||
|
"Last-Translator: Ernest Adrogué <eadrogue@gmx.net>\n"
|
||||||
|
"Language-Team: Catalan <ca@dodds.net>\n"
|
||||||
|
"MIME-Version: 1.0\n"
|
||||||
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/connection.c:467 ../../WINGs/connection.c:532
|
||||||
|
#: ../../WINGs/connection.c:575
|
||||||
|
msgid "Bad address-service-protocol combination"
|
||||||
|
msgstr "Combinació adreça-servei-protocol incorrecta"
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:54
|
||||||
|
#, c-format
|
||||||
|
msgid "Unknown error %d"
|
||||||
|
msgstr "Error no identificat %d"
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:59
|
||||||
|
#, c-format
|
||||||
|
msgid "Error %d"
|
||||||
|
msgstr "Error %d"
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:110
|
||||||
|
msgid " warning: "
|
||||||
|
msgstr ": atenció: "
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:137
|
||||||
|
msgid " fatal error: "
|
||||||
|
msgstr ": error fatal: "
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:163 ../../WINGs/error.c:192
|
||||||
|
msgid " error: "
|
||||||
|
msgstr ": error: "
|
||||||
|
|
||||||
|
#: ../../WINGs/findfile.c:48
|
||||||
|
#, c-format
|
||||||
|
msgid "could not get password entry for UID %i"
|
||||||
|
msgstr "no s'ha pogut obtenir l'informació de compte de l'UID %i"
|
||||||
|
|
||||||
|
#: ../../WINGs/findfile.c:66
|
||||||
|
#, c-format
|
||||||
|
msgid "could not get password entry for user %s"
|
||||||
|
msgstr "no s'ha pogut obtenir l'informació de compte de l'usuari %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/host.c:114
|
||||||
|
msgid "Cannot get current host name"
|
||||||
|
msgstr "No s'ha pogut obtenir el nom de host actual"
|
||||||
|
|
||||||
|
# falten coses per traduïr en el codi font. eac
|
||||||
|
#: ../../WINGs/proplist.c:91
|
||||||
|
#, c-format
|
||||||
|
msgid "syntax error in %s %s, line %i: %s"
|
||||||
|
msgstr "error de sintaxi a %s %s, línia %i: %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:150
|
||||||
|
msgid "Only string or data is supported for a proplist dictionary key"
|
||||||
|
msgstr ""
|
||||||
|
"Una entrada PropList de diccionari només pot contenir dades o una cadena"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:184 ../../WINGs/proplist.c:236
|
||||||
|
#: ../../WINGs/proplist.c:394 ../../WINGs/proplist.c:474
|
||||||
|
#: ../../WINGs/proplist.c:1075 ../../WINGs/proplist.c:1127
|
||||||
|
#: ../../WINGs/proplist.c:1293 ../../WINGs/proplist.c:1372
|
||||||
|
#: ../../WINGs/proplist.c:1493 ../../WINGs/proplist.c:1540
|
||||||
|
msgid "Used proplist functions on non-WMPropLists objects"
|
||||||
|
msgstr "S'han usat funcions PropList en objectes no-WMPropLists"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:630
|
||||||
|
msgid "unterminated PropList string"
|
||||||
|
msgstr "cadena PropList incompleta"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:670
|
||||||
|
msgid "unterminated PropList data"
|
||||||
|
msgstr "dades PropList incompletes"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:678
|
||||||
|
msgid "unterminated PropList data (missing hexdigit)"
|
||||||
|
msgstr "Dades PropList incompletes (falta un digit hexadecimal)"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:690 ../../WINGs/proplist.c:695
|
||||||
|
msgid "non hexdigit character in PropList data"
|
||||||
|
msgstr "cap digit hexadecimal a les dades PropList"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:729
|
||||||
|
msgid "unterminated PropList array"
|
||||||
|
msgstr "matriu PropList incompleta"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:737
|
||||||
|
msgid "missing or unterminated PropList array"
|
||||||
|
msgstr "matriu PropList incompleta o inexistent"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:747
|
||||||
|
msgid "could not get PropList array element"
|
||||||
|
msgstr "no s'ha pogut obtenir un element de la matriu PropList"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:776
|
||||||
|
msgid "unterminated PropList dictionary"
|
||||||
|
msgstr "diccionari PropList incomplet"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:793
|
||||||
|
msgid "missing PropList dictionary key"
|
||||||
|
msgstr "falta una entrada PropList de diccionari"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:795
|
||||||
|
msgid "missing PropList dictionary entry key or unterminated dictionary"
|
||||||
|
msgstr "falta una entrada PropList de diccionari o bé està incompleta"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:803
|
||||||
|
msgid "error parsing PropList dictionary key"
|
||||||
|
msgstr "error mentre s'analitzava l'entrada PropList de diccionari"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:811
|
||||||
|
msgid "missing = in PropList dictionary entry"
|
||||||
|
msgstr "falta un \"=\" a l'entrada PropList de diccionari"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:819
|
||||||
|
msgid "error parsing PropList dictionary entry value"
|
||||||
|
msgstr "error mentre s'analitzava el valor de l'entrada PropList de diccionari"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:827
|
||||||
|
msgid "missing ; in PropList dictionary entry"
|
||||||
|
msgstr "falta un \";\" a l'entrada PropList de diccionari"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:888
|
||||||
|
msgid ""
|
||||||
|
"was expecting a string, data, array or dictionary. If it's a string, try "
|
||||||
|
"enclosing it with \"."
|
||||||
|
msgstr ""
|
||||||
|
"s'esperava una cadena, dada, matriu o diccionari. Si es tractava d'una\n"
|
||||||
|
"cadena proveu d'escriure-la \"entre cometes\"."
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:892
|
||||||
|
msgid "Comments are not allowed inside WindowMaker owned domain files."
|
||||||
|
msgstr "No es permeten comentaris en els fitxers de domini de WindowMaker."
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1563 ../../WINGs/proplist.c:1630
|
||||||
|
msgid "extra data after end of property list"
|
||||||
|
msgstr "sobren dades després de la llista de propietats"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1606
|
||||||
|
#, c-format
|
||||||
|
msgid "could not get size for file '%s'"
|
||||||
|
msgstr "no s'ha pogut obtenir la mida de \"%s\""
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1619
|
||||||
|
#, c-format
|
||||||
|
msgid "error reading from file '%s'"
|
||||||
|
msgstr "error mentre es llegia el fitxer \"%s\""
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1671
|
||||||
|
#, c-format
|
||||||
|
msgid "mkstemp (%s) failed"
|
||||||
|
msgstr "la rutina mkstemp (%s) ha fallat"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1682
|
||||||
|
#, c-format
|
||||||
|
msgid "mktemp (%s) failed"
|
||||||
|
msgstr "la rutina mktemp (%s) ha fallat"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1693
|
||||||
|
#, c-format
|
||||||
|
msgid "open (%s) failed"
|
||||||
|
msgstr "la rutina open (%s) ha fallat"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1700
|
||||||
|
#, c-format
|
||||||
|
msgid "writing to file: %s failed"
|
||||||
|
msgstr "l'escriptura del fitxer \"%s\" ha fallat"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1708
|
||||||
|
#, c-format
|
||||||
|
msgid "fclose (%s) failed"
|
||||||
|
msgstr "la rutina fclose (%s) ha fallat"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1717
|
||||||
|
#, c-format
|
||||||
|
msgid "rename ('%s' to '%s') failed"
|
||||||
|
msgstr "el canvi de nom (\"%s\" a \"%s\") ha fallat"
|
||||||
|
|
||||||
|
#. something happened with the file. just overwrite it
|
||||||
|
#: ../../WINGs/userdefaults.c:188 ../../WINGs/userdefaults.c:204
|
||||||
|
#, c-format
|
||||||
|
msgid "cannot read domain from file '%s' when syncing"
|
||||||
|
msgstr "no s'ha pogut llegir un domini del fitxer \"%s\" quan es sincronitzava"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:224 ../../WINGs/wcolor.c:236 ../../WINGs/wcolor.c:275
|
||||||
|
#: ../../WINGs/wcolor.c:316
|
||||||
|
#, c-format
|
||||||
|
msgid "could not allocate %s color"
|
||||||
|
msgstr "no s'ha pogut assignar espai pel color \"%s\""
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:224
|
||||||
|
msgid "white"
|
||||||
|
msgstr "blanc"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:236
|
||||||
|
msgid "black"
|
||||||
|
msgstr "negre"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:275
|
||||||
|
msgid "gray"
|
||||||
|
msgstr "gris"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:316
|
||||||
|
msgid "dark gray"
|
||||||
|
msgstr "gris fosc"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:420
|
||||||
|
msgid "Colors"
|
||||||
|
msgstr "Colors"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:610 ../../WINGs/wcolorpanel.c:2829
|
||||||
|
msgid "Brightness"
|
||||||
|
msgstr "Claror"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:612 ../../WINGs/wcolorpanel.c:688
|
||||||
|
#: ../../WINGs/wcolorpanel.c:721 ../../WINGs/wcolorpanel.c:755
|
||||||
|
#: ../../WINGs/wcolorpanel.c:815 ../../WINGs/wcolorpanel.c:849
|
||||||
|
#: ../../WINGs/wcolorpanel.c:883 ../../WINGs/wcolorpanel.c:918
|
||||||
|
#: ../../WINGs/wcolorpanel.c:2169 ../../WINGs/wcolorpanel.c:2831
|
||||||
|
#: ../../WINGs/wcolorpanel.c:2867 ../../WINGs/wcolorpanel.c:2903
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3745
|
||||||
|
msgid "Color Panel: Could not allocate memory"
|
||||||
|
msgstr "Panell de color: No s'ha pogut assignar memòria"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:685 ../../WINGs/wcolorpanel.c:686
|
||||||
|
msgid "Red"
|
||||||
|
msgstr "Roig"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:718 ../../WINGs/wcolorpanel.c:719
|
||||||
|
msgid "Green"
|
||||||
|
msgstr "Verd"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:752 ../../WINGs/wcolorpanel.c:753
|
||||||
|
msgid "Blue"
|
||||||
|
msgstr "Blau"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:812 ../../WINGs/wcolorpanel.c:813
|
||||||
|
msgid "Cyan"
|
||||||
|
msgstr "Cian"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:846 ../../WINGs/wcolorpanel.c:847
|
||||||
|
msgid "Magenta"
|
||||||
|
msgstr "Magenta"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:880 ../../WINGs/wcolorpanel.c:881
|
||||||
|
msgid "Yellow"
|
||||||
|
msgstr "Groc"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:915 ../../WINGs/wcolorpanel.c:916
|
||||||
|
msgid "Black"
|
||||||
|
msgstr "Negre"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:996
|
||||||
|
msgid "Spectrum"
|
||||||
|
msgstr "Espectre"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1026
|
||||||
|
msgid "Palette"
|
||||||
|
msgstr "Paleta"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1032
|
||||||
|
msgid "New from File..."
|
||||||
|
msgstr "Obtenir d'un fitxer..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1033 ../../WINGs/wcolorpanel.c:1081
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1098
|
||||||
|
msgid "Rename..."
|
||||||
|
msgstr "Reanomenar..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1034 ../../WINGs/wcolorpanel.c:1082
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1099 ../../WINGs/wcolorpanel.c:3326
|
||||||
|
msgid "Remove"
|
||||||
|
msgstr "Eliminar"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1035
|
||||||
|
msgid "Copy"
|
||||||
|
msgstr "Copiar"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1036
|
||||||
|
msgid "New from Clipboard"
|
||||||
|
msgstr "Obtenir del porta-retalls..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1057
|
||||||
|
msgid "X11-Colors"
|
||||||
|
msgstr "Colors-X11"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1074
|
||||||
|
msgid "Color"
|
||||||
|
msgstr "Color"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1080
|
||||||
|
msgid "Add..."
|
||||||
|
msgstr "Afegeix..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1090
|
||||||
|
msgid "List"
|
||||||
|
msgstr "Llista"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1097
|
||||||
|
msgid "New..."
|
||||||
|
msgstr "Nou..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1236
|
||||||
|
#, c-format
|
||||||
|
msgid ""
|
||||||
|
"Color Panel: Could not create directory %s needed to store configurations"
|
||||||
|
msgstr ""
|
||||||
|
"Panell de color: No s'ha pogut crear el directori \"%s\" necessari per desar "
|
||||||
|
"la configuració"
|
||||||
|
|
||||||
|
#. Delete the file, it doesn't belong here
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1242 ../../WINGs/wcolorpanel.c:3212
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3216
|
||||||
|
msgid "File Error"
|
||||||
|
msgstr "Error de fitxer"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1243
|
||||||
|
msgid "Could not create ColorPanel configuration directory"
|
||||||
|
msgstr "No s'ha pogut crear el directori de configuració del Panell de color"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1244 ../../WINGs/wcolorpanel.c:3213
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3218 ../../WINGs/wcolorpanel.c:3245
|
||||||
|
#: ../../WINGs/wfilepanel.c:250 ../../WINGs/wfilepanel.c:650
|
||||||
|
#: ../../WINGs/wfilepanel.c:662 ../../WINGs/wfilepanel.c:763
|
||||||
|
#: ../../WINGs/wfilepanel.c:974 ../../WINGs/wfontpanel.c:751
|
||||||
|
msgid "OK"
|
||||||
|
msgstr "D'acord"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1250 ../../WINGs/wcolorpanel.c:1286
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1304
|
||||||
|
msgid "Color Panel: Could not find file"
|
||||||
|
msgstr "Panell de color: No s'ha trobat el fitxer"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1491 ../../WINGs/wcolorpanel.c:1556
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1620
|
||||||
|
msgid "Color Panel: X failed request"
|
||||||
|
msgstr "Panell de color: petició X fallida"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:2865
|
||||||
|
msgid "Saturation"
|
||||||
|
msgstr "Saturació"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:2901
|
||||||
|
msgid "Hue"
|
||||||
|
msgstr "Matís"
|
||||||
|
|
||||||
|
# és el títol d'un quadre de diàleg. eac
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3151
|
||||||
|
msgid "Open Palette"
|
||||||
|
msgstr "Obrir paleta"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3213
|
||||||
|
msgid "Invalid file format !"
|
||||||
|
msgstr "El format del fitxer no és vàlid !"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3215
|
||||||
|
#, c-format
|
||||||
|
msgid "can't remove file %s"
|
||||||
|
msgstr "no s'ha pogut eliminar el fitxer \"%s\""
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3217
|
||||||
|
msgid "Couldn't remove file from Configuration Directory !"
|
||||||
|
msgstr "No s'ha pogut eliminar el fitxer del directori de configuració !"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3244
|
||||||
|
msgid "Rename"
|
||||||
|
msgstr "Reanomena"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3244
|
||||||
|
msgid "Rename palette to:"
|
||||||
|
msgstr "Reanomena la paleta com a:"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3245 ../../WINGs/wfilepanel.c:259
|
||||||
|
#: ../../WINGs/wfilepanel.c:662 ../../WINGs/wfilepanel.c:763
|
||||||
|
msgid "Cancel"
|
||||||
|
msgstr "Cancel·la"
|
||||||
|
|
||||||
|
#. Careful, this palette exists already
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3261 ../../WINGs/wfilepanel.c:763
|
||||||
|
msgid "Warning"
|
||||||
|
msgstr "Atenció"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3262
|
||||||
|
msgid ""
|
||||||
|
"Palette already exists !\n"
|
||||||
|
"\n"
|
||||||
|
"Overwrite ?"
|
||||||
|
msgstr ""
|
||||||
|
"Ja existia una paleta amb aquest nom!\n"
|
||||||
|
"\n"
|
||||||
|
"La voleu sobreescriure?"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3262 ../../WINGs/wcolorpanel.c:3326
|
||||||
|
msgid "No"
|
||||||
|
msgstr "No"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3262 ../../WINGs/wcolorpanel.c:3326
|
||||||
|
msgid "Yes"
|
||||||
|
msgstr "Sí"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3294
|
||||||
|
#, c-format
|
||||||
|
msgid "Couldn't rename palette %s to %s\n"
|
||||||
|
msgstr "No s'ha pogut reanomenar la paleta %s com a %s\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3320
|
||||||
|
msgid "This will permanently remove the palette "
|
||||||
|
msgstr "Això eliminarà la paleta per sempre "
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3323
|
||||||
|
msgid ""
|
||||||
|
".\n"
|
||||||
|
"\n"
|
||||||
|
"Are you sure you want to remove this palette ?"
|
||||||
|
msgstr ""
|
||||||
|
".\n"
|
||||||
|
"\n"
|
||||||
|
"Esteu segurs que voleu eliminar aquesta paleta?"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3348
|
||||||
|
#, c-format
|
||||||
|
msgid "Couldn't remove palette %s\n"
|
||||||
|
msgstr "No s'ha pogut eliminar la paleta %s\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3647
|
||||||
|
#, c-format
|
||||||
|
msgid "Could not open %s"
|
||||||
|
msgstr "No s'ha pogut obrir %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3654
|
||||||
|
#, c-format
|
||||||
|
msgid "Could not create %s"
|
||||||
|
msgstr "No s'ha pogut crear %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3665
|
||||||
|
#, c-format
|
||||||
|
msgid "Write error on file %s"
|
||||||
|
msgstr "Error d'escriptura en el fitxer %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3710
|
||||||
|
msgid "Color Panel: Color unspecified"
|
||||||
|
msgstr "Panell de color: Color no especificat"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:235
|
||||||
|
msgid "Name:"
|
||||||
|
msgstr "Nom:"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:332 ../../WINGs/wfilepanel.c:396
|
||||||
|
msgid "Open"
|
||||||
|
msgstr "Obre"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:350 ../../WINGs/wfilepanel.c:402
|
||||||
|
msgid "Save"
|
||||||
|
msgstr "Desa"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:565
|
||||||
|
#, c-format
|
||||||
|
msgid "WINGs: could not open directory %s\n"
|
||||||
|
msgstr "WINGs: no s'ha pogut obrir el directori %s\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:583
|
||||||
|
#, c-format
|
||||||
|
msgid "WINGs: could not stat %s\n"
|
||||||
|
msgstr "WINGs: no s'ha pogut determinar l'estat de %s\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:650 ../../WINGs/wfilepanel.c:973
|
||||||
|
#: ../../WINGs/wfontpanel.c:750
|
||||||
|
msgid "Error"
|
||||||
|
msgstr "Error"
|
||||||
|
|
||||||
|
# és el nom d'un quadre de diàleg. eac
|
||||||
|
#: ../../WINGs/wfilepanel.c:661
|
||||||
|
msgid "Create Directory"
|
||||||
|
msgstr "Crear directori"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:662
|
||||||
|
msgid "Enter directory name"
|
||||||
|
msgstr "Entreu el nom del directori"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:698 ../../WINGs/wfilepanel.c:737
|
||||||
|
#: ../../WINGs/wfilepanel.c:768 ../../WINGs/wfilepanel.c:796
|
||||||
|
msgid "Permission denied."
|
||||||
|
msgstr "Permís denegat."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:701
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' already exists."
|
||||||
|
msgstr "\"%s\" existia prèviament."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:704
|
||||||
|
msgid "Path does not exist."
|
||||||
|
msgstr "L'ubicació no existeix."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:734 ../../WINGs/wfilepanel.c:793
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' does not exist."
|
||||||
|
msgstr "\"%s\" no existeix."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:741 ../../WINGs/wfilepanel.c:800
|
||||||
|
msgid "Insufficient memory available."
|
||||||
|
msgstr "No hi ha prou memòria disponible."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:745 ../../WINGs/wfilepanel.c:804
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' is on a read-only filesystem."
|
||||||
|
msgstr "\"%s\" es troba en un sistema de fitxers de només lectura."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:748 ../../WINGs/wfilepanel.c:780
|
||||||
|
#: ../../WINGs/wfilepanel.c:807
|
||||||
|
#, c-format
|
||||||
|
msgid "Can not delete '%s'."
|
||||||
|
msgstr "No s'ha pogut eliminar \"%s\"."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:755
|
||||||
|
#, c-format
|
||||||
|
msgid "Delete directory %s ?"
|
||||||
|
msgstr "Voleu eliminar el directori %s ?"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:759
|
||||||
|
#, c-format
|
||||||
|
msgid "Delete file %s ?"
|
||||||
|
msgstr "Voleu eliminar el fitxer %s ?"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:771
|
||||||
|
#, c-format
|
||||||
|
msgid "Directory '%s' does not exist."
|
||||||
|
msgstr "El directori \"%s\" no existeix."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:774
|
||||||
|
#, c-format
|
||||||
|
msgid "Directory '%s' is not empty."
|
||||||
|
msgstr "El directori \"%s\" no està buit."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:777
|
||||||
|
#, c-format
|
||||||
|
msgid "Directory '%s' is busy."
|
||||||
|
msgstr "El directori \"%s\" es troba ocupat."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:790
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' is a directory."
|
||||||
|
msgstr "\"%s\" és un directori."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:832
|
||||||
|
#, c-format
|
||||||
|
msgid "An error occured browsing '%s'."
|
||||||
|
msgstr "S'ha produït un error mentre s'explorava \"%s\"."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:836
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' is not a directory."
|
||||||
|
msgstr "\"%s\" no és un directori."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:973
|
||||||
|
msgid "File does not exist."
|
||||||
|
msgstr "El fitxer no existeix."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:324 ../../WINGs/wfont.c:344
|
||||||
|
#, c-format
|
||||||
|
msgid "could not load font %s."
|
||||||
|
msgstr "no s'ha pogut carregar el tipus de lletra %s."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:375 ../../WINGs/wfont.c:420 ../../WINGs/wfont.c:475
|
||||||
|
#: ../../WINGs/wfont.c:1337 ../../WINGs/wfont.c:1398 ../../WINGs/wfont.c:1469
|
||||||
|
#, c-format
|
||||||
|
msgid ""
|
||||||
|
"Conversion to widechar failed (possible invalid multibyte sequence): '%s':"
|
||||||
|
"(pos %d)\n"
|
||||||
|
msgstr ""
|
||||||
|
"Ha fallat la conversió a caràcter estès (possible seqüència no vàlida): '%"
|
||||||
|
"s': (pos %d)\n"
|
||||||
|
|
||||||
|
#. // remove warning later. or maybe not
|
||||||
|
#: ../../WINGs/wfont.c:591 ../../WINGs/wfont.c:1568
|
||||||
|
#, c-format
|
||||||
|
msgid "Invalid font specification: '%s'\n"
|
||||||
|
msgstr "Especificació de font no vàlida: \"%s\"\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:770 ../../WINGs/wfont.c:780
|
||||||
|
#, c-format
|
||||||
|
msgid "Invalid size specification '%s' in %s. Using default %d\n"
|
||||||
|
msgstr ""
|
||||||
|
"La mida \"%s\" especificada a %s no és vàlida. S'usa el valor per omissió %"
|
||||||
|
"d\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:824
|
||||||
|
#, c-format
|
||||||
|
msgid "the following character sets are missing in %s:"
|
||||||
|
msgstr "els següents conjunts de caràcters falten a %s:"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:830
|
||||||
|
#, c-format
|
||||||
|
msgid ""
|
||||||
|
"the string \"%s\" will be used in place of any characters from those sets."
|
||||||
|
msgstr ""
|
||||||
|
"la cadena \"%s\" s'usarà en lloc dels caràcters d'aquests conjunts de "
|
||||||
|
"caràcters."
|
||||||
|
|
||||||
|
#. is arial a good fallback for multibyte?
|
||||||
|
#: ../../WINGs/wfont.c:1232 ../../WINGs/wfont.c:1247
|
||||||
|
#, c-format
|
||||||
|
msgid "could not load font %s. Trying arial."
|
||||||
|
msgstr "no s'ha pogut carregar el tipus de lletra %s. Provant amb \"arial\"."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:1239
|
||||||
|
msgid "could not load antialiased font set. Reverting to standard font sets."
|
||||||
|
msgstr ""
|
||||||
|
"no s'ha pogut carregar el conjunt de fonts amb allisat. S'usarà l'estàndard."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:1242
|
||||||
|
#, c-format
|
||||||
|
msgid "could not load FontSet %s. Trying fixed."
|
||||||
|
msgstr "no s'ha pogut carregar el tipus de lletra %s. Provant amb \"fixed\"."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:1254
|
||||||
|
msgid "could not load antialiased fonts. Reverting to normal fonts."
|
||||||
|
msgstr "no s'han pogut carregar fonts allisades. S'usaran fonts normals."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:1257 ../../WINGs/wfont.c:1268
|
||||||
|
#, c-format
|
||||||
|
msgid "could not load font %s. Trying fixed."
|
||||||
|
msgstr "no s'ha pogut carregar la font %s. Provant amb \"fixed\"."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:1262
|
||||||
|
#, c-format
|
||||||
|
msgid "could not load font set %s. Trying fixed."
|
||||||
|
msgstr "no s'ha pogut carregar el conjunt de fonts %s. Provant amb \"fixed\"."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:1272
|
||||||
|
msgid "could not load fixed font!"
|
||||||
|
msgstr "no s'ha pogut carregar el tipus de lletra \"fixed\" !"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:1520
|
||||||
|
#, c-format
|
||||||
|
msgid "font description %s is too large."
|
||||||
|
msgstr "la descripció de tipus de lletra %s és massa gran."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:235
|
||||||
|
msgid "Test!!!"
|
||||||
|
msgstr "Prova!!!"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:241
|
||||||
|
msgid "Family"
|
||||||
|
msgstr "Familia"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:252
|
||||||
|
msgid "Typeface"
|
||||||
|
msgstr "Fosa"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:263
|
||||||
|
msgid "Size"
|
||||||
|
msgstr "Mida"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:282
|
||||||
|
msgid "Set"
|
||||||
|
msgstr "Conjunt"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:288
|
||||||
|
msgid "Revert"
|
||||||
|
msgstr "Torna"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:751
|
||||||
|
msgid "Could not retrieve font list"
|
||||||
|
msgstr "No s'ha pogut obtenir la llista de tipus de lletra"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:765
|
||||||
|
#, c-format
|
||||||
|
msgid "font name %s is longer than 256, which is invalid."
|
||||||
|
msgstr ""
|
||||||
|
"el nom de tipus de lletra %s ocupa més de 256 caràcters, per tant no és "
|
||||||
|
"vàlid."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:913
|
||||||
|
msgid "Roman"
|
||||||
|
msgstr "Romana"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:916
|
||||||
|
msgid "Italic"
|
||||||
|
msgstr "Itàlica"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:918
|
||||||
|
msgid "Oblique"
|
||||||
|
msgstr "Obliqua"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:920
|
||||||
|
msgid "Rev Italic"
|
||||||
|
msgstr "Itàlica inv"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:922
|
||||||
|
msgid "Rev Oblique"
|
||||||
|
msgstr "Obliqua inv"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:928
|
||||||
|
msgid "Normal"
|
||||||
|
msgstr "Normal"
|
||||||
|
|
||||||
|
#: ../../WINGs/widgets.c:419
|
||||||
|
#, c-format
|
||||||
|
msgid "WINGs: could not load widget images file: %s"
|
||||||
|
msgstr "WINGs: no s'ha pogut carregar el fitxer d'imatges: %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/widgets.c:772
|
||||||
|
msgid ""
|
||||||
|
"could not load any fonts. Make sure your font installation and locale "
|
||||||
|
"settings are correct."
|
||||||
|
msgstr ""
|
||||||
|
"no s'ha pogut carregar cap font. Assegureu-vos que heu instal·lat i "
|
||||||
|
"configurat correctament les fonts i el local."
|
||||||
|
|
||||||
|
#: ../../WINGs/wruler.c:192
|
||||||
|
msgid "0 inches"
|
||||||
|
msgstr "0 polzades"
|
||||||
|
|
||||||
|
#~ msgid ""
|
||||||
|
#~ "Text antialiasing is enabled in the configuration but the X server "
|
||||||
|
#~ "doesn't have the required capabilities (missing RENDER extension). "
|
||||||
|
#~ "Disabling text antialiasing."
|
||||||
|
#~ msgstr ""
|
||||||
|
#~ "L'allisat de text està habilitat a la configuració però el servidor X no\n"
|
||||||
|
#~ "té la capacitat necessària (falta l'extensió RENDER) de manera que "
|
||||||
|
#~ "l'allisat\n"
|
||||||
|
#~ "de text es deshabilitarà."
|
||||||
663
WINGs/po/cs.po
Normal file
663
WINGs/po/cs.po
Normal file
@@ -0,0 +1,663 @@
|
|||||||
|
# Czech messages for WINGs
|
||||||
|
# (C) 2001 Jiří Hnídek
|
||||||
|
# Special thanks to Jan "judas" Tomka
|
||||||
|
#
|
||||||
|
# Original translation by Jiří Hnídek on Oct 11 2001
|
||||||
|
# Currently maintained by Jiří Hnídek <jiri.hnidek@vslib.cz>
|
||||||
|
#
|
||||||
|
msgid ""
|
||||||
|
msgstr ""
|
||||||
|
"Project-Id-Version: WINGs 0.70.0\n"
|
||||||
|
"POT-Creation-Date: 2001-10-11 19:10+0100\n"
|
||||||
|
"PO-Revision-Date: 2001-10-11 22:00+0100\n"
|
||||||
|
"Last-Translator: Jiří Hnídek <jiri.hnidek@vslib.cz>\n"
|
||||||
|
"Language-Team: Czech <cz@li.org>\n"
|
||||||
|
"MIME-Version: 1.0\n"
|
||||||
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
|
"Content-Transfer-Encoding: unknown\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/connection.c:451 ../../WINGs/connection.c:516
|
||||||
|
#: ../../WINGs/connection.c:559
|
||||||
|
msgid "Bad address-service-protocol combination"
|
||||||
|
msgstr "Nesprávná kombinace adresa-služba-protokol"
|
||||||
|
|
||||||
|
#: ../../WINGs/dragsource.c:541
|
||||||
|
msgid "DND selection lost during drag operation..."
|
||||||
|
msgstr "DND výběr se ztratil během opere táhnutí..."
|
||||||
|
|
||||||
|
#: ../../WINGs/dragsource.c:610
|
||||||
|
#, c-format
|
||||||
|
msgid "drag & drop timed out while waiting for response from 0x%x\n"
|
||||||
|
msgstr "čas pro drag & drop vypršel během čekání na odpoveď z 0x%x\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/dragsource.c:728
|
||||||
|
msgid "could not get ownership or DND selection"
|
||||||
|
msgstr "nemožné získat vlastnictví nebo DND výběr"
|
||||||
|
|
||||||
|
#: ../../WINGs/dragsource.c:898
|
||||||
|
#, c-format
|
||||||
|
msgid "drag source received unexpected XdndFinished message from %x"
|
||||||
|
msgstr "zdroj tahání přijal neočekávanou zprávu XdndFinished z %x"
|
||||||
|
|
||||||
|
#: ../../WINGs/dragsource.c:1040
|
||||||
|
#, c-format
|
||||||
|
msgid "unknown XDND action %s from 0x%x"
|
||||||
|
msgstr "neznámá XDND akce %s z 0x%x"
|
||||||
|
|
||||||
|
#: ../../WINGs/dragsource.c:1073
|
||||||
|
msgid "received invalid drag & drop type list"
|
||||||
|
msgstr "přijatý nesprávný seznam typů drag & drop"
|
||||||
|
|
||||||
|
#: ../../WINGs/dragsource.c:1161
|
||||||
|
msgid "received Enter event in bad order"
|
||||||
|
msgstr "přijatá událost Enter v nesprávném pořadí"
|
||||||
|
|
||||||
|
#: ../../WINGs/dragsource.c:1168
|
||||||
|
#, c-format
|
||||||
|
msgid "received drag & drop request with unsupported version %i"
|
||||||
|
msgstr "přijatý požadavek drag & drop s nepodporovanou verzí %i"
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:56
|
||||||
|
#, c-format
|
||||||
|
msgid "Unknown error %d"
|
||||||
|
msgstr "Neznámá chyba %d"
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:61
|
||||||
|
#, c-format
|
||||||
|
msgid "Error %d"
|
||||||
|
msgstr "Chyba %d"
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:112
|
||||||
|
msgid " warning: "
|
||||||
|
msgstr " varovíní: "
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:139
|
||||||
|
msgid " fatal error: "
|
||||||
|
msgstr " fatální chyba: "
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:165 ../../WINGs/error.c:194
|
||||||
|
msgid " error: "
|
||||||
|
msgstr " chyba: "
|
||||||
|
|
||||||
|
#: ../../WINGs/findfile.c:50
|
||||||
|
#, c-format
|
||||||
|
msgid "could not get password entry for UID %i"
|
||||||
|
msgstr "nemožné zjistit informaci o UID %i"
|
||||||
|
|
||||||
|
#: ../../WINGs/findfile.c:68
|
||||||
|
#, c-format
|
||||||
|
msgid "could not get password entry for user %s"
|
||||||
|
msgstr "nemožné zjistit informaci o uživatelovi %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/hashtable.c:275
|
||||||
|
msgid "rebuilding hash table...\n"
|
||||||
|
msgstr "přepis tabulky hashovských funkcí...\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/hashtable.c:279
|
||||||
|
msgid "finished rebuild.\n"
|
||||||
|
msgstr "konec přepisu.\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/host.c:116
|
||||||
|
msgid "Cannot get current host name"
|
||||||
|
msgstr "Nemožné zjistit aktuální jméno počítače"
|
||||||
|
|
||||||
|
#: ../../WINGs/memory.c:94
|
||||||
|
msgid "malloc() failed. Retrying after 2s."
|
||||||
|
msgstr "chyba malloc(). Nový pokus o 2s."
|
||||||
|
|
||||||
|
#: ../../WINGs/memory.c:103
|
||||||
|
msgid "Really Bad Error: recursive malloc() failure."
|
||||||
|
msgstr "Skutečně ošklivá chyba: rekurzivní chyba malloc()."
|
||||||
|
|
||||||
|
#: ../../WINGs/memory.c:106 ../../WINGs/memory.c:146
|
||||||
|
msgid "virtual memory exhausted"
|
||||||
|
msgstr "virtuální paměť vyčerpaná"
|
||||||
|
|
||||||
|
#: ../../WINGs/memory.c:133
|
||||||
|
msgid "realloc() failed. Retrying after 2s."
|
||||||
|
msgstr "chyba realloc(). Nový pokus o 2s."
|
||||||
|
|
||||||
|
#: ../../WINGs/memory.c:142
|
||||||
|
msgid "Really Bad Error: recursive realloc() failure."
|
||||||
|
msgstr "Skutečně ošklivá chyba: rekurzivní chyba realloc()."
|
||||||
|
|
||||||
|
#: ../../WINGs/memory.c:205
|
||||||
|
#, c-format
|
||||||
|
msgid "trying to release unexisting data %p"
|
||||||
|
msgstr "pokus uvolnit neexistujícá data %p"
|
||||||
|
|
||||||
|
#: ../../WINGs/memory.c:210
|
||||||
|
#, c-format
|
||||||
|
msgid "RELEASING %p\n"
|
||||||
|
msgstr "UVOLNĚNÍ %p\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:198 ../../WINGs/wcolor.c:211 ../../WINGs/wcolor.c:250
|
||||||
|
#: ../../WINGs/wcolor.c:291
|
||||||
|
#, c-format
|
||||||
|
msgid "could not allocate %s color"
|
||||||
|
msgstr "nemožné alokovat %s barvu"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:198
|
||||||
|
msgid "white"
|
||||||
|
msgstr "bílou"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:211
|
||||||
|
msgid "black"
|
||||||
|
msgstr "černou"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:250
|
||||||
|
msgid "gray"
|
||||||
|
msgstr "šedou"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:291
|
||||||
|
msgid "dark gray"
|
||||||
|
msgstr "tmavě šedou"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:410
|
||||||
|
msgid "Colors"
|
||||||
|
msgstr "Barvy"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:600 ../../WINGs/wcolorpanel.c:2819
|
||||||
|
msgid "Brightness"
|
||||||
|
msgstr "Světlost"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:602 ../../WINGs/wcolorpanel.c:678
|
||||||
|
#: ../../WINGs/wcolorpanel.c:711 ../../WINGs/wcolorpanel.c:745
|
||||||
|
#: ../../WINGs/wcolorpanel.c:805 ../../WINGs/wcolorpanel.c:839
|
||||||
|
#: ../../WINGs/wcolorpanel.c:873 ../../WINGs/wcolorpanel.c:908
|
||||||
|
#: ../../WINGs/wcolorpanel.c:2159 ../../WINGs/wcolorpanel.c:2821
|
||||||
|
#: ../../WINGs/wcolorpanel.c:2857 ../../WINGs/wcolorpanel.c:2893
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3741
|
||||||
|
msgid "Color Panel: Could not allocate memory"
|
||||||
|
msgstr "Panel barev: Nemožné alokovat paměť"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:675 ../../WINGs/wcolorpanel.c:676
|
||||||
|
msgid "Red"
|
||||||
|
msgstr "Červená"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:708 ../../WINGs/wcolorpanel.c:709
|
||||||
|
msgid "Green"
|
||||||
|
msgstr "Zelená"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:742 ../../WINGs/wcolorpanel.c:743
|
||||||
|
msgid "Blue"
|
||||||
|
msgstr "Modrá"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:802 ../../WINGs/wcolorpanel.c:803
|
||||||
|
msgid "Cyan"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:836 ../../WINGs/wcolorpanel.c:837
|
||||||
|
msgid "Magenta"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:870 ../../WINGs/wcolorpanel.c:871
|
||||||
|
msgid "Yellow"
|
||||||
|
msgstr "Žlutá"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:905 ../../WINGs/wcolorpanel.c:906
|
||||||
|
msgid "Black"
|
||||||
|
msgstr "Černá"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:986
|
||||||
|
msgid "Spectrum"
|
||||||
|
msgstr "Spektrum"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1016
|
||||||
|
msgid "Palette"
|
||||||
|
msgstr "Paleta"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1022
|
||||||
|
msgid "New from File..."
|
||||||
|
msgstr "Nová ze souboru..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1023 ../../WINGs/wcolorpanel.c:1071
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1088
|
||||||
|
msgid "Rename..."
|
||||||
|
msgstr "Přejmenovat..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1024 ../../WINGs/wcolorpanel.c:1072
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1089 ../../WINGs/wcolorpanel.c:3316
|
||||||
|
msgid "Remove"
|
||||||
|
msgstr "Odstranit"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1025
|
||||||
|
msgid "Copy"
|
||||||
|
msgstr "Kopírovat"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1026
|
||||||
|
msgid "New from Clipboard"
|
||||||
|
msgstr "Nová ze schránky"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1047
|
||||||
|
msgid "X11-Colors"
|
||||||
|
msgstr "Barvy X11"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1064
|
||||||
|
msgid "Color"
|
||||||
|
msgstr "Barva"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1070
|
||||||
|
msgid "Add..."
|
||||||
|
msgstr "Přidat..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1080
|
||||||
|
msgid "List"
|
||||||
|
msgstr "Seznam"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1087
|
||||||
|
msgid "New..."
|
||||||
|
msgstr "Nový..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1226
|
||||||
|
#, c-format
|
||||||
|
msgid ""
|
||||||
|
"Color Panel: Could not create directory %s needed to store configurations"
|
||||||
|
msgstr ""
|
||||||
|
"Panel barev: Nemožné vytvořit adresář %s potřebný k uložení nastavení"
|
||||||
|
|
||||||
|
#. Delete the file, it doesn't belong here
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1232 ../../WINGs/wcolorpanel.c:3202
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3206
|
||||||
|
msgid "File Error"
|
||||||
|
msgstr "Chyba souboru"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1233
|
||||||
|
msgid "Could not create ColorPanel configuration directory"
|
||||||
|
msgstr "Nemožné vytvořit konfigurační adresář panelu barev"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1234 ../../WINGs/wcolorpanel.c:3203
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3208 ../../WINGs/wcolorpanel.c:3235
|
||||||
|
#: ../../WINGs/wfilepanel.c:243 ../../WINGs/wfilepanel.c:641
|
||||||
|
#: ../../WINGs/wfilepanel.c:653 ../../WINGs/wfilepanel.c:752
|
||||||
|
#: ../../WINGs/wfilepanel.c:963 ../../WINGs/wfontpanel.c:717
|
||||||
|
msgid "OK"
|
||||||
|
msgstr "OK"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1240 ../../WINGs/wcolorpanel.c:1276
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1294
|
||||||
|
msgid "Color Panel: Could not find file"
|
||||||
|
msgstr "Panel barev: Nemožné nalézt soubor"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1481 ../../WINGs/wcolorpanel.c:1546
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1610
|
||||||
|
msgid "Color Panel: X failed request"
|
||||||
|
msgstr "Panel barev: chyba požadavku X"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:2855
|
||||||
|
msgid "Saturation"
|
||||||
|
msgstr "Saturace"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:2891
|
||||||
|
msgid "Hue"
|
||||||
|
msgstr "Odteď"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3141
|
||||||
|
msgid "Open Palette"
|
||||||
|
msgstr "Otevřít paletu"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3203
|
||||||
|
msgid "Invalid file format !"
|
||||||
|
msgstr "Nesprávný souborový formát!"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3205
|
||||||
|
#, c-format
|
||||||
|
msgid "can't remove file %s"
|
||||||
|
msgstr "nemožné odstranit soubor %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3207
|
||||||
|
msgid "Couldn't remove file from Configuration Directory !"
|
||||||
|
msgstr "Nemožné odstranit soubor z konfiguračního adresáře!"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3234
|
||||||
|
msgid "Rename"
|
||||||
|
msgstr "Přejmenovat"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3234
|
||||||
|
msgid "Rename palette to:"
|
||||||
|
msgstr "Přejmenovat paletu:"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3235 ../../WINGs/wfilepanel.c:252
|
||||||
|
#: ../../WINGs/wfilepanel.c:653 ../../WINGs/wfilepanel.c:752
|
||||||
|
msgid "Cancel"
|
||||||
|
msgstr "Zrušit"
|
||||||
|
|
||||||
|
#. Careful, this palette exists already
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3251 ../../WINGs/wfilepanel.c:752
|
||||||
|
msgid "Warning"
|
||||||
|
msgstr "Varování"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3252
|
||||||
|
msgid ""
|
||||||
|
"Palette already exists !\n"
|
||||||
|
"\n"
|
||||||
|
"Overwrite ?"
|
||||||
|
msgstr ""
|
||||||
|
"Paleta už existuje!\n"
|
||||||
|
"\n"
|
||||||
|
"Přepsat?"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3252 ../../WINGs/wcolorpanel.c:3316
|
||||||
|
msgid "No"
|
||||||
|
msgstr "Ne"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3252 ../../WINGs/wcolorpanel.c:3316
|
||||||
|
msgid "Yes"
|
||||||
|
msgstr "Ano"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3284
|
||||||
|
#, c-format
|
||||||
|
msgid "Couldn't rename palette %s to %s\n"
|
||||||
|
msgstr "Nemožné přejmenovat paletu %s na %s\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3310
|
||||||
|
msgid "This will permanently remove the palette "
|
||||||
|
msgstr "Paleta bude natrvalo smazaná"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3313
|
||||||
|
msgid ""
|
||||||
|
".\n"
|
||||||
|
"\n"
|
||||||
|
"Are you sure you want to remove this palette ?"
|
||||||
|
msgstr ""
|
||||||
|
".\n"
|
||||||
|
"\n"
|
||||||
|
"Jste si jisti, že chcete odstranit tuto paletu?"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3338
|
||||||
|
#, c-format
|
||||||
|
msgid "Couldn't remove palette %s\n"
|
||||||
|
msgstr "Nemožné odstranit paletu %s\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3643
|
||||||
|
#, c-format
|
||||||
|
msgid "Could not open %s"
|
||||||
|
msgstr "Nemožné otevřít %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3650
|
||||||
|
#, c-format
|
||||||
|
msgid "Could not create %s"
|
||||||
|
msgstr "Nemožné vytvořit %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3661
|
||||||
|
#, c-format
|
||||||
|
msgid "Write error on file %s"
|
||||||
|
msgstr "Chyba při zápisu do souboru %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3706
|
||||||
|
msgid "Color Panel: Color unspecified"
|
||||||
|
msgstr "Panel barev: Nespecifikovaná barva"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:228
|
||||||
|
msgid "Name:"
|
||||||
|
msgstr "Jméno:"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:325 ../../WINGs/wfilepanel.c:390
|
||||||
|
msgid "Open"
|
||||||
|
msgstr "Otevřít"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:343 ../../WINGs/wfilepanel.c:396
|
||||||
|
msgid "Save"
|
||||||
|
msgstr "Uložit"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:556
|
||||||
|
#, c-format
|
||||||
|
msgid "WINGs: could not open directory %s\n"
|
||||||
|
msgstr "WINGs: nemožné otevřít adresář %s\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:574
|
||||||
|
#, c-format
|
||||||
|
msgid "WINGs: could not stat %s\n"
|
||||||
|
msgstr "WINGs: nemožné zjistit informace o %s\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:641 ../../WINGs/wfilepanel.c:962
|
||||||
|
#: ../../WINGs/wfontpanel.c:716
|
||||||
|
msgid "Error"
|
||||||
|
msgstr "Chyba"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:652
|
||||||
|
msgid "Create Directory"
|
||||||
|
msgstr "Vytvořit adresář"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:653
|
||||||
|
msgid "Enter directory name"
|
||||||
|
msgstr "Jméno adresáře"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:689 ../../WINGs/wfilepanel.c:728
|
||||||
|
#: ../../WINGs/wfilepanel.c:757 ../../WINGs/wfilepanel.c:785
|
||||||
|
msgid "Permission denied."
|
||||||
|
msgstr "Přístup odmítnut."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:692
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' already exists."
|
||||||
|
msgstr "'%s' už existuje"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:695
|
||||||
|
msgid "Path does not exist."
|
||||||
|
msgstr "Cesta neexistuje."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:725 ../../WINGs/wfilepanel.c:782
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' does not exist."
|
||||||
|
msgstr "'%s' neexistuje."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:732 ../../WINGs/wfilepanel.c:789
|
||||||
|
msgid "Insufficient memory available."
|
||||||
|
msgstr "Nedostatek paměti."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:736 ../../WINGs/wfilepanel.c:793
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' is on a read-only filesystem."
|
||||||
|
msgstr "'%s' je na souborovém systému jen pro čtení."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:739 ../../WINGs/wfilepanel.c:769
|
||||||
|
#: ../../WINGs/wfilepanel.c:796
|
||||||
|
#, c-format
|
||||||
|
msgid "Can not delete '%s'."
|
||||||
|
msgstr "Nemožné odstranit '%s'."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:745
|
||||||
|
#, c-format
|
||||||
|
msgid "Delete directory %s ?"
|
||||||
|
msgstr "Odstranit adresář %s?"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:748
|
||||||
|
#, c-format
|
||||||
|
msgid "Delete file %s ?"
|
||||||
|
msgstr "Odstranit soubor %s?"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:760
|
||||||
|
#, c-format
|
||||||
|
msgid "Directory '%s' does not exist."
|
||||||
|
msgstr "Adresář '%s' neexistuje."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:763
|
||||||
|
#, c-format
|
||||||
|
msgid "Directory '%s' is not empty."
|
||||||
|
msgstr "Adresář '%s' není prázdný."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:766
|
||||||
|
#, c-format
|
||||||
|
msgid "Directory '%s' is busy."
|
||||||
|
msgstr "Adresář '%s' je používaný."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:779
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' is a directory."
|
||||||
|
msgstr "'%s' je adresář."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:821
|
||||||
|
#, c-format
|
||||||
|
msgid "An error occured browsing '%s'."
|
||||||
|
msgstr "Při prohlížení '%s' nastala chyba."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:825
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' is not a directory."
|
||||||
|
msgstr "'%s' není adresář."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:962
|
||||||
|
msgid "File does not exist."
|
||||||
|
msgstr "Soubor neexistuje."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:129
|
||||||
|
#, c-format
|
||||||
|
msgid "the following character sets are missing in %s:"
|
||||||
|
msgstr "nasledující sady znaků chybí v %s:"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:136
|
||||||
|
#, c-format
|
||||||
|
msgid ""
|
||||||
|
"the string \"%s\" will be used in place of any characters from those sets."
|
||||||
|
msgstr ""
|
||||||
|
"řetězec \"%s\" bude použitý namísto znaků z těchto sad."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:282 ../../WINGs/wfont.c:318
|
||||||
|
#, c-format
|
||||||
|
msgid "could not load font set %s. Trying fixed."
|
||||||
|
msgstr "nemožné načíst font %s. Zkouší se načíst fixed."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:288 ../../WINGs/wfont.c:324
|
||||||
|
#, c-format
|
||||||
|
msgid "could not load font %s. Trying fixed."
|
||||||
|
msgstr "nemožno načíst font %s. Zkoší se načíst fixed."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:292 ../../WINGs/wfont.c:328
|
||||||
|
msgid "could not load fixed font!"
|
||||||
|
msgstr "nemožné načíst font fixed!"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:423
|
||||||
|
#, c-format
|
||||||
|
msgid "font description %s is too large."
|
||||||
|
msgstr "popis fontu %s je příliš velký."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:205
|
||||||
|
msgid "Test!!!"
|
||||||
|
msgstr "Zkouška!!!"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:211
|
||||||
|
msgid "Family"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:222
|
||||||
|
msgid "Typeface"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:233
|
||||||
|
msgid "Size"
|
||||||
|
msgstr "Velikost"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:252
|
||||||
|
msgid "Set"
|
||||||
|
msgstr "Sada"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:257
|
||||||
|
msgid "Revert"
|
||||||
|
msgstr "Zpět"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:717
|
||||||
|
msgid "Could not retrieve font list"
|
||||||
|
msgstr "Nemožné obdržet seznam fontů"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:729
|
||||||
|
#, c-format
|
||||||
|
msgid "font name %s is longer than 256, which is invalid."
|
||||||
|
msgstr "jméno fontu %s je delší než 256, což je špatně."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:880
|
||||||
|
msgid "Roman"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:883
|
||||||
|
msgid "Italic"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:885
|
||||||
|
msgid "Oblique"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:887
|
||||||
|
msgid "Rev Italic"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:889
|
||||||
|
msgid "Rev Oblique"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:895
|
||||||
|
msgid "Normal"
|
||||||
|
msgstr "Normílní"
|
||||||
|
|
||||||
|
#: ../../WINGs/widgets.c:414
|
||||||
|
#, c-format
|
||||||
|
msgid "WINGs: could not load widget images file: %s"
|
||||||
|
msgstr "WINGs: nemožné načíst soubor s obrázky pro widgety: %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/widgets.c:525
|
||||||
|
#, c-format
|
||||||
|
msgid "WINGs: could not open display %s"
|
||||||
|
msgstr "WINGs: nemožné otevřít display %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/widgets.c:717
|
||||||
|
msgid ""
|
||||||
|
"could not load any fonts. Make sure your font installationand locale "
|
||||||
|
"settings are correct."
|
||||||
|
msgstr ""
|
||||||
|
"nemožné načíst žádný font. Ubezpečte se, že instalace fontů a místního "
|
||||||
|
"nastavení jsou v pořádku."
|
||||||
|
|
||||||
|
#: ../../WINGs/wruler.c:189
|
||||||
|
msgid "0 inches"
|
||||||
|
msgstr "0 palců"
|
||||||
|
|
||||||
|
#: ../../WINGs/wtext.c:1212
|
||||||
|
msgid "...for this app will surely crash :-)\n"
|
||||||
|
msgstr "...pro tuto aplikaci to určitě spadne :-)\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wtext.c:2084
|
||||||
|
msgid "didn't get it\n"
|
||||||
|
msgstr "nedosaženo\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wtext.c:2726
|
||||||
|
#, c-format
|
||||||
|
msgid "type is [%s]\n"
|
||||||
|
msgstr "typ je [%s]\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wtext.c:2797
|
||||||
|
msgid "could not request data for dropped data"
|
||||||
|
msgstr "nemohou být vyžádána data pro položená data"
|
||||||
|
|
||||||
|
#: ../../WINGs/wtext.c:2995
|
||||||
|
msgid "could not create text's view\n"
|
||||||
|
msgstr "nemožné zobrazit text\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wview.c:219
|
||||||
|
msgid "trying to realize widget of unrealized parent"
|
||||||
|
msgstr "snaha vytvořit widget neexistujícího rodiče objektu"
|
||||||
|
|
||||||
|
#: ../../WINGs/wview.c:267
|
||||||
|
msgid "trying to reparent realized view to unrealized parent"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../WINGs/wtextfield.c:490
|
||||||
|
msgid "only left alignment is supported in textfields"
|
||||||
|
msgstr "pro textové pole je povolené jen levé zarovnání"
|
||||||
|
|
||||||
|
#pozor, co je STRING?
|
||||||
|
#: ../../WINGs/wwindow.c:222
|
||||||
|
msgid "window title conversion error... using STRING encoding"
|
||||||
|
msgstr "chyba konverze titulku okna... použije se kódovaní STRING"
|
||||||
|
|
||||||
|
#: ../../WINGs/wwindow.c:313
|
||||||
|
msgid "could not allocate memory for window size hints"
|
||||||
|
msgstr "nemožné alokovat paměť pro pokyny velikosti okna"
|
||||||
|
|
||||||
|
#: ../../WINGs/wwindow.c:586
|
||||||
|
msgid "could not allocate memory for WM hints"
|
||||||
|
msgstr "nemožné alokovat paměť pro pokyny WM"
|
||||||
|
|
||||||
|
#: ../../WINGs/wwindow.c:627
|
||||||
|
msgid "icon title conversion error..using STRING encoding"
|
||||||
|
msgstr "chyba konverze titulku ikony... použije se kódovaní STRING"
|
||||||
|
|
||||||
664
WINGs/po/de.po
Normal file
664
WINGs/po/de.po
Normal file
@@ -0,0 +1,664 @@
|
|||||||
|
# KTranslator Generated File
|
||||||
|
# SOME DESCRIPTIVE TITLE.
|
||||||
|
# Copyright (C) YEAR Free Software Foundation, Inc.
|
||||||
|
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
|
||||||
|
#
|
||||||
|
#, fuzzy
|
||||||
|
msgid ""
|
||||||
|
msgstr ""
|
||||||
|
"Project-Id-Version: WINGs 0.80.0\n"
|
||||||
|
"POT-Creation-Date: 2002-01-09 21:06+0100\n"
|
||||||
|
"PO-Revision-Date: 2002-01-09 21:20+0100\n"
|
||||||
|
"Last-Translator: Guido Scholz <guido.scholz@bayernline.de>\n"
|
||||||
|
"Language-Team: Deutsch <de@li.org>\n"
|
||||||
|
"MIME-Version: 1.0\n"
|
||||||
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
|
"Content-Transfer-Encoding: unknown\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/connection.c:461 ../../WINGs/connection.c:526
|
||||||
|
#: ../../WINGs/connection.c:569
|
||||||
|
msgid "Bad address-service-protocol combination"
|
||||||
|
msgstr "Ungültige Adress-Dienst-Protokoll Kombination"
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:54
|
||||||
|
#, c-format
|
||||||
|
msgid "Unknown error %d"
|
||||||
|
msgstr "Unbekannter Fehler %d"
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:59
|
||||||
|
#, c-format
|
||||||
|
msgid "Error %d"
|
||||||
|
msgstr "Fehler %d"
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:110
|
||||||
|
msgid " warning: "
|
||||||
|
msgstr " Warnung: "
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:137
|
||||||
|
msgid " fatal error: "
|
||||||
|
msgstr " fataler Fehler: "
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:163 ../../WINGs/error.c:192
|
||||||
|
msgid " error: "
|
||||||
|
msgstr " Fehler: "
|
||||||
|
|
||||||
|
#: ../../WINGs/findfile.c:48
|
||||||
|
#, c-format
|
||||||
|
msgid "could not get password entry for UID %i"
|
||||||
|
msgstr "konnte Passwort nicht ermitteln für UID %i"
|
||||||
|
|
||||||
|
#: ../../WINGs/findfile.c:66
|
||||||
|
#, c-format
|
||||||
|
msgid "could not get password entry for user %s"
|
||||||
|
msgstr "konnte Passwort nicht ermitteln für Benutzer %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/host.c:114
|
||||||
|
msgid "Cannot get current host name"
|
||||||
|
msgstr "Kann aktuellen Hostnamen nicht ermitteln"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:150
|
||||||
|
msgid "Only string or data is supported for a proplist dictionary key"
|
||||||
|
msgstr ""
|
||||||
|
"Nur string oder data wird als Schlüssel für ein proplist dictionary "
|
||||||
|
"unterstützt"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:184 ../../WINGs/proplist.c:236
|
||||||
|
#: ../../WINGs/proplist.c:394 ../../WINGs/proplist.c:474
|
||||||
|
#: ../../WINGs/proplist.c:1071 ../../WINGs/proplist.c:1123
|
||||||
|
#: ../../WINGs/proplist.c:1289 ../../WINGs/proplist.c:1368
|
||||||
|
#: ../../WINGs/proplist.c:1489 ../../WINGs/proplist.c:1536
|
||||||
|
msgid "Used proplist functions on non-WMPropLists objects"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:630
|
||||||
|
msgid "unterminated PropList string"
|
||||||
|
msgstr "nicht terminierter PropList string"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:670
|
||||||
|
msgid "unterminated PropList data"
|
||||||
|
msgstr "nicht terminiertes PropList data"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:678
|
||||||
|
msgid "unterminated PropList data (missing hexdigit)"
|
||||||
|
msgstr "nicht terminiertes PropList data (fehlendes hex-Zeichen)"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:690
|
||||||
|
msgid "non hexdigit character in PropList data"
|
||||||
|
msgstr "falsches hex-Zeichen in PropList data"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:725
|
||||||
|
msgid "unterminated PropList array"
|
||||||
|
msgstr "nicht terminiertes PropList array"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:733
|
||||||
|
msgid "missing or unterminated PropList array"
|
||||||
|
msgstr "fehlendes oder nicht terminiertes PropList array"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:743
|
||||||
|
msgid "could not get PropList array element"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:772
|
||||||
|
msgid "unterminated PropList dictionary"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:789
|
||||||
|
msgid "missing PropList dictionary key"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:791
|
||||||
|
msgid "missing PropList dictionary entry key or unterminated dictionary"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:799
|
||||||
|
msgid "error parsing PropList dictionary key"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:807
|
||||||
|
msgid "missing = in PropList dictionary entry"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:815
|
||||||
|
msgid "error parsing PropList dictionary entry value"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:823
|
||||||
|
msgid "missing ; in PropList dictionary entry"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:884
|
||||||
|
msgid ""
|
||||||
|
"was expecting a string, data, array or dictionary. If it's a string, try "
|
||||||
|
"enclosing it with \"."
|
||||||
|
msgstr ""
|
||||||
|
"string, data, array oder dictionary wurde erwartet. Zeichenketten mit \" "
|
||||||
|
"einklammern."
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:888
|
||||||
|
msgid "Comments are not allowed inside WindowMaker owned domain files."
|
||||||
|
msgstr "Kommentare sind in Domaindaten von WindowMaker nicht erlaubt."
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1559 ../../WINGs/proplist.c:1624
|
||||||
|
msgid "extra data after end of property list"
|
||||||
|
msgstr "zusätzliche Daten hinter dem Ende der Propertyliste"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1602
|
||||||
|
#, c-format
|
||||||
|
msgid "could not get size for file '%s'"
|
||||||
|
msgstr "konnte Dateigrösse von '%s' nicht ermitteln"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1614
|
||||||
|
#, c-format
|
||||||
|
msgid "error reading from file '%s'"
|
||||||
|
msgstr "Fehler beim Lesen der Datei '%s'"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1665
|
||||||
|
#, c-format
|
||||||
|
msgid "mkstemp (%s) failed"
|
||||||
|
msgstr "mkstemp (%s) schlug fehl"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1676
|
||||||
|
#, c-format
|
||||||
|
msgid "mktemp (%s) failed"
|
||||||
|
msgstr "mktemp (%s) schlug fehl"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1687
|
||||||
|
#, c-format
|
||||||
|
msgid "open (%s) failed"
|
||||||
|
msgstr "open (%s) schlug fehl"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1694
|
||||||
|
#, c-format
|
||||||
|
msgid "writing to file: %s failed"
|
||||||
|
msgstr "Schreiben in Datei: %s schlug fehl"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1702
|
||||||
|
#, c-format
|
||||||
|
msgid "fclose (%s) failed"
|
||||||
|
msgstr "fclose (%s) schlug fehl"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1711
|
||||||
|
#, c-format
|
||||||
|
msgid "rename ('%s' to '%s') failed"
|
||||||
|
msgstr "rename ('%s' to '%s') schlug fehl"
|
||||||
|
|
||||||
|
#. something happened with the file. just overwrite it
|
||||||
|
#: ../../WINGs/userdefaults.c:192 ../../WINGs/userdefaults.c:208
|
||||||
|
#, c-format
|
||||||
|
msgid "cannot read domain from file '%s' when syncing"
|
||||||
|
msgstr "Kannn bei der Synchronisation nicht aus Datei '%s' lesen"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:198 ../../WINGs/wcolor.c:211 ../../WINGs/wcolor.c:250
|
||||||
|
#: ../../WINGs/wcolor.c:291
|
||||||
|
#, c-format
|
||||||
|
msgid "could not allocate %s color"
|
||||||
|
msgstr "konnte die Farbe %s nicht erzeugen"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:198
|
||||||
|
msgid "white"
|
||||||
|
msgstr "weiß"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:211
|
||||||
|
msgid "black"
|
||||||
|
msgstr "schwarz"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:250
|
||||||
|
msgid "gray"
|
||||||
|
msgstr "grau"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:291
|
||||||
|
msgid "dark gray"
|
||||||
|
msgstr "dunkelgrau"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:415
|
||||||
|
msgid "Colors"
|
||||||
|
msgstr "Farben"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:605 ../../WINGs/wcolorpanel.c:2824
|
||||||
|
msgid "Brightness"
|
||||||
|
msgstr "Helligkeit"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:607 ../../WINGs/wcolorpanel.c:683
|
||||||
|
#: ../../WINGs/wcolorpanel.c:716 ../../WINGs/wcolorpanel.c:750
|
||||||
|
#: ../../WINGs/wcolorpanel.c:810 ../../WINGs/wcolorpanel.c:844
|
||||||
|
#: ../../WINGs/wcolorpanel.c:878 ../../WINGs/wcolorpanel.c:913
|
||||||
|
#: ../../WINGs/wcolorpanel.c:2164 ../../WINGs/wcolorpanel.c:2826
|
||||||
|
#: ../../WINGs/wcolorpanel.c:2862 ../../WINGs/wcolorpanel.c:2898
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3746
|
||||||
|
msgid "Color Panel: Could not allocate memory"
|
||||||
|
msgstr "Color Panel: Konnte keinen Speicher reservieren"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:680 ../../WINGs/wcolorpanel.c:681
|
||||||
|
msgid "Red"
|
||||||
|
msgstr "Rot"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:713 ../../WINGs/wcolorpanel.c:714
|
||||||
|
msgid "Green"
|
||||||
|
msgstr "Grün"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:747 ../../WINGs/wcolorpanel.c:748
|
||||||
|
msgid "Blue"
|
||||||
|
msgstr "Blau"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:807 ../../WINGs/wcolorpanel.c:808
|
||||||
|
msgid "Cyan"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:841 ../../WINGs/wcolorpanel.c:842
|
||||||
|
msgid "Magenta"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:875 ../../WINGs/wcolorpanel.c:876
|
||||||
|
msgid "Yellow"
|
||||||
|
msgstr "Gelb"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:910 ../../WINGs/wcolorpanel.c:911
|
||||||
|
msgid "Black"
|
||||||
|
msgstr "Schwarz"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:991
|
||||||
|
msgid "Spectrum"
|
||||||
|
msgstr "Spektrum"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1021
|
||||||
|
msgid "Palette"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1027
|
||||||
|
msgid "New from File..."
|
||||||
|
msgstr "Neu aus Datei..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1028 ../../WINGs/wcolorpanel.c:1076
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1093
|
||||||
|
msgid "Rename..."
|
||||||
|
msgstr "Umbenennen..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1029 ../../WINGs/wcolorpanel.c:1077
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1094 ../../WINGs/wcolorpanel.c:3321
|
||||||
|
msgid "Remove"
|
||||||
|
msgstr "Entfernen"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1030
|
||||||
|
msgid "Copy"
|
||||||
|
msgstr "Kopieren"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1031
|
||||||
|
msgid "New from Clipboard"
|
||||||
|
msgstr "Neu aus Zwischenablage"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1052
|
||||||
|
msgid "X11-Colors"
|
||||||
|
msgstr "X11-Farben"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1069
|
||||||
|
msgid "Color"
|
||||||
|
msgstr "Farbe"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1075
|
||||||
|
msgid "Add..."
|
||||||
|
msgstr "Hinzufügen..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1085
|
||||||
|
msgid "List"
|
||||||
|
msgstr "Liste"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1092
|
||||||
|
msgid "New..."
|
||||||
|
msgstr "Neu..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1231
|
||||||
|
#, c-format
|
||||||
|
msgid ""
|
||||||
|
"Color Panel: Could not create directory %s needed to store configurations"
|
||||||
|
msgstr ""
|
||||||
|
"Color Panel: Konnte das Verzeichnis %s zum Speichern der Konfiguration nicht erzeugen"
|
||||||
|
|
||||||
|
#. Delete the file, it doesn't belong here
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1237 ../../WINGs/wcolorpanel.c:3207
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3211
|
||||||
|
msgid "File Error"
|
||||||
|
msgstr "Dateifehler"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1238
|
||||||
|
msgid "Could not create ColorPanel configuration directory"
|
||||||
|
msgstr "Konnte Konfigurationsverzeichnis für Farbdialog nicht erzeugen"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1239 ../../WINGs/wcolorpanel.c:3208
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3213 ../../WINGs/wcolorpanel.c:3240
|
||||||
|
#: ../../WINGs/wfilepanel.c:250 ../../WINGs/wfilepanel.c:647
|
||||||
|
#: ../../WINGs/wfilepanel.c:659 ../../WINGs/wfilepanel.c:760
|
||||||
|
#: ../../WINGs/wfilepanel.c:971 ../../WINGs/wfontpanel.c:709
|
||||||
|
msgid "OK"
|
||||||
|
msgstr "OK"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1245 ../../WINGs/wcolorpanel.c:1281
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1299
|
||||||
|
msgid "Color Panel: Could not find file"
|
||||||
|
msgstr "Color Panel: Konnte Datei nicht finden"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1486 ../../WINGs/wcolorpanel.c:1551
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1615
|
||||||
|
msgid "Color Panel: X failed request"
|
||||||
|
msgstr "Color Panel: X Anfrage schlug fehl"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:2860
|
||||||
|
msgid "Saturation"
|
||||||
|
msgstr "Sättigung"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:2896
|
||||||
|
msgid "Hue"
|
||||||
|
msgstr "Farbton"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3146
|
||||||
|
msgid "Open Palette"
|
||||||
|
msgstr "Palette öffnen"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3208
|
||||||
|
msgid "Invalid file format !"
|
||||||
|
msgstr "Ungültiges Dateiformat!"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3210
|
||||||
|
#, c-format
|
||||||
|
msgid "can't remove file %s"
|
||||||
|
msgstr "kann Datei %s nicht entfernen"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3212
|
||||||
|
msgid "Couldn't remove file from Configuration Directory !"
|
||||||
|
msgstr "Konnte Datei nicht aus Konfigurationsverzeichnis entfernen!"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3239
|
||||||
|
msgid "Rename"
|
||||||
|
msgstr "Umbenennen"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3239
|
||||||
|
msgid "Rename palette to:"
|
||||||
|
msgstr "Palette umbenennen in:"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3240 ../../WINGs/wfilepanel.c:259
|
||||||
|
#: ../../WINGs/wfilepanel.c:659 ../../WINGs/wfilepanel.c:760
|
||||||
|
msgid "Cancel"
|
||||||
|
msgstr "Abbrechen"
|
||||||
|
|
||||||
|
#. Careful, this palette exists already
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3256 ../../WINGs/wfilepanel.c:760
|
||||||
|
msgid "Warning"
|
||||||
|
msgstr "Warnung"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3257
|
||||||
|
msgid ""
|
||||||
|
"Palette already exists !\n"
|
||||||
|
"\n"
|
||||||
|
"Overwrite ?"
|
||||||
|
msgstr ""
|
||||||
|
"Palette existiert bereits!\n"
|
||||||
|
"\n"
|
||||||
|
"Überschreiben?"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3257 ../../WINGs/wcolorpanel.c:3321
|
||||||
|
msgid "No"
|
||||||
|
msgstr "Nein"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3257 ../../WINGs/wcolorpanel.c:3321
|
||||||
|
msgid "Yes"
|
||||||
|
msgstr "Ja"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3289
|
||||||
|
#, c-format
|
||||||
|
msgid "Couldn't rename palette %s to %s\n"
|
||||||
|
msgstr "Konnte Palette %s nicht in %s umbenennen\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3315
|
||||||
|
msgid "This will permanently remove the palette "
|
||||||
|
msgstr "Das wird die Palette unwiderruflich löschen "
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3318
|
||||||
|
msgid ""
|
||||||
|
".\n"
|
||||||
|
"\n"
|
||||||
|
"Are you sure you want to remove this palette ?"
|
||||||
|
msgstr ""
|
||||||
|
".\n"
|
||||||
|
"\n"
|
||||||
|
"Sind Sie sicher, dass Sie die Palette löschen wollen?"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3343
|
||||||
|
#, c-format
|
||||||
|
msgid "Couldn't remove palette %s\n"
|
||||||
|
msgstr "Konnte Palette %s nicht löschen\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3648
|
||||||
|
#, c-format
|
||||||
|
msgid "Could not open %s"
|
||||||
|
msgstr "Konnte %s nicht öffnen"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3655
|
||||||
|
#, c-format
|
||||||
|
msgid "Could not create %s"
|
||||||
|
msgstr "Konnte %s nicht erzeugen"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3666
|
||||||
|
#, c-format
|
||||||
|
msgid "Write error on file %s"
|
||||||
|
msgstr "Schreibfehler bei Datei %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3711
|
||||||
|
msgid "Color Panel: Color unspecified"
|
||||||
|
msgstr "Color Panel: Farbe nicht spezifiziert"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:235
|
||||||
|
msgid "Name:"
|
||||||
|
msgstr "Name:"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:332 ../../WINGs/wfilepanel.c:396
|
||||||
|
msgid "Open"
|
||||||
|
msgstr "Öffnen"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:350 ../../WINGs/wfilepanel.c:402
|
||||||
|
msgid "Save"
|
||||||
|
msgstr "Speichern"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:562
|
||||||
|
#, c-format
|
||||||
|
msgid "WINGs: could not open directory %s\n"
|
||||||
|
msgstr "WINGs: Konnte Verzeichnis %s nicht öffen\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:580
|
||||||
|
#, c-format
|
||||||
|
msgid "WINGs: could not stat %s\n"
|
||||||
|
msgstr "WINGs: Dateistatus von %s nicht bestimmbar\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:647 ../../WINGs/wfilepanel.c:970
|
||||||
|
#: ../../WINGs/wfontpanel.c:708
|
||||||
|
msgid "Error"
|
||||||
|
msgstr "Fehler"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:658
|
||||||
|
msgid "Create Directory"
|
||||||
|
msgstr "Verzeichnis anlegen"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:659
|
||||||
|
msgid "Enter directory name"
|
||||||
|
msgstr "Verzeichnisname eingeben"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:695 ../../WINGs/wfilepanel.c:734
|
||||||
|
#: ../../WINGs/wfilepanel.c:765 ../../WINGs/wfilepanel.c:793
|
||||||
|
msgid "Permission denied."
|
||||||
|
msgstr "Zugriff verweigert."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:698
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' already exists."
|
||||||
|
msgstr "'%s' existiert bereits."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:701
|
||||||
|
msgid "Path does not exist."
|
||||||
|
msgstr "Pfad existiert nicht."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:731 ../../WINGs/wfilepanel.c:790
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' does not exist."
|
||||||
|
msgstr "'%s' existiert nicht."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:738 ../../WINGs/wfilepanel.c:797
|
||||||
|
msgid "Insufficient memory available."
|
||||||
|
msgstr "Nicht genügend Speicher verfügbar."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:742 ../../WINGs/wfilepanel.c:801
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' is on a read-only filesystem."
|
||||||
|
msgstr "'%s' liegt auf einem read-only Dateisystem."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:745 ../../WINGs/wfilepanel.c:777
|
||||||
|
#: ../../WINGs/wfilepanel.c:804
|
||||||
|
#, c-format
|
||||||
|
msgid "Can not delete '%s'."
|
||||||
|
msgstr "Kann %s nicht löschen."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:752
|
||||||
|
#, c-format
|
||||||
|
msgid "Delete directory %s ?"
|
||||||
|
msgstr "Verzeichnis % s löschen?"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:756
|
||||||
|
#, c-format
|
||||||
|
msgid "Delete file %s ?"
|
||||||
|
msgstr "Datei %s löschen?"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:768
|
||||||
|
#, c-format
|
||||||
|
msgid "Directory '%s' does not exist."
|
||||||
|
msgstr "Verzeichnis '%s' existiert nicht."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:771
|
||||||
|
#, c-format
|
||||||
|
msgid "Directory '%s' is not empty."
|
||||||
|
msgstr "Verzeichnis '%s' ist nicht leer."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:774
|
||||||
|
#, c-format
|
||||||
|
msgid "Directory '%s' is busy."
|
||||||
|
msgstr "Verzeichnis '%s' ist belegt."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:787
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' is a directory."
|
||||||
|
msgstr "'%s' ist ein Verzeichnis."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:829
|
||||||
|
#, c-format
|
||||||
|
msgid "An error occured browsing '%s'."
|
||||||
|
msgstr "Fehler beim Lesen von '%s'."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:833
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' is not a directory."
|
||||||
|
msgstr "'%s' ist kein Verzeichnis."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:970
|
||||||
|
msgid "File does not exist."
|
||||||
|
msgstr "Datei existiert nicht."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:129
|
||||||
|
#, c-format
|
||||||
|
msgid "the following character sets are missing in %s:"
|
||||||
|
msgstr "die folgenden Zeichensätze fehlen in %s:"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:136
|
||||||
|
#, c-format
|
||||||
|
msgid ""
|
||||||
|
"the string \"%s\" will be used in place of any characters from those sets."
|
||||||
|
msgstr ""
|
||||||
|
"die Zeichenkette \"%s\" ersetzt alle anderen Zeichen dieser Zeichensätze."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:287 ../../WINGs/wfont.c:323
|
||||||
|
#, c-format
|
||||||
|
msgid "could not load font set %s. Trying fixed."
|
||||||
|
msgstr "konnte Fonts nicht laden. Nehme fixed-Font."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:293 ../../WINGs/wfont.c:329
|
||||||
|
#, c-format
|
||||||
|
msgid "could not load font %s. Trying fixed."
|
||||||
|
msgstr "Konnte Font %s nicht laden. Nehme fixed-Font."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:297 ../../WINGs/wfont.c:333
|
||||||
|
msgid "could not load fixed font!"
|
||||||
|
msgstr "konnte fixed-Font nicht laden!"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:428
|
||||||
|
#, c-format
|
||||||
|
msgid "font description %s is too large."
|
||||||
|
msgstr "Fontbeschreibung ist zu groß."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:205
|
||||||
|
msgid "Test!!!"
|
||||||
|
msgstr "Test!"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:211
|
||||||
|
msgid "Family"
|
||||||
|
msgstr "Familie"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:222
|
||||||
|
msgid "Typeface"
|
||||||
|
msgstr "Schriftart"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:233
|
||||||
|
msgid "Size"
|
||||||
|
msgstr "Größe"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:252
|
||||||
|
msgid "Set"
|
||||||
|
msgstr "Setzen"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:257
|
||||||
|
msgid "Revert"
|
||||||
|
msgstr "Zurückn."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:709
|
||||||
|
msgid "Could not retrieve font list"
|
||||||
|
msgstr "Konnte Fontliste nicht wiederherstellen"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:721
|
||||||
|
#, c-format
|
||||||
|
msgid "font name %s is longer than 256, which is invalid."
|
||||||
|
msgstr "Fontname %s ist ungültig, da länger als 256 Zeichen."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:868
|
||||||
|
msgid "Roman"
|
||||||
|
msgstr "Roman"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:871
|
||||||
|
msgid "Italic"
|
||||||
|
msgstr "Kursiv"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:873
|
||||||
|
msgid "Oblique"
|
||||||
|
msgstr "Schräg"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:875
|
||||||
|
msgid "Rev Italic"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:877
|
||||||
|
msgid "Rev Oblique"
|
||||||
|
msgstr ""
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:883
|
||||||
|
msgid "Normal"
|
||||||
|
msgstr "Normal"
|
||||||
|
|
||||||
|
#: ../../WINGs/widgets.c:415
|
||||||
|
#, c-format
|
||||||
|
msgid "WINGs: could not load widget images file: %s"
|
||||||
|
msgstr "WINGs: Konnte Widget-Bildatei %s nicht laden."
|
||||||
|
|
||||||
|
#: ../../WINGs/widgets.c:763
|
||||||
|
msgid ""
|
||||||
|
"could not load any fonts. Make sure your font installationand locale "
|
||||||
|
"settings are correct."
|
||||||
|
msgstr ""
|
||||||
|
"Konnte keine Fonts laden. Überprüfen Sie, ob Ihre Fontinstallation und "
|
||||||
|
"-einstellungen korrekt sind."
|
||||||
|
|
||||||
|
#: ../../WINGs/wruler.c:189
|
||||||
|
msgid "0 inches"
|
||||||
|
msgstr "0 Inch"
|
||||||
739
WINGs/po/fr.po
Normal file
739
WINGs/po/fr.po
Normal file
@@ -0,0 +1,739 @@
|
|||||||
|
# KTranslator Generated File
|
||||||
|
# SOME DESCRIPTIVE TITLE.
|
||||||
|
# Copyright (C) YEAR Free Software Foundation, Inc.
|
||||||
|
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
|
||||||
|
#
|
||||||
|
msgid ""
|
||||||
|
msgstr ""
|
||||||
|
"Project-Id-Version: WINGs 0.80.0\n"
|
||||||
|
"POT-Creation-Date: 2003-05-02 15:39+0200\n"
|
||||||
|
"PO-Revision-Date: 2002-01-09 21:20+0100\n"
|
||||||
|
"Last-Translator: Emmanuel Benoit <tseeker@neptune.fr>\n"
|
||||||
|
"Language-Team: Français <fr@li.org>\n"
|
||||||
|
"MIME-Version: 1.0\n"
|
||||||
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
|
"Content-Transfer-Encoding: unknown\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/connection.c:467 ../../WINGs/connection.c:532
|
||||||
|
#: ../../WINGs/connection.c:575
|
||||||
|
msgid "Bad address-service-protocol combination"
|
||||||
|
msgstr "Mauvaise combinaison adresse-service-protocole"
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:54
|
||||||
|
#, c-format
|
||||||
|
msgid "Unknown error %d"
|
||||||
|
msgstr "Erreur inconnue %d"
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:59
|
||||||
|
#, c-format
|
||||||
|
msgid "Error %d"
|
||||||
|
msgstr "Erreur %d"
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:110
|
||||||
|
msgid " warning: "
|
||||||
|
msgstr " Avertissement : "
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:137
|
||||||
|
msgid " fatal error: "
|
||||||
|
msgstr " erreur fatale : "
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:163 ../../WINGs/error.c:192
|
||||||
|
msgid " error: "
|
||||||
|
msgstr " erreur : "
|
||||||
|
|
||||||
|
#: ../../WINGs/findfile.c:48
|
||||||
|
#, c-format
|
||||||
|
msgid "could not get password entry for UID %i"
|
||||||
|
msgstr "Impossible de lire le mot de passe de l'UID %i"
|
||||||
|
|
||||||
|
#: ../../WINGs/findfile.c:66
|
||||||
|
#, c-format
|
||||||
|
msgid "could not get password entry for user %s"
|
||||||
|
msgstr "Impossible de lire le mot de passe de l'utilisateur %i"
|
||||||
|
|
||||||
|
#: ../../WINGs/host.c:114
|
||||||
|
msgid "Cannot get current host name"
|
||||||
|
msgstr "Impossible de déterminer le nom de la machine"
|
||||||
|
|
||||||
|
# TODO pas de traduction correcte possible, cf source.
|
||||||
|
#: ../../WINGs/proplist.c:91
|
||||||
|
#, c-format
|
||||||
|
msgid "syntax error in %s %s, line %i: %s"
|
||||||
|
msgstr "Faute de syntaxe dans %s %s, ligne %i : %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:150
|
||||||
|
msgid "Only string or data is supported for a proplist dictionary key"
|
||||||
|
msgstr ""
|
||||||
|
"Seuls les types string ou data sont supportés pour une clé de dictionnaire "
|
||||||
|
"Proplist"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:184 ../../WINGs/proplist.c:236
|
||||||
|
#: ../../WINGs/proplist.c:394 ../../WINGs/proplist.c:474
|
||||||
|
#: ../../WINGs/proplist.c:1075 ../../WINGs/proplist.c:1127
|
||||||
|
#: ../../WINGs/proplist.c:1293 ../../WINGs/proplist.c:1372
|
||||||
|
#: ../../WINGs/proplist.c:1493 ../../WINGs/proplist.c:1540
|
||||||
|
msgid "Used proplist functions on non-WMPropLists objects"
|
||||||
|
msgstr "Une fonction Proplist a été utilisée sur des objets non-WMPropList"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:630
|
||||||
|
msgid "unterminated PropList string"
|
||||||
|
msgstr "chaîne PropList sans fin"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:670
|
||||||
|
msgid "unterminated PropList data"
|
||||||
|
msgstr "données PropList sans fin"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:678
|
||||||
|
msgid "unterminated PropList data (missing hexdigit)"
|
||||||
|
msgstr "données PropList sans fin (il manque un chiffre hexadécimal)"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:690 ../../WINGs/proplist.c:695
|
||||||
|
msgid "non hexdigit character in PropList data"
|
||||||
|
msgstr "caractère non-hexadécimal dans les données PropList"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:729
|
||||||
|
msgid "unterminated PropList array"
|
||||||
|
msgstr "tableau PropList sans fin"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:737
|
||||||
|
msgid "missing or unterminated PropList array"
|
||||||
|
msgstr "tableau PropList manquant ou sans fin"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:747
|
||||||
|
msgid "could not get PropList array element"
|
||||||
|
msgstr "impossible de lire l'élément du tableau PropList"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:776
|
||||||
|
msgid "unterminated PropList dictionary"
|
||||||
|
msgstr "dictionnaire PropList sans fin"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:793
|
||||||
|
msgid "missing PropList dictionary key"
|
||||||
|
msgstr "clef du dictionnaire PropList manquante"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:795
|
||||||
|
msgid "missing PropList dictionary entry key or unterminated dictionary"
|
||||||
|
msgstr "clef du dictionnaire PropList manquante ou dictionnaire sans fin"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:803
|
||||||
|
msgid "error parsing PropList dictionary key"
|
||||||
|
msgstr "erreur lors de l'analyse de la clef de dictionnaire PropList"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:811
|
||||||
|
msgid "missing = in PropList dictionary entry"
|
||||||
|
msgstr "signe '=' manquant dans l'entrée du dictionnaire PropList"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:819
|
||||||
|
msgid "error parsing PropList dictionary entry value"
|
||||||
|
msgstr ""
|
||||||
|
"erreur lors de l'analyse de la valeur de l'entrée du dictionnaire PropList"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:827
|
||||||
|
msgid "missing ; in PropList dictionary entry"
|
||||||
|
msgstr "signe ';' manquant dans l'entrée du dictionnaire PropList"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:888
|
||||||
|
msgid ""
|
||||||
|
"was expecting a string, data, array or dictionary. If it's a string, try "
|
||||||
|
"enclosing it with \"."
|
||||||
|
msgstr ""
|
||||||
|
"une chaine, des données, un tableau ou un dictionnaire étaient attendus. "
|
||||||
|
"S'il s'agit d'une chaîne, essayez de la délimiter grâce à '\"'."
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:892
|
||||||
|
msgid "Comments are not allowed inside WindowMaker owned domain files."
|
||||||
|
msgstr ""
|
||||||
|
"Les commentaires ne sont pas autorisés dans les fichiers appartenant au "
|
||||||
|
"domaine de Window Maker."
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1563 ../../WINGs/proplist.c:1628
|
||||||
|
msgid "extra data after end of property list"
|
||||||
|
msgstr "données excédentaires après la fin de la liste de propriétés"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1606
|
||||||
|
#, c-format
|
||||||
|
msgid "could not get size for file '%s'"
|
||||||
|
msgstr "impossible de déterminer la taille du fichier '%s'"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1618
|
||||||
|
#, c-format
|
||||||
|
msgid "error reading from file '%s'"
|
||||||
|
msgstr "erreur pendant la lecture du fichier '%s'"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1669
|
||||||
|
#, c-format
|
||||||
|
msgid "mkstemp (%s) failed"
|
||||||
|
msgstr "mkstemp (%s) a échoué"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1680
|
||||||
|
#, c-format
|
||||||
|
msgid "mktemp (%s) failed"
|
||||||
|
msgstr "mktemp (%s) a échoué"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1691
|
||||||
|
#, c-format
|
||||||
|
msgid "open (%s) failed"
|
||||||
|
msgstr "open (%s) a échoué"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1698
|
||||||
|
#, c-format
|
||||||
|
msgid "writing to file: %s failed"
|
||||||
|
msgstr "erreur pendant l'écriture dans le fichier '%s'"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1706
|
||||||
|
#, c-format
|
||||||
|
msgid "fclose (%s) failed"
|
||||||
|
msgstr "erreur lors de la fermeture du fichier '%s'"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1715
|
||||||
|
#, c-format
|
||||||
|
msgid "rename ('%s' to '%s') failed"
|
||||||
|
msgstr "impossible de renommer '%s' en '%s'"
|
||||||
|
|
||||||
|
#. something happened with the file. just overwrite it
|
||||||
|
#: ../../WINGs/userdefaults.c:188 ../../WINGs/userdefaults.c:204
|
||||||
|
#, c-format
|
||||||
|
msgid "cannot read domain from file '%s' when syncing"
|
||||||
|
msgstr ""
|
||||||
|
"impossible de lire le domaine depuis le fichier '%s' pendant la "
|
||||||
|
"synchronisation"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:224 ../../WINGs/wcolor.c:236 ../../WINGs/wcolor.c:275
|
||||||
|
#: ../../WINGs/wcolor.c:316
|
||||||
|
#, c-format
|
||||||
|
msgid "could not allocate %s color"
|
||||||
|
msgstr "impossible d'allouer la couleur %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:224
|
||||||
|
msgid "white"
|
||||||
|
msgstr "blanc"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:236
|
||||||
|
msgid "black"
|
||||||
|
msgstr "noir"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:275
|
||||||
|
msgid "gray"
|
||||||
|
msgstr "gris"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:316
|
||||||
|
msgid "dark gray"
|
||||||
|
msgstr "gris sombre"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:420
|
||||||
|
msgid "Colors"
|
||||||
|
msgstr "Couleurs"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:610 ../../WINGs/wcolorpanel.c:2829
|
||||||
|
msgid "Brightness"
|
||||||
|
msgstr "Luminosité"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:612 ../../WINGs/wcolorpanel.c:688
|
||||||
|
#: ../../WINGs/wcolorpanel.c:721 ../../WINGs/wcolorpanel.c:755
|
||||||
|
#: ../../WINGs/wcolorpanel.c:815 ../../WINGs/wcolorpanel.c:849
|
||||||
|
#: ../../WINGs/wcolorpanel.c:883 ../../WINGs/wcolorpanel.c:918
|
||||||
|
#: ../../WINGs/wcolorpanel.c:2169 ../../WINGs/wcolorpanel.c:2831
|
||||||
|
#: ../../WINGs/wcolorpanel.c:2867 ../../WINGs/wcolorpanel.c:2903
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3745
|
||||||
|
msgid "Color Panel: Could not allocate memory"
|
||||||
|
msgstr "Panneau de Sélection des Couleur: impossible d'allouer la mémoire"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:685 ../../WINGs/wcolorpanel.c:686
|
||||||
|
msgid "Red"
|
||||||
|
msgstr "Rouge"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:718 ../../WINGs/wcolorpanel.c:719
|
||||||
|
msgid "Green"
|
||||||
|
msgstr "Vert"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:752 ../../WINGs/wcolorpanel.c:753
|
||||||
|
msgid "Blue"
|
||||||
|
msgstr "Bleu"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:812 ../../WINGs/wcolorpanel.c:813
|
||||||
|
msgid "Cyan"
|
||||||
|
msgstr "Cyan"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:846 ../../WINGs/wcolorpanel.c:847
|
||||||
|
msgid "Magenta"
|
||||||
|
msgstr "Magenta"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:880 ../../WINGs/wcolorpanel.c:881
|
||||||
|
msgid "Yellow"
|
||||||
|
msgstr "Jaune"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:915 ../../WINGs/wcolorpanel.c:916
|
||||||
|
msgid "Black"
|
||||||
|
msgstr "Noir"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:996
|
||||||
|
msgid "Spectrum"
|
||||||
|
msgstr "Spectre"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1026
|
||||||
|
msgid "Palette"
|
||||||
|
msgstr "Palette"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1032
|
||||||
|
msgid "New from File..."
|
||||||
|
msgstr "Nouveau d'après le fichier..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1033 ../../WINGs/wcolorpanel.c:1081
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1098
|
||||||
|
msgid "Rename..."
|
||||||
|
msgstr "Renommer..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1034 ../../WINGs/wcolorpanel.c:1082
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1099 ../../WINGs/wcolorpanel.c:3326
|
||||||
|
msgid "Remove"
|
||||||
|
msgstr "Supprimer"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1035
|
||||||
|
msgid "Copy"
|
||||||
|
msgstr "Copier"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1036
|
||||||
|
msgid "New from Clipboard"
|
||||||
|
msgstr "Nouveau d'après le presse-papier"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1057
|
||||||
|
msgid "X11-Colors"
|
||||||
|
msgstr "Couleurs X11"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1074
|
||||||
|
msgid "Color"
|
||||||
|
msgstr "Couleur"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1080
|
||||||
|
msgid "Add..."
|
||||||
|
msgstr "Ajouter..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1090
|
||||||
|
msgid "List"
|
||||||
|
msgstr "Liste"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1097
|
||||||
|
msgid "New..."
|
||||||
|
msgstr "Nouveau..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1236
|
||||||
|
#, c-format
|
||||||
|
msgid ""
|
||||||
|
"Color Panel: Could not create directory %s needed to store configurations"
|
||||||
|
msgstr ""
|
||||||
|
"Panneau de sélection des couleurs : impossible de créer le répertoire %s "
|
||||||
|
"requis pour enregistrer les configurations."
|
||||||
|
|
||||||
|
#. Delete the file, it doesn't belong here
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1242 ../../WINGs/wcolorpanel.c:3212
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3216
|
||||||
|
msgid "File Error"
|
||||||
|
msgstr "Erreur de fichier"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1243
|
||||||
|
msgid "Could not create ColorPanel configuration directory"
|
||||||
|
msgstr ""
|
||||||
|
"Impossible de créer le répertoire pour la configuration du panneau de "
|
||||||
|
"sélection des couleurs."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1244 ../../WINGs/wcolorpanel.c:3213
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3218 ../../WINGs/wcolorpanel.c:3245
|
||||||
|
#: ../../WINGs/wfilepanel.c:250 ../../WINGs/wfilepanel.c:650
|
||||||
|
#: ../../WINGs/wfilepanel.c:662 ../../WINGs/wfilepanel.c:763
|
||||||
|
#: ../../WINGs/wfilepanel.c:974 ../../WINGs/wfontpanel.c:751
|
||||||
|
msgid "OK"
|
||||||
|
msgstr "OK"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1250 ../../WINGs/wcolorpanel.c:1286
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1304
|
||||||
|
msgid "Color Panel: Could not find file"
|
||||||
|
msgstr "Panneau de sélection des couleurs : Impossible de trouver le fichier."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1491 ../../WINGs/wcolorpanel.c:1556
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1620
|
||||||
|
msgid "Color Panel: X failed request"
|
||||||
|
msgstr "Panneau de sélection des couleurs : échec d'une requête X"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:2865
|
||||||
|
msgid "Saturation"
|
||||||
|
msgstr "Saturation"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:2901
|
||||||
|
msgid "Hue"
|
||||||
|
msgstr "Teinte"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3151
|
||||||
|
msgid "Open Palette"
|
||||||
|
msgstr "Ouvrir une palette"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3213
|
||||||
|
msgid "Invalid file format !"
|
||||||
|
msgstr "Format de fichier invalide !"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3215
|
||||||
|
#, c-format
|
||||||
|
msgid "can't remove file %s"
|
||||||
|
msgstr "Impossible de supprimer le fichier %s."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3217
|
||||||
|
msgid "Couldn't remove file from Configuration Directory !"
|
||||||
|
msgstr "Impossible de supprimer le fichier du répertoire de configuration !"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3244
|
||||||
|
msgid "Rename"
|
||||||
|
msgstr "Renommer"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3244
|
||||||
|
msgid "Rename palette to:"
|
||||||
|
msgstr "Renommer la palette en :"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3245 ../../WINGs/wfilepanel.c:259
|
||||||
|
#: ../../WINGs/wfilepanel.c:662 ../../WINGs/wfilepanel.c:763
|
||||||
|
msgid "Cancel"
|
||||||
|
msgstr "Annuler"
|
||||||
|
|
||||||
|
#. Careful, this palette exists already
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3261 ../../WINGs/wfilepanel.c:763
|
||||||
|
msgid "Warning"
|
||||||
|
msgstr "Avertissement"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3262
|
||||||
|
msgid ""
|
||||||
|
"Palette already exists !\n"
|
||||||
|
"\n"
|
||||||
|
"Overwrite ?"
|
||||||
|
msgstr ""
|
||||||
|
"La palette existe déjà !\n"
|
||||||
|
"\n"
|
||||||
|
"Écraser ?"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3262 ../../WINGs/wcolorpanel.c:3326
|
||||||
|
msgid "No"
|
||||||
|
msgstr "Non"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3262 ../../WINGs/wcolorpanel.c:3326
|
||||||
|
msgid "Yes"
|
||||||
|
msgstr "Oui"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3294
|
||||||
|
#, c-format
|
||||||
|
msgid "Couldn't rename palette %s to %s\n"
|
||||||
|
msgstr "Impossible de renommer la palette %s en %s.\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3320
|
||||||
|
msgid "This will permanently remove the palette "
|
||||||
|
msgstr "Ceci détruira définitivement la palette "
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3323
|
||||||
|
msgid ""
|
||||||
|
".\n"
|
||||||
|
"\n"
|
||||||
|
"Are you sure you want to remove this palette ?"
|
||||||
|
msgstr ""
|
||||||
|
".\n"
|
||||||
|
"\n"
|
||||||
|
"Êtes-vous sûr de vouloir supprimer cette palette ?"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3348
|
||||||
|
#, c-format
|
||||||
|
msgid "Couldn't remove palette %s\n"
|
||||||
|
msgstr "Impossible de détruire la palette %s.\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3647
|
||||||
|
#, c-format
|
||||||
|
msgid "Could not open %s"
|
||||||
|
msgstr "Impossible d'ouvrir %s."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3654
|
||||||
|
#, c-format
|
||||||
|
msgid "Could not create %s"
|
||||||
|
msgstr "Impossible de créer %s."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3665
|
||||||
|
#, c-format
|
||||||
|
msgid "Write error on file %s"
|
||||||
|
msgstr "Erreur d'écriture dans le fichier %s."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3710
|
||||||
|
msgid "Color Panel: Color unspecified"
|
||||||
|
msgstr "Panneau de sélection des couleurs: couleur non spécifiée."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:235
|
||||||
|
msgid "Name:"
|
||||||
|
msgstr "Nom :"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:332 ../../WINGs/wfilepanel.c:396
|
||||||
|
msgid "Open"
|
||||||
|
msgstr "Ouvrir"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:350 ../../WINGs/wfilepanel.c:402
|
||||||
|
msgid "Save"
|
||||||
|
msgstr "Enregistrer"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:565
|
||||||
|
#, c-format
|
||||||
|
msgid "WINGs: could not open directory %s\n"
|
||||||
|
msgstr "WINGs : Impossible d'ouvrir le répertoire %s.\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:583
|
||||||
|
#, c-format
|
||||||
|
msgid "WINGs: could not stat %s\n"
|
||||||
|
msgstr "WINGs : impossible de lire l'état du fichier %s.\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:650 ../../WINGs/wfilepanel.c:973
|
||||||
|
#: ../../WINGs/wfontpanel.c:750
|
||||||
|
msgid "Error"
|
||||||
|
msgstr "Erreur"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:661
|
||||||
|
msgid "Create Directory"
|
||||||
|
msgstr "Créer un répertoire"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:662
|
||||||
|
msgid "Enter directory name"
|
||||||
|
msgstr "Saisissez le nom du répertoire"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:698 ../../WINGs/wfilepanel.c:737
|
||||||
|
#: ../../WINGs/wfilepanel.c:768 ../../WINGs/wfilepanel.c:796
|
||||||
|
msgid "Permission denied."
|
||||||
|
msgstr "Permission refusée."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:701
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' already exists."
|
||||||
|
msgstr "'%s' existe déjà."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:704
|
||||||
|
msgid "Path does not exist."
|
||||||
|
msgstr "Le chemin n'existe pas."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:734 ../../WINGs/wfilepanel.c:793
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' does not exist."
|
||||||
|
msgstr "'%s' n'existe pas."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:741 ../../WINGs/wfilepanel.c:800
|
||||||
|
msgid "Insufficient memory available."
|
||||||
|
msgstr "Mémoire disponible insuffisante."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:745 ../../WINGs/wfilepanel.c:804
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' is on a read-only filesystem."
|
||||||
|
msgstr "'%s' est sur un système de fichiers en lecture seule."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:748 ../../WINGs/wfilepanel.c:780
|
||||||
|
#: ../../WINGs/wfilepanel.c:807
|
||||||
|
#, c-format
|
||||||
|
msgid "Can not delete '%s'."
|
||||||
|
msgstr "Impossible de supprimer '%s'."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:755
|
||||||
|
#, c-format
|
||||||
|
msgid "Delete directory %s ?"
|
||||||
|
msgstr "Supprimer le répertoire %s ?"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:759
|
||||||
|
#, c-format
|
||||||
|
msgid "Delete file %s ?"
|
||||||
|
msgstr "Supprimer le fichier %s ?"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:771
|
||||||
|
#, c-format
|
||||||
|
msgid "Directory '%s' does not exist."
|
||||||
|
msgstr "Le répertoire '%s' n'existe pas."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:774
|
||||||
|
#, c-format
|
||||||
|
msgid "Directory '%s' is not empty."
|
||||||
|
msgstr "Le répertoire '%s' n'est pas vide."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:777
|
||||||
|
#, c-format
|
||||||
|
msgid "Directory '%s' is busy."
|
||||||
|
msgstr "Le répertoire '%s' est occupé."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:790
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' is a directory."
|
||||||
|
msgstr "'%s' est un répertoire."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:832
|
||||||
|
#, c-format
|
||||||
|
msgid "An error occured browsing '%s'."
|
||||||
|
msgstr "Une erreur s'est produite pendant le parcours de '%s'."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:836
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' is not a directory."
|
||||||
|
msgstr "'%s' n'est pas un répertoire."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:973
|
||||||
|
msgid "File does not exist."
|
||||||
|
msgstr "Le fichier n'existe pas."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:133 ../../WINGs/wfont.c:143
|
||||||
|
#, c-format
|
||||||
|
msgid "Invalid size specification '%s' in %s. Using default %d\n"
|
||||||
|
msgstr ""
|
||||||
|
"Taille invalide dans %2$s : '%1$s'. Utilisation de la valeur par défaut %3"
|
||||||
|
"$d\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:187
|
||||||
|
#, c-format
|
||||||
|
msgid "the following character sets are missing in %s:"
|
||||||
|
msgstr "Les jeux de caractères suivants manquent dans %s :"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:193
|
||||||
|
#, c-format
|
||||||
|
msgid ""
|
||||||
|
"the string \"%s\" will be used in place of any characters from those sets."
|
||||||
|
msgstr ""
|
||||||
|
"La chaîne « %s » sera utilisée à la place de tous les caractères de ces jeux."
|
||||||
|
|
||||||
|
#. is arial a good fallback for multibyte?
|
||||||
|
#: ../../WINGs/wfont.c:599 ../../WINGs/wfont.c:614
|
||||||
|
#, c-format
|
||||||
|
msgid "could not load font %s. Trying arial."
|
||||||
|
msgstr ""
|
||||||
|
"Impossible de charger la police de caractères %s, essai de la police "
|
||||||
|
"« arial »."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:606
|
||||||
|
msgid "could not load antialiased font set. Reverting to standard font sets."
|
||||||
|
msgstr ""
|
||||||
|
"Impossible de charger les polices lissées, utilisation des polices normales."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:609
|
||||||
|
#, c-format
|
||||||
|
msgid "could not load FontSet %s. Trying fixed."
|
||||||
|
msgstr ""
|
||||||
|
"Impossible de charger la famille de polices %s, essai de la famille "
|
||||||
|
"« fixed »."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:621
|
||||||
|
msgid "could not load antialiased fonts. Reverting to normal fonts."
|
||||||
|
msgstr ""
|
||||||
|
"Impossible de charger les polices lissées, utilisation des polices normales."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:624 ../../WINGs/wfont.c:635
|
||||||
|
#, c-format
|
||||||
|
msgid "could not load font %s. Trying fixed."
|
||||||
|
msgstr ""
|
||||||
|
"Impossible de charger la police de caractères %s, essai de la police "
|
||||||
|
"« fixed »."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:629
|
||||||
|
#, c-format
|
||||||
|
msgid "could not load font set %s. Trying fixed."
|
||||||
|
msgstr ""
|
||||||
|
"Impossible de charger la famille de polices %s, essai de la famille "
|
||||||
|
"« fixed »."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:639
|
||||||
|
msgid "could not load fixed font!"
|
||||||
|
msgstr "Impossible de charger la police de caractères « fixed » !"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:704 ../../WINGs/wfont.c:765 ../../WINGs/wfont.c:836
|
||||||
|
#, c-format
|
||||||
|
msgid ""
|
||||||
|
"Conversion to widechar failed (possible invalid multibyte sequence): '%s':"
|
||||||
|
"(pos %d)\n"
|
||||||
|
msgstr ""
|
||||||
|
"Échec de la conversion en widechar (probablement une séquence d'octets "
|
||||||
|
"erronée) : « %s » (pos %d)\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:887
|
||||||
|
#, c-format
|
||||||
|
msgid "font description %s is too large."
|
||||||
|
msgstr "La description de la police de caractères %s est trop volumineuse."
|
||||||
|
|
||||||
|
#. // remove warning later. or maybe not
|
||||||
|
#: ../../WINGs/wfont.c:935
|
||||||
|
#, c-format
|
||||||
|
msgid "Invalid font specification: '%s'\n"
|
||||||
|
msgstr "Déclaration de police invalide : « %s »\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:235
|
||||||
|
msgid "Test!!!"
|
||||||
|
msgstr "Test !"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:241
|
||||||
|
msgid "Family"
|
||||||
|
msgstr "Famille"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:252
|
||||||
|
msgid "Typeface"
|
||||||
|
msgstr "Caractère"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:263
|
||||||
|
msgid "Size"
|
||||||
|
msgstr "Taille"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:282
|
||||||
|
msgid "Set"
|
||||||
|
msgstr "Famille"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:288
|
||||||
|
msgid "Revert"
|
||||||
|
msgstr "Revenir"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:751
|
||||||
|
msgid "Could not retrieve font list"
|
||||||
|
msgstr "Impossible de lire la liste des polices de caractères."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:765
|
||||||
|
#, c-format
|
||||||
|
msgid "font name %s is longer than 256, which is invalid."
|
||||||
|
msgstr ""
|
||||||
|
"Le nom de police %s a plus de 256 caractères et est par conséquent invalide."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:913
|
||||||
|
msgid "Roman"
|
||||||
|
msgstr "Roman"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:916
|
||||||
|
msgid "Italic"
|
||||||
|
msgstr "Italique"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:918
|
||||||
|
msgid "Oblique"
|
||||||
|
msgstr "Penché"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:920
|
||||||
|
msgid "Rev Italic"
|
||||||
|
msgstr "Italique inverse"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:922
|
||||||
|
msgid "Rev Oblique"
|
||||||
|
msgstr "Penché inverse"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:928
|
||||||
|
msgid "Normal"
|
||||||
|
msgstr "Normal"
|
||||||
|
|
||||||
|
#: ../../WINGs/widgets.c:419
|
||||||
|
#, c-format
|
||||||
|
msgid "WINGs: could not load widget images file: %s"
|
||||||
|
msgstr "WINGs : impossible de charger le fichier d'images de widget '%s'."
|
||||||
|
|
||||||
|
#: ../../WINGs/widgets.c:770
|
||||||
|
msgid ""
|
||||||
|
"Text antialiasing is enabled in the configuration but the X server doesn't "
|
||||||
|
"have the required capabilities (missing RENDER extension). Disabling text "
|
||||||
|
"antialiasing."
|
||||||
|
msgstr ""
|
||||||
|
"Le lissage du texte est activé dans la configuration mais le serveur X ne "
|
||||||
|
"dispose pas de l'extension adéquate (extension RENDER). Desactivation du "
|
||||||
|
"lissage."
|
||||||
|
|
||||||
|
#: ../../WINGs/widgets.c:787
|
||||||
|
msgid ""
|
||||||
|
"could not load any fonts. Make sure your font installation and locale "
|
||||||
|
"settings are correct."
|
||||||
|
msgstr ""
|
||||||
|
"Aucune police n'a pu être chargée. Veuillez vérifier que vos polices sont "
|
||||||
|
"correctement installées et que votre langue est bien configurée."
|
||||||
|
|
||||||
|
#: ../../WINGs/wruler.c:192
|
||||||
|
msgid "0 inches"
|
||||||
|
msgstr "0 pouces"
|
||||||
719
WINGs/po/sk.po
Normal file
719
WINGs/po/sk.po
Normal file
@@ -0,0 +1,719 @@
|
|||||||
|
# Slovak messages for WINGs
|
||||||
|
# (C) 2001 Jan "judas" Tomka
|
||||||
|
#
|
||||||
|
# Original translation by Jan "judas" Tomka on Feb 25 2001
|
||||||
|
# Currently maintained by Jan "judas" Tomka <judas@linux.sk>
|
||||||
|
#
|
||||||
|
# Version history:
|
||||||
|
# WM-ver author email date
|
||||||
|
# 0.65.1 Jan "judas" Tomka <judas@linux.sk> Aug 08 2001
|
||||||
|
# 0.70.0 Jan "judas" Tomka <judas@linux.sk> Oct 15 2001
|
||||||
|
# 0.70.1 Jan "judas" Tomka <judas@linux.sk> Nov 02 2001
|
||||||
|
# 0.80.0 Jan "judas" Tomka <judas@linux.sk> Dec 20 2001
|
||||||
|
# 0.80.2 Jan "judas" Tomka <judas@linux.sk> Jan 31 2004
|
||||||
|
#
|
||||||
|
msgid ""
|
||||||
|
msgstr ""
|
||||||
|
"Project-Id-Version: WINGs 0.80.0\n"
|
||||||
|
"POT-Creation-Date: 2004-01-31 18:36+0100\n"
|
||||||
|
"PO-Revision-Date: 2001-12-20 04:00+0100\n"
|
||||||
|
"Last-Translator: Jan \"judas\" Tomka <judas@linux.sk>\n"
|
||||||
|
"Language-Team: Slovak <sk@li.org>\n"
|
||||||
|
"MIME-Version: 1.0\n"
|
||||||
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/connection.c:467 ../../WINGs/connection.c:532
|
||||||
|
#: ../../WINGs/connection.c:575
|
||||||
|
msgid "Bad address-service-protocol combination"
|
||||||
|
msgstr "Nesprávna kombinácia adresa-služba-protokol"
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:54
|
||||||
|
#, c-format
|
||||||
|
msgid "Unknown error %d"
|
||||||
|
msgstr "Nezmána chyba %d"
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:59
|
||||||
|
#, c-format
|
||||||
|
msgid "Error %d"
|
||||||
|
msgstr "Chyba %d"
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:110
|
||||||
|
msgid " warning: "
|
||||||
|
msgstr " varovanie: "
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:137
|
||||||
|
msgid " fatal error: "
|
||||||
|
msgstr " fatálna chyba: "
|
||||||
|
|
||||||
|
#: ../../WINGs/error.c:163 ../../WINGs/error.c:192
|
||||||
|
msgid " error: "
|
||||||
|
msgstr " chyba: "
|
||||||
|
|
||||||
|
#: ../../WINGs/findfile.c:48
|
||||||
|
#, c-format
|
||||||
|
msgid "could not get password entry for UID %i"
|
||||||
|
msgstr "nemožno zistiť informácie o UID %i"
|
||||||
|
|
||||||
|
#: ../../WINGs/findfile.c:66
|
||||||
|
#, c-format
|
||||||
|
msgid "could not get password entry for user %s"
|
||||||
|
msgstr "nemožno zistiť informácie o užívateľovi %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/host.c:114
|
||||||
|
msgid "Cannot get current host name"
|
||||||
|
msgstr "Nemožno zistiť aktuálne meno počítača"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:91
|
||||||
|
#, c-format
|
||||||
|
msgid "syntax error in %s %s, line %i: %s"
|
||||||
|
msgstr "chyba syntaxe v %s %s, riadok %i: %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:150
|
||||||
|
msgid "Only string or data is supported for a proplist dictionary key"
|
||||||
|
msgstr "Pre kľúč slovníka proplist je podporovaný len reťazec alebo dáta"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:184 ../../WINGs/proplist.c:236
|
||||||
|
#: ../../WINGs/proplist.c:394 ../../WINGs/proplist.c:474
|
||||||
|
#: ../../WINGs/proplist.c:1075 ../../WINGs/proplist.c:1127
|
||||||
|
#: ../../WINGs/proplist.c:1293 ../../WINGs/proplist.c:1372
|
||||||
|
#: ../../WINGs/proplist.c:1493 ../../WINGs/proplist.c:1540
|
||||||
|
msgid "Used proplist functions on non-WMPropLists objects"
|
||||||
|
msgstr "Použitá proplist funkcia na iných ako WMPropLists objektoch"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:630
|
||||||
|
msgid "unterminated PropList string"
|
||||||
|
msgstr "neukončený PropList reťazec"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:670
|
||||||
|
msgid "unterminated PropList data"
|
||||||
|
msgstr "neukončené PropList dáta"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:678
|
||||||
|
msgid "unterminated PropList data (missing hexdigit)"
|
||||||
|
msgstr "neukončené PropList dáta (chýbajúca hex číslica)"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:690 ../../WINGs/proplist.c:695
|
||||||
|
msgid "non hexdigit character in PropList data"
|
||||||
|
msgstr "v PropList dátach je znak, ktorý nie je hex číslicou"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:729
|
||||||
|
msgid "unterminated PropList array"
|
||||||
|
msgstr "neukončené PropList pole"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:737
|
||||||
|
msgid "missing or unterminated PropList array"
|
||||||
|
msgstr "chýbajúce alebo neukončené PropList pole"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:747
|
||||||
|
msgid "could not get PropList array element"
|
||||||
|
msgstr "nemožno zistiť prvok PropList poľa"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:776
|
||||||
|
msgid "unterminated PropList dictionary"
|
||||||
|
msgstr "neukončený PropList slovník"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:793
|
||||||
|
msgid "missing PropList dictionary key"
|
||||||
|
msgstr "chýbajúci kľúč PropList slovníka"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:795
|
||||||
|
msgid "missing PropList dictionary entry key or unterminated dictionary"
|
||||||
|
msgstr "chýbajúci kľúč položky PropList slovníka alebo neukončený slovník"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:803
|
||||||
|
msgid "error parsing PropList dictionary key"
|
||||||
|
msgstr "chyba pri parsovaní kľúča PropList slovníka"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:811
|
||||||
|
msgid "missing = in PropList dictionary entry"
|
||||||
|
msgstr "chýbajúce = v položke PropList slovníka"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:819
|
||||||
|
msgid "error parsing PropList dictionary entry value"
|
||||||
|
msgstr "chyba pri parsovaní hodnoty položky PropList slovníka"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:827
|
||||||
|
msgid "missing ; in PropList dictionary entry"
|
||||||
|
msgstr "chýbajúca ; v položke PropList slovníka"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:888
|
||||||
|
msgid ""
|
||||||
|
"was expecting a string, data, array or dictionary. If it's a string, try "
|
||||||
|
"enclosing it with \"."
|
||||||
|
msgstr ""
|
||||||
|
"očakávaný bol reťazec, dáta, pole alebo slovník. Ak je to reťazec, skúste ho "
|
||||||
|
"uzavrieť medzi \"."
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:892
|
||||||
|
msgid "Comments are not allowed inside WindowMaker owned domain files."
|
||||||
|
msgstr "Komentáre v doménových súboroch Window Makera nie sú povolené."
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1563 ../../WINGs/proplist.c:1630
|
||||||
|
msgid "extra data after end of property list"
|
||||||
|
msgstr "prebytočné dáta na konci property listu"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1606
|
||||||
|
#, c-format
|
||||||
|
msgid "could not get size for file '%s'"
|
||||||
|
msgstr "nemožno zistiť veľkosť súboru '%s'"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1619
|
||||||
|
#, c-format
|
||||||
|
msgid "error reading from file '%s'"
|
||||||
|
msgstr "chyba pri čítaní zo súboru '%s'"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1671
|
||||||
|
#, c-format
|
||||||
|
msgid "mkstemp (%s) failed"
|
||||||
|
msgstr "chyba mkstemp (%s)"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1682
|
||||||
|
#, c-format
|
||||||
|
msgid "mktemp (%s) failed"
|
||||||
|
msgstr "chyba mktemp(%s)"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1693
|
||||||
|
#, c-format
|
||||||
|
msgid "open (%s) failed"
|
||||||
|
msgstr "chyba pri otváraní (%s)"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1700
|
||||||
|
#, c-format
|
||||||
|
msgid "writing to file: %s failed"
|
||||||
|
msgstr "chyba pri zápise do súboru: %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1708
|
||||||
|
#, c-format
|
||||||
|
msgid "fclose (%s) failed"
|
||||||
|
msgstr "chyba fclose (%s)"
|
||||||
|
|
||||||
|
#: ../../WINGs/proplist.c:1717
|
||||||
|
#, c-format
|
||||||
|
msgid "rename ('%s' to '%s') failed"
|
||||||
|
msgstr "chyba rename ('%s' na '%s')"
|
||||||
|
|
||||||
|
#. something happened with the file. just overwrite it
|
||||||
|
#: ../../WINGs/userdefaults.c:188 ../../WINGs/userdefaults.c:204
|
||||||
|
#, c-format
|
||||||
|
msgid "cannot read domain from file '%s' when syncing"
|
||||||
|
msgstr "nemožno čítať doménu zo súboru '%s' pri synchronizácii"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:224 ../../WINGs/wcolor.c:236 ../../WINGs/wcolor.c:275
|
||||||
|
#: ../../WINGs/wcolor.c:316
|
||||||
|
#, c-format
|
||||||
|
msgid "could not allocate %s color"
|
||||||
|
msgstr "nemožno alokovať %s farbu"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:224
|
||||||
|
msgid "white"
|
||||||
|
msgstr "bielu"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:236
|
||||||
|
msgid "black"
|
||||||
|
msgstr "čiernu"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:275
|
||||||
|
msgid "gray"
|
||||||
|
msgstr "šedú"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolor.c:316
|
||||||
|
msgid "dark gray"
|
||||||
|
msgstr "tmavošedú"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:420
|
||||||
|
msgid "Colors"
|
||||||
|
msgstr "Farby"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:610 ../../WINGs/wcolorpanel.c:2829
|
||||||
|
msgid "Brightness"
|
||||||
|
msgstr "Svetlosť"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:612 ../../WINGs/wcolorpanel.c:688
|
||||||
|
#: ../../WINGs/wcolorpanel.c:721 ../../WINGs/wcolorpanel.c:755
|
||||||
|
#: ../../WINGs/wcolorpanel.c:815 ../../WINGs/wcolorpanel.c:849
|
||||||
|
#: ../../WINGs/wcolorpanel.c:883 ../../WINGs/wcolorpanel.c:918
|
||||||
|
#: ../../WINGs/wcolorpanel.c:2169 ../../WINGs/wcolorpanel.c:2831
|
||||||
|
#: ../../WINGs/wcolorpanel.c:2867 ../../WINGs/wcolorpanel.c:2903
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3745
|
||||||
|
msgid "Color Panel: Could not allocate memory"
|
||||||
|
msgstr "Panel farieb: Nemožno alokovať pamäť"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:685 ../../WINGs/wcolorpanel.c:686
|
||||||
|
msgid "Red"
|
||||||
|
msgstr "Červená"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:718 ../../WINGs/wcolorpanel.c:719
|
||||||
|
msgid "Green"
|
||||||
|
msgstr "Zelená"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:752 ../../WINGs/wcolorpanel.c:753
|
||||||
|
msgid "Blue"
|
||||||
|
msgstr "Modrá"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:812 ../../WINGs/wcolorpanel.c:813
|
||||||
|
msgid "Cyan"
|
||||||
|
msgstr "Azúrová"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:846 ../../WINGs/wcolorpanel.c:847
|
||||||
|
msgid "Magenta"
|
||||||
|
msgstr "Purpurová"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:880 ../../WINGs/wcolorpanel.c:881
|
||||||
|
msgid "Yellow"
|
||||||
|
msgstr "Žltá"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:915 ../../WINGs/wcolorpanel.c:916
|
||||||
|
msgid "Black"
|
||||||
|
msgstr "Čierna"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:996
|
||||||
|
msgid "Spectrum"
|
||||||
|
msgstr "Spektrum"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1026
|
||||||
|
msgid "Palette"
|
||||||
|
msgstr "Paleta"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1032
|
||||||
|
msgid "New from File..."
|
||||||
|
msgstr "Nová zo súboru..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1033 ../../WINGs/wcolorpanel.c:1081
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1098
|
||||||
|
msgid "Rename..."
|
||||||
|
msgstr "Premenovať..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1034 ../../WINGs/wcolorpanel.c:1082
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1099 ../../WINGs/wcolorpanel.c:3326
|
||||||
|
msgid "Remove"
|
||||||
|
msgstr "Odstrániť"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1035
|
||||||
|
msgid "Copy"
|
||||||
|
msgstr "Kopírovať"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1036
|
||||||
|
msgid "New from Clipboard"
|
||||||
|
msgstr "Nová z nástenky"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1057
|
||||||
|
msgid "X11-Colors"
|
||||||
|
msgstr "Farby X11"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1074
|
||||||
|
msgid "Color"
|
||||||
|
msgstr "Farba"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1080
|
||||||
|
msgid "Add..."
|
||||||
|
msgstr "Pridať..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1090
|
||||||
|
msgid "List"
|
||||||
|
msgstr "Zoznam"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1097
|
||||||
|
msgid "New..."
|
||||||
|
msgstr "Nový..."
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1236
|
||||||
|
#, c-format
|
||||||
|
msgid ""
|
||||||
|
"Color Panel: Could not create directory %s needed to store configurations"
|
||||||
|
msgstr ""
|
||||||
|
"Panel farieb: Nemožno vytvoriť adresár %s potrebný na uloženie nastavení"
|
||||||
|
|
||||||
|
#. Delete the file, it doesn't belong here
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1242 ../../WINGs/wcolorpanel.c:3212
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3216
|
||||||
|
msgid "File Error"
|
||||||
|
msgstr "Chyba súboru"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1243
|
||||||
|
msgid "Could not create ColorPanel configuration directory"
|
||||||
|
msgstr "Nemožno vytvoriť konfiguračný adresár panelu farieb"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1244 ../../WINGs/wcolorpanel.c:3213
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3218 ../../WINGs/wcolorpanel.c:3245
|
||||||
|
#: ../../WINGs/wfilepanel.c:250 ../../WINGs/wfilepanel.c:650
|
||||||
|
#: ../../WINGs/wfilepanel.c:662 ../../WINGs/wfilepanel.c:763
|
||||||
|
#: ../../WINGs/wfilepanel.c:974 ../../WINGs/wfontpanel.c:751
|
||||||
|
msgid "OK"
|
||||||
|
msgstr "OK"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1250 ../../WINGs/wcolorpanel.c:1286
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1304
|
||||||
|
msgid "Color Panel: Could not find file"
|
||||||
|
msgstr "Panel farieb: Nemožno nájsť súbor"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1491 ../../WINGs/wcolorpanel.c:1556
|
||||||
|
#: ../../WINGs/wcolorpanel.c:1620
|
||||||
|
msgid "Color Panel: X failed request"
|
||||||
|
msgstr "Panel farieb: chyba požiadavky X"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:2865
|
||||||
|
msgid "Saturation"
|
||||||
|
msgstr "Saturácia"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:2901
|
||||||
|
msgid "Hue"
|
||||||
|
msgstr "Odtieň"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3151
|
||||||
|
msgid "Open Palette"
|
||||||
|
msgstr "Otvoriť paletu"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3213
|
||||||
|
msgid "Invalid file format !"
|
||||||
|
msgstr "Nesprávny súborový formát!"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3215
|
||||||
|
#, c-format
|
||||||
|
msgid "can't remove file %s"
|
||||||
|
msgstr "namožno odstrániť súbor %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3217
|
||||||
|
msgid "Couldn't remove file from Configuration Directory !"
|
||||||
|
msgstr "Nemožno odstrániť súbor z konfiguračného adresára!"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3244
|
||||||
|
msgid "Rename"
|
||||||
|
msgstr "Premenovať"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3244
|
||||||
|
msgid "Rename palette to:"
|
||||||
|
msgstr "Premenovať paletu:"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3245 ../../WINGs/wfilepanel.c:259
|
||||||
|
#: ../../WINGs/wfilepanel.c:662 ../../WINGs/wfilepanel.c:763
|
||||||
|
msgid "Cancel"
|
||||||
|
msgstr "Zrušiť"
|
||||||
|
|
||||||
|
#. Careful, this palette exists already
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3261 ../../WINGs/wfilepanel.c:763
|
||||||
|
msgid "Warning"
|
||||||
|
msgstr "Varovanie"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3262
|
||||||
|
msgid ""
|
||||||
|
"Palette already exists !\n"
|
||||||
|
"\n"
|
||||||
|
"Overwrite ?"
|
||||||
|
msgstr ""
|
||||||
|
"Paleta už existuje!\n"
|
||||||
|
"\n"
|
||||||
|
"Prepísať?"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3262 ../../WINGs/wcolorpanel.c:3326
|
||||||
|
msgid "No"
|
||||||
|
msgstr "Nie"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3262 ../../WINGs/wcolorpanel.c:3326
|
||||||
|
msgid "Yes"
|
||||||
|
msgstr "Áno"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3294
|
||||||
|
#, c-format
|
||||||
|
msgid "Couldn't rename palette %s to %s\n"
|
||||||
|
msgstr "Nemožno premenovať paletu %s na %s\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3320
|
||||||
|
msgid "This will permanently remove the palette "
|
||||||
|
msgstr "Paleta bude natrvalo zmazaná"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3323
|
||||||
|
msgid ""
|
||||||
|
".\n"
|
||||||
|
"\n"
|
||||||
|
"Are you sure you want to remove this palette ?"
|
||||||
|
msgstr ""
|
||||||
|
".\n"
|
||||||
|
"\n"
|
||||||
|
"Ste si istý, že chcete odstrániť túto paletu?"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3348
|
||||||
|
#, c-format
|
||||||
|
msgid "Couldn't remove palette %s\n"
|
||||||
|
msgstr "Nemožno odstrániť paletu %s\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3647
|
||||||
|
#, c-format
|
||||||
|
msgid "Could not open %s"
|
||||||
|
msgstr "Nemožno otvoriť %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3654
|
||||||
|
#, c-format
|
||||||
|
msgid "Could not create %s"
|
||||||
|
msgstr "Nemožno vytvoriť %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3665
|
||||||
|
#, c-format
|
||||||
|
msgid "Write error on file %s"
|
||||||
|
msgstr "Chyba zápisu do súboru %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/wcolorpanel.c:3710
|
||||||
|
msgid "Color Panel: Color unspecified"
|
||||||
|
msgstr "Panel farieb: Nešpecifikovaná farba"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:235
|
||||||
|
msgid "Name:"
|
||||||
|
msgstr "Meno:"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:332 ../../WINGs/wfilepanel.c:396
|
||||||
|
msgid "Open"
|
||||||
|
msgstr "Otvoriť"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:350 ../../WINGs/wfilepanel.c:402
|
||||||
|
msgid "Save"
|
||||||
|
msgstr "Uložiť"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:565
|
||||||
|
#, c-format
|
||||||
|
msgid "WINGs: could not open directory %s\n"
|
||||||
|
msgstr "WINGs: nemožno otvoriť adresár %s\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:583
|
||||||
|
#, c-format
|
||||||
|
msgid "WINGs: could not stat %s\n"
|
||||||
|
msgstr "WINGs: nemožno zistiť informácie o %s\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:650 ../../WINGs/wfilepanel.c:973
|
||||||
|
#: ../../WINGs/wfontpanel.c:750
|
||||||
|
msgid "Error"
|
||||||
|
msgstr "Chyba"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:661
|
||||||
|
msgid "Create Directory"
|
||||||
|
msgstr "Vytvoriť adresár"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:662
|
||||||
|
msgid "Enter directory name"
|
||||||
|
msgstr "Meno adresára"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:698 ../../WINGs/wfilepanel.c:737
|
||||||
|
#: ../../WINGs/wfilepanel.c:768 ../../WINGs/wfilepanel.c:796
|
||||||
|
msgid "Permission denied."
|
||||||
|
msgstr "Prístup zamietnutý."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:701
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' already exists."
|
||||||
|
msgstr "'%s' už existuje"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:704
|
||||||
|
msgid "Path does not exist."
|
||||||
|
msgstr "Cesta neexistuje."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:734 ../../WINGs/wfilepanel.c:793
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' does not exist."
|
||||||
|
msgstr "'%s' neexistuje."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:741 ../../WINGs/wfilepanel.c:800
|
||||||
|
msgid "Insufficient memory available."
|
||||||
|
msgstr "Nedostatok pamäti."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:745 ../../WINGs/wfilepanel.c:804
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' is on a read-only filesystem."
|
||||||
|
msgstr "'%s' je na súborovom systéme len pre čítanie."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:748 ../../WINGs/wfilepanel.c:780
|
||||||
|
#: ../../WINGs/wfilepanel.c:807
|
||||||
|
#, c-format
|
||||||
|
msgid "Can not delete '%s'."
|
||||||
|
msgstr "Nemožno odstrániť '%s'."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:755
|
||||||
|
#, c-format
|
||||||
|
msgid "Delete directory %s ?"
|
||||||
|
msgstr "Odstrániť adresár %s?"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:759
|
||||||
|
#, c-format
|
||||||
|
msgid "Delete file %s ?"
|
||||||
|
msgstr "Odstrániť súbor %s?"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:771
|
||||||
|
#, c-format
|
||||||
|
msgid "Directory '%s' does not exist."
|
||||||
|
msgstr "Adresár '%s' neexistuje."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:774
|
||||||
|
#, c-format
|
||||||
|
msgid "Directory '%s' is not empty."
|
||||||
|
msgstr "Adresár '%s' nie je prázdny."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:777
|
||||||
|
#, c-format
|
||||||
|
msgid "Directory '%s' is busy."
|
||||||
|
msgstr "Adresár '%s' je používaný."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:790
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' is a directory."
|
||||||
|
msgstr "'%s' je adresár."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:832
|
||||||
|
#, c-format
|
||||||
|
msgid "An error occured browsing '%s'."
|
||||||
|
msgstr "Pri prehliadaní '%s' nastala chyba."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:836
|
||||||
|
#, c-format
|
||||||
|
msgid "'%s' is not a directory."
|
||||||
|
msgstr "'%s' nie je adresár."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfilepanel.c:973
|
||||||
|
msgid "File does not exist."
|
||||||
|
msgstr "Súbor neexistuje."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:324 ../../WINGs/wfont.c:344
|
||||||
|
#, c-format
|
||||||
|
msgid "could not load font %s."
|
||||||
|
msgstr "nemožno načítať font %s."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:375 ../../WINGs/wfont.c:420 ../../WINGs/wfont.c:475
|
||||||
|
#: ../../WINGs/wfont.c:1337 ../../WINGs/wfont.c:1398 ../../WINGs/wfont.c:1469
|
||||||
|
#, c-format
|
||||||
|
msgid ""
|
||||||
|
"Conversion to widechar failed (possible invalid multibyte sequence): '%s':"
|
||||||
|
"(pos %d)\n"
|
||||||
|
msgstr ""
|
||||||
|
"Konverzia do widechar zlyhala (možno nesprávna multibyte sekvencia): '%s':"
|
||||||
|
"(pos %d)\n"
|
||||||
|
|
||||||
|
#. // remove warning later. or maybe not
|
||||||
|
#: ../../WINGs/wfont.c:591 ../../WINGs/wfont.c:1568
|
||||||
|
#, c-format
|
||||||
|
msgid "Invalid font specification: '%s'\n"
|
||||||
|
msgstr "Chybná špecifikácia fontu: '%s'\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:770 ../../WINGs/wfont.c:780
|
||||||
|
#, c-format
|
||||||
|
msgid "Invalid size specification '%s' in %s. Using default %d\n"
|
||||||
|
msgstr "Chybná špecifikácia veľkosti '%s' v %s. Použije sa implicitná %d\n"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:824
|
||||||
|
#, c-format
|
||||||
|
msgid "the following character sets are missing in %s:"
|
||||||
|
msgstr "nasledujúce sady znakov chýbajú v %s:"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:830
|
||||||
|
#, c-format
|
||||||
|
msgid ""
|
||||||
|
"the string \"%s\" will be used in place of any characters from those sets."
|
||||||
|
msgstr "reťazec \"%s\" bude použitý namiesto znakov z týchto sád."
|
||||||
|
|
||||||
|
#. is arial a good fallback for multibyte?
|
||||||
|
#: ../../WINGs/wfont.c:1232 ../../WINGs/wfont.c:1247
|
||||||
|
#, c-format
|
||||||
|
msgid "could not load font %s. Trying arial."
|
||||||
|
msgstr "nemožno načítať font %s. Skúša sa načítať arial."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:1239
|
||||||
|
msgid "could not load antialiased font set. Reverting to standard font sets."
|
||||||
|
msgstr "nemožno načítať antialiasovanú sadu fontov. Späť k štandardnej sade fontov."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:1242
|
||||||
|
#, c-format
|
||||||
|
msgid "could not load FontSet %s. Trying fixed."
|
||||||
|
msgstr "nemožno načítať sadu fontov %s. Skúša sa načítať fixed."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:1254
|
||||||
|
msgid "could not load antialiased fonts. Reverting to normal fonts."
|
||||||
|
msgstr "nemožno zaviesť antialiasovaný font. Návrat k normálnemu fontu."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:1257 ../../WINGs/wfont.c:1268
|
||||||
|
#, c-format
|
||||||
|
msgid "could not load font %s. Trying fixed."
|
||||||
|
msgstr "nemožno načítať font %s. Skúša sa načítať fixed."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:1262
|
||||||
|
#, c-format
|
||||||
|
msgid "could not load font set %s. Trying fixed."
|
||||||
|
msgstr "nemožno načítať font %s. Skúša sa načítať fixed."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:1272
|
||||||
|
msgid "could not load fixed font!"
|
||||||
|
msgstr "nemožno načítať font fixed!"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfont.c:1520
|
||||||
|
#, c-format
|
||||||
|
msgid "font description %s is too large."
|
||||||
|
msgstr "popis fontu %s je príliš veľký."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:235
|
||||||
|
msgid "Test!!!"
|
||||||
|
msgstr "Skúška!!!"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:241
|
||||||
|
msgid "Family"
|
||||||
|
msgstr "Rodina"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:252
|
||||||
|
msgid "Typeface"
|
||||||
|
msgstr "Vzhľad"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:263
|
||||||
|
msgid "Size"
|
||||||
|
msgstr "Veľkosť"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:282
|
||||||
|
msgid "Set"
|
||||||
|
msgstr "Sada"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:288
|
||||||
|
msgid "Revert"
|
||||||
|
msgstr "Obrátiť"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:751
|
||||||
|
msgid "Could not retrieve font list"
|
||||||
|
msgstr "Nemožno obdržať zoznam fontov"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:765
|
||||||
|
#, c-format
|
||||||
|
msgid "font name %s is longer than 256, which is invalid."
|
||||||
|
msgstr "meno fontu %s je dlhšie ako 256, čo je nesprávne."
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:913
|
||||||
|
msgid "Roman"
|
||||||
|
msgstr "roman"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:916
|
||||||
|
msgid "Italic"
|
||||||
|
msgstr "kurzíva"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:918
|
||||||
|
msgid "Oblique"
|
||||||
|
msgstr "šikmé"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:920
|
||||||
|
msgid "Rev Italic"
|
||||||
|
msgstr "obr. kurzíva"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:922
|
||||||
|
msgid "Rev Oblique"
|
||||||
|
msgstr "obr. šikmé"
|
||||||
|
|
||||||
|
#: ../../WINGs/wfontpanel.c:928
|
||||||
|
msgid "Normal"
|
||||||
|
msgstr "normálne"
|
||||||
|
|
||||||
|
#: ../../WINGs/widgets.c:419
|
||||||
|
#, c-format
|
||||||
|
msgid "WINGs: could not load widget images file: %s"
|
||||||
|
msgstr "WINGs: nemožno načítať súbor s obrázkami pre widgety: %s"
|
||||||
|
|
||||||
|
#: ../../WINGs/widgets.c:772
|
||||||
|
msgid ""
|
||||||
|
"could not load any fonts. Make sure your font installation and locale "
|
||||||
|
"settings are correct."
|
||||||
|
msgstr ""
|
||||||
|
"nemožno načítať žiadny font. Ubezpečte sa, že inštalácia fontov a miestne "
|
||||||
|
"nastavenia sú v poriadku."
|
||||||
|
|
||||||
|
#: ../../WINGs/wruler.c:192
|
||||||
|
msgid "0 inches"
|
||||||
|
msgstr "0 palcov"
|
||||||
1734
WINGs/proplist.c
Normal file
1734
WINGs/proplist.c
Normal file
File diff suppressed because it is too large
Load Diff
5
WINGs/python/.cvsignore
Normal file
5
WINGs/python/.cvsignore
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
build
|
||||||
|
WINGs.c
|
||||||
|
wings.so
|
||||||
|
*.pyc
|
||||||
|
*.pyo
|
||||||
17
WINGs/python/Makefile
Normal file
17
WINGs/python/Makefile
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
|
||||||
|
all: WINGs.c
|
||||||
|
python setup.py build
|
||||||
|
ln -sf `find build/ -name wings.so` .
|
||||||
|
|
||||||
|
install: WINGs.c
|
||||||
|
python setup.py install
|
||||||
|
|
||||||
|
clean:
|
||||||
|
rm -rf build dist WINGs.c *.o *~ *.so MANIFEST wings.py *.pyc *.pyo core
|
||||||
|
|
||||||
|
dist:
|
||||||
|
python setup.py sdist
|
||||||
|
|
||||||
|
WINGs.c: WINGs.i
|
||||||
|
swig -python -noproxy `get-wings-flags --cflags` -I.. -o WINGs.c WINGs.i
|
||||||
|
|
||||||
20
WINGs/python/README
Normal file
20
WINGs/python/README
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
|
||||||
|
This is a python wrapper for the WINGs library, that can be used to write python
|
||||||
|
based programs with WINGs-based graphic interfaces.
|
||||||
|
|
||||||
|
This module in not built by default. To build it you need python2.1 or later
|
||||||
|
and swig-1.3.14 or later.
|
||||||
|
|
||||||
|
To build it, first compile and install WINGs. after that run 'make' in this
|
||||||
|
directory. 'make install' will install the python module into the python tree.
|
||||||
|
|
||||||
|
run test.py or WINGs.py for an example.
|
||||||
|
|
||||||
|
the code is not finished yet and may fail to work as expected in some cases.
|
||||||
|
|
||||||
|
Note: currently the module expects WINGs installed to build. it won't take
|
||||||
|
the WINGs libraries and header files from the source tree. You need to
|
||||||
|
install WINGs first. Even if an old version of WINGs is already installed,
|
||||||
|
you still need to install the newly built WINGs, else the python module will
|
||||||
|
be built against the old version.
|
||||||
|
|
||||||
699
WINGs/python/WINGs.i
Normal file
699
WINGs/python/WINGs.i
Normal file
@@ -0,0 +1,699 @@
|
|||||||
|
%module wings
|
||||||
|
%{
|
||||||
|
#include "WINGs/WINGsP.h"
|
||||||
|
%}
|
||||||
|
|
||||||
|
%include typemaps.i
|
||||||
|
|
||||||
|
// This tells SWIG to treat char ** as a special case
|
||||||
|
%typemap(python, in) char ** {
|
||||||
|
/* Check if is a list */
|
||||||
|
if (PyList_Check($input)) {
|
||||||
|
int size = PyList_Size($input);
|
||||||
|
int i = 0;
|
||||||
|
$1 = (char **) wmalloc((size+1)*sizeof(char *));
|
||||||
|
for (i = 0; i < size; i++) {
|
||||||
|
PyObject *o = PyList_GetItem($input, i);
|
||||||
|
if (PyString_Check(o))
|
||||||
|
$1[i] = PyString_AsString(PyList_GetItem($input, i));
|
||||||
|
else {
|
||||||
|
PyErr_SetString(PyExc_TypeError, "list must contain strings");
|
||||||
|
wfree($1);
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
$1[i] = 0;
|
||||||
|
} else {
|
||||||
|
PyErr_SetString(PyExc_TypeError, "not a list");
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// This cleans up the char ** array we malloc-ed before the function call
|
||||||
|
%typemap(python, freearg) char ** {
|
||||||
|
wfree($1);
|
||||||
|
}
|
||||||
|
// This allows a C function to return a char ** as a Python list
|
||||||
|
%typemap(python, out) char ** {
|
||||||
|
int len,i;
|
||||||
|
len = 0;
|
||||||
|
while ($1[len]) len++;
|
||||||
|
$result = PyList_New(len);
|
||||||
|
for (i = 0; i < len; i++) {
|
||||||
|
PyList_SetItem($result, i, PyString_FromString($1[i]));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Now for some callbacks
|
||||||
|
%typemap(python, in) PyObject *pyacArgs {
|
||||||
|
if (PyTuple_Check($input)) {
|
||||||
|
if (PyTuple_Size($input) != 3) {
|
||||||
|
PyErr_SetString(PyExc_ValueError,
|
||||||
|
"wrong number of parameters in tuple. should be 3.");
|
||||||
|
return NULL;
|
||||||
|
} else {
|
||||||
|
PyObject *func = PyTuple_GetItem($input, 1);
|
||||||
|
if (func!=Py_None && !PyCallable_Check(func)) {
|
||||||
|
PyErr_SetString(PyExc_TypeError,
|
||||||
|
"'action' needs to be a callable object!");
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
PyErr_SetString(PyExc_TypeError, "2nd argument not a tuple!");
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
$1 = $input;
|
||||||
|
}
|
||||||
|
|
||||||
|
%typemap(python, in) PyObject *pycArgs {
|
||||||
|
if (PyTuple_Check($input)) {
|
||||||
|
if (PyTuple_Size($input) != 2) {
|
||||||
|
PyErr_SetString(PyExc_ValueError,
|
||||||
|
"wrong number of parameters in tuple. should be 2.");
|
||||||
|
return NULL;
|
||||||
|
} else {
|
||||||
|
PyObject *func = PyTuple_GetItem($input, 0);
|
||||||
|
if (func!=Py_None && !PyCallable_Check(func)) {
|
||||||
|
PyErr_SetString(PyExc_TypeError,
|
||||||
|
"'action' needs to be a callable object!");
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
PyErr_SetString(PyExc_TypeError, "2nd argument not a tuple!");
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
$1 = $input;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Type mapping for grabbing a FILE * from Python
|
||||||
|
%typemap(python, in) FILE * {
|
||||||
|
if (!PyFile_Check($input)) {
|
||||||
|
PyErr_SetString(PyExc_TypeError, "Need a file!");
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
$1 = PyFile_AsFile($input);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* These are for free-ing the return of functions that need to be freed
|
||||||
|
* before returning control to python. */
|
||||||
|
%typemap(python, ret) char* WMGetTextFieldText { wfree($1); };
|
||||||
|
|
||||||
|
|
||||||
|
%include exception.i
|
||||||
|
|
||||||
|
%exception pyWMScreenMainLoop {
|
||||||
|
$function
|
||||||
|
if (PyErr_Occurred())
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
|
%exception pyWMRunModalLoop {
|
||||||
|
$function
|
||||||
|
if (PyErr_Occurred())
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
|
%{
|
||||||
|
static int mainLoopDone = 0;
|
||||||
|
%}
|
||||||
|
|
||||||
|
|
||||||
|
%inline %{
|
||||||
|
WMScreen *pyWMOpenScreen(const char *display, int simpleapp)
|
||||||
|
{
|
||||||
|
Display *dpy = XOpenDisplay(display);
|
||||||
|
|
||||||
|
if (!dpy) {
|
||||||
|
wwarning("WINGs: could not open display %s", XDisplayName(display));
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (simpleapp) {
|
||||||
|
return WMCreateSimpleApplicationScreen(dpy);
|
||||||
|
} else {
|
||||||
|
return WMCreateScreen(dpy, DefaultScreen(dpy));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void pyWMScreenMainLoop(WMScreen *scr)
|
||||||
|
{
|
||||||
|
XEvent event;
|
||||||
|
|
||||||
|
while (!PyErr_Occurred() && !mainLoopDone) {
|
||||||
|
WMNextEvent(((W_Screen*)scr)->display, &event);
|
||||||
|
WMHandleEvent(&event);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void pyWMBreakScreenMainLoop(WMScreen *scr)
|
||||||
|
{
|
||||||
|
mainLoopDone = 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
void pyWMRunModalLoop(WMScreen *scr, WMView *view)
|
||||||
|
{
|
||||||
|
int oldModalLoop = scr->modalLoop;
|
||||||
|
WMView *oldModalView = scr->modalView;
|
||||||
|
|
||||||
|
scr->modalView = view;
|
||||||
|
|
||||||
|
scr->modalLoop = 1;
|
||||||
|
while (!PyErr_Occurred() && scr->modalLoop) {
|
||||||
|
XEvent event;
|
||||||
|
|
||||||
|
WMNextEvent(scr->display, &event);
|
||||||
|
WMHandleEvent(&event);
|
||||||
|
}
|
||||||
|
|
||||||
|
scr->modalView = oldModalView;
|
||||||
|
scr->modalLoop = oldModalLoop;
|
||||||
|
}
|
||||||
|
%}
|
||||||
|
|
||||||
|
|
||||||
|
//%rename WMScreenMainLoop _WMScreenMainLoop;
|
||||||
|
//%rename(_WMScreenMainLoop) WMScreenMainLoop;
|
||||||
|
//%rename WMRunModalLoop _WMRunModalLoop;
|
||||||
|
|
||||||
|
|
||||||
|
%{
|
||||||
|
/* These functions match the prototypes of the normal C callback
|
||||||
|
* functions. However, we use the clientdata pointer for holding a
|
||||||
|
* reference to a Python tuple containing (object, funct, clientData).
|
||||||
|
*/
|
||||||
|
static void PythonWMActionCallback(WMWidget *widget, void *cdata)
|
||||||
|
{
|
||||||
|
PyObject *pyobj, *func, *pydata, *arglist, *tuple, *result;
|
||||||
|
|
||||||
|
tuple = (PyObject*) cdata;
|
||||||
|
pyobj = PyTuple_GetItem(tuple, 0);
|
||||||
|
func = PyTuple_GetItem(tuple, 1);
|
||||||
|
if (func && func!=Py_None) {
|
||||||
|
pydata = PyTuple_GetItem(tuple, 2);
|
||||||
|
arglist = Py_BuildValue("(OO)", pyobj, pydata);
|
||||||
|
result = PyEval_CallObject(func, arglist);
|
||||||
|
Py_DECREF(arglist);
|
||||||
|
Py_XDECREF(result);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
static void PythonWMCallback(void *data)
|
||||||
|
{
|
||||||
|
PyObject *func, *pydata, *arglist, *tuple, *result;
|
||||||
|
|
||||||
|
tuple = (PyObject*) data;
|
||||||
|
func = PyTuple_GetItem(tuple, 0);
|
||||||
|
if (func && func!=Py_None) {
|
||||||
|
pydata = PyTuple_GetItem(tuple, 1);
|
||||||
|
arglist = Py_BuildValue("(O)", pydata);
|
||||||
|
result = PyEval_CallObject(func, arglist);
|
||||||
|
Py_DECREF(arglist);
|
||||||
|
Py_XDECREF(result);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
static void
|
||||||
|
pyTextFieldDidBeginEditing(WMTextFieldDelegate *self, WMNotification *notif)
|
||||||
|
{
|
||||||
|
PyObject *pyobj, *delegate, *func, *pydata, *arglist, *tuple, *result;
|
||||||
|
int action;
|
||||||
|
|
||||||
|
tuple = (PyObject*) self->data;
|
||||||
|
pyobj = PyTuple_GetItem(tuple, 0);
|
||||||
|
delegate = PyTuple_GetItem(tuple, 1);
|
||||||
|
if (delegate != Py_None) {
|
||||||
|
// should we call PyObject_HasAttrString()?? rather not and let
|
||||||
|
// python raise an exception because the object doesn't has the
|
||||||
|
// attribute
|
||||||
|
func = PyObject_GetAttrString(delegate, "didBeginEditing");
|
||||||
|
if (func!=NULL && func!=Py_None) {
|
||||||
|
pydata = PyObject_GetAttrString(delegate, "data");
|
||||||
|
if (!pydata) {
|
||||||
|
Py_INCREF(Py_None);
|
||||||
|
pydata = Py_None;
|
||||||
|
}
|
||||||
|
action = (int)WMGetNotificationClientData(notif);
|
||||||
|
arglist = Py_BuildValue("(OOi)", pyobj, pydata, action);
|
||||||
|
result = PyEval_CallObject(func, arglist);
|
||||||
|
Py_DECREF(pydata);
|
||||||
|
Py_DECREF(arglist);
|
||||||
|
Py_XDECREF(result);
|
||||||
|
}
|
||||||
|
Py_XDECREF(func);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
static void
|
||||||
|
pyTextFieldDidChange(WMTextFieldDelegate *self, WMNotification *notif)
|
||||||
|
{
|
||||||
|
PyObject *pyobj, *delegate, *func, *pydata, *arglist, *tuple, *result;
|
||||||
|
int action;
|
||||||
|
|
||||||
|
tuple = (PyObject*) self->data;
|
||||||
|
pyobj = PyTuple_GetItem(tuple, 0);
|
||||||
|
delegate = PyTuple_GetItem(tuple, 1);
|
||||||
|
if (delegate != Py_None) {
|
||||||
|
func = PyObject_GetAttrString(delegate, "didChange");
|
||||||
|
if (func!=NULL && func!=Py_None) {
|
||||||
|
pydata = PyObject_GetAttrString(delegate, "data");
|
||||||
|
if (!pydata) {
|
||||||
|
Py_INCREF(Py_None);
|
||||||
|
pydata = Py_None;
|
||||||
|
}
|
||||||
|
action = (int)WMGetNotificationClientData(notif);
|
||||||
|
arglist = Py_BuildValue("(OOi)", pyobj, pydata, action);
|
||||||
|
result = PyEval_CallObject(func, arglist);
|
||||||
|
Py_DECREF(pydata);
|
||||||
|
Py_DECREF(arglist);
|
||||||
|
Py_XDECREF(result);
|
||||||
|
}
|
||||||
|
Py_XDECREF(func);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
static void
|
||||||
|
pyTextFieldDidEndEditing(WMTextFieldDelegate *self, WMNotification *notif)
|
||||||
|
{
|
||||||
|
PyObject *pyobj, *delegate, *func, *pydata, *arglist, *tuple, *result;
|
||||||
|
int action;
|
||||||
|
|
||||||
|
tuple = (PyObject*) self->data;
|
||||||
|
pyobj = PyTuple_GetItem(tuple, 0);
|
||||||
|
delegate = PyTuple_GetItem(tuple, 1);
|
||||||
|
if (delegate != Py_None) {
|
||||||
|
func = PyObject_GetAttrString(delegate, "didEndEditing");
|
||||||
|
if (func!=NULL && func!=Py_None) {
|
||||||
|
pydata = PyObject_GetAttrString(delegate, "data");
|
||||||
|
if (!pydata) {
|
||||||
|
Py_INCREF(Py_None);
|
||||||
|
pydata = Py_None;
|
||||||
|
}
|
||||||
|
action = (int)WMGetNotificationClientData(notif);
|
||||||
|
arglist = Py_BuildValue("(OOi)", pyobj, pydata, action);
|
||||||
|
result = PyEval_CallObject(func, arglist);
|
||||||
|
Py_DECREF(pydata);
|
||||||
|
Py_DECREF(arglist);
|
||||||
|
Py_XDECREF(result);
|
||||||
|
}
|
||||||
|
Py_XDECREF(func);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
static Bool
|
||||||
|
pyTextFieldShouldBeginEditing(WMTextFieldDelegate *self, WMTextField *tPtr)
|
||||||
|
{
|
||||||
|
PyObject *pyobj, *delegate, *func, *pydata, *arglist, *tuple, *result;
|
||||||
|
Bool retval = False;
|
||||||
|
|
||||||
|
tuple = (PyObject*) self->data;
|
||||||
|
pyobj = PyTuple_GetItem(tuple, 0);
|
||||||
|
delegate = PyTuple_GetItem(tuple, 1);
|
||||||
|
if (delegate != Py_None) {
|
||||||
|
func = PyObject_GetAttrString(delegate, "shouldBeginEditing");
|
||||||
|
if (func!=NULL && func!=Py_None) {
|
||||||
|
pydata = PyObject_GetAttrString(delegate, "data");
|
||||||
|
if (!pydata) {
|
||||||
|
Py_INCREF(Py_None);
|
||||||
|
pydata = Py_None;
|
||||||
|
}
|
||||||
|
arglist = Py_BuildValue("(OO)", pyobj, pydata);
|
||||||
|
result = PyEval_CallObject(func, arglist);
|
||||||
|
if (result!=Py_None && PyInt_AsLong(result)!=0) {
|
||||||
|
retval = True;
|
||||||
|
}
|
||||||
|
Py_DECREF(pydata);
|
||||||
|
Py_DECREF(arglist);
|
||||||
|
Py_XDECREF(result);
|
||||||
|
}
|
||||||
|
Py_XDECREF(func);
|
||||||
|
}
|
||||||
|
|
||||||
|
return retval;
|
||||||
|
}
|
||||||
|
|
||||||
|
static Bool
|
||||||
|
pyTextFieldShouldEndEditing(WMTextFieldDelegate *self, WMTextField *tPtr)
|
||||||
|
{
|
||||||
|
PyObject *pyobj, *delegate, *func, *pydata, *arglist, *tuple, *result;
|
||||||
|
Bool retval = False;
|
||||||
|
|
||||||
|
tuple = (PyObject*) self->data;
|
||||||
|
pyobj = PyTuple_GetItem(tuple, 0);
|
||||||
|
delegate = PyTuple_GetItem(tuple, 1);
|
||||||
|
if (delegate != Py_None) {
|
||||||
|
func = PyObject_GetAttrString(delegate, "shouldEndEditing");
|
||||||
|
if (func!=NULL && func!=Py_None) {
|
||||||
|
pydata = PyObject_GetAttrString(delegate, "data");
|
||||||
|
if (!pydata) {
|
||||||
|
Py_INCREF(Py_None);
|
||||||
|
pydata = Py_None;
|
||||||
|
}
|
||||||
|
arglist = Py_BuildValue("(OO)", pyobj, pydata);
|
||||||
|
result = PyEval_CallObject(func, arglist);
|
||||||
|
if (result!=Py_None && PyInt_AsLong(result)!=0) {
|
||||||
|
retval = True;
|
||||||
|
}
|
||||||
|
Py_DECREF(pydata);
|
||||||
|
Py_DECREF(arglist);
|
||||||
|
Py_XDECREF(result);
|
||||||
|
}
|
||||||
|
Py_XDECREF(func);
|
||||||
|
}
|
||||||
|
|
||||||
|
return retval;
|
||||||
|
}
|
||||||
|
%}
|
||||||
|
|
||||||
|
%inline %{
|
||||||
|
void pyWMSetWindowCloseAction(WMWindow *win, PyObject *pyacArgs) {
|
||||||
|
WMSetWindowCloseAction(win, PythonWMActionCallback, (void*)pyacArgs);
|
||||||
|
Py_INCREF(pyacArgs);
|
||||||
|
}
|
||||||
|
|
||||||
|
void pyWMSetButtonAction(WMButton *bPtr, PyObject *pyacArgs) {
|
||||||
|
WMSetButtonAction(bPtr, PythonWMActionCallback, (void*)pyacArgs);
|
||||||
|
Py_INCREF(pyacArgs);
|
||||||
|
}
|
||||||
|
|
||||||
|
void pyWMSetScrollerAction(WMScroller *sPtr, PyObject *pyacArgs) {
|
||||||
|
WMSetScrollerAction(sPtr, PythonWMActionCallback, (void*)pyacArgs);
|
||||||
|
Py_INCREF(pyacArgs);
|
||||||
|
}
|
||||||
|
|
||||||
|
void pyWMSetListAction(WMList *lPtr, PyObject *pyacArgs) {
|
||||||
|
WMSetListAction(lPtr, PythonWMActionCallback, (void*)pyacArgs);
|
||||||
|
Py_INCREF(pyacArgs);
|
||||||
|
}
|
||||||
|
|
||||||
|
void pyWMSetListDoubleAction(WMList *lPtr, PyObject *pyacArgs) {
|
||||||
|
WMSetListDoubleAction(lPtr, PythonWMActionCallback, (void*)pyacArgs);
|
||||||
|
Py_INCREF(pyacArgs);
|
||||||
|
}
|
||||||
|
|
||||||
|
void pyWMSetBrowserAction(WMBrowser *bPtr, PyObject *pyacArgs) {
|
||||||
|
WMSetBrowserAction(bPtr, PythonWMActionCallback, (void*)pyacArgs);
|
||||||
|
Py_INCREF(pyacArgs);
|
||||||
|
}
|
||||||
|
|
||||||
|
void pyWMSetBrowserDoubleAction(WMBrowser *bPtr, PyObject *pyacArgs) {
|
||||||
|
WMSetBrowserDoubleAction(bPtr, PythonWMActionCallback, (void*)pyacArgs);
|
||||||
|
Py_INCREF(pyacArgs);
|
||||||
|
}
|
||||||
|
|
||||||
|
void pyWMSetMenuItemAction(WMMenuItem *miPtr, PyObject *pyacArgs) {
|
||||||
|
WMSetMenuItemAction(miPtr, PythonWMActionCallback, (void*)pyacArgs);
|
||||||
|
Py_INCREF(pyacArgs);
|
||||||
|
}
|
||||||
|
|
||||||
|
void pyWMSetPopUpButtonAction(WMPopUpButton *pPtr, PyObject *pyacArgs) {
|
||||||
|
WMSetPopUpButtonAction(pPtr, PythonWMActionCallback, (void*)pyacArgs);
|
||||||
|
Py_INCREF(pyacArgs);
|
||||||
|
}
|
||||||
|
|
||||||
|
void pyWMSetSliderAction(WMSlider *sPtr, PyObject *pyacArgs) {
|
||||||
|
WMSetSliderAction(sPtr, PythonWMActionCallback, (void*)pyacArgs);
|
||||||
|
Py_INCREF(pyacArgs);
|
||||||
|
}
|
||||||
|
|
||||||
|
void pyWMSetRulerMoveAction(WMRuler *rPtr, PyObject *pyacArgs) {
|
||||||
|
WMSetRulerMoveAction(rPtr, PythonWMActionCallback, (void*)pyacArgs);
|
||||||
|
Py_INCREF(pyacArgs);
|
||||||
|
}
|
||||||
|
|
||||||
|
void pyWMSetRulerReleaseAction(WMRuler *rPtr, PyObject *pyacArgs) {
|
||||||
|
WMSetRulerReleaseAction(rPtr, PythonWMActionCallback, (void*)pyacArgs);
|
||||||
|
Py_INCREF(pyacArgs);
|
||||||
|
}
|
||||||
|
|
||||||
|
void pyWMSetColorPanelAction(WMColorPanel *panel, PyObject *pyacArgs) {
|
||||||
|
WMSetColorPanelAction(panel, (WMAction2*)PythonWMActionCallback, (void*)pyacArgs);
|
||||||
|
Py_INCREF(pyacArgs);
|
||||||
|
}
|
||||||
|
|
||||||
|
void* pyWMAddTimerHandler(int miliseconds, PyObject *pycArgs) {
|
||||||
|
Py_INCREF(pycArgs);
|
||||||
|
return (void*)WMAddTimerHandler(miliseconds, PythonWMCallback,
|
||||||
|
(void*)pycArgs);
|
||||||
|
}
|
||||||
|
|
||||||
|
void* pyWMAddPersistentTimerHandler(int miliseconds, PyObject *pycArgs) {
|
||||||
|
Py_INCREF(pycArgs);
|
||||||
|
return (void*)WMAddPersistentTimerHandler(miliseconds, PythonWMCallback,
|
||||||
|
(void*)pycArgs);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* this doesn't work. we pass (func, data) as cdata at creation time, but
|
||||||
|
* only data at destruction, so it won't find it unless we change
|
||||||
|
* WMDeleteTimerWithClientData() to extract data from the tuple, and this
|
||||||
|
* requires access to the internals of WINGs
|
||||||
|
void pyWMDeleteTimerWithClientData(PyObject *pycData) {
|
||||||
|
WMDeleteTimerWithClientData((void*)pycData);
|
||||||
|
}*/
|
||||||
|
|
||||||
|
void pyWMDeleteTimerHandler(void *handlerID) {
|
||||||
|
WMDeleteTimerHandler((WMHandlerID)handlerID);
|
||||||
|
}
|
||||||
|
|
||||||
|
void* pyWMAddIdleHandler(PyObject *pycArgs) {
|
||||||
|
Py_INCREF(pycArgs);
|
||||||
|
return (void*)WMAddIdleHandler(PythonWMCallback, (void*)pycArgs);
|
||||||
|
}
|
||||||
|
|
||||||
|
void pyWMDeleteIdleHandler(void *handlerID) {
|
||||||
|
WMDeleteIdleHandler((WMHandlerID)handlerID);
|
||||||
|
}
|
||||||
|
|
||||||
|
%}
|
||||||
|
|
||||||
|
|
||||||
|
%exception pyWMSetTextFieldDelegate {
|
||||||
|
$function
|
||||||
|
if (PyErr_Occurred()) {
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
%inline %{
|
||||||
|
void pyWMSetTextFieldDelegate(WMTextField *tPtr, PyObject *txtArgs) {
|
||||||
|
WMTextFieldDelegate *td;
|
||||||
|
|
||||||
|
if (!txtArgs || !PyTuple_Check(txtArgs) || PyTuple_Size(txtArgs)!=2) {
|
||||||
|
PyErr_SetString(PyExc_TypeError, "invalid setting of WMTextField "
|
||||||
|
"delegate. Should be '(self, delegate)'");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
// how do I check if txtArgs[1] is an instance of WMTextFieldDelegate?
|
||||||
|
td = WMGetTextFieldDelegate(tPtr);
|
||||||
|
if (!td) {
|
||||||
|
td = (WMTextFieldDelegate*)wmalloc(sizeof(WMTextFieldDelegate));
|
||||||
|
td->didBeginEditing = pyTextFieldDidBeginEditing;
|
||||||
|
td->didChange = pyTextFieldDidChange;
|
||||||
|
td->didEndEditing = pyTextFieldDidEndEditing;
|
||||||
|
td->shouldBeginEditing = pyTextFieldShouldBeginEditing;
|
||||||
|
td->shouldEndEditing = pyTextFieldShouldEndEditing;
|
||||||
|
} else {
|
||||||
|
Py_XDECREF((PyObject*)td->data);
|
||||||
|
}
|
||||||
|
Py_INCREF(txtArgs);
|
||||||
|
td->data = txtArgs;
|
||||||
|
WMSetTextFieldDelegate(tPtr, td);
|
||||||
|
}
|
||||||
|
%}
|
||||||
|
|
||||||
|
|
||||||
|
%inline %{
|
||||||
|
PyObject* pyWMGetTextFieldDelegate(WMTextField *tPtr) {
|
||||||
|
WMTextFieldDelegate *td;
|
||||||
|
PyObject *result, *tuple;
|
||||||
|
|
||||||
|
td = WMGetTextFieldDelegate(tPtr);
|
||||||
|
if (!td) {
|
||||||
|
Py_INCREF(Py_None);
|
||||||
|
return Py_None;
|
||||||
|
}
|
||||||
|
|
||||||
|
tuple = (PyObject*)td->data;
|
||||||
|
if (!tuple || !PyTuple_Check(tuple) || PyTuple_Size(tuple)!=2) {
|
||||||
|
PyErr_SetString(PyExc_TypeError, "invalid TextField delegate");
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
|
||||||
|
result = PyTuple_GetItem(tuple, 1);
|
||||||
|
if (!result)
|
||||||
|
result = Py_None;
|
||||||
|
|
||||||
|
Py_INCREF(result);
|
||||||
|
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
%}
|
||||||
|
|
||||||
|
|
||||||
|
/* ignore structures we will not use */
|
||||||
|
%ignore ConnectionDelegate;
|
||||||
|
|
||||||
|
/* ignore functions we don't need */
|
||||||
|
// should we ignore vararg functions, or just convert them to functions with
|
||||||
|
// a fixed number of parameters?
|
||||||
|
%varargs(char*) wmessage;
|
||||||
|
//%ignore wmessage;
|
||||||
|
%ignore wwarning;
|
||||||
|
%ignore wfatal;
|
||||||
|
%ignore wsyserror;
|
||||||
|
%ignore wsyserrorwithcode;
|
||||||
|
%ignore WMCreatePLArray;
|
||||||
|
%ignore WMCreatePLDictionary;
|
||||||
|
|
||||||
|
%apply int *INPUT { int *argc };
|
||||||
|
|
||||||
|
#define Bool int
|
||||||
|
|
||||||
|
%include "WINGs/WUtil.h"
|
||||||
|
|
||||||
|
/* ignore structures we will not use */
|
||||||
|
|
||||||
|
/* ignore functions we don't need */
|
||||||
|
|
||||||
|
%include "WINGs/WINGs.h"
|
||||||
|
|
||||||
|
|
||||||
|
%{
|
||||||
|
void
|
||||||
|
WHandleEvents()
|
||||||
|
{
|
||||||
|
/* Check any expired timers */
|
||||||
|
W_CheckTimerHandlers();
|
||||||
|
|
||||||
|
/* Do idle and timer stuff while there are no input events */
|
||||||
|
/* Do not wait for input here. just peek to se if input is available */
|
||||||
|
while (!W_HandleInputEvents(False, -1) && W_CheckIdleHandlers()) {
|
||||||
|
/* dispatch timer events */
|
||||||
|
W_CheckTimerHandlers();
|
||||||
|
}
|
||||||
|
|
||||||
|
W_HandleInputEvents(True, -1);
|
||||||
|
|
||||||
|
/* Check any expired timers */
|
||||||
|
W_CheckTimerHandlers();
|
||||||
|
}
|
||||||
|
%}
|
||||||
|
|
||||||
|
|
||||||
|
/* rewrite functions originally defined as macros */
|
||||||
|
%inline %{
|
||||||
|
#undef WMDuplicateArray
|
||||||
|
WMArray* WMDuplicateArray(WMArray* array) {
|
||||||
|
return WMCreateArrayWithArray(array);
|
||||||
|
}
|
||||||
|
|
||||||
|
#undef WMPushInArray
|
||||||
|
void WMPushInArray(WMArray *array, void *item) {
|
||||||
|
WMAddToArray(array, item);
|
||||||
|
}
|
||||||
|
|
||||||
|
#undef WMSetInArray
|
||||||
|
void* WMSetInArray(WMArray *array, int index, void *item) {
|
||||||
|
return WMReplaceInArray(array, index, item);
|
||||||
|
}
|
||||||
|
|
||||||
|
#undef WMRemoveFromArray
|
||||||
|
int WMRemoveFromArray(WMArray *array, void *item) {
|
||||||
|
return WMRemoveFromArrayMatching(array, NULL, item);
|
||||||
|
}
|
||||||
|
|
||||||
|
#undef WMGetFirstInArray
|
||||||
|
int WMGetFirstInArray(WMArray *array, void *item) {
|
||||||
|
return WMFindInArray(array, NULL, item);
|
||||||
|
}
|
||||||
|
|
||||||
|
#undef WMCreateBag
|
||||||
|
WMBag* WMCreateBag(int size) {
|
||||||
|
return WMCreateTreeBag();
|
||||||
|
}
|
||||||
|
|
||||||
|
#undef WMCreateBagWithDestructor
|
||||||
|
WMBag* WMCreateBagWithDestructor(int size, WMFreeDataProc *destructor) {
|
||||||
|
return WMCreateTreeBagWithDestructor(destructor);
|
||||||
|
}
|
||||||
|
|
||||||
|
#undef WMSetInBag
|
||||||
|
void* WMSetInBag(WMBag *bag, int index, void *item) {
|
||||||
|
return WMReplaceInBag(bag, index, item);
|
||||||
|
}
|
||||||
|
|
||||||
|
#undef WMAddItemToTree
|
||||||
|
WMTreeNode* WMAddItemToTree(WMTreeNode *parent, void *item) {
|
||||||
|
return WMInsertItemInTree(parent, -1, item);
|
||||||
|
}
|
||||||
|
|
||||||
|
#undef WMAddNodeToTree
|
||||||
|
WMTreeNode* WMAddNodeToTree(WMTreeNode *parent, WMTreeNode *aNode) {
|
||||||
|
return WMInsertNodeInTree(parent, -1, aNode);
|
||||||
|
}
|
||||||
|
|
||||||
|
#undef WMGetFirstInTree
|
||||||
|
/* Returns first tree node that has data == cdata */
|
||||||
|
WMTreeNode* WMGetFirstInTree(WMTreeNode *aTree, void *cdata) {
|
||||||
|
return WMFindInTree(aTree, NULL, cdata);
|
||||||
|
}
|
||||||
|
|
||||||
|
#undef WMFlushConnection
|
||||||
|
int WMFlushConnection(WMConnection *cPtr) {
|
||||||
|
return WMSendConnectionData(cPtr, NULL);
|
||||||
|
}
|
||||||
|
|
||||||
|
#undef WMGetConnectionQueuedData
|
||||||
|
WMArray* WMGetConnectionQueuedData(WMConnection *cPtr) {
|
||||||
|
return WMGetConnectionUnsentData(cPtr);
|
||||||
|
}
|
||||||
|
|
||||||
|
#undef WMWidgetClass
|
||||||
|
W_Class WMWidgetClass(WMWidget *widget) {
|
||||||
|
return (((W_WidgetType*)(widget))->widgetClass);
|
||||||
|
}
|
||||||
|
|
||||||
|
#undef WMWidgetView
|
||||||
|
WMView* WMWidgetView(WMWidget *widget) {
|
||||||
|
return (((W_WidgetType*)(widget))->view);
|
||||||
|
}
|
||||||
|
|
||||||
|
#undef WMCreateCommandButton
|
||||||
|
WMButton* WMCreateCommandButton(WMWidget *parent) {
|
||||||
|
return WMCreateCustomButton(parent, WBBSpringLoadedMask|WBBPushInMask
|
||||||
|
|WBBPushLightMask|WBBPushChangeMask);
|
||||||
|
}
|
||||||
|
|
||||||
|
#undef WMCreateRadioButton
|
||||||
|
WMButton* WMCreateRadioButton(WMWidget *parent) {
|
||||||
|
return WMCreateButton(parent, WBTRadio);
|
||||||
|
}
|
||||||
|
|
||||||
|
#undef WMCreateSwitchButton
|
||||||
|
WMButton* WMCreateSwitchButton(WMWidget *parent) {
|
||||||
|
return WMCreateButton(parent, WBTSwitch);
|
||||||
|
}
|
||||||
|
|
||||||
|
#undef WMAddListItem
|
||||||
|
WMListItem* WMAddListItem(WMList *lPtr, char *text)
|
||||||
|
{
|
||||||
|
return WMInsertListItem(lPtr, -1, text);
|
||||||
|
}
|
||||||
|
|
||||||
|
#undef WMCreateText
|
||||||
|
WMText* WMCreateText(WMWidget *parent) {
|
||||||
|
return WMCreateTextForDocumentType(parent, NULL, NULL);
|
||||||
|
}
|
||||||
|
|
||||||
|
#undef WMRefreshText
|
||||||
|
void WMRefreshText(WMText *tPtr) {
|
||||||
|
return WMThawText(tPtr);
|
||||||
|
}
|
||||||
|
|
||||||
|
#undef WMClearText
|
||||||
|
void WMClearText(WMText *tPtr) {
|
||||||
|
return WMAppendTextStream(tPtr, NULL);
|
||||||
|
}
|
||||||
|
%}
|
||||||
|
|
||||||
|
|
||||||
643
WINGs/python/WINGs.py
Normal file
643
WINGs/python/WINGs.py
Normal file
@@ -0,0 +1,643 @@
|
|||||||
|
#!/usr/bin/env python
|
||||||
|
|
||||||
|
import sys
|
||||||
|
import wings
|
||||||
|
|
||||||
|
# Some useful constants
|
||||||
|
|
||||||
|
False = 0
|
||||||
|
True = 1
|
||||||
|
|
||||||
|
# check about None as action for buttonAction/windowCloseAction ...
|
||||||
|
|
||||||
|
################################################################################
|
||||||
|
# Exceptions
|
||||||
|
################################################################################
|
||||||
|
from exceptions import Exception, StandardError
|
||||||
|
|
||||||
|
class Error(StandardError):
|
||||||
|
pass
|
||||||
|
|
||||||
|
del Exception, StandardError
|
||||||
|
|
||||||
|
class WMTimer:
|
||||||
|
def __init__(self, milliseconds, callback, cdata=None, persistent=False):
|
||||||
|
if persistent:
|
||||||
|
self._o = wings.pyWMAddPersistentTimerHandler(milliseconds, (callback, cdata))
|
||||||
|
else:
|
||||||
|
self._o = wings.pyWMAddTimerHandler(milliseconds, (callback, cdata))
|
||||||
|
self.__WMDeleteTimerHandler = wings.pyWMDeleteTimerHandler
|
||||||
|
|
||||||
|
def __del__(self):
|
||||||
|
self.__WMDeleteTimerHandler(self._o)
|
||||||
|
|
||||||
|
|
||||||
|
class WMPersistentTimer(WMTimer):
|
||||||
|
def __init__(self, milliseconds, callback, cdata=None):
|
||||||
|
WMTimer.__init__(self, milliseconds, callback, cdata, persistent=True)
|
||||||
|
|
||||||
|
|
||||||
|
class WMScreen:
|
||||||
|
__readonly = ('display', 'width', 'height', 'depth')
|
||||||
|
|
||||||
|
def __init__(self, appname, display="", simpleapp=False):
|
||||||
|
wings.WMInitializeApplication(appname, len(sys.argv), sys.argv)
|
||||||
|
self._o = wings.pyWMOpenScreen(display, simpleapp)
|
||||||
|
if not self._o:
|
||||||
|
raise Error, "Cannot open display %s" % display
|
||||||
|
self.__dict__['display'] = wings.WMScreenDisplay(self._o)
|
||||||
|
self.__dict__['width'] = wings.WMScreenWidth(self._o)
|
||||||
|
self.__dict__['height'] = wings.WMScreenHeight(self._o)
|
||||||
|
self.__dict__['depth'] = wings.WMScreenDepth(self._o)
|
||||||
|
|
||||||
|
def __setattr__(self, name ,value):
|
||||||
|
if name in self.__readonly:
|
||||||
|
#raise AttributeError, "'%s' is a read-only WMScreen attribute" % name
|
||||||
|
raise Error, "'%s' is a read-only WMScreen attribute" % name
|
||||||
|
self.__dict__[name] = value
|
||||||
|
|
||||||
|
def __delattr__(self, name):
|
||||||
|
if name in self.__readonly:
|
||||||
|
#raise AttributeError, "'%s' attribute cannot be deleted from WMScreen instance" % name
|
||||||
|
raise Error, "'%s' attribute cannot be deleted from WMScreen instance" % name
|
||||||
|
try:
|
||||||
|
del(self.__dict__[name])
|
||||||
|
except KeyError:
|
||||||
|
raise AttributeError, "%s instance has no attribute '%s'" % \
|
||||||
|
(self.__class__.__name__, name)
|
||||||
|
|
||||||
|
def mainLoop(self):
|
||||||
|
wings.pyWMScreenMainLoop(self._o)
|
||||||
|
|
||||||
|
def breakMainLoop(self):
|
||||||
|
wings.pyWMBreakScreenMainLoop(self._o)
|
||||||
|
|
||||||
|
def runModalLoop(self, view):
|
||||||
|
wings.pyWMRunModalLoop(self._o, view)
|
||||||
|
|
||||||
|
def breakModalLoop(self):
|
||||||
|
wings.WMBreakModalLoop(self._o)
|
||||||
|
|
||||||
|
def size(self):
|
||||||
|
return (self.width, self.height)
|
||||||
|
|
||||||
|
|
||||||
|
class WMView:
|
||||||
|
pass
|
||||||
|
|
||||||
|
|
||||||
|
class WMWidget(WMView):
|
||||||
|
def __init__(self):
|
||||||
|
if self.__class__ == WMWidget:
|
||||||
|
raise Error, "a WMWidget can't be instantiated directly"
|
||||||
|
self._o = None
|
||||||
|
self.__WMDestroyWidget = wings.WMDestroyWidget
|
||||||
|
|
||||||
|
def __del__(self):
|
||||||
|
if self._o is not None:
|
||||||
|
self.__WMDestroyWidget(self._o)
|
||||||
|
|
||||||
|
def resize(self, width, height):
|
||||||
|
wings.WMResizeWidget(self._o, width, height)
|
||||||
|
|
||||||
|
def move(self, x, y):
|
||||||
|
wings.WMMoveWidget(self._o, x, y)
|
||||||
|
|
||||||
|
def realize(self):
|
||||||
|
wings.WMRealizeWidget(self._o)
|
||||||
|
|
||||||
|
def show(self):
|
||||||
|
wings.WMMapWidget(self._o)
|
||||||
|
|
||||||
|
def hide(self):
|
||||||
|
wings.WMUnmapWidget(self._o)
|
||||||
|
|
||||||
|
def redisplay(self):
|
||||||
|
wings.WMRedisplayWidget(self._o)
|
||||||
|
|
||||||
|
def width(self):
|
||||||
|
return wings.WMWidgetWidth(self._o)
|
||||||
|
|
||||||
|
def height(self):
|
||||||
|
return wings.WMWidgetHeight(self._o)
|
||||||
|
|
||||||
|
def screen(self):
|
||||||
|
return wings.WMWidgetScreen(self._o)
|
||||||
|
|
||||||
|
def view(self):
|
||||||
|
return wings.WMWidgetView(self._o)
|
||||||
|
|
||||||
|
def setFocusTo(self, other):
|
||||||
|
wings.WMSetFocusToWidget(other._o)
|
||||||
|
|
||||||
|
|
||||||
|
class WMWindow(WMWidget):
|
||||||
|
def __init__(self, screen, name, style=wings.WMTitledWindowMask
|
||||||
|
|wings.WMClosableWindowMask|wings.WMMiniaturizableWindowMask
|
||||||
|
|wings.WMResizableWindowMask):
|
||||||
|
WMWidget.__init__(self)
|
||||||
|
self._o = wings.WMCreateWindowWithStyle(screen._o, name, style)
|
||||||
|
|
||||||
|
def setMinSize(self, minWidth, minHeight):
|
||||||
|
wings.WMSetWindowMinSize(self._o, minWidth, minHeight)
|
||||||
|
|
||||||
|
def setMaxSize(self, maxWidth, maxHeight):
|
||||||
|
wings.WMSetWindowMaxSize(self._o, maxWidth, maxHeight)
|
||||||
|
|
||||||
|
def setInitialPosition(self, x, y):
|
||||||
|
wings.WMSetWindowInitialPosition(self._o, x, y)
|
||||||
|
|
||||||
|
def setTitle(self, title):
|
||||||
|
wings.WMSetWindowTitle(self._o, title)
|
||||||
|
|
||||||
|
def setCloseAction(self, action, data=None):
|
||||||
|
if action!=None and (not callable(action)):
|
||||||
|
raise Error, "action needs to be a callable object or None"
|
||||||
|
wings.pyWMSetWindowCloseAction(self._o, (self, action, data))
|
||||||
|
|
||||||
|
|
||||||
|
class WMPanel(WMWindow):
|
||||||
|
def __init__(self, owner, name, style=wings.WMTitledWindowMask
|
||||||
|
|wings.WMClosableWindowMask|wings.WMResizableWindowMask):
|
||||||
|
WMWidget.__init__(self)
|
||||||
|
self._o = wings.WMCreatePanelWithStyleForWindow(owner._o, name, style)
|
||||||
|
|
||||||
|
class WMFrame(WMWidget):
|
||||||
|
def __init__(self, parent, title=None):
|
||||||
|
WMWidget.__init__(self)
|
||||||
|
self._o = wings.WMCreateFrame(parent._o)
|
||||||
|
self.setTitle(title)
|
||||||
|
|
||||||
|
def setRelief(self, relief):
|
||||||
|
wings.WMSetFrameRelief(self._o, relief)
|
||||||
|
|
||||||
|
def setTitle(self, title=""):
|
||||||
|
wings.WMSetFrameTitle(self._o, title)
|
||||||
|
|
||||||
|
def setTitlePosition(self, position):
|
||||||
|
wings.WMSetFrameTitlePosition(self._o, position)
|
||||||
|
|
||||||
|
class WMLabel(WMWidget):
|
||||||
|
def __init__(self, parent, text=None):
|
||||||
|
WMWidget.__init__(self)
|
||||||
|
self._o = wings.WMCreateLabel(parent._o)
|
||||||
|
self.setText(text)
|
||||||
|
|
||||||
|
def setWraps(self, flag):
|
||||||
|
# bool(flag) for python2.2
|
||||||
|
wings.WMSetLabelWraps(self._o, flag)
|
||||||
|
|
||||||
|
def setRelief(self, relief):
|
||||||
|
wings.WMSetLabelRelief(self._o, relief)
|
||||||
|
|
||||||
|
def setText(self, text=""):
|
||||||
|
wings.WMSetLabelText(self._o, text)
|
||||||
|
|
||||||
|
def setTextColor(self, color):
|
||||||
|
wings.WMSetLabelTextColor(self._o, color)
|
||||||
|
|
||||||
|
def setFont(self, font):
|
||||||
|
wings.WMSetLabelFont(self._o, font)
|
||||||
|
|
||||||
|
def setTextAlignment(self, alignment):
|
||||||
|
wings.WMSetLabelTextAlignment(self._o, alignment)
|
||||||
|
|
||||||
|
def setImage(self, image):
|
||||||
|
wings.WMSetLabelImage(self._o, image)
|
||||||
|
|
||||||
|
def setImagePosition(self, position):
|
||||||
|
wings.WMSetLabelImagePosition(self._o, position)
|
||||||
|
|
||||||
|
def text(self):
|
||||||
|
return wings.WMGetLabelText(self._o)
|
||||||
|
|
||||||
|
def font(self):
|
||||||
|
return wings.WMGetLabelFont(self._o)
|
||||||
|
|
||||||
|
def image(self):
|
||||||
|
return wings.WMGetLabelImage(self._o)
|
||||||
|
|
||||||
|
|
||||||
|
class WMBox(WMWidget):
|
||||||
|
def __init__(self, parent):
|
||||||
|
WMWidget.__init__(self)
|
||||||
|
self._o = wings.WMCreateBox(parent._o)
|
||||||
|
|
||||||
|
def setHorizontal(self, flag):
|
||||||
|
# bool(flag) for python2.2
|
||||||
|
wings.WMSetBoxHorizontal(self._o, flag)
|
||||||
|
|
||||||
|
def setBorderWidth(self, width):
|
||||||
|
wings.WMSetBoxBorderWidth(self._o, width)
|
||||||
|
|
||||||
|
def addSubview(self, view, expand, fill, minSize, maxSize, space):
|
||||||
|
wings.WMAddBoxSubview(self._o, view, expand, fill, minSize, maxSixe, space)
|
||||||
|
|
||||||
|
def addSubviewAtEnd(self, view, expand, fill, minSize, maxSize, space):
|
||||||
|
wings.WMAddBoxSubviewAtEnd(self._o, view, expand, fill, minSize, maxSixe, space)
|
||||||
|
|
||||||
|
def removeSubview(self, view):
|
||||||
|
wings.WMRemoveBoxSubview(self._o, view)
|
||||||
|
|
||||||
|
|
||||||
|
class WMButton(WMWidget): # not for user instantiation
|
||||||
|
def __init__(self, parent):
|
||||||
|
WMWidget.__init__(self)
|
||||||
|
if self.__class__ == WMButton:
|
||||||
|
raise Error, "a WMButton can't be instantiated directly"
|
||||||
|
|
||||||
|
|
||||||
|
def setText(self, text=""):
|
||||||
|
wings.WMSetButtonText(self._o, text)
|
||||||
|
|
||||||
|
def setAction(self, action, data=None):
|
||||||
|
if action!=None and (not callable(action)):
|
||||||
|
raise Error, "action needs to be a callable object or None"
|
||||||
|
wings.pyWMSetButtonAction(self._o, (self, action, data))
|
||||||
|
|
||||||
|
def performClick(self):
|
||||||
|
wings.WMPerformButtonClick(self._o)
|
||||||
|
|
||||||
|
def setEnabled(self, flag):
|
||||||
|
# bool(flag) for python2.2
|
||||||
|
wings.WMSetButtonEnabled(self._o, flag)
|
||||||
|
|
||||||
|
def isEnabled(self):
|
||||||
|
return wings.WMGetButtonEnabled(self._o)
|
||||||
|
|
||||||
|
def setImageDimsWhenDisabled(self, flag):
|
||||||
|
# bool(flag)
|
||||||
|
wings.WMSetButtonImageDimsWhenDisabled(self._o, flag)
|
||||||
|
|
||||||
|
def setImage(self, image):
|
||||||
|
wings.WMSetButtonImage(self_.o, image)
|
||||||
|
|
||||||
|
def setAlternateImage(self, image):
|
||||||
|
wings.WMSetButtonAltImage(self._o, image)
|
||||||
|
|
||||||
|
def setImagePosition(self, position):
|
||||||
|
wings.WMSetButtonImagePosition(self._o, position)
|
||||||
|
|
||||||
|
def setImageDefault(self):
|
||||||
|
wings.WMSetButtonImageDefault(self._o)
|
||||||
|
|
||||||
|
|
||||||
|
class WMCommandButton(WMButton):
|
||||||
|
def __init__(self, parent):
|
||||||
|
WMButton.__init__(self, parent)
|
||||||
|
self._o = wings.WMCreateCommandButton(parent._o)
|
||||||
|
|
||||||
|
|
||||||
|
class WMSwitchButton(WMButton):
|
||||||
|
def __init__(self, parent):
|
||||||
|
WMButton.__init__(self, parent)
|
||||||
|
self._o = wings.WMCreateSwitchButton(parent._o)
|
||||||
|
|
||||||
|
|
||||||
|
class WMRadioButton(WMButton):
|
||||||
|
def __init__(self, parent, group=None):
|
||||||
|
WMButton.__init__(self, parent)
|
||||||
|
self._o = wings.WMCreateRadioButton(parent._o)
|
||||||
|
if group:
|
||||||
|
wings.WMGroupButtons(group._o, self._o)
|
||||||
|
|
||||||
|
|
||||||
|
class WMListItem:
|
||||||
|
pass
|
||||||
|
|
||||||
|
|
||||||
|
class WMList(WMWidget):
|
||||||
|
def __init__(self, parent):
|
||||||
|
WMWidget.__init__(self)
|
||||||
|
self._o = wings.WMCreateList(parent._o)
|
||||||
|
|
||||||
|
def allowEmptySelection(self, flag):
|
||||||
|
# bool(flag)
|
||||||
|
wings.WMSetListAllowEmptySelection(self._o, flag)
|
||||||
|
|
||||||
|
def allowMultipleSelection(self, flag):
|
||||||
|
# bool(flag)
|
||||||
|
wings.WMSetListAllowMultipleSelection(self._o, flag)
|
||||||
|
|
||||||
|
def addItem(self, item):
|
||||||
|
wings.WMAddListItem(self._o, item)
|
||||||
|
|
||||||
|
def insertItem(self, row, item):
|
||||||
|
wings.WMInsertListItem(self._o, row, item)
|
||||||
|
|
||||||
|
def sortItems(self):
|
||||||
|
wings.WMSortListItems(self._o)
|
||||||
|
|
||||||
|
def rowWithTitle(self, title):
|
||||||
|
return wings.WMFindRowOfListItemWithTitle(self._o, title)
|
||||||
|
|
||||||
|
def selectedItemRow(self):
|
||||||
|
return wings.WMGetListSelectedItemRow(self._o)
|
||||||
|
|
||||||
|
def selectedItem(self):
|
||||||
|
return wings.WMGetListSelectedItem(self._o)
|
||||||
|
|
||||||
|
def removeItem(self, index):
|
||||||
|
wings.WMRemoveListItem(self._o, index)
|
||||||
|
|
||||||
|
def selectItem(self, index):
|
||||||
|
wings.WMSelectListItem(self._o, index)
|
||||||
|
|
||||||
|
def unselectItem(self, index):
|
||||||
|
wings.WMUnselectListItem(self._o, index)
|
||||||
|
|
||||||
|
|
||||||
|
class WMTextFieldDelegate:
|
||||||
|
__callbacks = ('didBeginEditing', 'didChange', 'didEndEditing',
|
||||||
|
'shouldBeginEditing', 'shouldEndEditing')
|
||||||
|
|
||||||
|
def __init__(self):
|
||||||
|
self.__dict__['data'] = None
|
||||||
|
self.__dict__['didBeginEditing'] = None
|
||||||
|
self.__dict__['didChange'] = None
|
||||||
|
self.__dict__['didEndEditing'] = None
|
||||||
|
self.__dict__['shouldBeginEditing'] = None
|
||||||
|
self.__dict__['shouldEndEditing'] = None
|
||||||
|
|
||||||
|
def __setattr__(self, name ,value):
|
||||||
|
if name in self.__callbacks and value!=None and (not callable(value)):
|
||||||
|
#raise AttributeError, "%s.%s needs to be a callable object or None" % (self.__class__.__name__, name)
|
||||||
|
raise Error, "%s.%s needs to be a callable object or None" % (self.__class__.__name__, name)
|
||||||
|
else:
|
||||||
|
self.__dict__[name] = value
|
||||||
|
|
||||||
|
|
||||||
|
class WMTextField(WMWidget):
|
||||||
|
def __init__(self, parent, text=""):
|
||||||
|
WMWidget.__init__(self)
|
||||||
|
self._o = wings.WMCreateTextField(parent._o)
|
||||||
|
wings.WMSetTextFieldText(self._o, text)
|
||||||
|
|
||||||
|
def setDelegate(self, delegate):
|
||||||
|
if delegate.__class__ != WMTextFieldDelegate:
|
||||||
|
raise Error, "textfield delegate must be of type 'WMTextFieldDelegate'"
|
||||||
|
wings.pyWMSetTextFieldDelegate(self._o, (self, delegate))
|
||||||
|
|
||||||
|
def delegate(self):
|
||||||
|
return wings.pyWMGetTextFieldDelegate(self._o)
|
||||||
|
|
||||||
|
def text(self):
|
||||||
|
return wings.WMGetTextFieldText(self._o)
|
||||||
|
|
||||||
|
def setEditable(self, flag):
|
||||||
|
# bool(flag)
|
||||||
|
wings.WMSetTextFieldEditable(self._o, flag)
|
||||||
|
|
||||||
|
def setBordered(self, flag):
|
||||||
|
# bool(flag)
|
||||||
|
wings.WMSetTextFieldBordered(self._o, flag)
|
||||||
|
|
||||||
|
def setBeveled(self, flag):
|
||||||
|
# bool(flag)
|
||||||
|
wings.WMSetTextFieldBeveled(self._o, flag)
|
||||||
|
|
||||||
|
def setSecure(self, flag):
|
||||||
|
# bool(flag)
|
||||||
|
wings.WMSetTextFieldSecure(self._o, flag)
|
||||||
|
|
||||||
|
def setCursorPosition(self, position):
|
||||||
|
wings.WMSetTextFieldCursorPosition(self._o, position)
|
||||||
|
|
||||||
|
def setNextText(self, next):
|
||||||
|
wings.WMSetTextFieldNextTextField(self._o, next._o)
|
||||||
|
|
||||||
|
def setPreviousText(self, previous):
|
||||||
|
wings.WMSetTextFieldPrevTextField(self._o, previous._o)
|
||||||
|
|
||||||
|
def setTextAlignment(self, alignment):
|
||||||
|
wings.WMSetTextFieldAlignment(self._o, alignment)
|
||||||
|
|
||||||
|
def isEditable(self):
|
||||||
|
return wings.WMGetTextFieldEditable(self._o)
|
||||||
|
|
||||||
|
def insertText(self, text, position):
|
||||||
|
wings.WMInsertTextFieldText(self._o, text, position)
|
||||||
|
|
||||||
|
def deleteText(self, start, count):
|
||||||
|
wings.WMDeleteTextFieldRange(self._o, wings.wmkrange(start, count))
|
||||||
|
|
||||||
|
def selectText(self, start, count):
|
||||||
|
wings.WMSelectTextFieldRange(self._o, wings.wmkrange(start, count))
|
||||||
|
|
||||||
|
def setFont(self, font):
|
||||||
|
wings.WMSetTextFieldFont(self._o, font)
|
||||||
|
|
||||||
|
def font(self):
|
||||||
|
return wings.WMGetTextFieldFont(self._o)
|
||||||
|
|
||||||
|
|
||||||
|
################################################################################
|
||||||
|
# wrap the WINGs constants so we don't need wings.constant_name
|
||||||
|
################################################################################
|
||||||
|
|
||||||
|
# WMWindow title style
|
||||||
|
WMTitledWindowMask = wings.WMTitledWindowMask
|
||||||
|
WMClosableWindowMask = wings.WMClosableWindowMask
|
||||||
|
WMMiniaturizableWindowMask = wings.WMMiniaturizableWindowMask
|
||||||
|
WMResizableWindowMask = wings.WMResizableWindowMask
|
||||||
|
|
||||||
|
# WMFrame title positions
|
||||||
|
WTPNoTitle = wings.WTPNoTitle
|
||||||
|
WTPAboveTop = wings.WTPAboveTop
|
||||||
|
WTPAtTop = wings.WTPAtTop
|
||||||
|
WTPBelowTop = wings.WTPBelowTop
|
||||||
|
WTPAboveBottom = wings.WTPAboveBottom
|
||||||
|
WTPAtBottom = wings.WTPAtBottom
|
||||||
|
WTPBelowBottom = wings.WTPBelowBottom
|
||||||
|
|
||||||
|
# Alingments
|
||||||
|
WALeft = wings.WALeft
|
||||||
|
WACenter = wings.WACenter
|
||||||
|
WARight = wings.WARight
|
||||||
|
WAJustified = wings.WAJustified # not valid for textfields
|
||||||
|
|
||||||
|
# Image positions
|
||||||
|
WIPNoImage = wings.WIPNoImage
|
||||||
|
WIPImageOnly = wings.WIPImageOnly
|
||||||
|
WIPLeft = wings.WIPLeft
|
||||||
|
WIPRight = wings.WIPRight
|
||||||
|
WIPBelow = wings.WIPBelow
|
||||||
|
WIPAbove = wings.WIPAbove
|
||||||
|
WIPOverlaps = wings.WIPOverlaps
|
||||||
|
|
||||||
|
# Relief types
|
||||||
|
WRFlat = wings.WRFlat
|
||||||
|
WRSimple = wings.WRSimple
|
||||||
|
WRRaised = wings.WRRaised
|
||||||
|
WRSunken = wings.WRSunken
|
||||||
|
WRGroove = wings.WRGroove
|
||||||
|
WRRidge = wings.WRRidge
|
||||||
|
WRPushed = wings.WRPushed
|
||||||
|
|
||||||
|
|
||||||
|
# TextField events
|
||||||
|
WMReturnTextMovement = wings.WMReturnTextMovement
|
||||||
|
WMEscapeTextMovement = wings.WMEscapeTextMovement
|
||||||
|
WMIllegalTextMovement = wings.WMIllegalTextMovement
|
||||||
|
WMTabTextMovement = wings.WMTabTextMovement
|
||||||
|
WMBacktabTextMovement = wings.WMBacktabTextMovement
|
||||||
|
WMLeftTextMovement = wings.WMLeftTextMovement
|
||||||
|
WMRightTextMovement = wings.WMRightTextMovement
|
||||||
|
WMUpTextMovement = wings.WMUpTextMovement
|
||||||
|
WMDownTextMovement = wings.WMDownTextMovement
|
||||||
|
|
||||||
|
|
||||||
|
if __name__ == "__main__":
|
||||||
|
def quit(obj, data):
|
||||||
|
#sys.exit()
|
||||||
|
scr.breakMainLoop()
|
||||||
|
|
||||||
|
def click(btn, list):
|
||||||
|
print win.width(), win.height()
|
||||||
|
print list.selectedItemRow()
|
||||||
|
win2.show()
|
||||||
|
scr.runModalLoop(win2.view())
|
||||||
|
print txt2.text()
|
||||||
|
|
||||||
|
def sayhi(btn, data):
|
||||||
|
print "hi"
|
||||||
|
|
||||||
|
def breakLoop(btn, data):
|
||||||
|
#sys.exit()
|
||||||
|
scr.breakModalLoop()
|
||||||
|
win2.hide()
|
||||||
|
|
||||||
|
def dc(object, data, action):
|
||||||
|
print "didChange:", object, data, action
|
||||||
|
|
||||||
|
def dbe(object, data, action):
|
||||||
|
print "didBeginEditing:", object, data, action
|
||||||
|
|
||||||
|
def dee(object, data, action):
|
||||||
|
if action == wings.WMReturnTextMovement:
|
||||||
|
if object == txt:
|
||||||
|
object.setFocusTo(txt2)
|
||||||
|
else:
|
||||||
|
object.setFocusTo(txt)
|
||||||
|
print "didEndEditing:", object, data, action, object.text()
|
||||||
|
|
||||||
|
def tcb(one):
|
||||||
|
old = list.selectedItemRow()
|
||||||
|
list.selectItem(list.index)
|
||||||
|
list.unselectItem(old)
|
||||||
|
list.index = (list.index+1) % 3
|
||||||
|
#print one
|
||||||
|
|
||||||
|
scr = WMScreen("foobar")
|
||||||
|
win = WMWindow(scr, "aWindow")
|
||||||
|
win.setCloseAction(quit)
|
||||||
|
win.setTitle("test window")
|
||||||
|
win.resize(400, 180)
|
||||||
|
win.setInitialPosition((scr.width-win.width())/2, (scr.height-win.height())/2)
|
||||||
|
|
||||||
|
btn = WMCommandButton(win)
|
||||||
|
btn.setText("Click Me")
|
||||||
|
btn.resize(100, 25)
|
||||||
|
btn.move(20, 20)
|
||||||
|
btn.show()
|
||||||
|
|
||||||
|
sw = WMSwitchButton(win)
|
||||||
|
sw.setText("Some option")
|
||||||
|
sw.resize(100, 25)
|
||||||
|
sw.move(20, 50)
|
||||||
|
sw.show()
|
||||||
|
|
||||||
|
radios = []
|
||||||
|
r = None
|
||||||
|
j = 0
|
||||||
|
for i in ["One", "Two", "Four"]:
|
||||||
|
r = WMRadioButton(win, r)
|
||||||
|
radios.append(r)
|
||||||
|
r.show()
|
||||||
|
r.setText(i)
|
||||||
|
r.move(20, 70+j*25)
|
||||||
|
r.resize(100, 25)
|
||||||
|
j=j+1
|
||||||
|
|
||||||
|
sw.setAction(sayhi)
|
||||||
|
|
||||||
|
list = WMList(win)
|
||||||
|
list.resize(100,100)
|
||||||
|
list.move(130, 20)
|
||||||
|
list.addItem("one")
|
||||||
|
list.addItem("two")
|
||||||
|
list.addItem("three")
|
||||||
|
list.allowMultipleSelection(1)
|
||||||
|
list.show()
|
||||||
|
list.index = 0
|
||||||
|
|
||||||
|
txtdel = WMTextFieldDelegate()
|
||||||
|
txtdel.data = 'mydata'
|
||||||
|
txtdel.didBeginEditing = dbe
|
||||||
|
txtdel.didEndEditing = dee
|
||||||
|
txtdel.didChange = dc
|
||||||
|
|
||||||
|
txt = WMTextField(win, "abc")
|
||||||
|
txt.resize(95, 20)
|
||||||
|
txt.move(295, 20)
|
||||||
|
txt.setDelegate(txtdel)
|
||||||
|
txt.show()
|
||||||
|
txt2 = WMTextField(win, "01234567890")
|
||||||
|
txt2.resize(95, 20)
|
||||||
|
txt2.move(295, 45)
|
||||||
|
txt2.setDelegate(txtdel)
|
||||||
|
txt2.show()
|
||||||
|
|
||||||
|
txt.setNextText(txt2)
|
||||||
|
txt2.setNextText(txt)
|
||||||
|
|
||||||
|
label = WMLabel(win, "Text1:")
|
||||||
|
label.setTextAlignment(WARight)
|
||||||
|
label.move(240, 20)
|
||||||
|
label.resize(55, 20)
|
||||||
|
label.show()
|
||||||
|
|
||||||
|
label2 = WMLabel(win, "mytext2:")
|
||||||
|
label2.setTextAlignment(WARight)
|
||||||
|
label2.move(240, 45)
|
||||||
|
label2.resize(55, 20)
|
||||||
|
label2.show()
|
||||||
|
|
||||||
|
btn.setAction(click, list)
|
||||||
|
|
||||||
|
frame = WMFrame(win, "My Frame")
|
||||||
|
frame.resize(150, 50)
|
||||||
|
frame.move(240, 70)
|
||||||
|
#frame.setRelief(WRPushed)
|
||||||
|
frame.show()
|
||||||
|
|
||||||
|
ebtn = WMCommandButton(win)
|
||||||
|
ebtn.setText("Exit")
|
||||||
|
ebtn.resize(100, 25)
|
||||||
|
ebtn.move(290, 147)
|
||||||
|
ebtn.setAction(quit)
|
||||||
|
ebtn.show()
|
||||||
|
|
||||||
|
win.realize()
|
||||||
|
win.show()
|
||||||
|
|
||||||
|
timer = WMPersistentTimer(1000, tcb, win)
|
||||||
|
#del(timer)
|
||||||
|
#timer.delete()
|
||||||
|
|
||||||
|
win2 = WMPanel(win, "anotherWindow", WMTitledWindowMask)
|
||||||
|
win2.setTitle("transient test window")
|
||||||
|
win2.resize(150, 50)
|
||||||
|
win2.setInitialPosition((scr.width-win2.width())/2, (scr.height-win2.height())/2)
|
||||||
|
|
||||||
|
btn7 = WMCommandButton(win2)
|
||||||
|
btn7.setText("Dismiss")
|
||||||
|
btn7.resize(100, 25)
|
||||||
|
btn7.move(27, 10)
|
||||||
|
btn7.show()
|
||||||
|
btn7.setAction(breakLoop)
|
||||||
|
|
||||||
|
win2.realize()
|
||||||
|
|
||||||
|
scr.mainLoop()
|
||||||
|
|
||||||
71
WINGs/python/setup.py
Executable file
71
WINGs/python/setup.py
Executable file
@@ -0,0 +1,71 @@
|
|||||||
|
#!/usr/bin/env python
|
||||||
|
|
||||||
|
"""Setup script for the WINGs module distribution."""
|
||||||
|
|
||||||
|
import os, sys
|
||||||
|
from distutils.core import setup
|
||||||
|
from distutils.extension import Extension
|
||||||
|
|
||||||
|
## Get the include dirs
|
||||||
|
wings = os.popen("get-wings-flags --cflags", "r")
|
||||||
|
flags = wings.read().split()
|
||||||
|
include_dirs = [x[2:] for x in flags]
|
||||||
|
#include_dirs += [".."]
|
||||||
|
wings.close()
|
||||||
|
|
||||||
|
## Get the library dirs
|
||||||
|
wings = os.popen("get-wings-flags --ldflags", "r")
|
||||||
|
flags = wings.read().split()
|
||||||
|
library_dirs = [x[2:] for x in flags]
|
||||||
|
#library_dirs += [".."]
|
||||||
|
wings.close()
|
||||||
|
|
||||||
|
## Get the libraries
|
||||||
|
wings = os.popen("get-wings-flags --libs", "r")
|
||||||
|
flags = wings.read().split()
|
||||||
|
libraries = [x[2:] for x in flags]
|
||||||
|
wings.close()
|
||||||
|
|
||||||
|
runtime_library_dirs = []
|
||||||
|
extra_objects = []
|
||||||
|
extra_compile_args = ['-Wno-strict-prototypes', '-Wno-unused']
|
||||||
|
|
||||||
|
long_description = \
|
||||||
|
"""Python interface to the WINGs library
|
||||||
|
|
||||||
|
Python WINGs is an interface to WINGs, a small widget set with the
|
||||||
|
N*XTSTEP look and feel. It's API is inspired in OpenStep and it's
|
||||||
|
implementation borrows some ideas from Tk. It has a reasonable set of
|
||||||
|
widgets, sufficient for building small applications (like a CDPlayer
|
||||||
|
or hacking something like rxvt). It also has other functions that are
|
||||||
|
usefull for applications, like a User Defaults alike configuration
|
||||||
|
manager and a notification system.
|
||||||
|
|
||||||
|
"""
|
||||||
|
|
||||||
|
setup (# Distribution meta-data
|
||||||
|
name = "Python-WINGs",
|
||||||
|
version = "0.81.0",
|
||||||
|
description = "A python interface to WINGs",
|
||||||
|
long_description=long_description,
|
||||||
|
author = "Dan Pascu",
|
||||||
|
author_email = "dan@windowmaker.org",
|
||||||
|
license = "GPL",
|
||||||
|
platforms = "ALL",
|
||||||
|
url = "http://windowmaker.org/",
|
||||||
|
|
||||||
|
# Description of the modules and packages in the distribution
|
||||||
|
|
||||||
|
py_modules = ["WINGs"],
|
||||||
|
|
||||||
|
ext_modules = [Extension(
|
||||||
|
name='wings',
|
||||||
|
sources=['WINGs.c'],
|
||||||
|
include_dirs=include_dirs,
|
||||||
|
library_dirs=library_dirs,
|
||||||
|
runtime_library_dirs=runtime_library_dirs,
|
||||||
|
libraries=libraries,
|
||||||
|
extra_objects=extra_objects,
|
||||||
|
extra_compile_args=extra_compile_args,
|
||||||
|
)],
|
||||||
|
)
|
||||||
159
WINGs/python/test.py
Executable file
159
WINGs/python/test.py
Executable file
@@ -0,0 +1,159 @@
|
|||||||
|
#!/usr/bin/env python
|
||||||
|
|
||||||
|
import sys
|
||||||
|
from WINGs import *
|
||||||
|
|
||||||
|
if __name__ == "__main__":
|
||||||
|
def quit(obj, data):
|
||||||
|
#sys.exit()
|
||||||
|
scr.breakMainLoop()
|
||||||
|
|
||||||
|
def click(btn, list):
|
||||||
|
print win.width(), win.height()
|
||||||
|
print list.selectedItemRow()
|
||||||
|
win2.show()
|
||||||
|
scr.runModalLoop(win2.view())
|
||||||
|
print txt2.text()
|
||||||
|
|
||||||
|
def sayhi(btn, data):
|
||||||
|
print "hi"
|
||||||
|
|
||||||
|
def breakLoop(btn, data):
|
||||||
|
#sys.exit()
|
||||||
|
scr.breakModalLoop()
|
||||||
|
win2.hide()
|
||||||
|
|
||||||
|
def dc(object, data, action):
|
||||||
|
print "didChange:", object, data, action
|
||||||
|
|
||||||
|
def dbe(object, data, action):
|
||||||
|
print "didBeginEditing:", object, data, action
|
||||||
|
|
||||||
|
def dee(object, data, action):
|
||||||
|
if action == wings.WMReturnTextMovement:
|
||||||
|
if object == txt:
|
||||||
|
object.setFocusTo(txt2)
|
||||||
|
else:
|
||||||
|
object.setFocusTo(txt)
|
||||||
|
print "didEndEditing:", object, data, action, object.text()
|
||||||
|
|
||||||
|
def tcb(one):
|
||||||
|
old = list.selectedItemRow()
|
||||||
|
list.selectItem(list.index)
|
||||||
|
list.unselectItem(old)
|
||||||
|
list.index = (list.index+1) % 3
|
||||||
|
#print one
|
||||||
|
|
||||||
|
scr = WMScreen("foobar")
|
||||||
|
win = WMWindow(scr, "aWindow")
|
||||||
|
win.setCloseAction(quit)
|
||||||
|
win.setTitle("test window")
|
||||||
|
win.resize(400, 180)
|
||||||
|
win.setInitialPosition((scr.width-win.width())/2, (scr.height-win.height())/2)
|
||||||
|
|
||||||
|
btn = WMCommandButton(win)
|
||||||
|
btn.setText("Click Me")
|
||||||
|
btn.resize(100, 25)
|
||||||
|
btn.move(20, 20)
|
||||||
|
btn.show()
|
||||||
|
|
||||||
|
sw = WMSwitchButton(win)
|
||||||
|
sw.setText("Some option")
|
||||||
|
sw.resize(100, 25)
|
||||||
|
sw.move(20, 50)
|
||||||
|
sw.show()
|
||||||
|
|
||||||
|
radios = []
|
||||||
|
r = None
|
||||||
|
j = 0
|
||||||
|
for i in ["One", "Two", "Four"]:
|
||||||
|
r = WMRadioButton(win, r)
|
||||||
|
radios.append(r)
|
||||||
|
r.show()
|
||||||
|
r.setText(i)
|
||||||
|
r.move(20, 70+j*25)
|
||||||
|
r.resize(100, 25)
|
||||||
|
j=j+1
|
||||||
|
|
||||||
|
sw.setAction(sayhi)
|
||||||
|
|
||||||
|
list = WMList(win)
|
||||||
|
list.resize(100,100)
|
||||||
|
list.move(130, 20)
|
||||||
|
list.addItem("one")
|
||||||
|
list.addItem("two")
|
||||||
|
list.addItem("three")
|
||||||
|
list.allowMultipleSelection(1)
|
||||||
|
list.show()
|
||||||
|
list.index = 0
|
||||||
|
|
||||||
|
txtdel = WMTextFieldDelegate()
|
||||||
|
txtdel.data = 'mydata'
|
||||||
|
txtdel.didBeginEditing = dbe
|
||||||
|
txtdel.didEndEditing = dee
|
||||||
|
txtdel.didChange = dc
|
||||||
|
|
||||||
|
txt = WMTextField(win)
|
||||||
|
txt.resize(95, 20)
|
||||||
|
txt.move(295, 20)
|
||||||
|
txt.setDelegate(txtdel)
|
||||||
|
txt.show()
|
||||||
|
txt2 = WMTextField(win, "01234567890")
|
||||||
|
txt2.resize(95, 20)
|
||||||
|
txt2.move(295, 45)
|
||||||
|
txt2.setDelegate(txtdel)
|
||||||
|
txt2.show()
|
||||||
|
|
||||||
|
txt.setNextText(txt2)
|
||||||
|
txt2.setNextText(txt)
|
||||||
|
|
||||||
|
label = WMLabel(win, "Text1:")
|
||||||
|
label.setTextAlignment(WARight)
|
||||||
|
label.move(240, 20)
|
||||||
|
label.resize(55, 20)
|
||||||
|
label.show()
|
||||||
|
|
||||||
|
label2 = WMLabel(win, "mytext2:")
|
||||||
|
label2.setTextAlignment(WARight)
|
||||||
|
label2.move(240, 45)
|
||||||
|
label2.resize(55, 20)
|
||||||
|
label2.show()
|
||||||
|
|
||||||
|
btn.setAction(click, list)
|
||||||
|
|
||||||
|
frame = WMFrame(win, "My Frame")
|
||||||
|
frame.resize(150, 50)
|
||||||
|
frame.move(240, 70)
|
||||||
|
#frame.setRelief(WRPushed)
|
||||||
|
frame.show()
|
||||||
|
|
||||||
|
ebtn = WMCommandButton(win)
|
||||||
|
ebtn.setText("Exit")
|
||||||
|
ebtn.resize(100, 25)
|
||||||
|
ebtn.move(290, 147)
|
||||||
|
ebtn.setAction(quit)
|
||||||
|
ebtn.show()
|
||||||
|
|
||||||
|
win.realize()
|
||||||
|
win.show()
|
||||||
|
|
||||||
|
timer = WMPersistentTimer(1000, tcb, win)
|
||||||
|
#del(timer)
|
||||||
|
#timer.delete()
|
||||||
|
|
||||||
|
win2 = WMPanel(win, "anotherWindow", WMTitledWindowMask)
|
||||||
|
win2.setTitle("transient test window")
|
||||||
|
win2.resize(150, 50)
|
||||||
|
win2.setInitialPosition((scr.width-win2.width())/2, (scr.height-win2.height())/2)
|
||||||
|
|
||||||
|
btn7 = WMCommandButton(win2)
|
||||||
|
btn7.setText("Dismiss")
|
||||||
|
btn7.resize(100, 25)
|
||||||
|
btn7.move(27, 10)
|
||||||
|
btn7.show()
|
||||||
|
btn7.setAction(breakLoop)
|
||||||
|
|
||||||
|
win2.realize()
|
||||||
|
|
||||||
|
scr.mainLoop()
|
||||||
|
|
||||||
@@ -9,6 +9,9 @@
|
|||||||
#define MAX_PROPERTY_SIZE 8*1024
|
#define MAX_PROPERTY_SIZE 8*1024
|
||||||
|
|
||||||
|
|
||||||
|
char *WMSelectionOwnerDidChangeNotification = "WMSelectionOwnerDidChange";
|
||||||
|
|
||||||
|
|
||||||
typedef struct SelectionHandler {
|
typedef struct SelectionHandler {
|
||||||
WMView *view;
|
WMView *view;
|
||||||
Atom selection;
|
Atom selection;
|
||||||
@@ -38,9 +41,14 @@ typedef struct SelectionCallback {
|
|||||||
} SelectionCallback;
|
} SelectionCallback;
|
||||||
|
|
||||||
|
|
||||||
WMBag *selCallbacks = NULL;
|
|
||||||
|
|
||||||
WMBag *selHandlers = NULL;
|
static WMArray *selCallbacks = NULL;
|
||||||
|
|
||||||
|
static WMArray *selHandlers = NULL;
|
||||||
|
|
||||||
|
static Bool gotXError = False;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
void
|
void
|
||||||
@@ -49,27 +57,31 @@ WMDeleteSelectionHandler(WMView *view, Atom selection, Time timestamp)
|
|||||||
SelectionHandler *handler;
|
SelectionHandler *handler;
|
||||||
Display *dpy = W_VIEW_SCREEN(view)->display;
|
Display *dpy = W_VIEW_SCREEN(view)->display;
|
||||||
Window win = W_VIEW_DRAWABLE(view);
|
Window win = W_VIEW_DRAWABLE(view);
|
||||||
WMBagIterator iter;
|
WMArrayIterator iter;
|
||||||
|
|
||||||
if (!selHandlers)
|
if (!selHandlers)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
/*//printf("deleting selection handler for %d", win);*/
|
||||||
|
|
||||||
WM_ITERATE_BAG(selHandlers, handler, iter) {
|
WM_ITERATE_ARRAY(selHandlers, handler, iter) {
|
||||||
if (handler->view == view
|
if (handler->view == view
|
||||||
&& (handler->selection == selection || selection == None)
|
&& (handler->selection == selection || selection == None)
|
||||||
&& (handler->timestamp == timestamp || timestamp == CurrentTime)) {
|
&& (handler->timestamp == timestamp || timestamp == CurrentTime)) {
|
||||||
|
|
||||||
if (handler->flags.done_pending) {
|
if (handler->flags.done_pending) {
|
||||||
handler->flags.delete_pending = 1;
|
handler->flags.delete_pending = 1;
|
||||||
|
/*//puts(": postponed because still pending");*/
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
WMRemoveFromBag(selHandlers, handler);
|
/*//printf(": found & removed");*/
|
||||||
wfree(handler);
|
WMRemoveFromArray(selHandlers, handler);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*//printf("\n");*/
|
||||||
|
|
||||||
XGrabServer(dpy);
|
XGrabServer(dpy);
|
||||||
if (XGetSelectionOwner(dpy, selection) == win) {
|
if (XGetSelectionOwner(dpy, selection) == win) {
|
||||||
XSetSelectionOwner(dpy, selection, None, timestamp);
|
XSetSelectionOwner(dpy, selection, None, timestamp);
|
||||||
@@ -83,67 +95,63 @@ void
|
|||||||
WMDeleteSelectionCallback(WMView *view, Atom selection, Time timestamp)
|
WMDeleteSelectionCallback(WMView *view, Atom selection, Time timestamp)
|
||||||
{
|
{
|
||||||
SelectionCallback *handler;
|
SelectionCallback *handler;
|
||||||
WMBagIterator iter;
|
WMArrayIterator iter;
|
||||||
|
|
||||||
if (!selCallbacks)
|
if (!selCallbacks)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
WM_ITERATE_BAG(selCallbacks, handler, iter) {
|
WM_ITERATE_ARRAY(selCallbacks, handler, iter) {
|
||||||
if (handler->view == view
|
if (handler->view == view
|
||||||
&& (handler->selection == selection || selection == 0)
|
&& (handler->selection == selection || selection == None)
|
||||||
&& (handler->timestamp == timestamp || timestamp == CurrentTime)) {
|
&& (handler->timestamp == timestamp || timestamp == CurrentTime)) {
|
||||||
|
|
||||||
if (handler->flags.done_pending) {
|
if (handler->flags.done_pending) {
|
||||||
handler->flags.delete_pending = 1;
|
handler->flags.delete_pending = 1;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
WMRemoveFromBag(selCallbacks, handler);
|
WMRemoveFromArray(selCallbacks, handler);
|
||||||
wfree(handler);
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
static Bool gotError = 0;
|
|
||||||
/*
|
|
||||||
static int
|
static int
|
||||||
errorHandler(XErrorEvent *error)
|
handleXError(Display *dpy, XErrorEvent *ev)
|
||||||
{
|
{
|
||||||
return 0;
|
gotXError = True;
|
||||||
|
|
||||||
|
return 1;
|
||||||
}
|
}
|
||||||
*/
|
|
||||||
|
|
||||||
static Bool
|
static Bool
|
||||||
writeSelection(Display *dpy, Window requestor, Atom property, Atom type,
|
writeSelection(Display *dpy, Window requestor, Atom property, Atom type,
|
||||||
WMData *data)
|
WMData *data)
|
||||||
{
|
{
|
||||||
int format;
|
static void *oldHandler;
|
||||||
|
int format, bpi;
|
||||||
|
|
||||||
format = WMGetDataFormat(data);
|
format = WMGetDataFormat(data);
|
||||||
if (format == 0)
|
if (format == 0)
|
||||||
format = 8;
|
format = 8;
|
||||||
|
|
||||||
/*
|
bpi = format/8;
|
||||||
printf("write to %x: %s\n", requestor, XGetAtomName(dpy, property));
|
|
||||||
*/
|
|
||||||
gotError = False;
|
|
||||||
|
|
||||||
#ifndef __sgi
|
/* printf("write to %x: %s\n", requestor, XGetAtomName(dpy, property)); */
|
||||||
if (!XChangeProperty(dpy, requestor, property, type, format,
|
|
||||||
PropModeReplace, WMDataBytes(data),
|
oldHandler = XSetErrorHandler(handleXError);
|
||||||
WMGetDataLength(data)))
|
|
||||||
return False;
|
gotXError = False;
|
||||||
#else
|
|
||||||
/* in sgi seems this seems to return void */
|
XChangeProperty(dpy, requestor, property, type, format, PropModeReplace,
|
||||||
XChangeProperty(dpy, requestor, property, type, format,
|
WMDataBytes(data), WMGetDataLength(data)/bpi);
|
||||||
PropModeReplace, WMDataBytes(data), WMGetDataLength(data));
|
|
||||||
#endif
|
|
||||||
|
|
||||||
XFlush(dpy);
|
XFlush(dpy);
|
||||||
|
|
||||||
return !gotError;
|
XSetErrorHandler(oldHandler);
|
||||||
|
|
||||||
|
return !gotXError;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -151,9 +159,9 @@ static void
|
|||||||
notifySelection(XEvent *event, Atom prop)
|
notifySelection(XEvent *event, Atom prop)
|
||||||
{
|
{
|
||||||
XEvent ev;
|
XEvent ev;
|
||||||
/*
|
|
||||||
printf("envent to %x\n", event->xselectionrequest.requestor);
|
/* printf("event to %x\n", event->xselectionrequest.requestor); */
|
||||||
*/
|
|
||||||
ev.xselection.type = SelectionNotify;
|
ev.xselection.type = SelectionNotify;
|
||||||
ev.xselection.serial = 0;
|
ev.xselection.serial = 0;
|
||||||
ev.xselection.send_event = True;
|
ev.xselection.send_event = True;
|
||||||
@@ -170,38 +178,15 @@ notifySelection(XEvent *event, Atom prop)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
static void
|
|
||||||
deleteHandlers(WMBagIterator iter)
|
|
||||||
{
|
|
||||||
SelectionHandler *handler;
|
|
||||||
|
|
||||||
if (iter == NULL)
|
|
||||||
handler = WMBagFirst(selHandlers, &iter);
|
|
||||||
else
|
|
||||||
handler = WMBagNext(selHandlers, &iter);
|
|
||||||
|
|
||||||
if (handler == NULL)
|
|
||||||
return;
|
|
||||||
|
|
||||||
deleteHandlers(iter);
|
|
||||||
|
|
||||||
if (handler->flags.delete_pending) {
|
|
||||||
WMDeleteSelectionHandler(handler->view, handler->selection,
|
|
||||||
handler->timestamp);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
handleRequestEvent(XEvent *event)
|
handleRequestEvent(XEvent *event)
|
||||||
{
|
{
|
||||||
SelectionHandler *handler;
|
SelectionHandler *handler;
|
||||||
WMBagIterator iter;
|
WMArrayIterator iter;
|
||||||
Bool handledRequest = False;
|
WMArray *copy;
|
||||||
|
Bool handledRequest;
|
||||||
|
|
||||||
WM_ITERATE_BAG(selHandlers, handler, iter) {
|
WM_ITERATE_ARRAY(selHandlers, handler, iter) {
|
||||||
|
|
||||||
switch (event->type) {
|
switch (event->type) {
|
||||||
case SelectionClear:
|
case SelectionClear:
|
||||||
@@ -220,8 +205,7 @@ handleRequestEvent(XEvent *event)
|
|||||||
break;
|
break;
|
||||||
|
|
||||||
case SelectionRequest:
|
case SelectionRequest:
|
||||||
if (W_VIEW_DRAWABLE(handler->view)
|
if (W_VIEW_DRAWABLE(handler->view)!=event->xselectionrequest.owner) {
|
||||||
!= event->xselectionrequest.owner) {
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -238,6 +222,8 @@ handleRequestEvent(XEvent *event)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
handledRequest = False;
|
||||||
|
|
||||||
handler->flags.done_pending = 1;
|
handler->flags.done_pending = 1;
|
||||||
|
|
||||||
data = handler->procs.convertSelection(handler->view,
|
data = handler->procs.convertSelection(handler->view,
|
||||||
@@ -245,28 +231,22 @@ handleRequestEvent(XEvent *event)
|
|||||||
event->xselectionrequest.target,
|
event->xselectionrequest.target,
|
||||||
handler->data,
|
handler->data,
|
||||||
&atom);
|
&atom);
|
||||||
if (data == NULL) {
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
handledRequest = True;
|
|
||||||
|
|
||||||
|
|
||||||
prop = event->xselectionrequest.property;
|
prop = event->xselectionrequest.property;
|
||||||
/* obsolete clients that don't set the property field */
|
/* obsolete clients that don't set the property field */
|
||||||
if (prop == None)
|
if (prop == None)
|
||||||
prop = event->xselectionrequest.target;
|
prop = event->xselectionrequest.target;
|
||||||
|
|
||||||
if (!writeSelection(event->xselectionrequest.display,
|
if (data) {
|
||||||
|
if (writeSelection(event->xselectionrequest.display,
|
||||||
event->xselectionrequest.requestor,
|
event->xselectionrequest.requestor,
|
||||||
prop, atom, data)) {
|
prop, atom, data)) {
|
||||||
WMReleaseData(data);
|
handledRequest = True;
|
||||||
notifySelection(event, None);
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
WMReleaseData(data);
|
WMReleaseData(data);
|
||||||
|
}
|
||||||
|
|
||||||
notifySelection(event, prop);
|
notifySelection(event, (handledRequest==True ? prop : None));
|
||||||
|
|
||||||
if (handler->procs.selectionDone != NULL) {
|
if (handler->procs.selectionDone != NULL) {
|
||||||
handler->procs.selectionDone(handler->view,
|
handler->procs.selectionDone(handler->view,
|
||||||
@@ -276,42 +256,21 @@ handleRequestEvent(XEvent *event)
|
|||||||
}
|
}
|
||||||
|
|
||||||
handler->flags.done_pending = 0;
|
handler->flags.done_pending = 0;
|
||||||
|
|
||||||
if (!handledRequest) {
|
|
||||||
notifySelection(event, None);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
deleteHandlers(NULL);
|
/* delete handlers */
|
||||||
}
|
copy = WMDuplicateArray(selHandlers);
|
||||||
|
WM_ITERATE_ARRAY(copy, handler, iter) {
|
||||||
|
if (handler && handler->flags.delete_pending) {
|
||||||
|
WMDeleteSelectionHandler(handler->view, handler->selection,
|
||||||
static void
|
|
||||||
deleteCallbacks(WMBagIterator iter)
|
|
||||||
{
|
|
||||||
SelectionCallback *handler;
|
|
||||||
|
|
||||||
if (iter == NULL)
|
|
||||||
handler = WMBagFirst(selCallbacks, &iter);
|
|
||||||
else
|
|
||||||
handler = WMBagNext(selCallbacks, &iter);
|
|
||||||
|
|
||||||
if (handler == NULL)
|
|
||||||
return;
|
|
||||||
|
|
||||||
deleteCallbacks(iter);
|
|
||||||
|
|
||||||
if (handler->flags.delete_pending) {
|
|
||||||
WMDeleteSelectionCallback(handler->view, handler->selection,
|
|
||||||
handler->timestamp);
|
handler->timestamp);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
WMFreeArray(copy);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
static WMData*
|
static WMData*
|
||||||
@@ -320,7 +279,7 @@ getSelectionData(Display *dpy, Window win, Atom where)
|
|||||||
WMData *wdata;
|
WMData *wdata;
|
||||||
unsigned char *data;
|
unsigned char *data;
|
||||||
Atom rtype;
|
Atom rtype;
|
||||||
unsigned bits;
|
unsigned bits, bpi;
|
||||||
unsigned long len, bytes;
|
unsigned long len, bytes;
|
||||||
|
|
||||||
|
|
||||||
@@ -330,10 +289,9 @@ getSelectionData(Display *dpy, Window win, Atom where)
|
|||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
wdata = WMCreateDataWithBytesNoCopy(data, len, (WMFreeDataProc*)XFree);
|
bpi = bits/8;
|
||||||
if (wdata == NULL) {
|
|
||||||
return NULL;
|
wdata = WMCreateDataWithBytesNoCopy(data, len*bpi, (WMFreeDataProc*)XFree);
|
||||||
}
|
|
||||||
WMSetDataFormat(wdata, bits);
|
WMSetDataFormat(wdata, bits);
|
||||||
|
|
||||||
return wdata;
|
return wdata;
|
||||||
@@ -344,13 +302,14 @@ static void
|
|||||||
handleNotifyEvent(XEvent *event)
|
handleNotifyEvent(XEvent *event)
|
||||||
{
|
{
|
||||||
SelectionCallback *handler;
|
SelectionCallback *handler;
|
||||||
WMBagIterator iter;
|
WMArrayIterator iter;
|
||||||
|
WMArray *copy;
|
||||||
WMData *data;
|
WMData *data;
|
||||||
|
|
||||||
WM_ITERATE_BAG(selCallbacks, handler, iter) {
|
WM_ITERATE_ARRAY(selCallbacks, handler, iter) {
|
||||||
|
|
||||||
if (W_VIEW_DRAWABLE(handler->view) != event->xselection.requestor
|
if (W_VIEW_DRAWABLE(handler->view) != event->xselection.requestor
|
||||||
&& handler->selection == event->xselection.selection) {
|
|| handler->selection != event->xselection.selection) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
handler->flags.done_pending = 1;
|
handler->flags.done_pending = 1;
|
||||||
@@ -373,7 +332,16 @@ handleNotifyEvent(XEvent *event)
|
|||||||
handler->flags.done_pending = 0;
|
handler->flags.done_pending = 0;
|
||||||
handler->flags.delete_pending = 1;
|
handler->flags.delete_pending = 1;
|
||||||
}
|
}
|
||||||
deleteCallbacks(NULL);
|
|
||||||
|
/* delete callbacks */
|
||||||
|
copy = WMDuplicateArray(selCallbacks);
|
||||||
|
WM_ITERATE_ARRAY(copy, handler, iter) {
|
||||||
|
if (handler && handler->flags.delete_pending) {
|
||||||
|
WMDeleteSelectionCallback(handler->view, handler->selection,
|
||||||
|
handler->timestamp);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
WMFreeArray(copy);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -381,6 +349,18 @@ handleNotifyEvent(XEvent *event)
|
|||||||
void
|
void
|
||||||
W_HandleSelectionEvent(XEvent *event)
|
W_HandleSelectionEvent(XEvent *event)
|
||||||
{
|
{
|
||||||
|
/*//printf("%d received selection ", event->xany.window);*/
|
||||||
|
/*//switch(event->type) {
|
||||||
|
case SelectionNotify:
|
||||||
|
puts("notify"); break;
|
||||||
|
case SelectionRequest:
|
||||||
|
puts("request"); break;
|
||||||
|
case SelectionClear:
|
||||||
|
puts("clear"); break;
|
||||||
|
default:
|
||||||
|
puts("unknown"); break;
|
||||||
|
}*/
|
||||||
|
|
||||||
if (event->type == SelectionNotify) {
|
if (event->type == SelectionNotify) {
|
||||||
handleNotifyEvent(event);
|
handleNotifyEvent(event);
|
||||||
} else {
|
} else {
|
||||||
@@ -390,7 +370,6 @@ W_HandleSelectionEvent(XEvent *event)
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Bool
|
Bool
|
||||||
WMCreateSelectionHandler(WMView *view, Atom selection, Time timestamp,
|
WMCreateSelectionHandler(WMView *view, Atom selection, Time timestamp,
|
||||||
WMSelectionProcs *procs, void *cdata)
|
WMSelectionProcs *procs, void *cdata)
|
||||||
@@ -399,12 +378,16 @@ WMCreateSelectionHandler(WMView *view, Atom selection, Time timestamp,
|
|||||||
Display *dpy = W_VIEW_SCREEN(view)->display;
|
Display *dpy = W_VIEW_SCREEN(view)->display;
|
||||||
|
|
||||||
XSetSelectionOwner(dpy, selection, W_VIEW_DRAWABLE(view), timestamp);
|
XSetSelectionOwner(dpy, selection, W_VIEW_DRAWABLE(view), timestamp);
|
||||||
if (XGetSelectionOwner(dpy, selection) != W_VIEW_DRAWABLE(view))
|
if (XGetSelectionOwner(dpy, selection) != W_VIEW_DRAWABLE(view)) {
|
||||||
return False;
|
return False;
|
||||||
|
}
|
||||||
|
|
||||||
handler = malloc(sizeof(SelectionHandler));
|
WMPostNotificationName(WMSelectionOwnerDidChangeNotification,
|
||||||
if (handler == NULL)
|
(void*)selection, (void*)view);
|
||||||
return False;
|
|
||||||
|
/*//printf("created selection handler for %d\n", W_VIEW_DRAWABLE(view));*/
|
||||||
|
|
||||||
|
handler = wmalloc(sizeof(SelectionHandler));
|
||||||
|
|
||||||
handler->view = view;
|
handler->view = view;
|
||||||
handler->selection = selection;
|
handler->selection = selection;
|
||||||
@@ -414,10 +397,10 @@ WMCreateSelectionHandler(WMView *view, Atom selection, Time timestamp,
|
|||||||
memset(&handler->flags, 0, sizeof(handler->flags));
|
memset(&handler->flags, 0, sizeof(handler->flags));
|
||||||
|
|
||||||
if (selHandlers == NULL) {
|
if (selHandlers == NULL) {
|
||||||
selHandlers = WMCreateTreeBag();
|
selHandlers = WMCreateArrayWithDestructor(4, wfree);
|
||||||
}
|
}
|
||||||
|
|
||||||
WMPutInBag(selHandlers, handler);
|
WMAddToArray(selHandlers, handler);
|
||||||
|
|
||||||
return True;
|
return True;
|
||||||
}
|
}
|
||||||
@@ -433,6 +416,12 @@ WMRequestSelection(WMView *view, Atom selection, Atom target, Time timestamp,
|
|||||||
if (XGetSelectionOwner(W_VIEW_SCREEN(view)->display, selection) == None)
|
if (XGetSelectionOwner(W_VIEW_SCREEN(view)->display, selection) == None)
|
||||||
return False;
|
return False;
|
||||||
|
|
||||||
|
if (!XConvertSelection(W_VIEW_SCREEN(view)->display, selection, target,
|
||||||
|
W_VIEW_SCREEN(view)->clipboardAtom,
|
||||||
|
W_VIEW_DRAWABLE(view), timestamp)) {
|
||||||
|
return False;
|
||||||
|
}
|
||||||
|
|
||||||
handler = wmalloc(sizeof(SelectionCallback));
|
handler = wmalloc(sizeof(SelectionCallback));
|
||||||
|
|
||||||
handler->view = view;
|
handler->view = view;
|
||||||
@@ -444,16 +433,10 @@ WMRequestSelection(WMView *view, Atom selection, Atom target, Time timestamp,
|
|||||||
memset(&handler->flags, 0, sizeof(handler->flags));
|
memset(&handler->flags, 0, sizeof(handler->flags));
|
||||||
|
|
||||||
if (selCallbacks == NULL) {
|
if (selCallbacks == NULL) {
|
||||||
selCallbacks = WMCreateTreeBag();
|
selCallbacks = WMCreateArrayWithDestructor(4, wfree);
|
||||||
}
|
}
|
||||||
|
|
||||||
WMPutInBag(selCallbacks, handler);
|
WMAddToArray(selCallbacks, handler);
|
||||||
|
|
||||||
if (!XConvertSelection(W_VIEW_SCREEN(view)->display, selection, target,
|
|
||||||
W_VIEW_SCREEN(view)->clipboardAtom,
|
|
||||||
W_VIEW_DRAWABLE(view), timestamp)) {
|
|
||||||
return False;
|
|
||||||
}
|
|
||||||
|
|
||||||
return True;
|
return True;
|
||||||
}
|
}
|
||||||
|
|||||||
938
WINGs/snprintf.c
Normal file
938
WINGs/snprintf.c
Normal file
@@ -0,0 +1,938 @@
|
|||||||
|
/*
|
||||||
|
* Copyright Patrick Powell 1995
|
||||||
|
* This code is based on code written by Patrick Powell (papowell@astart.com)
|
||||||
|
* It may be used for any purpose as long as this notice remains intact
|
||||||
|
* on all source code distributions
|
||||||
|
*/
|
||||||
|
|
||||||
|
/**************************************************************
|
||||||
|
* Original:
|
||||||
|
* Patrick Powell Tue Apr 11 09:48:21 PDT 1995
|
||||||
|
* A bombproof version of doprnt (dopr) included.
|
||||||
|
* Sigh. This sort of thing is always nasty do deal with. Note that
|
||||||
|
* the version here does not include floating point...
|
||||||
|
*
|
||||||
|
* snprintf() is used instead of sprintf() as it does limit checks
|
||||||
|
* for string length. This covers a nasty loophole.
|
||||||
|
*
|
||||||
|
* The other functions are there to prevent NULL pointers from
|
||||||
|
* causing nast effects.
|
||||||
|
*
|
||||||
|
* More Recently:
|
||||||
|
* Brandon Long <blong@fiction.net> 9/15/96 for mutt 0.43
|
||||||
|
* This was ugly. It is still ugly. I opted out of floating point
|
||||||
|
* numbers, but the formatter understands just about everything
|
||||||
|
* from the normal C string format, at least as far as I can tell from
|
||||||
|
* the Solaris 2.5 printf(3S) man page.
|
||||||
|
*
|
||||||
|
* Brandon Long <blong@fiction.net> 10/22/97 for mutt 0.87.1
|
||||||
|
* Ok, added some minimal floating point support, which means this
|
||||||
|
* probably requires libm on most operating systems. Don't yet
|
||||||
|
* support the exponent (e,E) and sigfig (g,G). Also, fmtint()
|
||||||
|
* was pretty badly broken, it just wasn't being exercised in ways
|
||||||
|
* which showed it, so that's been fixed. Also, formated the code
|
||||||
|
* to mutt conventions, and removed dead code left over from the
|
||||||
|
* original. Also, there is now a builtin-test, just compile with:
|
||||||
|
* gcc -DTEST_SNPRINTF -o snprintf snprintf.c -lm
|
||||||
|
* and run snprintf for results.
|
||||||
|
*
|
||||||
|
* Thomas Roessler <roessler@guug.de> 01/27/98 for mutt 0.89i
|
||||||
|
* The PGP code was using unsigned hexadecimal formats.
|
||||||
|
* Unfortunately, unsigned formats simply didn't work.
|
||||||
|
*
|
||||||
|
* Michael Elkins <me@cs.hmc.edu> 03/05/98 for mutt 0.90.8
|
||||||
|
* The original code assumed that both snprintf() and vsnprintf() were
|
||||||
|
* missing. Some systems only have snprintf() but not vsnprintf(), so
|
||||||
|
* the code is now broken down under HAVE_SNPRINTF and HAVE_VSNPRINTF.
|
||||||
|
*
|
||||||
|
* Andrew Tridgell (tridge@samba.org) Oct 1998
|
||||||
|
* fixed handling of %.0f
|
||||||
|
* added test for HAVE_LONG_DOUBLE
|
||||||
|
*
|
||||||
|
* tridge@samba.org, idra@samba.org, April 2001
|
||||||
|
* got rid of fcvt code (twas buggy and made testing harder)
|
||||||
|
* added C99 semantics
|
||||||
|
*
|
||||||
|
**************************************************************/
|
||||||
|
|
||||||
|
#ifndef NO_CONFIG_H /* for some tests */
|
||||||
|
#include "config.h"
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef HAVE_STRING_H
|
||||||
|
#include <string.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef HAVE_STRINGS_H
|
||||||
|
#include <strings.h>
|
||||||
|
#endif
|
||||||
|
#ifdef HAVE_CTYPE_H
|
||||||
|
#include <ctype.h>
|
||||||
|
#endif
|
||||||
|
#include <sys/types.h>
|
||||||
|
#include <stdarg.h>
|
||||||
|
#ifdef HAVE_STDLIB_H
|
||||||
|
#include <stdlib.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(HAVE_SNPRINTF) && defined(HAVE_VSNPRINTF) && defined(HAVE_C99_VSNPRINTF)
|
||||||
|
/* only include stdio.h if we are not re-defining snprintf or vsnprintf */
|
||||||
|
#include <stdio.h>
|
||||||
|
/* make the compiler happy with an empty file */
|
||||||
|
void dummy_snprintf(void) {}
|
||||||
|
#else
|
||||||
|
|
||||||
|
#ifdef HAVE_LONG_DOUBLE
|
||||||
|
#define LDOUBLE long double
|
||||||
|
#else
|
||||||
|
#define LDOUBLE double
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef HAVE_LONG_LONG
|
||||||
|
#define LLONG long long
|
||||||
|
#else
|
||||||
|
#define LLONG long
|
||||||
|
#endif
|
||||||
|
|
||||||
|
static size_t dopr(char *buffer, size_t maxlen, const char *format,
|
||||||
|
va_list args);
|
||||||
|
static void fmtstr(char *buffer, size_t *currlen, size_t maxlen,
|
||||||
|
char *value, int flags, int min, int max);
|
||||||
|
static void fmtint(char *buffer, size_t *currlen, size_t maxlen,
|
||||||
|
long value, int base, int min, int max, int flags);
|
||||||
|
static void fmtfp(char *buffer, size_t *currlen, size_t maxlen,
|
||||||
|
LDOUBLE fvalue, int min, int max, int flags);
|
||||||
|
static void dopr_outch(char *buffer, size_t *currlen, size_t maxlen, char c);
|
||||||
|
|
||||||
|
/*
|
||||||
|
* dopr(): poor man's version of doprintf
|
||||||
|
*/
|
||||||
|
|
||||||
|
/* format read states */
|
||||||
|
#define DP_S_DEFAULT 0
|
||||||
|
#define DP_S_FLAGS 1
|
||||||
|
#define DP_S_MIN 2
|
||||||
|
#define DP_S_DOT 3
|
||||||
|
#define DP_S_MAX 4
|
||||||
|
#define DP_S_MOD 5
|
||||||
|
#define DP_S_CONV 6
|
||||||
|
#define DP_S_DONE 7
|
||||||
|
|
||||||
|
/* format flags - Bits */
|
||||||
|
#define DP_F_MINUS (1 << 0)
|
||||||
|
#define DP_F_PLUS (1 << 1)
|
||||||
|
#define DP_F_SPACE (1 << 2)
|
||||||
|
#define DP_F_NUM (1 << 3)
|
||||||
|
#define DP_F_ZERO (1 << 4)
|
||||||
|
#define DP_F_UP (1 << 5)
|
||||||
|
#define DP_F_UNSIGNED (1 << 6)
|
||||||
|
|
||||||
|
/* Conversion Flags */
|
||||||
|
#define DP_C_SHORT 1
|
||||||
|
#define DP_C_LONG 2
|
||||||
|
#define DP_C_LDOUBLE 3
|
||||||
|
#define DP_C_LLONG 4
|
||||||
|
|
||||||
|
#define char_to_int(p) ((p)- '0')
|
||||||
|
#ifndef MAX
|
||||||
|
#define MAX(p,q) (((p) >= (q)) ? (p) : (q))
|
||||||
|
#endif
|
||||||
|
|
||||||
|
static size_t dopr(char *buffer, size_t maxlen, const char *format, va_list args)
|
||||||
|
{
|
||||||
|
char ch;
|
||||||
|
LLONG value;
|
||||||
|
LDOUBLE fvalue;
|
||||||
|
char *strvalue;
|
||||||
|
int min;
|
||||||
|
int max;
|
||||||
|
int state;
|
||||||
|
int flags;
|
||||||
|
int cflags;
|
||||||
|
size_t currlen;
|
||||||
|
|
||||||
|
state = DP_S_DEFAULT;
|
||||||
|
currlen = flags = cflags = min = 0;
|
||||||
|
max = -1;
|
||||||
|
ch = *format++;
|
||||||
|
|
||||||
|
while (state != DP_S_DONE) {
|
||||||
|
if (ch == '\0')
|
||||||
|
state = DP_S_DONE;
|
||||||
|
|
||||||
|
switch(state) {
|
||||||
|
case DP_S_DEFAULT:
|
||||||
|
if (ch == '%')
|
||||||
|
state = DP_S_FLAGS;
|
||||||
|
else
|
||||||
|
dopr_outch (buffer, &currlen, maxlen, ch);
|
||||||
|
ch = *format++;
|
||||||
|
break;
|
||||||
|
case DP_S_FLAGS:
|
||||||
|
switch (ch) {
|
||||||
|
case '-':
|
||||||
|
flags |= DP_F_MINUS;
|
||||||
|
ch = *format++;
|
||||||
|
break;
|
||||||
|
case '+':
|
||||||
|
flags |= DP_F_PLUS;
|
||||||
|
ch = *format++;
|
||||||
|
break;
|
||||||
|
case ' ':
|
||||||
|
flags |= DP_F_SPACE;
|
||||||
|
ch = *format++;
|
||||||
|
break;
|
||||||
|
case '#':
|
||||||
|
flags |= DP_F_NUM;
|
||||||
|
ch = *format++;
|
||||||
|
break;
|
||||||
|
case '0':
|
||||||
|
flags |= DP_F_ZERO;
|
||||||
|
ch = *format++;
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
state = DP_S_MIN;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case DP_S_MIN:
|
||||||
|
if (isdigit((unsigned char)ch)) {
|
||||||
|
min = 10*min + char_to_int (ch);
|
||||||
|
ch = *format++;
|
||||||
|
} else if (ch == '*') {
|
||||||
|
min = va_arg (args, int);
|
||||||
|
ch = *format++;
|
||||||
|
state = DP_S_DOT;
|
||||||
|
} else {
|
||||||
|
state = DP_S_DOT;
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case DP_S_DOT:
|
||||||
|
if (ch == '.') {
|
||||||
|
state = DP_S_MAX;
|
||||||
|
ch = *format++;
|
||||||
|
} else {
|
||||||
|
state = DP_S_MOD;
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case DP_S_MAX:
|
||||||
|
if (isdigit((unsigned char)ch)) {
|
||||||
|
if (max < 0)
|
||||||
|
max = 0;
|
||||||
|
max = 10*max + char_to_int (ch);
|
||||||
|
ch = *format++;
|
||||||
|
} else if (ch == '*') {
|
||||||
|
max = va_arg (args, int);
|
||||||
|
ch = *format++;
|
||||||
|
state = DP_S_MOD;
|
||||||
|
} else {
|
||||||
|
state = DP_S_MOD;
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case DP_S_MOD:
|
||||||
|
switch (ch) {
|
||||||
|
case 'h':
|
||||||
|
cflags = DP_C_SHORT;
|
||||||
|
ch = *format++;
|
||||||
|
break;
|
||||||
|
case 'l':
|
||||||
|
cflags = DP_C_LONG;
|
||||||
|
ch = *format++;
|
||||||
|
if (ch == 'l') { /* It's a long long */
|
||||||
|
cflags = DP_C_LLONG;
|
||||||
|
ch = *format++;
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case 'L':
|
||||||
|
cflags = DP_C_LDOUBLE;
|
||||||
|
ch = *format++;
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
state = DP_S_CONV;
|
||||||
|
break;
|
||||||
|
case DP_S_CONV:
|
||||||
|
switch (ch) {
|
||||||
|
case 'd':
|
||||||
|
case 'i':
|
||||||
|
if (cflags == DP_C_SHORT)
|
||||||
|
value = va_arg (args, int);
|
||||||
|
else if (cflags == DP_C_LONG)
|
||||||
|
value = va_arg (args, long int);
|
||||||
|
else if (cflags == DP_C_LLONG)
|
||||||
|
value = va_arg (args, LLONG);
|
||||||
|
else
|
||||||
|
value = va_arg (args, int);
|
||||||
|
fmtint (buffer, &currlen, maxlen, value, 10, min, max, flags);
|
||||||
|
break;
|
||||||
|
case 'o':
|
||||||
|
flags |= DP_F_UNSIGNED;
|
||||||
|
if (cflags == DP_C_SHORT)
|
||||||
|
value = va_arg (args, unsigned int);
|
||||||
|
else if (cflags == DP_C_LONG)
|
||||||
|
value = (long)va_arg (args, unsigned long int);
|
||||||
|
else if (cflags == DP_C_LLONG)
|
||||||
|
value = (long)va_arg (args, unsigned LLONG);
|
||||||
|
else
|
||||||
|
value = (long)va_arg (args, unsigned int);
|
||||||
|
fmtint (buffer, &currlen, maxlen, value, 8, min, max, flags);
|
||||||
|
break;
|
||||||
|
case 'u':
|
||||||
|
flags |= DP_F_UNSIGNED;
|
||||||
|
if (cflags == DP_C_SHORT)
|
||||||
|
value = va_arg (args, unsigned int);
|
||||||
|
else if (cflags == DP_C_LONG)
|
||||||
|
value = (long)va_arg (args, unsigned long int);
|
||||||
|
else if (cflags == DP_C_LLONG)
|
||||||
|
value = (LLONG)va_arg (args, unsigned LLONG);
|
||||||
|
else
|
||||||
|
value = (long)va_arg (args, unsigned int);
|
||||||
|
fmtint (buffer, &currlen, maxlen, value, 10, min, max, flags);
|
||||||
|
break;
|
||||||
|
case 'X':
|
||||||
|
flags |= DP_F_UP;
|
||||||
|
case 'x':
|
||||||
|
flags |= DP_F_UNSIGNED;
|
||||||
|
if (cflags == DP_C_SHORT)
|
||||||
|
value = va_arg (args, unsigned int);
|
||||||
|
else if (cflags == DP_C_LONG)
|
||||||
|
value = (long)va_arg (args, unsigned long int);
|
||||||
|
else if (cflags == DP_C_LLONG)
|
||||||
|
value = (LLONG)va_arg (args, unsigned LLONG);
|
||||||
|
else
|
||||||
|
value = (long)va_arg (args, unsigned int);
|
||||||
|
fmtint (buffer, &currlen, maxlen, value, 16, min, max, flags);
|
||||||
|
break;
|
||||||
|
case 'f':
|
||||||
|
if (cflags == DP_C_LDOUBLE)
|
||||||
|
fvalue = va_arg (args, LDOUBLE);
|
||||||
|
else
|
||||||
|
fvalue = va_arg (args, double);
|
||||||
|
/* um, floating point? */
|
||||||
|
fmtfp (buffer, &currlen, maxlen, fvalue, min, max, flags);
|
||||||
|
break;
|
||||||
|
case 'E':
|
||||||
|
flags |= DP_F_UP;
|
||||||
|
case 'e':
|
||||||
|
if (cflags == DP_C_LDOUBLE)
|
||||||
|
fvalue = va_arg (args, LDOUBLE);
|
||||||
|
else
|
||||||
|
fvalue = va_arg (args, double);
|
||||||
|
break;
|
||||||
|
case 'G':
|
||||||
|
flags |= DP_F_UP;
|
||||||
|
case 'g':
|
||||||
|
if (cflags == DP_C_LDOUBLE)
|
||||||
|
fvalue = va_arg (args, LDOUBLE);
|
||||||
|
else
|
||||||
|
fvalue = va_arg (args, double);
|
||||||
|
break;
|
||||||
|
case 'c':
|
||||||
|
dopr_outch (buffer, &currlen, maxlen, va_arg (args, int));
|
||||||
|
break;
|
||||||
|
case 's':
|
||||||
|
strvalue = va_arg (args, char *);
|
||||||
|
if (max == -1) {
|
||||||
|
max = strlen(strvalue);
|
||||||
|
}
|
||||||
|
if (min > 0 && max >= 0 && min > max) max = min;
|
||||||
|
fmtstr (buffer, &currlen, maxlen, strvalue, flags, min, max);
|
||||||
|
break;
|
||||||
|
case 'p':
|
||||||
|
strvalue = va_arg (args, void *);
|
||||||
|
fmtint (buffer, &currlen, maxlen, (long) strvalue, 16, min, max, flags);
|
||||||
|
break;
|
||||||
|
case 'n':
|
||||||
|
if (cflags == DP_C_SHORT) {
|
||||||
|
short int *num;
|
||||||
|
num = va_arg (args, short int *);
|
||||||
|
*num = currlen;
|
||||||
|
} else if (cflags == DP_C_LONG) {
|
||||||
|
long int *num;
|
||||||
|
num = va_arg (args, long int *);
|
||||||
|
*num = (long int)currlen;
|
||||||
|
} else if (cflags == DP_C_LLONG) {
|
||||||
|
LLONG *num;
|
||||||
|
num = va_arg (args, LLONG *);
|
||||||
|
*num = (LLONG)currlen;
|
||||||
|
} else {
|
||||||
|
int *num;
|
||||||
|
num = va_arg (args, int *);
|
||||||
|
*num = currlen;
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
case '%':
|
||||||
|
dopr_outch (buffer, &currlen, maxlen, ch);
|
||||||
|
break;
|
||||||
|
case 'w':
|
||||||
|
/* not supported yet, treat as next char */
|
||||||
|
ch = *format++;
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
/* Unknown, skip */
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
ch = *format++;
|
||||||
|
state = DP_S_DEFAULT;
|
||||||
|
flags = cflags = min = 0;
|
||||||
|
max = -1;
|
||||||
|
break;
|
||||||
|
case DP_S_DONE:
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
/* hmm? */
|
||||||
|
break; /* some picky compilers need this */
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (maxlen != 0) {
|
||||||
|
if (currlen < maxlen - 1)
|
||||||
|
buffer[currlen] = '\0';
|
||||||
|
else if (maxlen > 0)
|
||||||
|
buffer[maxlen - 1] = '\0';
|
||||||
|
}
|
||||||
|
|
||||||
|
return currlen;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void fmtstr(char *buffer, size_t *currlen, size_t maxlen,
|
||||||
|
char *value, int flags, int min, int max)
|
||||||
|
{
|
||||||
|
int padlen, strln; /* amount to pad */
|
||||||
|
int cnt = 0;
|
||||||
|
|
||||||
|
#ifdef DEBUG_SNPRINTF
|
||||||
|
printf("fmtstr min=%d max=%d s=[%s]\n", min, max, value);
|
||||||
|
#endif
|
||||||
|
if (value == 0) {
|
||||||
|
value = "<NULL>";
|
||||||
|
}
|
||||||
|
|
||||||
|
for (strln = 0; value[strln]; ++strln); /* strlen */
|
||||||
|
padlen = min - strln;
|
||||||
|
if (padlen < 0)
|
||||||
|
padlen = 0;
|
||||||
|
if (flags & DP_F_MINUS)
|
||||||
|
padlen = -padlen; /* Left Justify */
|
||||||
|
|
||||||
|
while ((padlen > 0) && (cnt < max)) {
|
||||||
|
dopr_outch (buffer, currlen, maxlen, ' ');
|
||||||
|
--padlen;
|
||||||
|
++cnt;
|
||||||
|
}
|
||||||
|
while (*value && (cnt < max)) {
|
||||||
|
dopr_outch (buffer, currlen, maxlen, *value++);
|
||||||
|
++cnt;
|
||||||
|
}
|
||||||
|
while ((padlen < 0) && (cnt < max)) {
|
||||||
|
dopr_outch (buffer, currlen, maxlen, ' ');
|
||||||
|
++padlen;
|
||||||
|
++cnt;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Have to handle DP_F_NUM (ie 0x and 0 alternates) */
|
||||||
|
|
||||||
|
static void fmtint(char *buffer, size_t *currlen, size_t maxlen,
|
||||||
|
long value, int base, int min, int max, int flags)
|
||||||
|
{
|
||||||
|
int signvalue = 0;
|
||||||
|
unsigned long uvalue;
|
||||||
|
char convert[20];
|
||||||
|
int place = 0;
|
||||||
|
int spadlen = 0; /* amount to space pad */
|
||||||
|
int zpadlen = 0; /* amount to zero pad */
|
||||||
|
int caps = 0;
|
||||||
|
|
||||||
|
if (max < 0)
|
||||||
|
max = 0;
|
||||||
|
|
||||||
|
uvalue = value;
|
||||||
|
|
||||||
|
if(!(flags & DP_F_UNSIGNED)) {
|
||||||
|
if( value < 0 ) {
|
||||||
|
signvalue = '-';
|
||||||
|
uvalue = -value;
|
||||||
|
} else {
|
||||||
|
if (flags & DP_F_PLUS) /* Do a sign (+/i) */
|
||||||
|
signvalue = '+';
|
||||||
|
else if (flags & DP_F_SPACE)
|
||||||
|
signvalue = ' ';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (flags & DP_F_UP) caps = 1; /* Should characters be upper case? */
|
||||||
|
|
||||||
|
do {
|
||||||
|
convert[place++] =
|
||||||
|
(caps? "0123456789ABCDEF":"0123456789abcdef")
|
||||||
|
[uvalue % (unsigned)base ];
|
||||||
|
uvalue = (uvalue / (unsigned)base );
|
||||||
|
} while(uvalue && (place < 20));
|
||||||
|
if (place == 20) place--;
|
||||||
|
convert[place] = 0;
|
||||||
|
|
||||||
|
zpadlen = max - place;
|
||||||
|
spadlen = min - MAX (max, place) - (signvalue ? 1 : 0);
|
||||||
|
if (zpadlen < 0) zpadlen = 0;
|
||||||
|
if (spadlen < 0) spadlen = 0;
|
||||||
|
if (flags & DP_F_ZERO) {
|
||||||
|
zpadlen = MAX(zpadlen, spadlen);
|
||||||
|
spadlen = 0;
|
||||||
|
}
|
||||||
|
if (flags & DP_F_MINUS)
|
||||||
|
spadlen = -spadlen; /* Left Justifty */
|
||||||
|
|
||||||
|
#ifdef DEBUG_SNPRINTF
|
||||||
|
printf("zpad: %d, spad: %d, min: %d, max: %d, place: %d\n",
|
||||||
|
zpadlen, spadlen, min, max, place);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/* Spaces */
|
||||||
|
while (spadlen > 0) {
|
||||||
|
dopr_outch (buffer, currlen, maxlen, ' ');
|
||||||
|
--spadlen;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Sign */
|
||||||
|
if (signvalue)
|
||||||
|
dopr_outch (buffer, currlen, maxlen, signvalue);
|
||||||
|
|
||||||
|
/* Zeros */
|
||||||
|
if (zpadlen > 0) {
|
||||||
|
while (zpadlen > 0) {
|
||||||
|
dopr_outch (buffer, currlen, maxlen, '0');
|
||||||
|
--zpadlen;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Digits */
|
||||||
|
while (place > 0)
|
||||||
|
dopr_outch (buffer, currlen, maxlen, convert[--place]);
|
||||||
|
|
||||||
|
/* Left Justified spaces */
|
||||||
|
while (spadlen < 0) {
|
||||||
|
dopr_outch (buffer, currlen, maxlen, ' ');
|
||||||
|
++spadlen;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
static LDOUBLE abs_val(LDOUBLE value)
|
||||||
|
{
|
||||||
|
LDOUBLE result = value;
|
||||||
|
|
||||||
|
if (value < 0)
|
||||||
|
result = -value;
|
||||||
|
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
static LDOUBLE POW10(int exp)
|
||||||
|
{
|
||||||
|
LDOUBLE result = 1;
|
||||||
|
|
||||||
|
while (exp) {
|
||||||
|
result *= 10;
|
||||||
|
exp--;
|
||||||
|
}
|
||||||
|
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
static LLONG ROUND(LDOUBLE value)
|
||||||
|
{
|
||||||
|
LLONG intpart;
|
||||||
|
|
||||||
|
intpart = (LLONG)value;
|
||||||
|
value = value - intpart;
|
||||||
|
if (value >= 0.5) intpart++;
|
||||||
|
|
||||||
|
return intpart;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* a replacement for modf that doesn't need the math library. Should
|
||||||
|
be portable, but slow */
|
||||||
|
static double my_modf(double x0, double *iptr)
|
||||||
|
{
|
||||||
|
int i;
|
||||||
|
long l;
|
||||||
|
double x = x0;
|
||||||
|
double f = 1.0;
|
||||||
|
|
||||||
|
for (i=0;i<100;i++) {
|
||||||
|
l = (long)x;
|
||||||
|
if (l <= (x+1) && l >= (x-1)) break;
|
||||||
|
x *= 0.1;
|
||||||
|
f *= 10.0;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (i == 100) {
|
||||||
|
/* yikes! the number is beyond what we can handle. What do we do? */
|
||||||
|
(*iptr) = 0;
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (i != 0) {
|
||||||
|
double i2;
|
||||||
|
double ret;
|
||||||
|
|
||||||
|
ret = my_modf(x0-l*f, &i2);
|
||||||
|
(*iptr) = l*f + i2;
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
|
||||||
|
(*iptr) = l;
|
||||||
|
return x - (*iptr);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
static void fmtfp (char *buffer, size_t *currlen, size_t maxlen,
|
||||||
|
LDOUBLE fvalue, int min, int max, int flags)
|
||||||
|
{
|
||||||
|
int signvalue = 0;
|
||||||
|
double ufvalue;
|
||||||
|
char iconvert[311];
|
||||||
|
char fconvert[311];
|
||||||
|
int iplace = 0;
|
||||||
|
int fplace = 0;
|
||||||
|
int padlen = 0; /* amount to pad */
|
||||||
|
int zpadlen = 0;
|
||||||
|
int caps = 0;
|
||||||
|
int index;
|
||||||
|
double intpart;
|
||||||
|
double fracpart;
|
||||||
|
double temp;
|
||||||
|
|
||||||
|
/*
|
||||||
|
* AIX manpage says the default is 0, but Solaris says the default
|
||||||
|
* is 6, and sprintf on AIX defaults to 6
|
||||||
|
*/
|
||||||
|
if (max < 0)
|
||||||
|
max = 6;
|
||||||
|
|
||||||
|
ufvalue = abs_val (fvalue);
|
||||||
|
|
||||||
|
if (fvalue < 0) {
|
||||||
|
signvalue = '-';
|
||||||
|
} else {
|
||||||
|
if (flags & DP_F_PLUS) { /* Do a sign (+/i) */
|
||||||
|
signvalue = '+';
|
||||||
|
} else {
|
||||||
|
if (flags & DP_F_SPACE)
|
||||||
|
signvalue = ' ';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#if 0
|
||||||
|
if (flags & DP_F_UP) caps = 1; /* Should characters be upper case? */
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if 0
|
||||||
|
if (max == 0) ufvalue += 0.5; /* if max = 0 we must round */
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Sorry, we only support 16 digits past the decimal because of our
|
||||||
|
* conversion method
|
||||||
|
*/
|
||||||
|
if (max > 16)
|
||||||
|
max = 16;
|
||||||
|
|
||||||
|
/* We "cheat" by converting the fractional part to integer by
|
||||||
|
* multiplying by a factor of 10
|
||||||
|
*/
|
||||||
|
|
||||||
|
temp = ufvalue;
|
||||||
|
my_modf(temp, &intpart);
|
||||||
|
|
||||||
|
fracpart = ROUND((POW10(max)) * (ufvalue - intpart));
|
||||||
|
|
||||||
|
if (fracpart >= POW10(max)) {
|
||||||
|
intpart++;
|
||||||
|
fracpart -= POW10(max);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* Convert integer part */
|
||||||
|
do {
|
||||||
|
temp = intpart;
|
||||||
|
my_modf(intpart*0.1, &intpart);
|
||||||
|
temp = temp*0.1;
|
||||||
|
index = (int) ((temp -intpart +0.05)* 10.0);
|
||||||
|
/* index = (int) (((double)(temp*0.1) -intpart +0.05) *10.0); */
|
||||||
|
/* printf ("%llf, %f, %x\n", temp, intpart, index); */
|
||||||
|
iconvert[iplace++] =
|
||||||
|
(caps? "0123456789ABCDEF":"0123456789abcdef")[index];
|
||||||
|
} while (intpart && (iplace < 311));
|
||||||
|
if (iplace == 311) iplace--;
|
||||||
|
iconvert[iplace] = 0;
|
||||||
|
|
||||||
|
/* Convert fractional part */
|
||||||
|
if (fracpart)
|
||||||
|
{
|
||||||
|
do {
|
||||||
|
temp = fracpart;
|
||||||
|
my_modf(fracpart*0.1, &fracpart);
|
||||||
|
temp = temp*0.1;
|
||||||
|
index = (int) ((temp -fracpart +0.05)* 10.0);
|
||||||
|
/* index = (int) ((((temp/10) -fracpart) +0.05) *10); */
|
||||||
|
/* printf ("%lf, %lf, %ld\n", temp, fracpart, index); */
|
||||||
|
fconvert[fplace++] =
|
||||||
|
(caps? "0123456789ABCDEF":"0123456789abcdef")[index];
|
||||||
|
} while(fracpart && (fplace < 311));
|
||||||
|
if (fplace == 311) fplace--;
|
||||||
|
}
|
||||||
|
fconvert[fplace] = 0;
|
||||||
|
|
||||||
|
/* -1 for decimal point, another -1 if we are printing a sign */
|
||||||
|
padlen = min - iplace - max - 1 - ((signvalue) ? 1 : 0);
|
||||||
|
zpadlen = max - fplace;
|
||||||
|
if (zpadlen < 0) zpadlen = 0;
|
||||||
|
if (padlen < 0)
|
||||||
|
padlen = 0;
|
||||||
|
if (flags & DP_F_MINUS)
|
||||||
|
padlen = -padlen; /* Left Justifty */
|
||||||
|
|
||||||
|
if ((flags & DP_F_ZERO) && (padlen > 0)) {
|
||||||
|
if (signvalue) {
|
||||||
|
dopr_outch (buffer, currlen, maxlen, signvalue);
|
||||||
|
--padlen;
|
||||||
|
signvalue = 0;
|
||||||
|
}
|
||||||
|
while (padlen > 0) {
|
||||||
|
dopr_outch (buffer, currlen, maxlen, '0');
|
||||||
|
--padlen;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
while (padlen > 0) {
|
||||||
|
dopr_outch (buffer, currlen, maxlen, ' ');
|
||||||
|
--padlen;
|
||||||
|
}
|
||||||
|
if (signvalue)
|
||||||
|
dopr_outch (buffer, currlen, maxlen, signvalue);
|
||||||
|
|
||||||
|
while (iplace > 0)
|
||||||
|
dopr_outch (buffer, currlen, maxlen, iconvert[--iplace]);
|
||||||
|
|
||||||
|
#ifdef DEBUG_SNPRINTF
|
||||||
|
printf("fmtfp: fplace=%d zpadlen=%d\n", fplace, zpadlen);
|
||||||
|
#endif
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Decimal point. This should probably use locale to find the correct
|
||||||
|
* char to print out.
|
||||||
|
*/
|
||||||
|
if (max > 0) {
|
||||||
|
dopr_outch (buffer, currlen, maxlen, '.');
|
||||||
|
|
||||||
|
while (fplace > 0)
|
||||||
|
dopr_outch (buffer, currlen, maxlen, fconvert[--fplace]);
|
||||||
|
}
|
||||||
|
|
||||||
|
while (zpadlen > 0) {
|
||||||
|
dopr_outch (buffer, currlen, maxlen, '0');
|
||||||
|
--zpadlen;
|
||||||
|
}
|
||||||
|
|
||||||
|
while (padlen < 0) {
|
||||||
|
dopr_outch (buffer, currlen, maxlen, ' ');
|
||||||
|
++padlen;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
static void dopr_outch(char *buffer, size_t *currlen, size_t maxlen, char c)
|
||||||
|
{
|
||||||
|
if (*currlen < maxlen) {
|
||||||
|
buffer[(*currlen)] = c;
|
||||||
|
}
|
||||||
|
(*currlen)++;
|
||||||
|
}
|
||||||
|
|
||||||
|
#if !defined(HAVE_VSNPRINTF) || !defined(HAVE_C99_VSNPRINTF)
|
||||||
|
int vsnprintf (char *str, size_t count, const char *fmt, va_list args)
|
||||||
|
{
|
||||||
|
return dopr(str, count, fmt, args);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if !defined(HAVE_SNPRINTF) || !defined(HAVE_C99_VSNPRINTF)
|
||||||
|
int snprintf(char *str,size_t count,const char *fmt,...)
|
||||||
|
{
|
||||||
|
size_t ret;
|
||||||
|
va_list ap;
|
||||||
|
|
||||||
|
va_start(ap, fmt);
|
||||||
|
ret = vsnprintf(str, count, fmt, ap);
|
||||||
|
va_end(ap);
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifndef HAVE_VASPRINTF
|
||||||
|
int vasprintf(char **ptr, const char *format, va_list ap)
|
||||||
|
{
|
||||||
|
int ret;
|
||||||
|
|
||||||
|
ret = vsnprintf(NULL, 0, format, ap);
|
||||||
|
if (ret <= 0) return ret;
|
||||||
|
|
||||||
|
(*ptr) = (char *)malloc(ret+1);
|
||||||
|
if (!*ptr) return -1;
|
||||||
|
ret = vsnprintf(*ptr, ret+1, format, ap);
|
||||||
|
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
#ifndef HAVE_ASPRINTF
|
||||||
|
int asprintf(char **ptr, const char *format, ...)
|
||||||
|
{
|
||||||
|
va_list ap;
|
||||||
|
int ret;
|
||||||
|
|
||||||
|
va_start(ap, format);
|
||||||
|
ret = vasprintf(ptr, format, ap);
|
||||||
|
va_end(ap);
|
||||||
|
|
||||||
|
return ret;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef TEST_SNPRINTF
|
||||||
|
|
||||||
|
int sprintf(char *str,const char *fmt,...);
|
||||||
|
|
||||||
|
int main (void)
|
||||||
|
{
|
||||||
|
char buf1[1024];
|
||||||
|
char buf2[1024];
|
||||||
|
char *fp_fmt[] = {
|
||||||
|
"%1.1f",
|
||||||
|
"%-1.5f",
|
||||||
|
"%1.5f",
|
||||||
|
"%123.9f",
|
||||||
|
"%10.5f",
|
||||||
|
"% 10.5f",
|
||||||
|
"%+22.9f",
|
||||||
|
"%+4.9f",
|
||||||
|
"%01.3f",
|
||||||
|
"%4f",
|
||||||
|
"%3.1f",
|
||||||
|
"%3.2f",
|
||||||
|
"%.0f",
|
||||||
|
"%f",
|
||||||
|
"-16.16f",
|
||||||
|
NULL
|
||||||
|
};
|
||||||
|
double fp_nums[] = { 6442452944.1234, -1.5, 134.21, 91340.2, 341.1234, 0203.9, 0.96, 0.996,
|
||||||
|
0.9996, 1.996, 4.136, 0};
|
||||||
|
char *int_fmt[] = {
|
||||||
|
"%-1.5d",
|
||||||
|
"%1.5d",
|
||||||
|
"%123.9d",
|
||||||
|
"%5.5d",
|
||||||
|
"%10.5d",
|
||||||
|
"% 10.5d",
|
||||||
|
"%+22.33d",
|
||||||
|
"%01.3d",
|
||||||
|
"%4d",
|
||||||
|
"%d",
|
||||||
|
NULL
|
||||||
|
};
|
||||||
|
long int_nums[] = { -1, 134, 91340, 341, 0203, 0};
|
||||||
|
char *str_fmt[] = {
|
||||||
|
"10.5s",
|
||||||
|
"5.10s",
|
||||||
|
"10.1s",
|
||||||
|
"0.10s",
|
||||||
|
"10.0s",
|
||||||
|
"1.10s",
|
||||||
|
"%s",
|
||||||
|
"%.1s",
|
||||||
|
"%.10s",
|
||||||
|
"%10s",
|
||||||
|
NULL
|
||||||
|
};
|
||||||
|
char *str_vals[] = {"hello", "a", "", "a longer string", NULL};
|
||||||
|
int x, y;
|
||||||
|
int fail = 0;
|
||||||
|
int num = 0;
|
||||||
|
|
||||||
|
printf ("Testing snprintf format codes against system sprintf...\n");
|
||||||
|
|
||||||
|
for (x = 0; fp_fmt[x] ; x++) {
|
||||||
|
for (y = 0; fp_nums[y] != 0 ; y++) {
|
||||||
|
int l1 = snprintf(NULL, 0, fp_fmt[x], fp_nums[y]);
|
||||||
|
int l2 = snprintf(buf1, sizeof(buf1), fp_fmt[x], fp_nums[y]);
|
||||||
|
sprintf (buf2, fp_fmt[x], fp_nums[y]);
|
||||||
|
if (strcmp (buf1, buf2)) {
|
||||||
|
printf("snprintf doesn't match Format: %s\n\tsnprintf = [%s]\n\t sprintf = [%s]\n",
|
||||||
|
fp_fmt[x], buf1, buf2);
|
||||||
|
fail++;
|
||||||
|
}
|
||||||
|
if (l1 != l2) {
|
||||||
|
printf("snprintf l1 != l2 (%d %d) %s\n", l1, l2, fp_fmt[x]);
|
||||||
|
fail++;
|
||||||
|
}
|
||||||
|
num++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
for (x = 0; int_fmt[x] ; x++) {
|
||||||
|
for (y = 0; int_nums[y] != 0 ; y++) {
|
||||||
|
int l1 = snprintf(NULL, 0, int_fmt[x], int_nums[y]);
|
||||||
|
int l2 = snprintf(buf1, sizeof(buf1), int_fmt[x], int_nums[y]);
|
||||||
|
sprintf (buf2, int_fmt[x], int_nums[y]);
|
||||||
|
if (strcmp (buf1, buf2)) {
|
||||||
|
printf("snprintf doesn't match Format: %s\n\tsnprintf = [%s]\n\t sprintf = [%s]\n",
|
||||||
|
int_fmt[x], buf1, buf2);
|
||||||
|
fail++;
|
||||||
|
}
|
||||||
|
if (l1 != l2) {
|
||||||
|
printf("snprintf l1 != l2 (%d %d) %s\n", l1, l2, int_fmt[x]);
|
||||||
|
fail++;
|
||||||
|
}
|
||||||
|
num++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
for (x = 0; str_fmt[x] ; x++) {
|
||||||
|
for (y = 0; str_vals[y] != 0 ; y++) {
|
||||||
|
int l1 = snprintf(NULL, 0, str_fmt[x], str_vals[y]);
|
||||||
|
int l2 = snprintf(buf1, sizeof(buf1), str_fmt[x], str_vals[y]);
|
||||||
|
sprintf (buf2, str_fmt[x], str_vals[y]);
|
||||||
|
if (strcmp (buf1, buf2)) {
|
||||||
|
printf("snprintf doesn't match Format: %s\n\tsnprintf = [%s]\n\t sprintf = [%s]\n",
|
||||||
|
str_fmt[x], buf1, buf2);
|
||||||
|
fail++;
|
||||||
|
}
|
||||||
|
if (l1 != l2) {
|
||||||
|
printf("snprintf l1 != l2 (%d %d) %s\n", l1, l2, str_fmt[x]);
|
||||||
|
fail++;
|
||||||
|
}
|
||||||
|
num++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
printf ("%d tests failed out of %d.\n", fail, num);
|
||||||
|
|
||||||
|
printf("seeing how many digits we support\n");
|
||||||
|
{
|
||||||
|
double v0 = 0.12345678901234567890123456789012345678901;
|
||||||
|
for (x=0; x<100; x++) {
|
||||||
|
snprintf(buf1, sizeof(buf1), "%1.1f", v0*pow(10, x));
|
||||||
|
sprintf(buf2, "%1.1f", v0*pow(10, x));
|
||||||
|
if (strcmp(buf1, buf2)) {
|
||||||
|
printf("we seem to support %d digits\n", x-1);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
#endif /* SNPRINTF_TEST */
|
||||||
|
|
||||||
@@ -1,4 +1,6 @@
|
|||||||
|
|
||||||
|
#include "wconfig.h"
|
||||||
|
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <ctype.h>
|
#include <ctype.h>
|
||||||
@@ -175,4 +177,74 @@ wtrimspace(char *s)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
char*
|
||||||
|
wstrdup(char *str)
|
||||||
|
{
|
||||||
|
assert(str!=NULL);
|
||||||
|
|
||||||
|
return strcpy(wmalloc(strlen(str)+1), str);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
char*
|
||||||
|
wstrndup(char *str, size_t len)
|
||||||
|
{
|
||||||
|
char *copy;
|
||||||
|
|
||||||
|
assert(str!=NULL);
|
||||||
|
|
||||||
|
len = WMIN(len, strlen(str));
|
||||||
|
copy = strncpy(wmalloc(len+1), str, len);
|
||||||
|
copy[len] = 0;
|
||||||
|
|
||||||
|
return copy;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
char*
|
||||||
|
wstrconcat(char *str1, char *str2)
|
||||||
|
{
|
||||||
|
char *str;
|
||||||
|
|
||||||
|
if (!str1)
|
||||||
|
return wstrdup(str2);
|
||||||
|
else if (!str2)
|
||||||
|
return wstrdup(str1);
|
||||||
|
|
||||||
|
str = wmalloc(strlen(str1)+strlen(str2)+1);
|
||||||
|
strcpy(str, str1);
|
||||||
|
strcat(str, str2);
|
||||||
|
|
||||||
|
return str;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
char*
|
||||||
|
wstrappend(char *dst, char *src)
|
||||||
|
{
|
||||||
|
if (!dst)
|
||||||
|
return wstrdup(src);
|
||||||
|
else if (!src || *src==0)
|
||||||
|
return dst;
|
||||||
|
|
||||||
|
dst = wrealloc(dst, strlen(dst)+strlen(src)+1);
|
||||||
|
strcat(dst, src);
|
||||||
|
|
||||||
|
return dst;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
#ifndef HAVE_STRCASECMP
|
||||||
|
int
|
||||||
|
strcasecmp(const char *s1, const char *s2)
|
||||||
|
{
|
||||||
|
while (*s1 && *s2 && (tolower(*s1)==tolower(*s2))) {
|
||||||
|
s1++;
|
||||||
|
s2++;
|
||||||
|
}
|
||||||
|
|
||||||
|
return (tolower(*s1) - tolower(*s2));
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user