10 ms·
Kivy – Open-source Python library for rapid development of applications
- gadders 12y agoApart from the size issues mentioned below, how does this work on Android? Is it better than PhoneGap etc and closer to native apps?
- inclemnet 12y agoIt compiles the python interpreter for android/arm, then bundles this all together in an APK - along with much of the standard library and any extra modules the user wants. It also includes a java bootstrap app that interacts with the system, but does essentially nothing except initialise and display an opengl surface that kivy renders to - along with running the python interpreter on the user's kivy code. This bootstrap is invisible to the user, you don't need to touch the java to use kivy. That said, kivy has some cool sister projects for using the normal java api - pyjnius for accessing java classes directly from python, and more recently plyer to provide a more pythonic wrapper to common things like vibration, sensors etc. (The above is also mostly the same for the ios build process). > Is it better than PhoneGap etc and closer to native apps? I would say more that it is just different, with advantages and disadvantages of its own. It doesn't use native widgets (though it's possible to create and use them in some ways with pyjnius), so it isn't different in this sense.
- vdfs 12y ago2048 app that use Kivy on android https://play.google.com/store/apps/details?id=com.meltingrocks.kivy2048 https://play.google.com/store/apps/details?id=com.meltingroc...
- revskill 12y agoI've tried it, but the resulted built size is huge. How could a Hello World application (built for android) took 15 minutes to build, and about 60MB in size ?? Why not those measurement been told in the main site to tell other to try and use ?
- ayrx 12y agoI'm guessing this is because Kivy includes a Python interpreter and Python libraries in each APK?
- okso 12y agoThe Python interpreter itself is only about 1.5-2 Mo. The issue is mainly related to the libraries.
- anewhnaccount 12y agoThe actual apk can be as small as 5-6mb, but yes it's too big. Ideally common files to all Kivy applications (the python runtime and libraries) would only exist once, but that's a problem people can't quite agree how to solve. https://github.com/kivy/python-for-android/issues/202 https://github.com/kivy/python-for-android/issues/202
- rplnt 12y agoI'm pretty sure apps can have dependencies, so that looks like the best solution. Yes, users will be annoyed, but I think it's still better than various other "hacks".
- eric_bullington 12y agoQT has tried that on Android and it's an exceedingly poor solution. Almost no user will click to download additional files -- they've been (rightfully) conditioned to view this as a suspicious technique. As long as you blacklist unneeded libraries on Kivy, you can get the size down to 5 - 10 MB. I personally don't believe this download size is such a problem for users (many native Java apps are upwards of 5 MB). What is a problem is the start-up time and battery usage, both much harder problems to address. Because they require the Python interpreter, Kivy apps take significantly longer to start-up, and use significantly more battery power than Java apps. I have some hope that Micropython may eventually offer a solution to this for Python on Android, although porting Kivy to Micropython will be a major task.
- daGrevis 12y agoHere's an application my co-worker built using Kivy. https://github.com/aigarius/photoriver https://github.com/aigarius/photoriver
- albertzeyer 12y agoI found this in my logs from 2013 and it looks really nice now. Another example app with Kivy + SQLite: Image Viewer and Organizer, https://github.com/gau-veldt/ImageOrg https://github.com/gau-veldt/ImageOrg This is also interesting: http://libnui.github.io/nui3/ http://libnui.github.io/nui3/ I'm not exactly sure anymore about the relation. Is Kivy based on libnui?
- markdown 12y ago> ImageOrg I see a few files, but no instructions. Isn't kivy supposed to be a GUI building tool? Where is the exe or dmg file?
- inclemnet 12y agoThe user hasn't packaged this into a standalone executable (though this is possible with e.g. pyinstaller). You need to run the ImageOrg.py file with python.
- emmen 12y agoNo, kivy has no relation to libnui.
- meelooo 12y agoKivy looks very nice but NUI is a very different beast (I'm the author). The main difference being that even though NUI is a complete multi-plateform framework that uses OpenGL for rendering, it has a strictly C++ API. If you want to see apps built with NUI I just released reChord: http://bit.ly/rechord http://bit.ly/rechord And also some very nice music apps with NUI: http://intua.net/products/beatmaker2/ http://intua.net/products/beatmaker2/ http://www.whitenoiseaudio.com/apps/genome-midi-sequencer/ http://www.whitenoiseaudio.com/apps/genome-midi-sequencer/ http://www.whitenoiseaudio.com/apps/bleepbox/ http://www.whitenoiseaudio.com/apps/bleepbox/
- albertzeyer 12y agoIn the GitHub description (https://github.com/kivy/kivy https://github.com/kivy/kivy), it says about Kivy: "Open source software library for creating NUI applications, running on Windows, Linux, MacOSX, Android and iOS" I guess that is why I searched for NUI and I probably found your lib. I don't remember that I have heard that term "NUI" before.
- therealmarv 12y agoI think for 2D related apps/games which do not require the native OS UI controls this is a good choice.
- kitd 12y agoNice. I may try this on my daughter who has been asking to get into programming. I remember the buzz I got building simple visual apps in VB. This feels similar.
- bharatkhatri14 12y agoI've always been confused about open-source projects that go big on marketing themselves. Building a good community around open-source projects holds obvious advantages as you'd always need contributors to push the project through its future generations. As far as I can see, Kivy is supported by a group of independent developers. Kivy (as a group) must have spent money in marketing the product, launching developer contests, publishing books on Kivy (I've seen a couple books on Kivy by O'reilly), and other stuff. I'm just curious to know in what other ways, apart from the need to grow the community around your project, does marketing your open-source project help? And is the money put into marketing the project contributed by the creators themselves?
- inclemnet 12y ago> Kivy (as a group) must have spent money in marketing the product I don't think kivy (as a group) does anything except recently the contest, and things like maintaining a g+ account, mailing list, posting on hn or reddit if something intersting happens etc. - were you thinking of anything in particular here? > launching developer contests This was funded entirely from sponsorship, you can see the list on the contest page (http://kivy.org/#contest http://kivy.org/#contest). > publishing books on Kivy (I've seen a couple books on Kivy by O'reilly) Publishers commission books because they think they will make money, not because kivy pays them to - actually, I don't think any of the core developer team have been directly involved in kivy books. > and other stuff Honestly, not really - I can't think of any other expenses except small things like powering the website server. > I've always been confused about open-source projects that go big on marketing themselves. I don't think kivy is really big on marketing itself - if anything, maybe the opposite. I've wondered before if its relatively unknown status (compared to phonegap etc) is at least partly because we don't advertise much, though it may just as well be that more people are interested in html. Things like the developer contest are great to build interest and get the word out that kivy exists, and as you said yourself have obvious advantages in maintaining and growing the community - if this is 'going big' on marketing, I don't think that term is very meaningful.
- thirtman 12y agoI confirm there was no money directly spent on promoting kivy. Most of our communication has been directly with the community, through help on irc/google-groups/SO and other places. We did start to improve communication on twitter/g+/facebook, but it's really on our own time, not paying any agency or specialist of these things. For books, while we were contacted by a few publishers, none of the core-dev authored any, yet. We tried to give a hand, however, reviewing the books when we could, i personnaly reviewed O'Reilly's book, pointing out a few mistakes to the editor, and gave it a good review, as it was, in my opinion, a well written book with very good exemples and explanations. As it seems usual, i got a free book and a little payment for this (that i didn't expect at all when doing it, my motivation was that there was a need for good kivy books). And i agree we should do more, if not on marketing, at least on communication (there are a few markets that kivy can fully or partially cover already, we don't want to limit these options, just help it grow where users want to use it), but users need to know about it, and to easily get a good understanding of what's possible to do with it. We have a lot of recurring questions about that, as well as people discovering us and asking why they didn't heard about us sooner. I do think the community could be way bigger, but we need to adapt the tools we use to communicate, irc works very well up to the hundred of connected users we have, probably less at more, and waste a lot of energy in saying the same things over and over again (although the direct interaction with our users is highly appreciable), SO seems to make reuse of explanations much more common, and is sometime more effective than direct documentation. Anyway, i'm getting away from the point, will cut it there. :)
- __Joker 12y agoAnybody knows of any app built for iOS using Kivy ?
- inclemnet 12y agoThere's a (probably not exhaustive) list at https://github.com/kivy/kivy/wiki/List-of-Kivy-Projects#kivy-apps-in-the-apple-app-store https://github.com/kivy/kivy/wiki/List-of-Kivy-Projects#kivy... .
- r618 12y agoKivy is great, although its bottleneck is in (python)libraries, at least on iOS - for example pygame works like charm (the toolchain compiles transparently to user all the SDL stuff), but numpy is unusable: https://github.com/kivy/kivy/issues/1161 https://github.com/kivy/kivy/issues/1161 https://www.bountysource.com/issues/305883-numpy-for-kivy-ios https://www.bountysource.com/issues/305883-numpy-for-kivy-io...
- JasonFruit 12y agoI have a couple hymnal apps in the Play Store built with Kivy, and reviews suggest that performance is a problem for some people, especially scrolling through long views. I'm in the process of rewriting them using HTML and JavaScript in a WebView. That being said, Kivy is really nice to work with; the documentation is good and it's a well thought-out library. I'd enjoy using it for future apps that don't happen to have long views to scroll through.
- thirtman 12y agoDid you use ListView, or did you roll your own ScrollView managed content? We are sorry about the state of ListView currently, and plan to redesign it soon, it's really not optimal currently, and not offering a very useful interface either, so maybe you could fix you issues just putting a GridLayout in a ScrollView and fill it as needed (i documented a way to do a publisher/consumer using threads on my blog, it's efficient for these kind of things). http://blog.tshirtman.fr/2014/1/14/publisher-consumer-model-in-kivy http://blog.tshirtman.fr/2014/1/14/publisher-consumer-model-...
- JasonFruit 12y agoInitially I used the ListView, but found performance problems on every device. I then rolled my own using a layout in a ScrollView, and it's better, but still troublesome. I'll compare what I've done to what you wrote about and see if I can improve matters.
- MrBra 12y agoWould it be correct to say that Kivy is the Python equivalent for Ruby Shoes? In which aspect the one or the other is more powerful?
- aikah 12y agoI never was able to run it on my computer unfortunatly(mackbook ,bootcamp,windows 7). But it looks great.
- nemesisj 12y agoAnyone tried Kivy for game development? I'm interested in brushing up my Python and was thinking about making a game that could be OpenGL accelerated, and it seemed like a good match.
- thirtman 12y agoYes, you can see examples of games done with kivy in the two contests (kivy.org/#contest), and there are also a few games on the market, it's also interesting to look at kovak's efforts on kivent.org, a 2D game engine built on top of kivy and cymunk, which seems like the way to go for games with a lot of actors.
- nemesisj 12y agoCool, thanks! I'll have a look at that. Does the kivent.org stuff support Tiled?
- inclemnet 12y agoI don't think it does right now, but it should be pretty easy to add this kind of support.
- thirtman 12y agoThere has been at least one user working on it, for kivy, so maybe it'll available soon, either as 3rd party package, or as a PR to either project (though it would probably make more sense on kivent).
- pacofvf 12y agoIs there any plotting library I can use with Kivy?, something of the likes of D3.js (http://github.com/mbostock/d3/wiki/Gallery http://github.com/mbostock/d3/wiki/Gallery)
- jardaroh 12y agomatlibplot is one of the best and most extensive plotting libraries. You also have d3py that is a d3.js implementation in python. Do a google search for python graph or python plot and you will find plenty.
- chadillac 12y agoMessed with Kivy about 6 months ago, while I love what it is, it suffers from PyGame'ism. Yes you can write games and such, but the end result always just feels bloated and performance hungry. I ended up going with Corona (http://coronalabs.com/ http://coronalabs.com/), and it is/was awesome for the game I was building.
- arstudio 12y agoI wrote a Kivy app for a multi-touch table a few years ago as my Masters project in CSE. I appreciated being able to develop on my Mac, run it on the table using Windows, and even got it running on an iPad. Getting the environment set up to deploy to iOS was complex (especially cross compiling non-standard Python libraries), but it has been a few years.