📄 horsetravel1.java
字号:
jButton17.setText("17"); jButton18.setText("18"); jButton19.setText("19"); jButton20.setText("20"); jButton21.setText("21"); jButton22.setText("22"); jButton23.setText("23"); jButton24.setText("24"); jButton25.setText("25"); jButton26.setText("26"); jButton27.setText("27"); jButton28.setText("28"); jButton29.setText("29"); jButton30.setText("30"); jButton31.setText("31"); jButton32.setText("32"); jButton33.setText("33"); jButton34.setText("34"); jButton35.setText("35"); jButton36.setText("36"); jButton37.setText("37"); jButton38.setText("38"); jButton39.setText("39"); jButton40.setText("40"); jButton41.setText("41"); jButton42.setText("42"); jButton43.setText("43"); jButton44.setText("44"); jButton45.setText("45"); jButton46.setText("46"); jButton47.setText("47"); jButton48.setText("48"); jButton49.setText("49"); jButton50.setText("50"); jButton51.setText("51"); jButton52.setText("52"); jButton53.setText("53"); jButton54.setText("54"); jButton55.setText("55"); jButton56.setText("56"); jButton57.setText("57"); jButton58.setText("58"); jButton59.setText("59"); jButton60.setText("60"); jButton61.setText("61"); jButton62.setText("62"); jButton63.setText("63"); jButton64.setText("64"); jButton1.setText("1"); jLabel6.setText("红色表示当前正在走的格子,绿色表示上一步,粉色表示已走过的格子。"); org.jdesktop.layout.GroupLayout jPanel2Layout = new org.jdesktop.layout.GroupLayout(jPanel2); jPanel2.setLayout(jPanel2Layout); jPanel2Layout.setHorizontalGroup( jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(jPanel2Layout.createSequentialGroup() .add(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(jPanel2Layout.createSequentialGroup() .add(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING) .add(org.jdesktop.layout.GroupLayout.LEADING, jPanel2Layout.createSequentialGroup() .add(jButton33) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton34) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton35) .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED) .add(jButton36)) .add(org.jdesktop.layout.GroupLayout.LEADING, jPanel2Layout.createSequentialGroup() .add(jButton25) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton26) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton27) .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED) .add(jButton28))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(jPanel2Layout.createSequentialGroup() .add(jButton29) .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED) .add(jButton30) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton31) .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED) .add(jButton32)) .add(jPanel2Layout.createSequentialGroup() .add(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(jPanel2Layout.createSequentialGroup() .add(jButton37) .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED) .add(jButton38) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton39)) .add(jPanel2Layout.createSequentialGroup() .add(55, 55, 55) .add(jButton46) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton47))) .add(10, 10, 10) .add(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(jButton48) .add(jButton40))))) .add(jPanel2Layout.createSequentialGroup() .add(jButton41) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton42) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton43) .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED) .add(jButton44) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton45)) .add(jPanel2Layout.createSequentialGroup() .add(jButton17) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton18) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton19) .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED) .add(jButton20) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton21) .add(10, 10, 10) .add(jButton22) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton23) .add(10, 10, 10) .add(jButton24)) .add(jPanel2Layout.createSequentialGroup() .add(jButton57) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton58) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton59) .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED) .add(jButton60) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton61) .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED) .add(jButton62) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton63) .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED) .add(jButton64)) .add(jPanel2Layout.createSequentialGroup() .add(jButton49) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton50) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton51) .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED) .add(jButton52) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton53) .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED) .add(jButton54) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton55) .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED) .add(jButton56)) .add(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING, false) .add(jLabel6, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .add(org.jdesktop.layout.GroupLayout.LEADING, jPanel2Layout.createSequentialGroup() .add(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING, false) .add(jButton9, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .add(jButton1, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) .add(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(jPanel2Layout.createSequentialGroup() .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED) .add(jButton10)) .add(jPanel2Layout.createSequentialGroup() .add(12, 12, 12) .add(jButton2, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 43, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))) .add(10, 10, 10) .add(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.TRAILING, false) .add(jButton11, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .add(jButton3, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 45, Short.MAX_VALUE)) .add(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(jPanel2Layout.createSequentialGroup() .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton12)) .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel2Layout.createSequentialGroup() .add(4, 4, 4) .add(jButton4, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 47, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING, false) .add(jButton5, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .add(jButton13, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) .add(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING, false) .add(jPanel2Layout.createSequentialGroup() .add(11, 11, 11) .add(jButton14) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton15) .add(10, 10, 10) .add(jButton16)) .add(jPanel2Layout.createSequentialGroup() .add(12, 12, 12) .add(jButton6) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED) .add(jButton7, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 47, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE) .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED) .add(jButton8, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)))))) .addContainerGap()) ); jPanel2Layout.setVerticalGroup( jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(org.jdesktop.layout.GroupLayout.TRAILING, jPanel2Layout.createSequentialGroup() .add(jLabel6) .addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .add(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(jButton6) .add(jButton1) .add(jButton4) .add(jButton7) .add(jButton5) .add(jButton2) .add(jButton8) .add(jButton3)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED) .add(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(jButton13) .add(jButton9) .add(jButton10) .add(jButton16) .add(jButton12) .add(jButton14) .add(jButton11) .add(jButton15)) .addPreferredGap(org.jdesktop.layout.LayoutStyle.UNRELATED) .add(jPanel2Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.BASELINE) .add(jButton17)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -