title: set Transparent background to alertdialog in android
body: <p><img src="https://i.stack.imgur.com/xcagf.png" alt="enter image description here"></p>
  
  <p>I want to show alert dialog with transparent background.
  My code of alert dialog is:</p>
  
  <pre><code>AlertDialog.Builder imageDialog = new AlertDialog.Builder(SubProducts.this);
  LayoutInflater inflater = (LayoutInflater)SubProducts.this.getSystemService(LAYOUT_INFLATER_SERVICE);
  
  View layout = inflater.inflate(R.layout.cust_toast_layout,(ViewGroup)findViewById(R.id.linearLayout2));
  
  ImageView image = (ImageView)layout.findViewById(R.id.imageView1);
  image.setPadding(0, 20, 0, 0);
  imgLoader.DisplayImage(image_url, loader, image);
  
  
  TextView tprice=(TextView)layout.findViewById(R.id.pricetext);
  tprice.setText("$ "+pricedouble);
  
  TextView tvdprh=(TextView)layout.findViewById(R.id.textView1);
  
  tvdprh.setText(prohd);
  
  
  
  
  WebView wv=(WebView)layout.findViewById(R.id.webview);
  
  
  
  Spanned sub=Html.fromHtml(descp);
  String s = "&lt;html&gt;&lt;head&gt;&lt;style type='text/css' &gt;@font-face {font-family:'myfont';src: url('file:///android_asset/fonts/ABeeZee-Regular.ttf');}body {margin:0px;color:000000;font-family: myfont;"
          + "text-align: justify;}&lt;/style&gt;&lt;/head&gt;&lt;body&gt;"
          + sub
          + "&lt;/body&gt;&lt;/html&gt;";
  
  wv.loadDataWithBaseURL("", s, "text/html", "utf-8", null);
  wv.setVerticalScrollBarEnabled(true);
  wv.setBackgroundColor(Color.TRANSPARENT);
  wv.setPadding(5, 25, 5, 0);
  
  
  ImageView imgcartl=(ImageView)layout.findViewById(R.id.imageView2);
  imgcartl.setBackgroundResource(R.drawable.cartlines);
  
  ImageView brobutton=(ImageView)layout.findViewById(R.id.imageView3);
  brobutton.setOnClickListener(new OnClickListener() {
  
  @Override
  public void onClick(View v) {
  
  
  
          Intent intentlabl = new Intent(getBaseContext(), Label.class);
  Bundle b=new Bundle();
  b.putString("url", image_urlpdf);
  b.putBoolean("isDialog", true);
  intentlabl.putExtras(b);
  startActivity(intentlabl);
  
  }
          });
  
  ImageView shobutton=(ImageView)layout.findViewById(R.id.imageView4);
  
  shobutton.setOnClickListener(new OnClickListener() {
  
  @Override
  public void onClick(View v) {
          // TODO Auto-generated method stub
  //intent code
          }
          });
  
  ImageView addbutton=(ImageView)layout.findViewById(R.id.imageView5);
  addbutton.setBackgroundResource(R.drawable.addicon);
  addbutton.setOnClickListener(new OnClickListener() {
  
  @Override
  public void onClick(View v) {
          // TODO Auto-generated method stub
  
          passingid.add(prodid);
  
  Product prodobj=new Product();
  prodobj.setId(passingid);
  
  
  new LongRunningGetIO4().execute(pricedouble, prodid);
  }
          });
  
  
  imageDialog.setView(layout);
  
  
  imageDialog.create();
  imageDialog.show();
  </code></pre>
  
  <p>My Background image contains rounded corners.But unfortunately,pop is appearing with rectangle white background.Any body plz suggest me with idea.Thanks in Advance. </p>