zoukankan      html  css  js  c++  java
  • GUI 之 JScrollPane (面板)

    编写代码 JScrollDemo测试类

    package com.xiang.lesson05;
    
    import javax.swing.*;
    import java.awt.*;
    
    //滚动条 JScrollPane 面板
    public class JScrollDemo extends JFrame {
        public JScrollDemo() {
            Container container = getContentPane();
    
    //        文本域
            JTextArea textArea = new JTextArea(20, 10);
            textArea.setText("Machine reading comprehension (MRC) aims to teach machines to read and comprehend human
    " +
                    "languages, which is a long-standing goal of natural language processing (NLP). With the burst of
    " +
                    "deep neural networks and the evolution of contextualized language models (CLMs), the research
    " +
                    "of MRC has experienced two significant breakthroughs. MRC and CLM, as a phenomenon,
    " +
                    "have a great impact on the NLP community. In this survey, we provide a comprehensive and
    " +
                    "comparative review on MRC covering overall research topics about 1) the origin and development
    " +
                    "of MRC and CLM, with particular focus on the role of CLMs; 2) the impact of MRC and CLM
    " +
                    "to the NLP community; 3) the definition, datasets, and evaluation of MRC; 4) general MRC
    " +
                    "architecture and technical methods in the view of two-stage Encoder-Decoder solving archiu0002tecture from the insights of the cognitive process of humans; 5) previous highlights, emerging
    " +
                    "topics, and our empirical analysis, among which we especially focus on what works in different
    " +
                    "periods of MRC researches. We propose a full-view categorization and new taxonomies on these
    " +
                    "topics. The primary views we have arrived at are that 1) MRC boosts the progress from language
    " +
                    "processing to understanding; 2) the rapid improvement of MRC systems greatly benefits from
    " +
                    "the development of CLMs; 3) the theme of MRC is gradually moving from shallow text matching
    " +
                    "to cognitive reasoning.");
    
    //        JScrollPane 面板
            JScrollPane scrollPane = new JScrollPane(textArea);
    
    
            container.add(scrollPane);
    
            setVisible(true);
            setBounds(100, 100, 400, 200);
            setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);
    
        }
    
        public static void main(String[] args) {
            new JScrollDemo();
        }
    }
    
    

    运行结果

  • 相关阅读:
    电脑开机小键盘灯不亮,应该怎么设置?
    关于SqlServer数据库日期函数
    SqlServer数据库几种字段类型对比
    如何查找计算机端口?
    实用的几个小命令
    SqlServer中创建Oracle连接服务器
    局域网内设置打印机
    SqlServer2008数据库自动备份设置
    文件内容替换BAT
    Dockerfile文件与常用指令详解(2) Marathon
  • 原文地址:https://www.cnblogs.com/d534/p/15111592.html
Copyright © 2011-2022 走看看