私のアプリでは、画像、見出し、日付のみを表示するrecyclerviewのニュースページを実装しました。ユーザーが特定のニュースをクリックすると、そのニュースの詳細ページにリダイレクトされます。今、このページでは、ニュースの主な写真であるニュースの表紙画像が表示されます。このニュースの下に、そのニュースの説明が表示されます。そして、その下で彼は4,5枚の画像のような、そのニュースに関連する多くの画像を見ることができます。ここでは、画像リストがすべてのニュースについて固定されているわけではないことを言及したいと思います。 4または5または6である可能性があります。ページにはスクロールビューの動作が必要です。 CollapsingToolbaseのレイアウトについて読んだことがあります。しかし。この場合、スクロールバーでテキストまたはイメージを追加できます。しかし、それを行う最も効率的な方法は何でしょうか。私はこの詳細ページの適切なレイアウトを作成していました。以下の説明と多くの画像andoidでカバー画像を表示
答えて
あなたの画像に別のRecyclerView
を使用することもできます。この方法で、イメージのリストをアダプターに渡し、イメージの量を動的にします。
EDIT
は、これと同様のレイアウトください:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical" android:layout_width="match_parent"
android:layout_height="match_parent">
<ImageView
android:id="@+id/imageView2"
android:layout_width="match_parent"
android:layout_height="150dp"
android:src="@color/dark_blue" />
<TextView
android:text="Your description: Lorem ipsum dolor sit amet..."
android:layout_width="match_parent"
android:layout_height="200dp" />
<android.support.v7.widget.RecyclerView
android:layout_width="match_parent"
android:layout_height="match_parent" />
</LinearLayout>
をそして他の画像とあなたのRecyclerViewを取り込みます。
画像のリサイクラービューは1つのオプションです。しかし、Cover Imageの下のfixrdの説明のために私は何ができますか?私はここで全体を整理する方法を意味します –
私の答えを編集しました。これがあなたの必要とするものなら教えてください。 –
ありがとう。はい、私はこのタイプのレイアウトが必要です。私はそこにScrollViewを追加しました。 –
<?xml version="1.0" encoding="utf-8"?>
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:focusableInTouchMode="true"
android:orientation="vertical">
<ImageView
android:id="@+id/top_seller"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@color/colorAccent"
android:contentDescription="@string/app_name"
android:adjustViewBounds="true"
android:src="@drawable/image1"
android:scaleType="fitXY"
/>
<android.support.v4.widget.NestedScrollView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:scrollbars="none">
<TextView
android:id="@+id/textView2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/large_text" />
</android.support.v4.widget.NestedScrollView>
<android.support.v7.widget.RecyclerView
android:id="@+id/image_list"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical" />
</LinearLayout>
</ScrollView>
- 1. 説明の下に画像を移動
- 2. イメージギャラリーピッカー画像と説明プレビュー
- 3. 画像の説明cssとhtmlの画像にあるボックス
- 4. 画像表示の画像を表示
- 5. NodeJSとExpressで多くの画像を表示する
- 6. asp:画像表示画像
- 7. AWS CLI:AWS EC2説明-画像:ループとファイル
- 8. 画像の明瞭さを失うことなく表示画像を表示する方法
- 9. ページの下部に画像を表示
- 10. オーバーレイ画像と別の透明画像
- 11. C、GTK:60fps以下のRGB画像の表示ストリーム
- 12. 以下のコンボボックスで画像をドラッグ
- 13. facebook wallの画像と説明を表示するFacebookのようなオプション
- 14. 画像の説明Liferay Webコンテンツテンプレート
- 15. 多くの画像をアンドロイドで表示する
- 16. Jquery画像スライドショー画像のランダム表示
- 17. 100vhの背景カバー画像
- 18. 画像の多くのプリロード、プリロード画面
- 19. C++またはpythonで画像から画像の説明を読むには?
- 20. 画像のアップロードと表示
- 21. MigraDoc画像を画像上に表示
- 22. 画像をギャラリーに表示アセット/画像
- 23. 背景色と透明な画像のHTML表:下の枠線
- 24. 画像表示
- 25. 表示画像
- 26. 表示画像
- 27. 表示画像
- 28. 表示画像
- 29. 画像表示
- 30. 表示画像
このhttps://github.com/ongakuer/CircleIndicatorを試してみてhttps://github.com/JakeWharton/ViewPagerIndicatorとhttp://www.androprogrammer.com/2015/06/view-pager- with-circular-indicator.htmlとこれもhttps://www.androidhive.info/2013/09/android-fullscreen-image-slider-with-swipe-and-pinch-zoom-gestures/ –
@NileshRathod私はしませんここに任意のビューページャーを実装したい。このページはスクロールする必要があります。表示の動作 –
は簡潔に説明します –