Comments (33)
Hello. Thanks for question. There are a list of examples activities in sample app. You can look there and also check source code to resolve your issue.
from navigationtabbar.
Yeah, I'm trying to do that.
from navigationtabbar.
And what?
from navigationtabbar.
Hello, i have the same issue with french language title and badge do not show
from navigationtabbar.
<com.gigamole.navigationtabbar.ntb.NavigationTabBar
android:id="@+id/navigationTabBar"
android:layout_alignParentBottom="true"
android:layout_width="match_parent"
android:layout_height="60dp"
app:ntb_badge_gravity="top"
app:ntb_badge_position="right"
app:ntb_badged="true"
app:ntb_scaled="true"
app:ntb_tinted="true"
app:ntb_title_mode="all"
app:ntb_titled="true"
app:ntb_swiped="true"/>
from navigationtabbar.
final ArrayList<NavigationTabBar.Model> models = new ArrayList<NavigationTabBar.Model>()
{
{
add(new NavigationTabBar.Model.Builder(
getResources().getDrawable(R.drawable.icone_profile_tab),
Color.parseColor("#000000")
).title(getString(R.string.tab_bar_profil))
.build());
add(new NavigationTabBar.Model.Builder(
getResources().getDrawable(R.drawable.tab_bar_icone_missions),
Color.parseColor("#000000")
).title(getString(R.string.tab_bar_missions))
.build());
add(new NavigationTabBar.Model.Builder(
getResources().getDrawable(R.drawable.icone_push_tab),
Color.parseColor("#000000")
).build());
add(new NavigationTabBar.Model.Builder(
getResources().getDrawable(R.drawable.icone_activites_tab),
Color.parseColor("#000000")
)
.title(getString(R.string.tab_bar_histoires))
.build());
add(new NavigationTabBar.Model.Builder(
getResources().getDrawable(R.drawable.icone_circuit_tab),
Color.parseColor("#000000") // fond du linearlayout quand actif
).title(getString(R.string.tab_bar_circuits))
.build());
}
};
navigationTabBar.setModels(models);
//setBackgroundColor ne marche pas
navigationTabBar.setActiveColor(getResources().getColor(R.color.white)); //couleur de l'icone quand actif
navigationTabBar.setInactiveColor(getResources().getColor(R.color.white)); //couleur de l'icone quand pas actif
navigationTabBar.setBgColor(getResources().getColor(R.color.tab_bar_non_selectionne));//fond de couleur quand pas actif
navigationTabBar.setViewPager(mViewPager, Prefs.getInt(GlobalConfig.SHARED_PREFERENCES_CURRENT_TAB, 2));
no error but they dont show
from navigationtabbar.
<com.gigamole.navigationtabbar.ntb.NavigationTabBar
android:id="@+id/navTabBar"
android:layout_width="match_parent"
android:layout_height="50dp"
android:layout_alignParentBottom="true"
app:ntb_badge_gravity="top"
app:ntb_badge_position="right"
app:ntb_badged="true"
app:ntb_scaled="true"
app:ntb_tinted="true"
app:ntb_title_mode="all"
app:ntb_bg_color="@color/white"
app:ntb_titled="true"
app:ntb_swiped="true"/>
from navigationtabbar.
Do you set titles in models? And what color of your titles?
from navigationtabbar.
Maybe your fonttype doesnt provide any symbols for your languages?
from navigationtabbar.
How do you set the color of the titles please?
from navigationtabbar.
Can you send me yout strings?
from navigationtabbar.
<string name = "tab_bar_profil">Profile</string>
<string name = "tab_bar_missions">Quizz</string>
<string name = "tab_bar_histoires">Activities</string>
<string name = "tab_bar_circuits">Circuits</string>
from navigationtabbar.
Its so interesting.
from navigationtabbar.
I dont know what is the problem is. I`ve tested on many langs and there was ok.
from navigationtabbar.
Its seems like your method of getString(R.string.tab_bar_histoires) returns to you "". Try to log this.
from navigationtabbar.
maybe a conflict with an other library
compile 'com.github.MKergall:osmbonuspack:v5.8.1'
compile 'org.osmdroid:osmdroid-android:5.2@aar'
compile 'com.orhanobut:dialogplus:1.11@aar'
compile 'com.github.frank-zhu:pullzoomview:1.0.0'
compile 'com.facebook.android:facebook-android-sdk:+'
compile 'com.github.dmytrodanylyk.android-process-button:library:1.0.4'
compile 'com.github.bumptech.glide:glide:3.7.0'
compile 'com.squareup.retrofit2:converter-gson:2.0.2'
compile 'com.squareup.okhttp3:okhttp:3.2.0'
compile 'com.github.2359media:EasyAndroidAnimations:0.8'
compile 'com.squareup.retrofit2:retrofit:2.0.2'
compile 'com.google.android.gms:play-services-analytics:+'
compile 'com.mobsandgeeks:android-saripaar:+'
compile 'com.google.android.gms:play-services-location:+'
compile 'com.android.support:appcompat-v7:24.0.0'
compile 'com.jaredrummler:android-device-names:1.0.9'
compile 'com.android.support:multidex:1.0.1'
compile 'com.android.support:design:24.0.0'
compile 'info.hoang8f:fbutton:1.0.5'
compile 'uk.co.chrisjenx:calligraphy:2.2.0'
compile 'com.android.support:recyclerview-v7:24.0.0'
compile fileTree(include: ['*.jar'], dir: 'libs')
compile 'org.greenrobot:eventbus:3.0.0'
compile 'com.github.johnkil.android-progressfragment:progressfragment:1.4.+'
compile 'de.hdodenhof:circleimageview:+'
compile 'com.google.android.gms:play-services-panorama:+'
compile 'com.github.halysongoncalves:pugnotification:1.8.1'
compile 'com.commonsware.cwac:cam2:0.6.2'
compile 'com.infstory:recyclerlist:1.0.0'
compile 'com.kogitune:pre-lollipop-activity-transition:+'
compile 'com.github.pwittchen:reactivenetwork:0.2.0'
compile('net.i2p.android.ext:floatingactionbutton:1.10.0') {
exclude module: "library"
}
compile 'com.makeramen:roundedimageview:2.2.1'
compile 'com.github.dmytrodanylyk.shadow-layout:library:1.0.1'
compile 'com.squareup.leakcanary:leakcanary-android:+'
compile 'org.zeroturnaround:zt-zip:1.9'
compile 'com.pixplicity.easyprefs:library:+'
compile 'com.github.jd-alexander:library:1.1.0'
compile 'com.github.viethoa:fastscroller:1.1.0'
compile 'com.github.fenjuly:ArrowDownloadButton:9e15b85e8a'
compile 'com.github.vlonjatg:progress-activity:v1.0.3'
compile('com.github.gabrielemariotti.recyclerview:recyclerview-animators:0.3.0-SNAPSHOT@aar') {
exclude module: "okhttp"
}
compile('com.twitter.sdk.android:twitter:+') {
transitive = true;
}
compile 'com.karumi:dexter:2.2.2'
compile 'com.hedgehog.ratingbar:app:1.0.4'
compile 'com.google.android.gms:play-services:+'
compile 'com.jonathanfinerty.expandabletextview:expandabletextview:0.0.2'
compile 'io.reactivex:rxandroid:1.2.0'
compile 'com.sangcomz:FishBun:0.4.4@aar'
//compile 'cn.finalteam:galleryfinal:1.4.8.7'
compile 'com.github.NightWhistler:HtmlSpanner:+'
//compile 'com.jakewharton:butterknife:8.0.1'
//apt 'com.jakewharton:butterknife-compiler:8.0.1'
compile 'com.anjlab.android.iab.v3:library:1.0.+'
compile 'com.joanzapata.iconify:android-iconify:+'
compile 'com.joanzapata.iconify:android-iconify-fontawesome:+'
compile 'com.github.thorbenprimke:realm-searchview:+'
compile 'com.jakewharton:butterknife:7.0.1'
compile 'com.pacioianu.david:ink-page-indicator:1.2.0'
compile 'com.github.johnpersano:supertoasts:1.3.4@aar'
compile 'com.estimote:sdk:0.10.5@aar'
compile 'com.github.medyo:fancybuttons:1.8.1'
compile 'com.rengwuxian.materialedittext:library:2.1.4'
compile 'com.github.dmytrodanylyk.shadow-layout:library:1.0.3'
compile 'com.github.devlight.navigationtabbar:navigationtabbar:1.2.3'
from navigationtabbar.
will try to log it
from navigationtabbar.
No. This is problem on your side.
from navigationtabbar.
A yes, it's our problem, the sample code can run normally
from navigationtabbar.
Mhhh the logs are correct, its really strange because the demo are ok
from navigationtabbar.
Well, it is very strange
from navigationtabbar.
Maybe your strings placed in not default folder of /values or /string.xml. Maybe there are some flag for this path like lang etc.
from navigationtabbar.
i am trying this
final String[] colors = getResources().getStringArray(R.array.default_preview);
final ArrayList<NavigationTabBar.Model> models = new ArrayList<NavigationTabBar.Model>();
models.add(
new NavigationTabBar.Model.Builder(
getResources().getDrawable(R.drawable.ic_third),
Color.parseColor(colors[0]))
.selectedIcon(getResources().getDrawable(R.drawable.ic_third))
.title("Heart")
.badgeTitle("NTB")
.build()
);
models.add(
new NavigationTabBar.Model.Builder(
getResources().getDrawable(R.drawable.ic_third),
Color.parseColor(colors[1]))
// .selectedIcon(getResources().getDrawable(R.drawable.ic_eighth))
.title("Cup")
.badgeTitle("with")
.build()
);
models.add(
new NavigationTabBar.Model.Builder(
getResources().getDrawable(R.drawable.ic_third),
Color.parseColor(colors[2]))
.selectedIcon(getResources().getDrawable(R.drawable.ic_third))
.title("Diploma")
.badgeTitle("state")
.build()
);
models.add(
new NavigationTabBar.Model.Builder(
getResources().getDrawable(R.drawable.ic_third),
Color.parseColor(colors[3]))
// .selectedIcon(getResources().getDrawable(R.drawable.ic_eighth))
.title("Flag")
.badgeTitle("icon")
.build()
);
models.add(
new NavigationTabBar.Model.Builder(
getResources().getDrawable(R.drawable.ic_third),
Color.parseColor(colors[4]))
.selectedIcon(getResources().getDrawable(R.drawable.ic_third))
.title("Medal")
.badgeTitle("777")
.build()
);
navigationTabBar.setModels(models);
//setBackgroundColor ne marche pas
navigationTabBar.setActiveColor(getResources().getColor(R.color.white)); //couleur de l'icone quand actif
navigationTabBar.setInactiveColor(getResources().getColor(R.color.white)); //couleur de l'icone quand pas actif
navigationTabBar.setBgColor(getResources().getColor(R.color.tab_bar_non_selectionne));//fond de couleur quand pas actif
DebugUtilities.displayInConsole("TOTO : " + getString(R.string.tab_bar_profil));
navigationTabBar.setViewPager(mViewPager, Prefs.getInt(GlobalConfig.SHARED_PREFERENCES_CURRENT_TAB, 2));
navigationTabBar.setOnTabBarSelectedIndexListener(new NavigationTabBar.OnTabBarSelectedIndexListener() {
@Override
public void onStartTabSelected(NavigationTabBar.Model model, int index) {
try {
Prefs.putInt(GlobalConfig.SHARED_PREFERENCES_CURRENT_TAB, index);
} catch (Exception e) {
new ExceptionManager(e, MonumentTrackerApplication.context);
}
}
@Override
public void onEndTabSelected(NavigationTabBar.Model model, int index) {
}
});
from navigationtabbar.
What's the reason why I found. Cannot use relativelayout parent layout
from navigationtabbar.
mhhh i use parent relativelayout
from navigationtabbar.
will try with linearlayout
from navigationtabbar.
linearlayout is ok
from navigationtabbar.
no it does not work with linearlayout too :/
from navigationtabbar.
ok it works with linearlayout like that
<com.monumentTrackerAddictive.Coeur.Fragments.NonScrollingViewPager
android:id="@+id/viewpager"
android:layout_width="match_parent"
android:layout_height="0dp"
android:layout_weight="1"/>
<com.gigamole.navigationtabbar.ntb.NavigationTabBar
android:id="@+id/navigationTabBar"
android:layout_width="match_parent"
android:layout_height="60dp"
app:ntb_badge_gravity="top"
app:ntb_badge_position="right"
app:ntb_badged="true"
app:ntb_scaled="true"
app:ntb_tinted="true"
app:ntb_title_mode="all"
app:ntb_titled="true"
app:ntb_swiped="true"/>
<include
android:layout_alignParentTop="true"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
layout="@layout/navigation_action_bar_progression" />
from navigationtabbar.
i have the titles finally :)
from navigationtabbar.
Thank you very much for your help
from navigationtabbar.
:)
from navigationtabbar.
You welcome.
from navigationtabbar.
Related Issues (20)
- [BADGE NOT SHOWED] HOT 2
- How Select tab by index ?
- Implementing fragments HOT 6
- is it impossible to show tabs only with title (no icon, no badge)?
- More pageviewer/ fragment
- Indicator Style
- boolean android.graphics.Bitmap.isRecycled() null object reference error
- boolean android.graphics.Bitmap.isRecycled() null object reference error
- I try to change title in runtime.But it won't be changed everytime.
- Drawable Background
- Migrate to AndroidX
- Does this navigation support sliding, such as 5 menu items on the side. Only show four, the other can be displayed by sliding
- Can you give each icon a color? HOT 1
- method add not working in arraylist add method
- No fake drag in progress. Call beginFakeDrag first. HOT 2
- i want to disable this nav
- ArrayIndexOutOfBounds Exception
- programmatically set selected item
- "
- how to disable scroll
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from navigationtabbar.