我自定义了一个RadioButton样式,用于在右侧添加radiobutton图像
<RadioButton
android:layout_margin="20dp"
android:drawableRight="@drawable/custom_btn_radio"
android:button="@null"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="Invite Only"/>
Run Code Online (Sandbox Code Playgroud)
custom_btn_radio.xml
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:drawable="@drawable/check_box" android:state_checked="false"/>
<item android:drawable="@drawable/close_btn" android:state_checked="true"/>
</selector>
Run Code Online (Sandbox Code Playgroud)
但是,radiobutton的涟漪效应也增大了.如何从RadioButton中消除涟漪效应?还有如何自定义涟漪效果?
先感谢您.
我想选择 a 内的所有文本div
而不考虑里面的标签。
<div>
<p>some text here <a href="">a link here <span>span here<span></a></p>
</div>
Run Code Online (Sandbox Code Playgroud)
我需要得到结果
这里有一些文字,这里有一个链接,这里跨度
我试过这个
response.xpath('//div/text()')
Run Code Online (Sandbox Code Playgroud) 我在使用anroid 4.4打印api时收到错误"java.lang.IllegalStateException:只能从活动中打印".
它适用于4.4以上的所有anroid吗?
我的代码
public class MainActivity extends Activity {
Context cotext;
WebView mWebView;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
cotext = getApplicationContext();
}
public void printData(View view){
doWebViewPrint();
}
private void doWebViewPrint() {
// Create a WebView object specifically for printing
WebView webView = new WebView(cotext);
webView.setWebViewClient(new WebViewClient() {
public boolean shouldOverrideUrlLoading(WebView view, String url) {
return false;
}
@Override
public void onPageFinished(WebView view, String url) {
Log.i("TAG", "page finished loading " + url);
createWebPrintJob(view);
mWebView = …
Run Code Online (Sandbox Code Playgroud)