WebGadget Editable

Linux specific forum
User avatar
Progi1984
Addict
Addict
Posts: 806
Joined: Fri Feb 25, 2005 1:01 am
Location: France > Rennes
Contact:

WebGadget Editable

Post by Progi1984 »

Hi,
A small question : Is it possible under Linux to edit the WebGadget or to set Editable the WebGadget ?

Thank you
Trond
Always Here
Always Here
Posts: 7446
Joined: Mon Sep 22, 2003 6:45 pm
Location: Norway

Post by Trond »

Apart from the minor problem that it's not possible to even create a WebGadget, then yes. However, you don't have the nice features of getting the contents of the page afterwards, so it's quite useless.
User avatar
Progi1984
Addict
Addict
Posts: 806
Joined: Fri Feb 25, 2005 1:01 am
Location: France > Rennes
Contact:

Post by Progi1984 »

Oh sorry i believed that the Webgadget is crossplatform !
freak
PureBasic Team
PureBasic Team
Posts: 5948
Joined: Fri Apr 25, 2003 5:21 pm
Location: Germany

Post by freak »

It is corossplatform. Works perfectly here on all OS.

Trond: maybe Fred's solution here helps you ?
http://www.purebasic.fr/english/viewtopic.php?t=26549

(basically he had a libplc4.so in two places of different versions, which caused the trouble)

Progi1984: It is possible to put the gadget in design mode i think, but it is not easy.
Basically there is a XPCOM model (similar to Windows COM, but not fully) with which to do it.
XPCOM is designed for use in C++, that is why it is hard to access from PB.
quidquid Latine dictum sit altum videtur
Trond
Always Here
Always Here
Posts: 7446
Joined: Mon Sep 22, 2003 6:45 pm
Location: Norway

Post by Trond »

freak wrote:Trond: maybe Fred's solution here helps you ?
http://www.purebasic.fr/english/viewtopic.php?t=26549
Well, he only gives the problem (two libplc4.so), not a solution. I tried to delete the one in /usr/lib, but that made Epiphany stop working, which was not an option so I didn't test further. (My Epiphany is compiled with Firefox back-end.)
Progi1984: It is possible to put the gadget in design mode i think, but it is not easy.
Basically there is a XPCOM model (similar to Windows COM, but not fully) with which to do it.
XPCOM is designed for use in C++, that is why it is hard to access from PB.
As long as you can set the address, simply create a file with this inside: "<html><body contenteditable=true>Hello</body></html>" and load that file in the WebGadget.
Trond
Always Here
Always Here
Posts: 7446
Joined: Mon Sep 22, 2003 6:45 pm
Location: Norway

Post by Trond »

So it doesn't work in Xubuntu Dapper and Zenwalk. I just tested more with Ubuntu Feisty and it doesn't work. I also tested with Fedora Core, there it actually does work (!), except that the second parameter of WebGadgetPath() must be set to the path to the mozilla components, even though this path is the same as the path for the embedding library (should be unnecessary according to the manual), or the WebGadget command gives and invalid memory access.
freak
PureBasic Team
PureBasic Team
Posts: 5948
Joined: Fri Apr 25, 2003 5:21 pm
Location: Germany

Post by freak »

Sounds just like the usual Linux distribution & package mess to me.

The embedding library is loaded and called according to my best interpretation of the
(not so helpful) documentation about it and as i said, it works like a charm here.
I don't know what else to do really. Everybody does his own thing here it seems,
and none of them are compatible.

The best thing to do would probably be to compile our own version of the gecko
engine and including it with PB programs, thus adding yet another redundant
copy of the same thing (but slightly different).
This would solve the problem for us, but increase the overall mess.

Software freedom is great... but please, some standardisation wouldn't hurt.
quidquid Latine dictum sit altum videtur
chen
Enthusiast
Enthusiast
Posts: 338
Joined: Fri Dec 23, 2005 2:20 pm
Location: Quebec, Canada
Contact:

Post by chen »

freak wrote:Sounds just like the usual Linux distribution & package mess to me.

The best thing to do would probably be to compile our own version of the gecko
engine and including it with PB programs, thus adding yet another redundant
copy of the same thing (but slightly different).
Yesterday I was testing an example with several gadgets one of them Webgadget,
Of course the whole example failed. Looking some help in the forum and
testing I got the example to run... but the WebGadget does not appear..

This kind of things make me feel PB for Linux is far from PB from Windows..
I know that in Linux is hard to standarized everything, but for me PB must
create something that make our lifes easy... it does not matter if some
redundancy comes up.
Brice Manuel

Post by Brice Manuel »

I have noticed this too. I have a couple of cross-platform e-book programs that need it, but it does not function on a default install of the latest version of Ubuntu.
This kind of things make me feel PB for Linux is far from PB from Windows..
In this case, they are kinda the same. On Windows, PB will not use the standard atl.dll that is installed on Windows. On Windows if you use the web gadget with PB, you have to distribute PB's atl.dll with you app in the apps directory to get the web gadget to work. Other languages with web gadgets like, BlitzPlus, BlitzMax, IBasic, IBasic Pro, EBASIC, Aurora, (and I could continue down a long list) do not have this issue and do not require a DLL to be distributed just for web gadget support. Apps haven't had to do this since IE 4.0 introduced Active Desktop to Windows 95. Unfortunately, PB doesn't follow the norm, and for web gadgets, we have to distribute a dll just so the gadget will work.

I am going to take a guess that for the Linux issue PB is doing something that is NOT the norm, but I am not familiar enough with Linux to be able even guess the problem. As it is PB is more advanced than many competing Linux based indie languages. If I have to learn to live without web gadgets, I am not happy about it, but it is a tradeoff we will have to learn to live with.
Last edited by Brice Manuel on Fri Apr 27, 2007 10:50 am, edited 1 time in total.
Trond
Always Here
Always Here
Posts: 7446
Joined: Mon Sep 22, 2003 6:45 pm
Location: Norway

Post by Trond »

Freak, what distro is "here"?
freak
PureBasic Team
PureBasic Team
Posts: 5948
Joined: Fri Apr 25, 2003 5:21 pm
Location: Germany

Post by freak »

OpenSuse 10.2 for me and Ubuntu for Fred.
Fred had the dublicated library problem but other than that it works there too.
quidquid Latine dictum sit altum videtur
nrasool
User
User
Posts: 28
Joined: Tue Apr 26, 2005 9:55 am

Post by nrasool »

I use the latest ubuntu disto, webgadget wasn't working, until Walker and ts-soft helped me out, see http://www.purebasic.fr/english/viewtopic.php?t=26549

If the webgadget is not working for you, try checking that thread :)

Kind Regards
Post Reply