Display multi view in android on adapterView - android

I want to make a app for pdf reader, Now ,I can read every page of pdf ,but I dont' know how to make the pages organized, I want to organize the pages when I click the right ,it presents the next page , in a contrast, click the left ,it presents the last page, in a addition, the page should display in full screen.
Through collecting some infomation, I know maybe the adapterView and adapter can be used to , but I still don't know how to do it.
Can you give me a idea? Thank you very much.

Related

How redirect different portions of activity on different click in android

I need help, i want a functionality like make a reference of different portions in one activity with different clicks. For example, if an activity consist of 4 button at top in horizontal View and 4 portions (Part1, Paer2, Part3, Par4) are make in the same activity below this horizontal portion. i want when i click on button 1 it redirect to part1 portion (this all in 1 same activity). Same like other click on button 4 redirect to portion 4. I don't know what is the name of this functionality.
Please go to this link to see the image
The above link show you the picture we see at first time, the upper portion have option like "WRAPS", "DESI MEALS" etc. And if your click on "DESI MEALS" it switch or redirect to the that portion like i show in the following pic:
Please go to this pic to see when i go to specfic portion
I also see this functionality on websites, when there is menu at top of website and if we choose an option it redirect to that portion on same 1 page , i think that is one page website.
As i understand i hope you're looking for fragments with tablayout on top example like below
if yes here is how to implement it https://developer.android.com/guide/navigation/navigation-swipe-view

How to create book app for android?

I want to build a simple book app for android that contains 100 pages of text-only content using android studio.
First activity to enter , 2 buttons for navigating to next and previous page and page number indicator. Also when page indicator clicked, a window pops up for entering specific page number.
Which way is better for this purpose ? Database or HTML method ?
Is there any source code or tutorial resources ?
I have done this using HTML method. What I did is I created HTML files for all the pages, then zipped all the pages.
After that unzipped it into android file system then using WebView I am able to view all the pages like a book app does.
I have added next page, previous page, and search button also.

Implement Page Curl/ Turn effect on single layout

I know page curl is discussed a lot times before(like here, here , this). Am supposed to do a book like application where while turning the pages would give the feel of a real book page. I have a layout which holds a text view and on next and previous button click am able to update the page content.
But implementing a pagecurl on this layout seems a lot difficult. Most of the samples do curl effect on images say 3 or 5 images. And some others do page curl effect on 2 layouts by flipping between them. In my case I need to bring this effect on my sublayout(linearlayout) within parent layout(relative). I just need to bring a curl effect on my sublayout so as to get the feel of book turning and content updation.
Does anyone have any idea.
Any suggestions/advise is appreciated
Thanks in advance

use one webview replace with the listview?

all, I am developing a app "forum client", I use the webview as each item in listview for showing the post list, there are pics, texts and some attachments which can be downloaded by user. it does work, but the webview is heavy component, need lots of system resources. so I have to find another method to show the post list. I found this question is the same with my problem, and the last post by author said, use "one webview with bunch of DIVs rendering the individual contents", but I cannot get it, so, what did he mean?
I think he meant that you should get all the HTML that you are showing in the different WebViews in each ListView item, wrap each in a div tag, then show that in one single WebView that the user can scroll. You should get much better performance since you will only have one WebView on-screen (and thus in memory) at one time, rather than one for each visible row which will take a lot of memory.

Full Screen Gallery View on User Click

I use a Gallery view to display set of images in the header part of my application's main page. Now I need to make the Gallery full screen when user click on any gallery image. In the full screen mode it should have the Gallery functionality (Should be able to move between images...). Finally, in the full screen mode, when user click the image, it should go back to normal screen.
It this possible with Android? Please help me.
Unfortunately you haven't told us what you've tried or haven't and thus it's hard to pick a starting point...
How I would do it, might be a little over kill using an added activity but I prefer the organization, but launch a new activity on view click and pass the strings of the paths in a bundle and the index of the one selected. Then create a bitmap or imageview, however you want to do it but make sure it can have a setOnTouchListener. This way you can use the MotionEvent to see if they swiped left or right and navigate through the list of images you passed to the activity as strings.
If you don't feel like doing bundles, you can make a static class that holds all the image information..

Categories

Resources