我知道之前已经问过这个问题,像这样:
但我的问题是当我这样做时:
LayoutParams params = new LayoutParams(
LayoutParams.WRAP_CONTENT,
LayoutParams.WRAP_CONTENT
);
params.setMargins(left, top, right, bottom);
Run Code Online (Sandbox Code Playgroud)
它表明params没有setMargins.谁可以帮忙?