Showing posts with label kivy. Show all posts
Showing posts with label kivy. Show all posts

Monday, 15 August 2016

Programming : My Thoughts on Kivy

About a year ago, I had to work on Python, suddenly and without warning.  And though I had tinkered with python I neither listed it in my arsenal of programming languages nor thought myself conversant enough in it to deliver a product.  But the powers that be said "he's the linux guy, this is python, we don't want it on Windows, give it him".

So there I was, Python on the Linux server and Python on the Android phone... Two parts of the same project, and they needed a nice UI.

Now I don't know Qt at all, I've used it, never been terribly impressed (though that opinion is for another post and is highly subject to change) with the look of it.  So I set about looking for alternatives.

The alternative I found, which worked best for me, was Kivy.

I found the syntax a little awkward, and the actual creation of the recipe for the WI was very awkward at times, finding what inherited where being the main problem, it was a little.  Well it was a little counter intuitive to say the least, but it worked.

And the product went out there looking black and sleek and cool, and it was on everyone's Samsung smart phone at the launch meeting, and I was quite proud I'd managed it, and Kivy was the key in that delivery.

It has been a year since I created that application, a year of waiting for any feedback, it was a demanding time to get stuff floated and out to users.  I hope they liked it, I certainly did.

Android - Python - Kivy... Pretty much my go-to platform for Android development.

Wednesday, 9 September 2015

Remember Remember to Blog in September

Sorry I've been away so long, but I've been very very busy, in the office I've had a paradigm shift in my projects, away from coaxing old C# systems and writing little C++ items to developing for Android.

I've therefore had to set up, and document, a whole manner of working with a new set of devices on an OS most of the folks in my office don't want to acknowledge, no not Android... Linux... They line Android... But detest and hate seeing Linux.

Yes, yes I know Android is Linux, and I know you know... But you tell some of the folks in my office, and the ones who don't have an opinion generally have an iPhone stuck to their ear.

So, developing for Android... I must have been doing Java eh?... Nope... Remember I said I was into Python, well I've been developing Python for Android, I've learned the languages, got to grips with Kivy and used buildozer to create my APK's for distribution to the devices.

I've dabbled with PyJNIus as well as other Android API libraries.

I will be bringing some tutorials to these pages about all this, once I've gotten the project itself completed.

My current challenge is animation of the active pages within the Application with Kivy.

Thursday, 13 August 2015

I'm into Python

This week has been an interesting week for me, as I have, for the first time in about three years, began to learn the ins and outs of a new programming language.

This language is Python.  I've heard a lot about python, it's use at google, it's use by those who are on the sharp end of internet based development, but whom want to remain serious programmers.

Now, of course, I'm an old style programmer, and I like my code to communicate to me exactly what it's doing, so the first problem I've had with Python is it's use of white space as code flow control.  This is perhaps my biggest bug bare with the language, it totally grates me, and there are ways around it, using perhaps a semi colon to close a class, or an if statement, or simply to indicate that the current stanza/block of code is about to end, rather then using indentation to indicate this.

This particular problem is put into great focus on Python for windows, when loading Idle (the IDE supplied) and it constantly starts to moan about unexpected uses of spaces or indentation... You can literally pull your hair out over this, but that's a bug in that editor not the language.  The language just shows up the problem.

The power of the language though is strong, string editing, numerics, you have a C power straight out of the box, exploring the libraries like urllib and you have extremely simple (2 lines of code) methods to download files from the internet.

Within 200 lines of code I had a working application, which would trawl a website following all the links and listing them.  It's clearly very powerful and not as I had feared a toy language.

One frustration is getting a GUI working, there are perhaps too many options and nothing solid to follow in order to get an interface running.

I'll keep you posted, perhaps I'll come back with some Python code soon enough.