title: How to remove extra space from Alert dialog in android
body: <p>In My android app, It is an alert dialog but there is one problem It have extra space from top of the title . How to remove extra space can anyone help me. </p>
  
  <p><a href="https://i.stack.imgur.com/Pgzdx.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Pgzdx.png" alt="In this image there is an alert dialog but I want to remove extra spaces from above welcome title"></a> </p>
  
  <pre><code>java code
  
   protected void onCreate(Bundle savedInstanceState) {
      super.onCreate(savedInstanceState);
      requestWindowFeature(Window.FEATURE_NO_TITLE);
      setContentView(R.layout.activity_welcome_from);
  
      final AlertDialog.Builder builder =
              new AlertDialog.Builder(this, R.style.AppCompatAlertDialogStyle);
  
      Typeface tfmain = Typeface.createFromAsset(getAssets(), fontFooterpath);
      Typeface tfContent = Typeface.createFromAsset(getAssets(), fontMain);
  
      CustomTFSpan tfSpan = new CustomTFSpan(tfContent);
      SpannableString spannableString = new SpannableString("Welcome");
      spannableString.setSpan(tfSpan, 0, spannableString.length(), Spannable.SPAN_EXCLUSIVE_EXCLUSIVE);
      builder.setTitle(spannableString);
  
      CustomTFSpan tfSpan1 = new CustomTFSpan(tfmain);
      SpannableString spannableString1 = new SpannableString("Hello");
      spannableString1.setSpan(tfSpan1, 0, spannableString1.length(), spannableString1.SPAN_EXCLUSIVE_EXCLUSIVE);
      builder.setMessage(spannableString1);
  
      builder.setPositiveButton("START", new DialogInterface.OnClickListener() {
          @Override
          public void onClick(DialogInterface dialogInterface, int i) {
              Intent ii = new Intent(WelcomeFromActivity.this, Question1Activity.class);
              startActivity(ii);
          }
      });
      builder.setCancelable(false); //for prevent outside touch
      builder.show();
  
  }
  </code></pre>
  
  <p>Can anyone know that how to remove extra space from alert dialog title. </p>