ilan Expert Licensed User Longtime User Dec 13, 2016 #1 hi 1, when i set background color to the tabstrip labels (page titles) i dont see anymore the indicator. 2, can i set the tabstrip so the top page title that is focused will always be at the center? 3, i would also like to know how to set the background color of the top of the screen where the clock is shown so it has the same background color as the tabstrip labels (do i have to start a new thread for this question?) (sample project incl.) thanx, ilan Attachments My Salary New.zip My Salary New.zip 32.4 KB · Views: 628
hi 1, when i set background color to the tabstrip labels (page titles) i dont see anymore the indicator. 2, can i set the tabstrip so the top page title that is focused will always be at the center? 3, i would also like to know how to set the background color of the top of the screen where the clock is shown so it has the same background color as the tabstrip labels (do i have to start a new thread for this question?) (sample project incl.) thanx, ilan
Erel B4X founder Staff member Licensed User Longtime User Dec 13, 2016 #2 1. The label color should be semi-transparent: Code: Copy lbl.Color = Colors.ARGB(150, 52,152,219) 2. This is already implemented in your code. The label is centered unless it is January or December. 3. https://www.b4x.com/android/forum/threads/statusbar-color.65600/#post-415530 Upvote 0
1. The label color should be semi-transparent: Code: Copy lbl.Color = Colors.ARGB(150, 52,152,219) 2. This is already implemented in your code. The label is centered unless it is January or December. 3. https://www.b4x.com/android/forum/threads/statusbar-color.65600/#post-415530
ilan Expert Licensed User Longtime User Dec 13, 2016 #3 Thank you for your help erel. 2, yes i would like to have januar or december also centered. Is it possible? Upvote 0
Thank you for your help erel. 2, yes i would like to have januar or december also centered. Is it possible?
Erel B4X founder Staff member Licensed User Longtime User Dec 13, 2016 #4 I don't think that it is possible. Upvote 0
ilan Expert Licensed User Longtime User Dec 13, 2016 #5 Erel said: I don't think that it is possible. Click to expand... i think it is (see attached project) Erel said: 1. The label color should be semi-transparent: Code: Copy lbl.Color = Colors.ARGB(150, 52,152,219) Click to expand... sorry but i still dont see the indicator even if i set the back color to semi-transparent Attachments My Salary New.zip My Salary New.zip 33.2 KB · Views: 631 Upvote 0
Erel said: I don't think that it is possible. Click to expand... i think it is (see attached project) Erel said: 1. The label color should be semi-transparent: Code: Copy lbl.Color = Colors.ARGB(150, 52,152,219) Click to expand... sorry but i still dont see the indicator even if i set the back color to semi-transparent
Erel B4X founder Staff member Licensed User Longtime User Dec 13, 2016 #6 Nice solution. The white color disappears. Change it to any other color and you will see it. Upvote 0
ilan Expert Licensed User Longtime User Dec 13, 2016 #7 Erel said: Nice solution. The white color disappears. Change it to any other color and you will see it. Click to expand... But i need white Never mind, as u can see in the project the selected page title is white and all other have alpha so i think its good enough to see what page has focus and i can give up the indicator. Thanx erel Upvote 0
Erel said: Nice solution. The white color disappears. Change it to any other color and you will see it. Click to expand... But i need white Never mind, as u can see in the project the selected page title is white and all other have alpha so i think its good enough to see what page has focus and i can give up the indicator. Thanx erel
ilan Expert Licensed User Longtime User Jan 3, 2017 #8 ok after working a little bit on my project i noticed that you cannot load any number of pages to a tabstrip. loading about 20 pages will give me a "out of memory" crash. i had to to find a way how to show a tabstrip that contains all month of the year where you can scroll from 1 month to the other. so the current month is in the center and the next month is on the right and the previous month is on the left. actually i only need 3 pages but there is no way to scroll and add new pages to the tabstrip and still get the nice sliding effect right? well, i found a nice work around for my issue and i want to share it with you. so what i do is i create 5 pages (3 where enough but when i scroll right/left i also show -2/+2 month, this looks better in my opinion) so what i do is very simple scrolling to the left will call after x ms a sub that will scroll back to page nr 2 and reload the title lbl. like this i only have 5 pages but it looks like i have unlimited pages. have a look Attachments My Salary New.zip My Salary New.zip 57.2 KB · Views: 620 Upvote 0
ok after working a little bit on my project i noticed that you cannot load any number of pages to a tabstrip. loading about 20 pages will give me a "out of memory" crash. i had to to find a way how to show a tabstrip that contains all month of the year where you can scroll from 1 month to the other. so the current month is in the center and the next month is on the right and the previous month is on the left. actually i only need 3 pages but there is no way to scroll and add new pages to the tabstrip and still get the nice sliding effect right? well, i found a nice work around for my issue and i want to share it with you. so what i do is i create 5 pages (3 where enough but when i scroll right/left i also show -2/+2 month, this looks better in my opinion) so what i do is very simple scrolling to the left will call after x ms a sub that will scroll back to page nr 2 and reload the title lbl. like this i only have 5 pages but it looks like i have unlimited pages. have a look
Erel B4X founder Staff member Licensed User Longtime User Jan 3, 2017 #9 It is better to post it in the code snippets forum. Upvote 0