向右移动输入文字的光标 [英] Move the cursor for input text to the right
本文介绍了向右移动输入文字的光标的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我希望用户将文本输入到文本字段中的位置移动到右边的而不将文本字段的边距移动到右边.我想要这样做是因为搜索按钮位于文本字段的顶部,用于样式设置,当前,当用户开始键入文本时,它会在搜索按钮下方开始.因此,我需要将光标的默认点向右移动几个像素.CSS可以做到这一点吗?
I want the the point at which a user types text into a textfield to be moved to the right without moving the margin of the text field to the right. I want this because the search button lies on top of the text field for styling purposes and currently when a user begins to type text it starts underneath the search button. So I need the default point of the cursor to be moved to the right by a few pixels. Is this possible with CSS?
推荐答案
我一定会使用
text-indent: 20px;
=)
这篇关于向右移动输入文字的光标的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文