what is the Alternative Way of TabActivity? - android-fragmentactivity

Hi I want to use Tab Activity(My Tab View must be at bottom) and android version 4.0 or later told that tabactivity is deprecated. so it must be a better way than it. but I could not find properly. some tutorials gave me advise to use Fragments but really I don't know anything about it. so please suggest me best tutorial or sample code for Fragments Or other best alternative way.
Thanks!

One suggestion is to use the Sherlock ActionBar. Inside the package there are good sample projects about Fragments, ActionBar, Navigation with tabs! I recommend ActionBarSherlock!
It also is 2.x compatible!!!

here is a link from android developer site,
http://developer.android.com/reference/android/app/TabActivity.html
and a tutorial,
http://maxalley.wordpress.com/2013/05/18/android-creating-a-tab-layout-with-fragmenttabhost-and-fragments/
Just by following above links you can create i easily.

Related

List particular function calls in outline of eclipse

In my C-code I repeatedly use a function from an external library:
XCALL("Blabla");
...
XCALL_END("Blabla");
It would be very helpful to be able to put each XCALL call into the outline view for better code querying. However, I could not find an easy solution for this. Also, installed Xtext in hope it was easy to configure. Any ideas?
Many thanks in advance!
I couldn't find any customization point open by CDT for modifying the behavior of the Outline view so I think you would have to get the CDT sources and build your customized version if you want to do that - or maybe see if they would be interested in you making this behavior customizable via extensions. In any case, this would represent quite a lot of work.

How to take screenshots in python?

I've an idea and want to implement it.
But I'm not sure if it's gonna work. So, wanted to get your inputs.
I would like to take screenshots of a url.
Say, when I open a web-site www.espncricinfo.com , I would like to take screenshot of that page and save locally. This saved image can be converted to GIF later on.
Can this be achieved through python ? Any suggestions/inputs to make it ?
Updated
And also is it possible to capture screenshot in headless-browser ?
Any possibilities to launch the browser in headless mode (non-GUI) and then take the screenshot of particular area of web-page ?
To take a screenshot using python:
import pyscreenshot as ImageGrab
im = ImageGrab.grab()
im.save('path/to/image/folder/image_name.png')
im.show()
Yes and no, if you send a request with urllib you will get the HTML in return, which is step one to displaying a webpage. But you have to build that webpage from that with a browser engine, otherwise all you will see is a bunch of text.
There are some python libraries that can do this, such as pywebkitgtk, but those are probably not going to give you the best experience and support.
Another thing you could try is to use crod and firefox/chrome/whatever and then use python to automate the process.
Oh, and by the way, I strongly recommend upgrading to python3
I know it is a bit to late now, but just saw this question and in case anyone else is looking for a mighty tool, to do screenshots and also use headless browsers with python... I just want to recommend to look more deeply into https://www.seleniumhq.org/. There are many tutorials on youtube available. However, this is IMHO the most accurate framework to execute your task, IMHO. To make screenshots, you can then define the screen resolution etc.

BB10 Core Native SDK: Programmatically adjust screen brightness?

Is it possible? If so please provide a working example.
I have come across this function which can use the SCREEN_PROPERTY_BRIGHTNESS to apparently change a windows brightness. However, I have had no success using this as there are no noticeable differences. In the comments below, see two other people who have had a similar issue (posted on the BlackBerry Support Forums). According to one user, the SCREEN_PROPERTY_BRIGHTNESS property does not work. Can anyone verify that or provide an alternative solution?
Your first link is to a page that does not exist. On the page from the second link there are to things. The property you want is probably SCREEN_PROPERTY_INTENSITY, but the documentation goes on to say
Full read/write access to Screen API object properties is product
dependent.

How to have ActionBar like Google Play in pre HoneyComb devices ( > 2.2)?

Firstly, This may look like a duplicate question but trust me I have searched all these questions, but couldn't find a suitable answer, yes it is frustrating. Still if you vote to close as duplicate please post comment so that I can learn, few of the similar questions are:-
1. ActionBar pre HoneyComb
2. Another similar question
What I want ?
In my Application I want to support the ActionBar like Google Play ( with few more buttons ). As shown below,
I want to use all three Action bars 1. Main Action Bar 2. Tab Action Bar and 3. Bottom Action Bar mentioned in this design page.
What I did ? I knew that ActionBar is not supported by default in pre-HoneyComb devices. so I started with searching for Alternatives, so I did following things:-
Downloaded the v4 support library and tried to get a working example, but couldn't.
Downloaded ActionBarShelock and created an example for that.
Downloaded this popular library (here on SO) from gitHub.
I have working examples of 2 and 3, but even they are far from what I desire. However I will prefer not using any prebuild library. Since it is a big Application which requires a lot of dynamic customization.
Please help me by providing any step by step guide to implement ActionBar using support library.
After considering that I decided using ActionBarSherlock, It is really easy to implement and to extend as well...

Looking for third party charting options for ColdFusion

A project I am working on makes extensive use of CFCHART. We have run into quite a few usage and performance issues with CFCHART, so I have been tasked to look at some third-party solutions to try out and recommend. Anybody have some reviews and recommendations they'd care to share?
Consider outputting the raw data and using JavaScript / Canvas to generate the charts on the fly. The load is the given to the client.
This makes it easier for screenreaders and people who like to save the data to access it as well.
Some JS charting libraries:
http://code.google.com/apis/chart/
http://omnipotent.net/jquery.sparkline/
http://code.google.com/p/flot/
http://codecanyon.net/item/graphup-jquery-plugin/108025?redirect_back=true&ref=1stwebdesigner&clickthrough_id=23945276
http://www.highcharts.com/
Not dependent on your server side technology (e.g. irrelevant to the fact that you're using CF), I have recently started playing around with HighCharts (http://www.highcharts.com/), and have been very impressed.
Bear in mind, it's not free for commercial use, but you didn't specify as to any such restrictions. Although their pricing seems pretty fair (see http://www.highcharts.com/license)
The Wijmo jQuery library has some nice charting widgets. http://wijmo.com/
We use FusionCharts. They have a comprehensive set of chart and widget types (eg sparklines) and have a very slick, professional finish.
ChartDirector is reasonable and is very advanced. It generates image-based graphs and we don't have to worry about whether or not different browsers support various advanced HTML features or Flash. You can download it, install and run it unlicensed and it will only add a little copyright in the bottom-right 20 pixels of the graph. (Licensing is inexpensive.) It comes with 239+ ColdFusion scripts so that you have plenty of sample code. Their support forums is very active and helpful.
http://www.advsofteng.com/cdcoldfusion.html
Check out the gallery. It has some very impressive samples. You can create just about anything.
http://www.advsofteng.com/gallery.html
You can try jqChart as well.
Thank you to everyone for these suggestions! This gives me a good list of applications to work with. Since there is no one "right" answer for a question like this I made sure to note each answer as useful.