|
Post by vovchik on Jul 13, 2016 21:48:15 GMT 1
Dear all, I modded my BaCon Cairo Messenger to compile properly with Bacon 3.3.1, so it now works OK with my Mint 17. Try clicking on vovmeteo and the other test scripts after unpacking (if you are using 32-bit binaries). Otherwise first compile bcm.bac and then do the clicking). Please let me know whether it works for you. With kind regards, vovchik Attachments:bcm-meteo.tar.gz (69.29 KB)
|
|
|
Post by Pjot on Jul 14, 2016 17:52:00 GMT 1
Thanks vovchik, Impressive! The weather report for my place looks pretty good anyway Regards Peter Attachments:
|
|
|
Post by vovchik on Jul 15, 2016 8:27:44 GMT 1
Dear Peter, Thanks for testing. I am glad that it worked. I assume you compiled for 64 bits. Alex is using Raspberry PI, and I have no idea how X functions there, but it would be nice if it also worked on that platform, too. With kind regards, vovchik
|
|
|
Post by basica on Jul 15, 2016 18:59:28 GMT 1
vovchik, Compiled and worked nicely for me. Thanks. This is a great collection you've made showing how many system and internet items can be shown in an attractive manner on the desktop using cairo. Next, I'll have to display my brain wave patterns on the desktop in 3d, so I can see visually where I often go wrong My best, basica
|
|
|
Post by vovchik on Jul 15, 2016 19:28:16 GMT 1
Dear basica, Thanks. I am glad it compiled and ran as expected. Here is another variation, but it uses GTK/GDK and, optionally, an internal svg for creating the frame and background. I hope it works for you. For proper effect you should install the two fonts in the ttf folder first. With kind regards, vovchik Attachments:notify.tar.gz (54.95 KB)
|
|
|
Post by rikky on Jul 15, 2016 21:08:46 GMT 1
incredebly beautifull, only the "!" is not working here. Obviously by you it is working though. Your example: bcm -c "#fafafafa" -b "#0f0f0ffa" -g r:t -t "<span font='Sans Bold 45' color='white'>Hello!</span>" -d 5 gives a bash: !: event not found also # 9. placement default (200:200), svg box mytext="<span font='Sans Bold 45' color='white'>Bye-Bye!</span>" ./notify_svg -t "$mytext" -a 270.5 gives the same error somehow. I've got absolutely no idea why. Rik.
|
|
|
Post by vovchik on Jul 15, 2016 21:25:39 GMT 1
Dear rikky,
Thanks for pointing that out. In the latest version of cairo, which I now have on my computer, the cairo bit interprets a lot of punctuation symbols as "accelerators" (e.g. & and !), although I do not call the cairo routine with the "_markup_with_acels" bit switched on. I think this is a real cairo bug, and there must be a workaround or patch; I have not (yet) found a way to turn acels off simply or elegantly. I will have a think, but extra parsing and escaping is a real PITA. If you get an idea or solution, please post it.
With kind regards, vovchik
|
|
|
Post by basica on Jul 15, 2016 23:38:32 GMT 1
vovchik, Thanks for posting "notify.tar.gz". I had to add a test for compiling - (my downlevel cairo complained about CAIRO_ANTIALIAS_BEST ) So I added the following to "notify_svg.bac" after line 333 - 333 cairo_set_operator(cr, CAIRO_OPERATOR_SOURCE)
IF (cairo_version() >= CAIRO_VERSION_ENCODE(1,12,0)) THEN CAIRO_ANTIALIAS_BEST = 6 ELSE CAIRO_ANTIALIAS_BEST = 0 END IF
All working nicely and best regards, basica
|
|
|
Post by alexfish on Jul 16, 2016 1:12:37 GMT 1
Hi Vovchik & Others IE BasicA , and new Members, Hi-light with capitals. I still be here. At present still reading. as in the Questions as to Why things are not connecting ...
When I see the bits . as in OK . try this .. without the Terse .. it works fine.. Here ... So What..
Then I will for sure. give a Reply, Raspberry Wise.
BR Alex
|
|
|
Post by greco558 on Jul 16, 2016 4:00:48 GMT 1
Hi vovchik,
I downloaded the file from your first post , and it compiled fine under tahrpup.
clicked on several scripts everything ran fine.
When I have some time I wiil have a look at your code and scripts, I always learn something from you.
Best, John
|
|
|
Post by alexfish on Jul 16, 2016 9:34:41 GMT 1
Hi Vovchik
Well.. Here on the Raspy the Dammed !!!!!!!! is acting as expected .. thought I would try multiple calls to history ! *** ,
eventual result = the expected , Reboot . twice and everything back to normal .. the browser hang was spectacular. esp when signed in and then trying to search for the ! glyph
Suppose will have to relegate the ! or eradicate it <fix it> somehow.
Added . sort of obvious . tested the gdk version as well . same as the original
A neat & terse bit of coding . Many Thanks
+
BR Alex
|
|
|
Post by vovchik on Jul 16, 2016 12:33:02 GMT 1
Dear Alex (and basica, rikky, Peter and John), Thanks. The "!" problem is also "&" problem. And it surfaced with the new cairo, where it assumes that those things are accelerators. In the cairo markup functions there are two variations _markup and _markup_with_acels. Since I specify the former, I do not know why it is coughing when it encounters those bloody chars. I wonder whether there is a flag ato set somewhere to tell cairo to behave itself. With kind regards, vovchik
|
|
|
Post by alexfish on Jul 16, 2016 12:43:11 GMT 1
Hi Vovchik
This Bash ..Terminal problem . Not Cairo..or any other bug
Upto now only cure on the Raspberry for the "!" is to pass the backslash "\" before it
IE "\!"
Then in opt parse function text section
Can then use the replace.
Suppose this can be mentioned in the help
the bit
CASE "t" msg_text$ = CHOP$(ARGUMENT$) msg_text$ = REPLACE$(msg_text$, "&", "&") msg_text$ = REPLACE$(msg_text$, CHR$(92), "")
and the code to test
./bcm -c "#fafafafa" -b "#0f0f0ffa" -g r:t -t "<span font='Sans Bold 45' color='white'>Hello\!</span>" -d 5
forgot to mention . now looking to see what terminal emulators are available for the Raspberry .. have check the GTK vte . as demo'd in hug add on the results are the same. hence that one be out .. BR Alex
|
|
|
Post by vovchik on Jul 16, 2016 13:01:45 GMT 1
Dear basica,
Thanks for your mod. If I use it as is I get an error (that is a defined constant in later cairo versions).
This works fine:
' basica's mod for old cairo IF (cairo_version() >= CAIRO_VERSION_ENCODE(1,12,0)) THEN cairo_set_antialias(cr, CAIRO_ANTIALIAS_BEST) ELSE cairo_set_antialias(cr, 0) END IF
replacing line 333:
cairo_set_antialias(cr, CAIRO_ANTIALIAS_BEST)
With kind regards, vovchik
|
|
|
Post by vovchik on Jul 16, 2016 13:48:53 GMT 1
Dear Alex, Good that you discovered the shell problem with certain chars. What about this thing? simple terminalI will look at it now. With kind regards, vovchik
|
|