This repository has been archived on 2026-05-29. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
WinBoLL_Bck20260513_154646_588/libaes/src/main/res/values/dimens.xml

17 lines
1.2 KiB
XML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<?xml version="1.0" encoding="utf-8"?>
<resources>
<!--<item name="top_weight" type="dimen" format="integer">5</item>
要在xml中引用上述定义的dimens可以使用@dimen/text_line_spacing。
要在代码中引用上述定义的dimens可以使用如下代码。
TypedValue outValue = new TypedValue();
getResources().getValue(R.dimen.text_line_spacing, outValue, true);
float value = outValue.getFloat();
注意不能通过getResources().getDimension(R.dimen.text_line_spacing);方式来引用如果用这种方式引用上述方法定义的dimens编译时不会报错但是运行时会抛出NotFoundException。
参考https://blog.csdn.net/qluojieq/article/details/49591535?app_version=5.15.7&code=app_1562916241&csdn_share_tail=%7B%22type%22%3A%22blog%22%2C%22rType%22%3A%22article%22%2C%22rId%22%3A%2249591535%22%2C%22source%22%3A%22weixin_38986226%22%7D&uLinkId=usr1mkqgl919blen&utm_source=app
-->
<item name="dialogPivotX" type="dimen" format="integer">900</item>
<item name="dialogPivotY" type="dimen" format="integer">-900</item>
<!--<item name="buttonHeight" type="dimen">100px</item>-->
</resources>