天天看點

android 設定按鈕高度,如何在本機android中設定按鈕的高度

我正在學習反應

Android移動應用程式的本機程式設計.我正在制作一個我需要設定按鈕高度的螢幕.我在視圖中添加了按鈕并設定了使用樣式的高度,但按鈕高度沒有變化.

import React, { Component } from "react";

import { AppRegistry, Text, View, Button, TextInput } from "react-native";

class LoginComponent extends Component {

render() {

return (

style={{

height: 40,

borderColor: "gray",

borderWidth: 0.5

}}

placeholder="Email address"

underlineColorAndroid="transparent"

/>

style={{

height: 40,

borderColor: "gray",

borderWidth: 0.5

}}

placeholder="Password"

secureTextEntry={true}

underlineColorAndroid="transparent"

/>

);

}

}

AppRegistry.registerComponent("Myntra", () => LoginComponent);

任何人都可以幫我根據我的要求設定按鈕的高度.

提前緻謝.