本文整理了Java中android.widget.CheckBox.setPadding()
方法的一些代码示例,展示了CheckBox.setPadding()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。CheckBox.setPadding()
方法的具体详情如下:
包路径:android.widget.CheckBox
类名称:CheckBox
方法名:setPadding
暂无
代码示例来源:origin: termux/termux-api
@Override
LinearLayout createWidgetView(AppCompatActivity activity) {
LinearLayout layout = new LinearLayout(activity);
layout.setOrientation(LinearLayout.VERTICAL);
LinearLayout.LayoutParams layoutParams = new LinearLayout.LayoutParams(LinearLayout.LayoutParams.MATCH_PARENT, LinearLayout.LayoutParams.WRAP_CONTENT);
layoutParams.topMargin = 32;
layoutParams.bottomMargin = 32;
String[] values = getInputValues(activity.getIntent());
for (int j = 0; j < values.length; ++j) {
String value = values[j];
CheckBox checkBox = new CheckBox(activity);
checkBox.setText(value);
checkBox.setId(j);
checkBox.setTextSize(18);
checkBox.setPadding(16, 16, 16, 16);
checkBox.setLayoutParams(layoutParams);
layout.addView(checkBox);
}
return layout;
}
代码示例来源:origin: labexp/osmtracker-android
layoutParams.setMargins(60, 0, 0, 0);
newCheckBox.setLayoutParams(layoutParams);
newCheckBox.setPadding(10,20,10,20);
newCheckBox.setOnClickListener(listener);
registerForContextMenu(newCheckBox);
代码示例来源:origin: WomenWhoCode/WomenWhoCode
cb.setPadding(32, 16, 4, 16);
代码示例来源:origin: linglongxin24/ARDevelopDemo
newView.setTag(command);
newView.setVisibility(View.VISIBLE);
newView.setPadding(mEntriesSidesPadding + leftPadding,
mEntriesUpDownPadding, mEntriesSidesPadding,
mEntriesUpDownPadding);
内容来源于网络,如有侵权,请联系作者删除!