Review UI Widget from Google Play

I need to implement a Reviews widget in my application, similar to that seen in Google Play. Image Below:

Are there any components our there that make it easier to do this? It would save time & trouble of implementing my own version.

Thanks

Answers


I would create a custom layout for that.

A TextField for stars information, a progress bar to show the number of stars and another TextField to show the number of ratings. Everything rapped on a LinearLayout (orientation = horizontal) for proper alignment.


Implement RatingBar in android.

some sample links


I used a custom layout for this as cmota recommended.

The labels for the stars are a series of TextViews within a Relative layout

The rating bars are Imageviews in a Linearlayouts.

Code snippet:

ImageView ratingOne = (ImageView) ratingsView.findViewById(R.id.ratingOne);

      <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="15dp"
        android:background="@android:color/white"
        >

        <ImageView
            android:id="@+id/ratings_length_one"
            android:layout_width="wrap_content"
            android:layout_height="15dp"
            android:background="@color/orange" />

      </LinearLayout>

Each imageview has a fixed height : for example i use 15dp above

The width of the imageview is the my rating count

Then i change the layoutParams for each imageView according to the values

LinearLayout.LayoutParams layoutParams = new LinearLayout.LayoutParams(myRatingCount, ratingOne.getHeight());

ratingOne.setLayoutParams(layoutParams);


Need Your Help

Why does the scanner gets te wrong input?

java if-statement

The input is a word. If the word is hello it should print: Hello sir etc if the input is not hello it should print: why dont you say hello?

Desktop Multithreading UI sample application for .net

.net wpf winforms multithreading user-interface

Are there any good sample UI applications which illustrate multi threading best practices in .net?