java界面--WePush-master 项目跑起来 -碰到的问题

  仅能在IntelliJ里面打开GUI Form文件来进行界面的拖拽设计--eclipse中也可以了 

当eclipse 打开.form文件时,提示有、对应的编辑工具可以打开它,请到市场去安装

    

    

 但是:本人安装这个插件后还是 打不开界面,应该是版本对应不上,造成:eclipse 打开的和IDEA打开的 From窗体代码少了一大部分:(窗体创建代码)

GUI initializer generated by IntelliJ IDEA GUI Designer 明确说明是有 工具生成的代码。

 private void createUIComponents() {
        // TODO: place custom component creation code here
    }

    {
// GUI initializer generated by IntelliJ IDEA GUI Designer
// >>> IMPORTANT!! <<<
// DO NOT EDIT OR ADD ANY CODE HERE!
        $$$setupUI$$$();
    }

    /**
     * Method generated by IntelliJ IDEA GUI Designer
     * >>> IMPORTANT!! <<<
     * DO NOT edit this method OR call it in your code!
     *
     * @noinspection ALL
     */
    private void $$$setupUI$$$() {
        mainPanel = new JPanel();
        mainPanel.setLayout(new GridLayoutManager(1, 1, new Insets(8, 0, 0, 0), -1, -1));
        tabbedPane = new JTabbedPane();
        tabbedPane.setFont(new Font(tabbedPane.getFont().getName(), tabbedPane.getFont().getStyle(), tabbedPane.getFont().getSize()));
        mainPanel.add(tabbedPane, new GridConstraints(0, 0, 1, 1, GridConstraints.ANCHOR_CENTER, GridConstraints.FILL_BOTH, GridConstraints.SIZEPOLICY_CAN_SHRINK | GridConstraints.SIZEPOLICY_CAN_GROW, GridConstraints.SIZEPOLICY_CAN_SHRINK | GridConstraints.SIZEPOLICY_CAN_GROW, null, new Dimension(200, 200), null, 0, false));
        aboutPanel = new JPanel();
        aboutPanel.setLayout(new GridLayoutManager(8, 6, new Insets(10, 10, 10, 10), -1, -1));
        aboutPanel.setForeground(new Color(-4486500));
        tabbedPane.addTab("关于", aboutPanel);
        final JLabel label1 = new JLabel();
        label1.setEnabled(true);
        label1.setFont(new Font(label1.getFont().getName(), label1.getFont().getStyle(), 36));
        label1.setText("WePush");
        aboutPanel.add(label1, new GridConstraints(1, 0, 1, 6, GridConstraints.ANCHOR_CENTER, GridConstraints.FILL_NONE, GridConstraints.SIZEPOLICY_FIXED, GridConstraints.SIZEPOLICY_FIXED, null, null, null, 0, false));
        final JLabel label2 = new JLabel();
        label2.setText("Proudly by 多多@放学了");
        aboutPanel.add(label2, new GridConstraints(2, 0, 2, 6, GridConstraints.ANCHOR_CENTER, GridConstraints.FILL_NONE, GridConstraints.SIZEPOLICY_FIXED, GridConstraints.SIZEPOLICY_FIXED, null, null, null, 0, false));
       
     ....省略

Test.setBorder(BorderFactory.createTitledBorder(BorderFactory.createRaisedBevelBorder(), "测试"));
    }

    /**
     * @noinspection ALL
     */
    public JComponent $$$getRootComponent$$$() {
        return mainPanel;
    }
}
eclipse缺少的代码

最终造成 eclipse无法跑起来。

== 放到idea 中,

设定 Edit Configurations 为application 添加如何 main函数

  

 因为在此之前本人已经 跑过一遍了,第二次很容易就跑起来了,

第一次大概经历:

lib里面的四个jar包我没有放到仓库,我IDEA 环境jar包的路径默认是用户路径,我就把那4个jar包手动放入Project Structure 的Libraries 里面,把pom原来的<executions> 去掉,我在edit configurations 中添加 application 和Main class;运行的时候提示错误:

对象空指针:是因为:Tab下的一个Jpanel我不小心勾上了下面的,意思是自定义创建。如果不勾就是由程序初始化自动创建。

  

发现后,去掉勾,可以跑起来。

第二次 重新导入项目后,因为上一次跑起来过一次了,所有lib下的4个jar包自动放到 了用户路径下的 jar库中了。所以本次不需要 把pom原来的<executions> 去掉

即可跑起来,下面动态图压缩了,所以有点模糊

   

 

 

---

GitHub - rememberber/WePush: 专注批量推送的小而美的工具,目前支持的消息类型:微信模板消息、微信客服消息、阿里大于模板短信 。
https://github.com/rememberber/WePush

build 说明 · rememberber/WePush Wiki
https://github.com/rememberber/WePush/wiki/build

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值