gpt4 book ai didi

ios - 在 View 中将 Stripe PaymentKit 信用卡文本字段居中

转载 作者:行者123 更新时间:2023-12-01 17:39:09 25 4
gpt4 key购买 nike

我正在使用 Stripe PaymentKit 中的代码。他们提供了 PaymentViewController 的代码,我希望文本字段在 View 中居中,但我不知道如何。我可以轻松更改位置和宽度/高度,但我希望它水平居中......有什么想法吗?

最佳答案

我通过修改 x 坐标找到了解决方法:

float X_Co = (self.view.frame.size.width - 290)/2;
self.paymentView = [[PTKView alloc] initWithFrame:CGRectMake(X_Co, 240, 290, 55)];

关于ios - 在 View 中将 Stripe PaymentKit 信用卡文本字段居中,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/27537303/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com