Asked about the novel reader questions.



This is a picture of "panda read a book" screenshot, I just want to be a function and the function the same, can be loaded into TXT form, like ScrollViewer, can move up and down and read a book, the bottom has a ProgressBar can be based on your mobile showing the percentage of book reading, now have the following questions.

1 how to realize rolling read a book, began to think is to use ScrollViewer TextBlock, but TextBlock has the length limit, over length, study does not come out, again if this novel is ten trillion, that once read out is certainly not, loader, the Internet to find an alternative, is to determine the length of then, with a dynamic TextBlock content creation, but I just read a 205K file, it reported abnormal, the display can not.
Consider TXT paging files read? How to achieve?

2 bookmarks is how to achieve?

3 how to calculate the percentage, and then tied to ProgressBar, and when the font spacing, time change, bookmarks, record the position should be how to position?

Thank you for the answer. . .

Started by Jean at December 13, 2016 - 6:59 PM

How come no one. .

Posted by Jean at December 14, 2016 - 7:05 PM

1,You need to calculate a screen can display the number of bytes is appropriate, when you flip to real-time read the next page flow. Stream can be calculated according to the offset.
2, The offset as a bookmark is stored in a separate storage space, the next time you open the software to read the data to read page data.
3, ProgressBar is added to a waiting? Your bookmarks not too accurate, record the page offset about it.

Posted by Richard at December 17, 2016 - 7:38 PM

1 how to realize rolling read a book, began to think is to use ScrollViewer TextBlock, but TextBlock has the length limit, over length, study does not come out, again if this novel is ten trillion, that once read out is certainly not, loader, the Internet to find an alternative, is to determine the length of then, with a dynamic TextBlock content creation, but I just read a 205K file, it reported abnormal, the display can not.
Consider TXT paging files read? How to achieve?
You can dynamically generate TextBlock and then inserted into StackPanel to display text. For example, a TextBlock insertion in 100K.
When the last time scroll to load.

2 bookmarks is how to achieve?
Record the current offset

3 how to calculate the percentage, and then tied to ProgressBar, and when the font spacing, time change, bookmarks, record the position should be how to position?
Or a current offset/ full text size is the current value of ProgressBar.

Note two: current reading currently loaded in offset offset

Posted by Beata at December 30, 2016 - 8:16 PM

3 can you give some code, still have no clue how to calculate the percentage, when sliding up and down. .

Posted by Jean at January 03, 2017 - 8:38 PM

What did you use to develop? I use VS2005 to write a wm5.0 reader, for my own use well

Posted by Fitzgerald at January 10, 2017 - 10:34 PM

Note two: current reading currently loaded in offset offset
There are pre loaded offset otherwise it will delay

Posted by Tony at January 14, 2017 - 9:34 PM