border-radius的中文意思有
1.圆角;边框圆角;圆角半径;圆角边框
例句:To stick with the border-radius example, consider what happens when you want to target just one corner of an object. (让我们继续停留在这个圆角效果的例子上,设想一下如你只想应用到一个对象的一个角上会产生什么情况。)
2.border-radius是CSS中用来设置 HTML 元素的圆角的属性。它可以将一个矩形元素的四个角变为圆角,让设计更加美观和圆润。其中心思想是给矩形元素画四条弧线,将这四段弧线连接起来便成了一个有圆角的矩形。
以下是使用border-radius属性创建不同圆角效果的例子:
圆形按钮:
.button {
width: 50px;
height: 50px;
border-radjButton1.setFont(new ja.awt.Font("楷体_GB2312", Font.PLAIN, 14));ius: 50%;
}圆角矩形框:
.box {
width: 200px;
height: 100px;
border-radius: 20px; / 或者使用
border-radius: 20px/10px /
}椭圆形:
.image {
width: 200px;
height: 100px;
border-radius: 100px / 50px;
}其中,以上CSS代码中border-radius:20px/10px;意味着使元素拥有20px的水平圆角和10px的垂直圆角。
框架边框;jButton2.addActionListener(new FrLogin_jButton2_actionAdapter(this));
frameborder 属性 -- HTML框架边框的显示方式 此属性应使用在frame标签中 frameborder属性取值: 1 -- 有边框 0 -- 无边框 默认值为1 border,中文"边框"的意思
/
以下是我曾经做项目时候做的登录,是从数据库提取登录名和密码的.具有广泛意义;如按楼主自己定义密码等,就更容易了。
p.s:因为时间忙,我就不另写程序了 希望对你有用。
package com.young.view;
import ja.awt.;
import ja.awt.nt.;
import com.young.jdbc.;
import ja.awt.Dimension;
import ja.awt.Rectangle;
import ja.awt.Font;
import jax.swing.DebugGraphics;
import jax.swing.text.html.ImageView;
import ja.awt.Color;
/
Title: 企业绩效管理系统
Description:
Copyright: Copyright (c) 2009
Company:
@author young
@version 1.0
public class FrLogin extends JFrame {
JPanel contentPane;
JLabel jLabel1 = new JLabel();
JLabel jLabel2 = new JLabel();
JLabel jLabel3 = new JLabel();
JButton jButton1 = new JButton();
JButton jButton2 = new JButton();
JTextField txtName = new JTextField();
JLabel jLabel5 = new JLabel();
JPasswordField txtPsw = new JPasswordField();
TitledBorder titledBorder1 = new TitledBorder("");
JPanel jPanel1 = new JPanel();
ImageIcon image = new ImageIcon("image/building.gif");
JButton btnImage = new JButton();
TitledBorder titledBorder2 = new TitledBorder("");
public FrLogin() {
tryborder-radius属性通常由两个值决定:个值为横向半径,第二个值为纵向半径。如果只提供一个值,则会被视为横向和纵向都是这个值。 {
setDefaultCloseOperation(EXIT_ON_CLOSE);
jbInit();
} catch (Exception exception) {
exception.printStackTrace();
/
Component initialization.
@throws ja.lang.Exception
private void jbInit() throws Exception {
contentPane = (JPanel) getContentPane();
contentPane.setLayout(null);
setSize(new Dimension(443, 327));
setTitle("Frame Title");
jLabel1.setFont(new ja.awt.Font("楷体_GB2312", Font.BOLD, 20));
jLabel1.setText("企业绩效管理系统");
jLabel1.setBounds(new Rectangle(126, 28, 168, 24));
jLabel2.setFont(new ja.awt.Font("楷体_GB2312", Font.PLAIN, 16));
jLabel2.setText("用户名:");
jLabel2.setBounds(new Rectangle(75, 124, 59, 24));
jLabel3.setFont(new ja.awt.Font("楷体_GB2312", Font.PLAIN, 16));
jLabel3.setText("密 码:");
jLabel3.setBounds(new Rectangle(75, 173, 59, 24));
jButton1.setBounds(new Rectangle(99, 218, 80, 28));
jButton1.setText("登录");
jButton1.addActionListener(new FrLogin_jButton1_actionAdapter(this));
jButton2.setBounds(new Rectangle(221, 217, 83, 29));
jButton2.setFont(new ja.awt.Font("楷体_GB2312", Font.PLAIN, 14));
jButton2.setText("取消");
txtName.setFont(new ja.awt.Font("楷体_GB2312", Font.PLAIN, 14));
txtName.setBounds(new Rectangle(146, 120, 102, 23));
txtName.addActionListener(new FrLogin_txtName_actionAdapter(this));
jLabel5.setText("等 级:");
jLabel5.setBounds(new Rectangle(75, 74, 59, 24));
txtPsw.setFont(new ja.awt.Font("楷体_GB2312", Font.PLAIN, 14));
txtPsw.addActionListener(new FrLogin_txtPsw_actionAdapter(this));
contentPane.setBorder(titledBorder1);
contentPane.setDebugGraphicsOptions(0);
contentPane.setNextFocusableComponent(jComboBox1);
contentPane.setToolTipText("企业绩效管理系统");
jPanel1.setNextFocusableComponent(jComboBox1);
jPanel1.setToolTipText("企业绩效管理系统");
jPanel1.setBounds(new Rectangle(1, 0, 441, 330));
jPanel1.setLayout(null);
jComboBox1.setFont(new ja.awt.Font("楷体_GB2312", Font.PLAIN, 14));
jComboBox1.setBounds(new Rectangle(146, 72, 102, 23));
jComboBox1.addActionListener(new FrLogin_jComboBox1_actionAdapter(this));
btnImage.setBounds(new Rectangle(271, 55, 120, 160));
btnImage.setBorder(titledBorder2);
jPanel1.add(jLabel1);
jPanel1.add(jLabel5);
jPanel1.add(jLabel2);
jPanel1.add(jLabel3);
jPanel1.add(txtName);
jPanel1.add(jComboBox1);
jPanel1.add(txtPsw);
jPanel1.add(jButton2);
jPanel1.add(jButton1);
jPanel1.add(btnImage);
contentPane.add(jPanel1);
jComboBox1.addItem(1);
jComboBox1.addItem(2);
btnImage.setIcon(image);
this.setTitle("登录");
}public void jButton2_actionPerformed(ActionEvent e) {
System.exit(0);
}public void jButton1_actionPerformed(ActionEvent e) {
//栏位判断
jax.swing.JOptionPane.showMessageDialog(this, "登录信息错误!请重新输入。");
txtName.setText("");
txtPsw.setText("");
} else {
boolean success = false;
int grade;
String name = "";
String psw = "";
JdbcUtils dbc = JdbcUtils.getInstance();
ResultSet rs = dbc.executeQuery("SELECT FROM user");
//查询帐号和密码是否匹配
try {
while (rs.next()) {
grade = rs.getInt("grade");
name = rs.getString("name");
psw = rs.getString("password");
txtPsw.getText().equals(psw) &&
((jComboBox1.getSelectedIndex() + 1) == grade)) {
//当时出现问题地方
//Integer.parseInt(jComboBox1.getSelectedItem()
success = true;
break;
//若匹配则登陆成功并进入主界面
if (success) {
FrMain ufram = new FrMain();
this.setVisible(false);
Dimension screenSize = Toolkit.getDefaultToolkit().
getScreenSize();
Dimension frameSize = ufram.getSize();
if (frameSize.height > screenSize.height) {
frameSize.height = screenSize.height;
}if (frameSize.width > screenSize.width) {
frameSize.width = screenSize.width;
2,
(screenSize.height - frameSize.height) /
2);
ufram.setVisible(true);
} else {
"名或密码错误!请重新输入。");
txtName.setText("");
txtPsw.setText("");
txtName.setFocusable(true);
}} catch (SQLException ex) {
ex.getMessage().toString());
return;
}public void txtName_actionPerformed(ActionEvent e) {
}public void jComboBox1_actionPerformed(ActionEvent e) {
}public void txtPsw_actionPerformed(ActionEvent e) {
class FrLogin_txtPsw_actionAdapter implements ActionListener {
FrLogin_txtPsw_actionAdapter(FrLogin adaptee) {
this.adaptee = adaptee;
}public void actionPerformed(ActionEvent e) {
adaptee.txtPsw_actionPerformed(e);
class FrLogin_jComboBox1_actionAdapter implements ActionListener {
FrLogin_jComboBox1_actionAdapter(FrLogin adaptee) {
this.adaptee = adaptee;
}public void actionPerformed(ActionEvent e) {
adaptee.jComboBox1_actionPerformed(e);
class FrLogin_txtName_actionAdapter implements ActionListener {
this.adaptee = adaptee;
}public void actionPerformed(ActionEvent e) {
adaptee.txtName_actionPerformed(e);
FrLogin_jButton1_actionAdapter(FrLogin adaptee) {
this.adaptee = adaptee;
}public void actionPerformed(ActionEvent e) {
adaptee.jButton1_actionPerformed(e);
class FrLogin_jButton2_actionAdapter implements ActionListener {
FrLogin_jButton2_actionAdapter(FrLogin adaptee) {
this.adaptee = adaptee;
}public void actionPerformed(ActionEvent e) {
adaptee.jButton2_actionPerformed(e);
border表示表格的边框线;cellpadding表示单元格内容与单元格就是表格的边框的宽度...0就是没边框...边框线的距离;cellspacing表示单元格与单元格之间的距离,你可以自己改变数值,看看变化!
dark是边框的上边和左边的颜色,亮度没的关系
}}light是边框的右边和下边的颜色,也和亮度没有关系
字面翻译:
borderColorDark 边框颜色暗
borderColorLight 边框颜色亮
就是把边框的颜色设为暗色还是亮色.
bordeclass FrLogin_jButton1_actionAdapter implements ActionListener {r表示某个元素边框
frame是框架,现在已经被w3c抛弃了:
框架的意思就是可以嵌入其他页面,上面代码中当前页面里面又包含了3个其他页面。你可以自己测试一下!border=n 以指定粗度显示表格边框
private FrLogin adaptee;border=0即不显示表格边框线
两个都是表示边框的意思!
不写border="0"的话,你在做连接时会显示一个框框,不好看!如果不做连接,可以不加入.
table里边的bordr="0"同样指的一样是边框,但是这个一般都要写上去,因为如果不为0,可能影响整个界面的美观.
边框线等于0 也就是说没有边框线
border='0'
这条子句一般常用在以下两个标记中:
src="/uploads/f5865178c0d922fc30015947f3faeec1.png" data-original=..
border="0">