Tag Archives: Quot

How to draw Arcs in Android using canvas?

By | January 10, 2013

This is a simple example showing how to draw Arcs in android, You can use this to create piecharts or someother similar thing you want. Here we have 3 classes. 1. GraphicsActivity.java 2. MainActivity.java 3. PictureLayout.java GraphicsActivity.java PictureLayout.java MainActivity.java Download the complete source code from here.

Creating a custom Sliding GalleryView with Paging in android

By | June 28, 2012

This is a simple example showing A sliding Gallery in android. This example shows a sliding gallery with a paging Control and a changing page text which also indicate the page change. Create a new project named “SlidingGallery” and copy this code into “SlidingGalleryDemo.java“. My Activity name is “SlidingGalleryDemo.java” here. Now create a new class… Read More »

How to read and write a text file that is stored in your application sandbox in ANDROID?

By | April 22, 2012

Hi all….. In this post I will show you how to read a text file in ANDOID. Let your file is in the your application sandbox of your ANDOID project, i.e the file’s location is /data/data/your_package_name folder. To view this folder -> open File Explorer and expand each folder. For this example to work first… Read More »

How to change the hint text color in android?

By | April 20, 2012

Hello all.. This simple example will show you how to change the hint text color in android Here is the java code to simply do this. here is a sample project to view the difference. This is the contents of the main java file. The main.xml file Here I am setting a read color to… Read More »

Creating Menu in Iphone Cocos2D or Box2D?

By | April 3, 2012

Use CCMenuItemSprite and CCMenu in iPhone to create menu. call this function to set up the menu for your home page in your iPhone game or you can change this code directly to ANDROID and it will work. Make sure you have all the images mentioned in the above example. This menu will appear on… Read More »

Creating Menu in Iphone Cocos2D or Box2D?

By | April 3, 2012

Use CCMenuItemSprite and CCMenu in iPhone to create menu. call this function to set up the menu for your home page in your iPhone game or you can change this code directly to ANDROID and it will work. Make sure you have all the images mentioned in the above example. This menu will appear on… Read More »

Creating Menu in Iphone Cocos2D or Box2D?

By | April 3, 2012

Use CCMenuItemSprite and CCMenu in iPhone to create menu. call this function to set up the menu for your home page in your iPhone game or you can change this code directly to ANDROID and it will work. Make sure you have all the images mentioned in the above example. This menu will appear on… Read More »

Creating Menu in Iphone Cocos2D or Box2D?

By | April 3, 2012

Use CCMenuItemSprite and CCMenu in iPhone to create menu. call this function to set up the menu for your home page in your iPhone game or you can change this code directly to ANDROID and it will work. Make sure you have all the images mentioned in the above example. This menu will appear on… Read More »

How to show a sliding window from below in Android?

By | December 22, 2011

Hello everyone, I have already showed you how to use a SlidingViewer to create a slidingWindow. Today I will show another way to create such a window with the help of animation. Please check one of my previous posts to do this in another way. How to show a sliding window from below in Android?… Read More »

SlidingDrawer in Android, A simple example.

By | December 1, 2011

Sliding-Drawer in a nice and useful widget in android. Please check one of my previous posts to do this in another way. How to show a sliding window from below in Android? Check this new One using Navigation Drawer About Sliding drawer SlidingDrawer hides content out of the screen and allows the user to drag… Read More »

C++ program to add two complex nos.

By | June 18, 2011

The program contains a class complex with two member variables x and y and a string class with one member variable. Two objects are created for complex class and string class and accepted values through read () function and their values are added using the operator overloaded function and assigned to the third object for… Read More »

C++ program append the two text files

By | June 18, 2011

Three file objects are created using the fstream class one for first, second for second file and third for the appended file. The first two files are opened in the input mode and third in the append mode. The first file is opened and checked for error condition if the file exist its contents are… Read More »

C++ program to copy the contents of a text file to another

By | June 18, 2011

Two file objects are created using the fstream class for the two files, one for source file and another destination file. The first file is opened and its contents are copied to the second file using get ( ) and put ( ) function. Each time the source file is opened error checking is done… Read More »