0
我在Android应用程序中使用的MPchart中的说明条形图有问题。android mpchart条形图说明位置
当我使用方法description.setPostion(3f, 3f)
时,说明消失。 我不知道要定制它的位置的默认值。
非常感谢您
我在Android应用程序中使用的MPchart中的说明条形图有问题。android mpchart条形图说明位置
当我使用方法description.setPostion(3f, 3f)
时,说明消失。 我不知道要定制它的位置的默认值。
非常感谢您
你的描述是隐藏在TOP_LEFT角落所以使用的代码否则不要设置说明现在的位置是我的模拟器的高度是1280,重量为720
//get the height and width of the device
DisplayMetrics ds = new DisplayMetrics();
this.getWindowManager().getDefaultDisplay().getMetrics(ds);
int width = ds.widthPixels;
int height = ds.heightPixels;
//set the custom description postion
Description desc = new Description();
desc.setText("Hai");
desc.setTextSize(13f);
desc.setPosition(width - 50,height - 175);
graph.setDescription(desc);
下图“海”是图的描述
desc.setPosition(宽度 - 50,高度 - 1250); //图:2描述是在最右边的角落显示
“海” 文字是描述