Re: plasmate 0.1alpha1
On Tue, Feb 9, 2010 at 6:21 PM, Aaron J. Seigo ase...@kde.org wrote: http://plasma.kde.org/plasmate-0.1alpha1.tar.bz2 please test the tarball and report any failures. 404 not found for the tarball. ___ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel
Re: how can I access DataEngines from JavaScript in the Web Plasmoids?
On Sun, Jan 3, 2010 at 11:39 PM, Aaron J. Seigo ase...@kde.org wrote: and probably give poor, or even incorrect, results. what exactly are you wanting to accomplish? HTML5 storage would allow making apps such as todo lists, note taker, or whatever that could make use of a db without the need of writing or using a data engine. Not perfect but nice. ___ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel
Re: how can I access DataEngines from JavaScript in the Web Plasmoids?
On Mon, Jan 4, 2010 at 3:45 PM, Chani chan...@gmail.com wrote: HTML5 storage would allow making apps such as todo lists, note taker, or whatever that could make use of a db without the need of writing or using a data engine. Not perfect but nice. kinda sounds like data you'd want to access through akonadi...? Could be, but the thing would be to use web technologies only. ___ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel
Re: how can I access DataEngines from JavaScript in the Web Plasmoids?
On Mon, Jan 4, 2010 at 4:23 PM, Aaron J. Seigo ase...@kde.org wrote: On January 4, 2010, Patrick Aljord wrote: Could be, but the thing would be to use web technologies only. if i understand it correctly, the request is for easy access to data persistence (separate from configuration data), correct? Correct. The reason I'm insisting (and sorry if I sound annoying) it's because when it comes to the web plasmoid at least, it makes sense to make use of web technologies as much as possible IMO, it's also easier for portability (if I want to reuse the widget with apple dashboard widgets or windows widgets). Also, html5 storage is not a toy, it's used by google on the iphone for example and will get bigger with the time. But yeah, having data persistence would be good even if we're not using html5 storage. It looks like it's qt bug though https://bugs.webkit.org/show_bug.cgi?id=28682 and maybe we'll get html5 storage for free with the next qt version :) ___ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel
Re: how can I access DataEngines from JavaScript in the Web Plasmoids?
On Mon, Jan 4, 2010 at 6:10 PM, Aaron J. Seigo ase...@kde.org wrote: relative to what we're doing, it is. i somehow doubt it will work at all with remote widgets, for instance. Ok I didn't think about remote widgets. Point taken. in particular, it's pretty evident that html5 storage has been designed for use in web browsers. it's really that specific. because we don't use html anywhere else, right? *sigh* the people looking after the web standards are truly myopic. I just assumed that the web plasmoid was done to write browser or web apps in plasmoids. but if the world goes all in on the web technology boat 100% we will be in a world of pain as time goes on. I don't think so, stuff like canvas, web sockets, fast js engines, webgl or even native client will turn the browser into a powerful platform not only for traditional web apps but I guess time will tell. thoughts/ideas/improvements/refinements? I like your version with no namespace pollution better: var storage = new Storage storage.document = noteId() storage.store(text, noteText()) Interestingly, the couchdb guys wrote an API on top of html5 storage to turn it into a key value store, it looks like this in JS: var jsondb = new JSONDB(dbname); jsondb[some_key] = {some:json}; jsondb.forEach(function(key, value) { // in order traversal }); jsondb.forEach(function(key, value) { // reverse order traversal }, { descending:true }); jsondb.forEach(function(key, value) { // inorder traversal, // starting from startkey, // ending with endkey // you can use throw() to stop traversal },{ startkey:a, endkey:z }); jsondb.forEach(function(key, value) { // reverse order traversal, starting from startkey // you can use throw() to stop traversal },{ startkey:z, descending:true }); // delete a btree JSONDB.drop(dbname); http://github.com/jchris/WebWorkerStorage/blob/ba716338d2627377fb1369193d7bf5dcf96b7ddd/JSONDB.md ___ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel
Re: how can I access DataEngines from JavaScript in the Web Plasmoids?
I saw you committed your changes, looks cool. I used to test my plasmoids in firefox with firebug but now using window.plasmoid makes the whole thing fail. It would be cool if there was a way to start the webkit web inspector from the web plasmoid. Any idea if that is possible? Thanks in advance, Pat ___ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel
Re: how can I access DataEngines from JavaScript in the Web Plasmoids?
On Sun, Jan 3, 2010 at 9:18 PM, Aaron J. Seigo ase...@kde.org wrote: anything else? Maybe this is not related but html5 storage doesn't seem to work, I get this error when starting the plasmoid: Failed to open the database on disk. This is probably because the version was bad or there is not enough space left in this domain's quota (I do have plenty of disk space) This is the example I used: http://webkit.org/demos/sticky-notes/ you can just copy and past the code of that page into main.html of a web plasmoid. It would be good also if when restarting plasma, it would remember what was in the database. ___ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel
Re: how can I access DataEngines from JavaScript in the Web Plasmoids?
On Sun, Jan 3, 2010 at 10:54 PM, Patrick Aljord patc...@gmail.com wrote: On Sun, Jan 3, 2010 at 9:18 PM, Aaron J. Seigo ase...@kde.org wrote: anything else? Maybe this is not related but html5 storage doesn't seem to work, I get this error when starting the plasmoid: Ok, I tested in arora and I get the same error so it's probably Qt related. It would be cool to have that though, it would enable to write real desktop web app like adobe air, I know I can use data engines but having that would be great too and easier for web devs. ___ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel
Re: how can I access DataEngines from JavaScript in the Web Plasmoids?
On Fri, Jan 1, 2010 at 8:56 PM, Aaron J. Seigo ase...@kde.org wrote: requires today's trunk for everything to work perfectly enjoy. thanks, today's trunk is what will become kde 4.4 right? Or has that moved to a branch already? ___ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel
Re: Review Request: make use of setClickMessage in the source textedit
On Mon, Aug 17, 2009 at 8:56 AM, Sebastian Küglerse...@kde.org wrote: /trunk/kdereview/plasma/applets/translatoid/ktranslatoid.cpp http://reviewboard.kde.org/r/1337/#comment1369 Your text here sounds nicer IMO Ok, I changed the text to that, I'm sending it here because reviewboard is down. Cheers, Pat ___ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel
Re: Review Request: Simplest Image Hosting support for pastebin applet
This is kind of unrelated but wouldn't it be a good thing to turn the upload backends into a plasma data engine? I can see other plasmoids making use of uploading pics and even kde apps like ksnapshot but I have no idea whether kde apps can make use of plasma engines. -Pat ___ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel
Re: [PATCH] Adds posting private picture to imagebin.ca from the pastebin plasmoid
On Sat, Aug 8, 2009 at 1:56 PM, Chani chan...@gmail.com wrote: kompare won't load the diff for some reason... I used the techbase tutorial here http://techbase.kde.org/Contribute/Send_Patches#Creating_a_Simple_File_Patch and used that command: svn diff --diff-cmd diff --extensions -u -p ___ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel
Re: [PATCH] Adds posting private picture to imagebin.ca from the pastebin plasmoid
http://reviewboard.kde.org/r/1248/ here is the diff with the imagebinPrivacy always as int. ___ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel
Re: [PATCH] Adds posting private picture to imagebin.ca from the pastebin plasmoid
oops, forgot to hit the publish button, should be up now http://reviewboard.kde.org/r/1248/ On Sun, Aug 9, 2009 at 3:00 PM, Patrick Aljordpatc...@gmail.com wrote: http://reviewboard.kde.org/r/1248/ here is the diff with the imagebinPrivacy always as int. ___ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel
[PATCH] Adds posting private picture to imagebin.ca from the pastebin plasmoid
Hey all, This is my first patch, it just adds posting private picture to imagebin.ca from the pastebin plasmoid as the title says, it needs to be applied from kdeplasma-addons, hope it works for you. Cheers, Pat Index: applets/pastebin/pastebin.cpp === --- applets/pastebin/pastebin.cpp (revision 1008583) +++ applets/pastebin/pastebin.cpp (working copy) @@ -463,6 +463,15 @@ void Pastebin::createConfigurationInterf QString imageshackURL = cg.readEntry(imageshack, http://imageshack.us;); uiServers.imageshack-setText(imageshackURL); + +uiConfig.textServer-setCurrentIndex(m_textBackend); + +QWidget *serversoptions = new QWidget(); +uiServersOptions.setupUi(serversoptions); +int imagebinPrivacy = cg.readEntry(imagebinPrivacy, 0).toInt(); +uiServersOptions.imagebinPrivacy-setCurrentIndex(imagebinPrivacy); + +parent-addPage(serversoptions, i18n(Servers Options), Applet::icon()); } void Pastebin::configAccepted() @@ -477,6 +486,8 @@ void Pastebin::configAccepted() QString imagebincaURL = uiServers.imagebinca-text(); QString imageshackURL = uiServers.imageshack-text(); +int imagebinPrivacy = uiServersOptions.imagebinPrivacy-currentIndex(); + cg.writeEntry(TextBackend, textBackend); cg.writeEntry(ImageBackend, imageBackend); cg.writeEntry(HistorySize, historySize); @@ -486,6 +497,8 @@ void Pastebin::configAccepted() cg.writeEntry(imagebinca, imagebincaURL); cg.writeEntry(imageshack, imageshackURL); +cg.writeEntry(imagebinPrivacy, imagebinPrivacy); + setTextServer(textBackend); setImageServer(imageBackend); setHistorySize(historySize); Index: applets/pastebin/backends/imagebinca.cpp === --- applets/pastebin/backends/imagebinca.cpp(revision 1008583) +++ applets/pastebin/backends/imagebinca.cpp(working copy) @@ -35,8 +35,8 @@ ImagebinCAServer::ImagebinCAServer(const KConfigGroup config) : PastebinServer() { +m_privacy = config.readEntry(imagebinPrivacy, 0); m_server = config.readEntry(imagebinca, http://imagebin.ca;); - m_boundary = --; m_boundary += KRandom::randomString(42 + 13).toAscii(); } @@ -168,10 +168,17 @@ void ImagebinCAServer::post(const QStrin addPair(tags, plasma); url.addQueryItem(tags, plasma); -addPair(adult, f); -url.addQueryItem(adult, f); +if(m_privacy == 0){ + adult = f; +} else { + adult = t; +} + +addPair(adult, adult); +url.addQueryItem(adult, adult); addFile(f, content); + finish(); _data.clear(); Index: applets/pastebin/backends/imagebinca.h === --- applets/pastebin/backends/imagebinca.h (revision 1008583) +++ applets/pastebin/backends/imagebinca.h (working copy) @@ -42,6 +42,8 @@ public: void finish(); bool addPair(const QString name, const QString value); bool addFile(const QString name,const QString path); +QString adult; +QString m_privacy; protected: QByteArray m_buffer; Index: applets/pastebin/pastebin.h === --- applets/pastebin/pastebin.h (revision 1008583) +++ applets/pastebin/pastebin.h (working copy) @@ -23,6 +23,7 @@ #include backends/backends.h #include ui_pastebinConfig.h #include ui_pastebinServersConfig.h +#include ui_pastebinServersOptionsConfig.h #include KDE/KIO/TransferJob #include KDE/KIO/Job @@ -153,6 +154,7 @@ private: Ui::pastebinConfig uiConfig; Ui::pastebinServersConfig uiServers; +Ui::pastebinServersOptionsConfig uiServersOptions; }; K_EXPORT_PLASMA_APPLET(pastebin, Pastebin) Index: applets/pastebin/CMakeLists.txt === --- applets/pastebin/CMakeLists.txt (revision 1008583) +++ applets/pastebin/CMakeLists.txt (working copy) @@ -1,5 +1,8 @@ project(plasma-pastebin) +cmake_minimum_required(VERSION 2.6) +find_package(KDE4 REQUIRED) + set(pastebin_SRCS backends/server.cpp backends/pastebinca.cpp @@ -10,6 +13,7 @@ set(pastebin_SRCS kde4_add_ui_files(pastebin_SRCS pastebinConfig.ui) kde4_add_ui_files(pastebin_SRCS pastebinServersConfig.ui) +kde4_add_ui_files(pastebin_SRCS pastebinServersOptionsConfig.ui) kde4_add_plugin(plasma_applet_pastebin ${pastebin_SRCS}) target_link_libraries(plasma_applet_pastebin ${KDE4_PLASMA_LIBS} ${KDE4_KDEUI_LIBS} ${KDE4_KIO_LIBS}) Index: applets/pastebin/pastebinServersOptionsConfig.ui === --- applets/pastebin/pastebinServersOptionsConfig.ui(revision 0) +++ applets/pastebin/pastebinServersOptionsConfig.ui(revision 0) @@ -0,0 +1,49 @@ +?xml version=1.0 encoding=UTF-8? +ui version=4.0 + classpastebinServersOptionsConfig/class + widget class=QWidget
Re: [PATCH] Adds posting private picture to imagebin.ca from the pastebin plasmoid
Thanks to all for your comments. I haven't coded anything in C++ for at least 3 years so I guess it shows :) I'll send the patch with your suggestions tomorrow, in the meantime here is the screenshot http://imagebin.ca/view/fyaoR7T.html ___ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel
Re: need help on my javascript plasmoid
On Wed, Jul 22, 2009 at 11:24 PM, Aaron J. Seigoase...@kde.org wrote: On Wednesday 22 July 2009, Patrick Aljord wrote: xmlUrl = new QUrl( http://ws.audioscrobbler.com; ); http = new QHttp; * do not use QHttp * the JS bindings do not have support for fetching things via KIO; note that this represents a security issue that would need to be address _FIRST_ before being added to the simple JS bindings * the simple JS bindings for plasma are NOT INTENDED to be complete bindings for a number of reasons (security, easy of learning, etc) * a full set should hopefully appear in qt 4.4 (richard, did you ever find time to fiddle with that while at GCDS?) * what, precisely, are you trying to accomplish? (just to understand the use case properly) -- Hey Aaron, Thanks for your answer. I'm trying to fetch an xml file from a website that has an xml api and display the results in my plasmoid. Also, I understand the security issues so I'm curious if the fact that it's possible in ruby and python could also give security issues? Thanks in advance, Pat ___ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel
Re: need help on my javascript plasmoid
On Thu, Jul 23, 2009 at 2:28 AM, Aaron J. Seigoase...@kde.org wrote: On Thursday 23 July 2009, Patrick Aljord wrote: Thanks for your answer. I'm trying to fetch an xml file from a website that has an xml api and display the results in my plasmoid. will you be parsing the xml before displaying it in some custom manner? (just wondering what all would be needed to be added to make this easy to accomplish) Yes I would be parsing the xml before displaying, that would be useful to show a feed to though for that I could use a plasma engine I guess. It would be good to be able to download and parse xml and json (well json is easy with JS). And even better, also being able to POST http request. That way we'd be able to interact with most web api (eg twitter, wikipedia, feeds etc). ruby and python are better in that regard, but otherwise (given today's runtime envs for each) are capable of far too many I think right now I could write a ruby script that execute File.rm_f('~'), upload it on kde-apps and people would be able to install that directly from the desktop, no? ___ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel
Re: need help on my javascript plasmoid
On Thu, Jul 23, 2009 at 12:36 PM, Aaron J. Seigoase...@kde.org wrote: I think right now I could write a ruby script that execute File.rm_f('~'), upload it on kde-apps and people would be able to install that directly from the desktop, no? yes. not great, i know. Maybe we could do one of the following for now: a) put a warning when the user install a non JS plasmoid from GHNS b) put a system on kde-apps.org where people could flag the plasmoids as secure or not. Only the one who have been flagged secure by X user could be installable on GHNS I guess it's too late for kde 4.3, especially b). ___ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel
Re: need help on my javascript plasmoid
Another feature that would be cool for JS plasmoids (and all scripted plasmoids in general), the possibility for plasmoids to update automatically like firefox and chrome extensions (http://dev.chromium.org/developers/design-documents/extensions/autoupdate), that could be done by adding an update_url to plasmoids metadata.desktop file :) Then again plasma devs would need to flag the update as OK first before the plasmoids updates automatically unless plasmoids are not downloaded from kde-apps.org, maybe when installing a plasmoid from a host, the user would have to confirm he/she trusts that hosts so that future updates may apply automatically. ___ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel
Re: Prospective costs of the 3rd Plasma meeting (Tokamak3) - part 2
On Thu, Jul 23, 2009 at 9:32 PM, Chanichan...@gmail.com wrote: it seems the costs for zurich and geneva are the same. is there any reason to pick one airport over the other, or should I flip a coin? ;) Geneva seems to be closer http://maps.google.com/maps?f=dsource=s_dsaddr=gen%C3%A8ve+suissedaddr=randa+suisse+to:zurich+suissehl=engeocode=mra=lssll=46.331775,7.006615sspn=1.105621,2.90863ie=UTF8t=hz=8 ___ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel
need help on my javascript plasmoid
Hey all, I've been following the Getting Started tutorial on techbase and it works great. Since then, I've been trying to use QHttp and other Qt classes in my main.js file but the plasmoid fails. I'm trying to download an xml file such as in this amarok script example: http://amarok.kde.org/forum/index.php?topic=17084.0 Something like that: Importer.loadQtBinding( qt.core ); Importer.loadQtBinding( qt.xml ); xmlUrl = new QUrl( http://ws.audioscrobbler.com; ); http = new QHttp; Any idea why it fails? By the way, how do I get any debugging? When I do plasmoidviewer . I just get the plasmoid with the Script initialization failed message, nothing more. Thanks in advance Pat ___ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel
Re: need help on my javascript plasmoid
On Wed, Jul 22, 2009 at 3:03 AM, Marco Martinnotm...@gmail.com wrote: in amarok js bindings are complete and autogenerated. for now in plasma hey are just a tiny subset and you can call only stuff explicitly exported by libplasma probably in the future we will have complete bindings too Ok thanks for the info, that kinds of limits a lot what can be done with JS, I hope it will improve soon. Do you know whether the ruby and python engines are limited in the same way too? ___ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel