-->

How to programmatically add both fonts and round cornered views to drawer

How to programmatically add both fonts and round cornered views to drawer
1.First you have to create a new project in sketchware
2.Add drawer to the main activity, you can do that by going to view and after that set App compact and design in the sketchware project.
3.Add a horizontal LinearView linear1 and set width to match parent.
4.Add a TextView textview1 and set textsize to 20, set textstyle to bold.
5.Go to fonts manager and add a custom font.
6.Then in main activity oncreate event, use add source directly to add the following codes;
_drawer_textview1.setTypeface(Typeface.createFromAsset(getAssets(), "fonts/cac_champagne.ttf"), 0);
(You should change the bolded ttf code above to the name of your added custom font and the textview1 is the id of the textview in drawer)
7.Below the first add source directly in oncreate event, add another add source directly with the following code to set rounded corners for linear in drawer ;
android.graphics.drawable.GradientDrawable hd = new android.graphics.drawable.GradientDrawable();
hd.setColor(Color.parseColor("#009688"));
hd.setCornerRadius(45);
_drawer_linear1.setBackground(hd);
(The number "009688" is the number of the color you want to add to the linear, you can check the code of all colors in sketchware while setting the background color of any linear)
8.Save and run the project in sketchware. There you have it , how to edit your drawer to be more beautiful.