Showing posts with label programming. Show all posts
Showing posts with label programming. Show all posts

Sunday, February 15, 2015

Andorid Error : java.lang.NoSuchMethodError: android.View.getMinimumHeight

So I got reports of the error from my Play Store for my app Message Counter.

java.lang.NoSuchMethodError: android.View.getMinimumHeight

In the new build, I had implemented a custom view that reads the min width and height from the xml declaration. The app was working on all the devices that I test. However I did notice that the reports were made from Android devices Version 4.0 or below. Further digging and I found the below solution.

getMinimumHeight() is available in API 16+. 
Use android.View.getSuggestedMinimumHeight() instead

It appears that ImageView.getMaxHeight() is also API 16+. Sadly I could not find any alternatives for this one.

Message Counter on Google Play

Wednesday, December 03, 2014

Message Counter 3.0 Beta


Material Love gets extended to Message Counter, after Random Contact. A fresh coat of paint, a new icon and use of some Material Design Principles is a start for the Beta version. This version is code named "Talisman" which follows "Silversun" and "Silvermoon". The updated code is available in GitHub as well.

As per Google Play regulations, only members of a test community are able to test these apps. So the community link is https://plus.google.com/communities/110966372903178356479.

From a technical standpoint, support has been added for AppCompat libraries, replaced ActionBar with a Toolbar. Using Toolbar should extend the experience to users with API less than 11 (Honeycomb). Use of padding, vibrant colors and card view are highlights of this build.

The first thing you will notice from the screenshot below is the use of Cards and a redesigned Counter screen. This will be the "hero screen" for the app.


Note that this is a work in progress and there may be some bugs or issues and do send them in. You can post them in the community or raise issues in the GitHub page for the project.

https://github.com/midhunhk/message-counter

Sunday, June 08, 2014

RoundedImageView in Android


The contact picture as it appears in Google+ inside a circle was part of the redesigned Random Contact app at the play store.

The solution was to create a custom View "RoundedImageView". Developed with help from stackoverlow.com, the custom view is released as an open source component that anyone can reuse.

RoundedImageView usd in Random Contact app
The RoundedImageView extends android.widget.ImageView and basically applies a circular mask over the image by overriding the onDraw() method.

This file is a part of the ae-apps-library project.

Source for RoundedImageView at https://github.com/midhunhk/ae-apps-library/blob/master/library/AeAppsLibrary/src/com/ae/apps/common/views/RoundedImageView.java

Thursday, November 21, 2013

Design evolution of Random Contact app

Background
Just this week I published an app on Google Play Store called Random Contact. It all started when I was learning the Android Contacts API. I wanted to make an app myself that made use of the Contacts API so that I could learn and see it working in a real environment. Especially as I had a Google Nexus S, it was even more an incentive to develop and experiment my own apps and see them running on my phone.

Random Contact
So that was the reason for developing this app. There seemed no point in making another contacts app as the stock(default) one was very good and many third party apps available. So I thought of making an app that shows a random contact details. It has a surprise element to it.

Warning: This app is not meant to be a replacement for your Contacts / Dialer app. This is a fun app with no real use. The main reason this app is considered as part of "Useless Apps" internally.

The development started with an old version of Android API (2.2 to be precise), so I wasn't keeping in mind the latest design guidelines and the result was an ugly looking app with very little user experience

Redesign and Rewrite
After the Holo design came out solid Android Design guidelines became the De-facto standard, I went about researching on how to create a better User experience (UX) keeping in mind that this app has no special value to a user.

After going through brainstorming and multiple drawings on paper, came up with the new design. And in keeping with the time, rewrote most of the code against Android 4.3 APIs and is now available on the Play Store. Along the way some optimizations and new features were added.

Few people might have seen the original app, so below you can find a screen shot of initial screen, design on paper and the present day app.

Left : First version, Middle : redesign on paper, Right : Completely redesigned UI


Apps Library
I will touch on this in a future post, but one of the side effects of development this app was an Android library app that I created which makes use of mostly my research and studies. This will be an ever growing library which is open sourced and publicly available on GitHub. Any new Android projects can make use of this library to achieve similar functionality.

Try out the app
So if you are still interested in checking out this app, follow the link below to get it from the Play Store.
Get it on Google Play

Friday, June 28, 2013

Bing Image Parser

How many people have noticed the different images that are displayed on the home page of the search engine Bing? I used to visit the Bing homepage just to check the image each day. As an aside you can get some trivia on the US version of the site.



It was then that I had an idea to see if there was a way to automate the way to see different images that are provided by Bing. After a search, done ironically, on well "Google" (Searching on Google is like second nature for me), I was able to get an RSS feed URL for the Bing images, and able to parse it using a small Java application.

The reason behind choosing a source which gives data as RSS is that it is a standard. What the core of this application does is parse an RSS Feed. The other functionality like console, ability to save image and other settings are built around this core. So essentially this can be reused to parse other RSS Feeds.
The UI is not very fancy, it is a invoked via command line and there is a windows shell script that can be used to run it easily. (Make sure you have Java runtime installed). If you don't want the source code, you can grab a build file (zip file with the application and shell script file) from GitHub.

After getting the build file, extract it to a folder, edit the "settings.properties" file and run the "run-biotd.cmd" file. If you are opting to save the images to disk, make sure that the folder specified exists.



The entire eclipse project is now available at GitHub and licensed under the "Apache License Version 2.0" at the link below.
https://github.com/midhunhk/the-bing-image-of-the-day-parser

Build no 0.4.5 is available at
https://github.com/midhunhk/the-bing-image-of-the-day-parser/blob/master/BIotD/builds/BIotD_0.4.5.zip

Make sure to check these out and watch out for future updates. You can use this source code to parse any other RSS feed response and make an awesome app, so don't wait up.

Saturday, June 22, 2013

Mobile App vs Desktop application Development

The app development and release cycle for mobile (or tablet) and desktop applications differ vastly.

A desktop application is expected to be feature complete at the time of launch and may have undergone years of development (in the case of large applications like an Office Suite) before a major version is released. Only minor fixes for bug and security are expected till the next major release.Unless it is a major security related update, most of the time I ignore application updates for my desktop applications. This is because if there is no change in user experience or performance, it doesn’t seem work to go over the procedure of doing an update (A system restart for some applications if on Windows adds to this misery). I keep my graphics driver software up to date without seeing any significant performance improvements.

On the other hand, most users expect their mobile apps to get regular updates. It has sort of become a norm. This could be an addition of a new feature, improvement in user experience or a bug fix. Updating an app is seamless and there is little or no data loss and you can start using the updated app as soon as it is updated.

So while developing a mobile app, in my view, it is important to launch the first version with the most important and basic features that an app is concentrating. And add additional features upon each updates in short cycles. This would keep give the users a feeling that the app developer is constantly developing the app on improving the user experience. Most importantly this would keep the app fresh. If it stops evolving, users might get bored and may try out another app.

The advantages of this kind of release cycle are that the developers can get feedback from the users early and take into account feature suggestions or changes.

It should, however be noted that these views may not apply to all scenarios, there are exceptions. For e.g.: there is no scope or need for a short release cycles in the case of an app like Calculator.Desktop browsers like Google Chrome and Firefox have short release cycles, although there may be some minor change in a version.


To conclude, the approach for mobile app development is different from that followed for conventional software releases. This should be researched from a marketing as well as technical stand point before being finalized.

Friday, May 03, 2013

Message Counter for Android

Development has been going on a simple Android application called "Message Counter".

How the Message application works on an Android phone will vary greatly based on the OS Version as well as any modification done by the manufacturer like HTC, Samsung etc.

So as the message details are stored on a device using SQLite and whose contents can be accessed programmatically, I decided to write up an app called MessageCounter. The first version was completed quite fast, but in order to support Android 2.3 and up, some sacrifices were made regarding the UI and performance.

Taking advantage of Fragments, ActionBar etc introduced in later versions of Android (3.0, Honeycomb), a new version was created re using code from the first version.

The V2 of Message Counter was completed in a matter of hours and improves on performance and UI. Below are the screenshots of the app. You can find an update to this post if and when the app is made available on Google Play Store.

There are plans of making the source code open source and will be hosted at GitHub. An update to this post will include the details.

Update 1 : The project is now available on GitHub at this address : https://github.com/midhunhk/message-counter. The source code is licensed under the Apache License Version 2.0




Friday, November 23, 2012

PNRStatusApp v3 (for Android)

And thus the long awaited major update to PNRStatusApp (for Android) is nearly here. In the midst of very hectic work schedule, with new features and a new look the version 3 is almost completed. However taking advantage of the latest APIs (Application Programming Interfaces) provided by the Android platform, this version is only supported from Android Honeycomb (3.0) and above. The old version supported from Android Froyo (2.2) and above.












The newest feature added is the ability to search the message inbox for messages from IRCTC regarding booked tickets and displaying detailed information. This part still requires some more tweaking on.






The Messages are displayed in a 'StackView' that lets the user scroll through the list of messages.

More information coming soon...

Sunday, June 17, 2012

PNRStatusApp for Android

    The PNRStatusApp for Android, which was not working because of broken Service Providers interface has been fixed. The app is still not available in the Google Play Store and is under Alpha testing phase. Following are some screen shots of the app in action.


Home Screen to add PNRNumbers



Detailed Status of the PNRNumber


About the App Screen

As mentioned in the About screen, this application does not store any information retrieved about the PNR number and also is not commercial in nature.

This application is a part of self learning to the Android Application development. The following details were explored in this application.

  • Skinning applications, buttons etc
  • Custom Adapter for a List View
  • Calling a web service and parsing the response
  • Check if Internet connection is available
  • Moving between activities
  • Passing custom objects between activities
  • Sharing content
  • Different layouts used in Android (and how to optimally use them)
That's a good number of features to learn using a simple application. 

Saturday, April 23, 2011

CryptX 6 Beta!

    CryptX 6 is finally here. Albeit in Beta version. After almost scrapping the project due to various technical challenges, we have found our way through those and able to make it perform beyond initial expectations.

    Like its predecessor, this version does encryption using the AES Algorithm. Some more work will be done on the application before it is liberated from the Beta Label. But most planned features have been implemented. We are expecting user reviews and suggestions to better understand the product. Checkout some screen shots of the application revealed for the first time.

Initial Screen
File Selected
Encrypting!
Encryption complete!
And the download link for CryptX 6 Beta : http://www.mediafire.com/?xib9jdmmi50k8d2 

Tuesday, January 06, 2009

The Rubicon Panel - Control Panel

    The Rubicon  Panel is a custom developed control panel for use with the redesigned Mangalam College of Engg site. A number of features have been improvised and implemented into the panel. Shown below are the screen shots of the important features of the panel.


    This is the Rich text editor for managing the news, events and even the static contents for the site. All the data arse stored in the database. Even a person without  any knowledge with web designing can easily add or edit contents with much ease.



    This is the Add new staff member to the database form, part of the staff management module. 



    The Gallery management module has been a powerful module that has been researched and implemented for this project. New album can be created very easily and thumbnails are generated automatically for each uploaded image.



    The uploaded document manager makes it easy to upload documents to the site. It also provides the feature to get the link for each file , so that it may be added to a news or event item easily.

    That covers the important features provided by the panel ....

   

Mangalam College of Engg - Redesign

    I was working on a project for redesigning the website for Mangalam College of Engineering, Kottayam, Kerala. After studying the old site and the requirements put forward by the college, started with the design and layout. A draft was completed in a week's time incorporating all the fine details.

    The details specified included having an interesting layout and provide information to prospective students and parents, current students and their parents, the AICTE and anyone wishing to know more about the college.

     The dynamic parts of the site includes having a Latest News and Events notification on homepage itself, display the details of all faculty members and courses given by the college, a Photo Gallery and a portal for Admission Queries among other things...

    Well, I dont know if this is gonna be implemented or not, but this is the homepage of the redesigned site.


    The design was done using Fireworks, Dreamweaver and Flash. The dynamic end is coded using PHP and uses MySql Database.

    Most of the time was spent on developing the Control Panel for the site. It is codenamed Rubicon Panel and can be features a Rich Text editor, Uploaded File manager, Staff List Manager, Gallery Album Manager.

        There is now question over when or if the redesigned site will get to be implemented. There has not been much further response from the management regarding this. So at the moment, the site lives on "localhost" ........

Tuesday, July 29, 2008

Cryptx 5 Beta 1 Release

   Cryptx 5 development has come massive distances after the project almost got scrapped due to various problems faced during development. Although there are minor flaws in it, we are happy to release it as a Beta 1 so that developers from around the world can help make this project better.

the download link for the CR5-B1 is as follows : 

http://www.mediafire.com/?d5n7331z40y

Screen shot
-------------

   Please understand that this release is not fully complete and has some bugs and problems in it. Some known issues are

* No Help included

* Encryption writes log incorrectly

* Decryption does not write a log

* Need to optimise code for execution pipelines

* command line arguments might be needed to be formatted again

* encrypted file size is larger than original or decrypted file.

Features that are already there include :
-----------------------------------------------

* Rich HTA based GUI

* Work History denoting the various steps that went through the development of the project

* CTimer class to follow time taken for processing the data.

* AES 128 bit encryption

* Encrypted data is stored as HEX for added protection.

* Password is not stored in the encrypted file, only a hashed string. (MD5 can be implemented easily for extra protection of the pasword. It can be done from within the HTA interface).

Updates available at : http://www.cryptx5.co.nr

Hoping for some favourable reply ....


Thursday, July 24, 2008

Calculate File size with C++

Programming .....

  The following is a C++ program to calculate file size of a file. It has been tested to correctly report file sizes upto 4Gb, ofcourse used 32 bit compiler!

--Begin--

/* getFileSize.cpp
 * Gets the file size of a DiskFile
 *
 * Midhun Hk (Centrum inc Software Solutions)
 * July 2008
 * $ v 0.1
 **/

# inculde <ifstream>
# include <iostream>

void main()
{
    ifstream is;
    unsigned long fileSize = 0L;

    is.open("FileName.bin");   // Open the file
    if(is.good())                    // If file is opened successfully
    {
           // calculate FileSize
           is.seekg(0,ios::end); // move 0 bytes from end
           fileSize = is.tellg();   // get offset
           is.seekg(0,ios::beg); // rewind
     }

      cout<<"File Size is : "<<fileSize<<:" bytes";
}

--End--

Hope this has been useful.

Saturday, May 24, 2008

FileSplitter 1.9 Beta - Download with Source

     Here is another completed project from us. Its called File Splitter and basically designed to split a large file into a number of smaller parts and to be able to rejoin them. Ofcourse you may not readily feel any need for such an application, but the point here is that it can be done and the project is Open Source and so everyone can learn from it.

   To have a look at the main features, look at the promotional poster given below :
 


The interface is done with the HTA technology which will be discussed here soon.

File Name : FileSplitter_1.9.zip (415.19 KB)
Download link : http://www.mediafire.com/?un2zjr3oz9m

Monday, March 10, 2008

CryptX 5 :: Class Structures revision 0.1.0.2

   Heres the newly revised specification for the class structures for the Open Source encryption software project codenamed SideLiner. Although not much input from the community, i was able to think out some more solutions for possible problems in the structure when implementing 
in C# or Java in later development life of the project.

The changes include :
1. Working around the MI (Multiple Inheritance) problem in C# and Java. 
2. Making the class structure more understandable. 
3. Made the "DiskFile" class abstract. 
4. Added ae watermark in the specification.

So expecting more help from the community out there.





  

Wednesday, March 05, 2008

Main Project - Audio Steganography

Our final semester main project is finally complete and i would like to point out some facts about that as i had posted earlier.

Project Name : Audio Steganography App
Frontend : Java (J2SE)
Backend  : SQL Server or MS Access db

Synopsis : Steganography is the art and science of writing hidden messages in such a way that no one apart from the sender and intended recipient even realizes there is a hidden message. Audio Steganography deals with 
embedding an encrypted message into an audio file. The embeded file still 
plays as a normal audio file!


Ok first of all let me say that this program has a deeply researched and unique GUI that sets it apart from most Java based applications, courtesy of Artistik expressionz.

GUI Development in Java is not exactly developer friendly i guess,
atleast for me. The GUI has to be handcoded and placed on the Stage. 
Frustrating, but found short cut methods for doing that. 
Some three days were devoted entirely on designing and placing controls 
for the first two frames! Working in .net was more fun :-(

Then some database connectivity was the next step. Although nothing 
specifically related to the main project, this would add a 
no of forms / frames, would make the project seem bigger 
than it really is.

So the main modules of the app can be stated as:
1. User Management
2. Steg
3. Desteg
4. Log Writing

Of these theres nothing much to discuss about User Management - Just user login, registration, changing password etc.

Log Writer is my own contribution. Just logs out all activities done 
by the program. I wanted to learn about File I/O in Java, 
thats why that was implemented and also one more class.

Now the main parts are Steg and Desteg and ill discuss in detail about them soon...

Sunday, January 13, 2008

Module Header - New Proposal

   Ok, heres a new addition / proposal for the satndardization 
of the module structure for software projects. Its just an 
addition to the previous one.

* Name of the module [Application Domain / Type]

ie;
[Application Domain] is the addition to the Name of a module and specifies which might suggest where the module is implemented and how it can be classified. This might be useful if the software development group has multiple application domains, like us. Its more or less like keywords..

eg:

* ClientScroller [hta / script]

* AlbumGallery [web / php / script / db]

* XmlReadList [app / flash / xml]

Wednesday, January 09, 2008

Software Module Header Structure

    After much research, i found a quite standard way of writing headers for software projects. It is used in almost every professional development environment. These are just some specifications, individuals or firms may have their own changes according to their requirements.

   The need for such a standardisation is that once a module is written and debugged, the author or other software developers may understand cleanly what is going on and would help in debugging for the entire application, modification without sideeffects and ofcourse as a strong supporter of the "Open Source" movement, code sharing.

Module Header Format ($ revisoon 2)
--------------------------------------------
* Name of Module
* Synopsis of Module
* Date of creation
* Author's Name
* [Modification History]
* [Different Functions supported with in / out params]
* [Global Variables accessed or modified by it]

--End--

eg : say the module header of a new program that i created might have the following header

--Start--
* ClientScroller
* script that Scrolls the client area up and down
* Decemebr 2007
* Midhun Harikumar (Centrum inc Software Solutions)

$ Version 0.32

--End--

    Another important specification is regarding the use of global variables. While using Object Oriented Programming, i guess there would be minimum amount of 
global variables lying around. The specification is to name the global variables 
with a leading small case g and underscore.

eg :
int g_nDestFileCount;

    This way we can easily figure out where the global variables are used and might help
debugging a lot easier.