Builder mBuilder = new Builder(ctx);Dialog mAlert = mBuilder.create();mAlert.show();Window window = mAlert.getWindow();WindowManager.LayoutParams P = window.getAttributes();P.width = 自定义宽度(px);P.height = 自定义高度(px);window.setAttributes(P);window.setBackgroundDrawableResource(android.R.color.transparent);// 去掉dialog的默认背景mAlert.setContentView(contentView);

更多相关文章

  1. android 完美获取状态栏高度
  2. Android动态设置控件高度
  3. android 获取实际view 宽度高度
  4. Android中动态设置布局高度一致
  5. android状态栏 高度
  6. Android 中获取屏幕长度及宽度
  7. Android中当item数量超过一定大小RecyclerView高度固定
  8. 2013.03.19(5)———android 获取状态栏的高度
  9. Android根据屏幕宽度缩放图片

随机推荐

  1. Android内存泄漏检测工具大全
  2. Android(安卓)OCR之tesseract
  3. Android TextView的一些小知识
  4. 消息驱动 Looper类
  5. android的Theme
  6. RadioGroup和RadioButton
  7. 窗体两个按钮各占一半
  8. 设置Android应用程序横竖屏显示
  9. Android(安卓)使用Shape绘制图形
  10. android开机自启广播无效果的曲线解决方