fermisurfer Git
Revision | bec189d8b68f0a23765be9de145da468644bd588 (tree) |
---|---|
Zeit | 2019-06-04 14:28:41 |
Autor | ![]() |
Commiter | mitsuaki1987 |
Using wxtext for terminal
@@ -131,7 +131,7 @@ static void check_bragg() { | ||
131 | 131 | |
132 | 132 | }/*for (ii = 0; ii < 2; ii++)*/ |
133 | 133 | }/*for (ibzl = 0; ibzl < nbzl; ibzl++)*/ |
134 | - printf(" Number of corners of 1st BZ : %d\n", nbzcorner); | |
134 | + *terminal << wxString::Format(wxT(" Number of corners of 1st BZ : %d\n"), nbzcorner); | |
135 | 135 | /**@brief |
136 | 136 | Then, compute real number Bragg plane of 1st BZ (::nbragg), |
137 | 137 | Re-order ::bragg and ::brnrm |
@@ -150,7 +150,7 @@ static void check_bragg() { | ||
150 | 150 | nbragg += 1; |
151 | 151 | } |
152 | 152 | } |
153 | - printf(" Number of plane of 1st BZ : %d\n", nbragg); | |
153 | + *terminal << wxString::Format(wxT(" Number of plane of 1st BZ : %d\n"), nbragg); | |
154 | 154 | }/*static void check_bragg*/ |
155 | 155 | /** |
156 | 156 | @brief Compute Brillouin zone boundariy lines |
@@ -113,9 +113,9 @@ void calc_nodeline() { | ||
113 | 113 | } |
114 | 114 | ntri_th[ib][0] = 0; |
115 | 115 | }/*for (ib = 0; ib < nb; ib++)*/ |
116 | - printf(" band # of nodeline\n"); | |
116 | + *terminal << wxT(" band # of nodeline\n"); | |
117 | 117 | for (ib = 0; ib < nb; ib++) { |
118 | - printf(" %d %d\n", ib + 1, nnl[ib]); | |
118 | + *terminal << wxString::Format(wxT(" %d %d\n"), ib + 1, nnl[ib]); | |
119 | 119 | }/*for (ib = 0; ib < nb; ib++)*/ |
120 | 120 | /* |
121 | 121 | Allocation of nodeline |
@@ -499,6 +499,8 @@ void TestGLCanvas::OnPaint(wxPaintEvent& WXUNUSED(event)) | ||
499 | 499 | int ierr; |
500 | 500 | char command_name[256]; |
501 | 501 | |
502 | + if (draw_band == NULL) return; | |
503 | + | |
502 | 504 | // This is a dummy, to avoid an endless succession of paint messages. |
503 | 505 | // OnPaint handlers must always create a wxPaintDC. |
504 | 506 | wxPaintDC dc(this); |
@@ -116,9 +116,9 @@ void equator() { | ||
116 | 116 | } |
117 | 117 | ntri_th[ib][0] = 0; |
118 | 118 | }/*for (ib = 0; ib < nb; ib++)*/ |
119 | - printf(" band # of nodeline\n"); | |
119 | + *terminal << wxT(" band # of nodeline\n"); | |
120 | 120 | for (ib = 0; ib < nb; ib++) { |
121 | - printf(" %d %d\n", ib + 1, nequator[ib]); | |
121 | + *terminal << wxString::Format(wxT(" %d %d\n"), ib + 1, nequator[ib]); | |
122 | 122 | }/*for (ib = 0; ib < nb; ib++)*/ |
123 | 123 | /* |
124 | 124 | Allocation of nodeline |
@@ -436,8 +436,8 @@ void fermi_patch() | ||
436 | 436 | /**/ |
437 | 437 | if (fbz == 1) { |
438 | 438 | if (query == 1) { |
439 | - printf("\n"); | |
440 | - printf(" ## First Brillouin zone mode #######\n"); | |
439 | + *terminal << wxT("\n"); | |
440 | + *terminal << wxT(" ## First Brillouin zone mode #######\n"); | |
441 | 441 | } |
442 | 442 | for (i0 = 0; i0 < 3; ++i0) { |
443 | 443 | start[i0] = ng[i0] / 2 - ng[i0]; |
@@ -446,15 +446,15 @@ void fermi_patch() | ||
446 | 446 | } |
447 | 447 | else { |
448 | 448 | if (query == 1) { |
449 | - printf("\n"); | |
450 | - printf(" ## Premitive Brillouin zone mode #######\n"); | |
449 | + *terminal << wxT("\n"); | |
450 | + *terminal << wxT(" ## Premitive Brillouin zone mode #######\n"); | |
451 | 451 | } |
452 | 452 | for (i0 = 0; i0 < 3; ++i0) { |
453 | 453 | start[i0] = 0; |
454 | 454 | last[i0] = ng[i0]; |
455 | 455 | } |
456 | 456 | } |
457 | - if (query == 1) printf(" Computing patch ...\n"); | |
457 | + if (query == 1)* terminal << wxT(" Computing patch ...\n"); | |
458 | 458 | /**/ |
459 | 459 | #pragma omp parallel default(none) \ |
460 | 460 | shared(nb,ntri,ntri_th,start,last,ng,ng0,eig,vf,EF,mat,shiftk,query) \ |
@@ -573,9 +573,9 @@ void fermi_patch() | ||
573 | 573 | ntri_th[ib][0] = 0; |
574 | 574 | } |
575 | 575 | /**/ |
576 | - printf(" band # of patchs\n"); | |
576 | + *terminal << wxT(" band # of patchs\n"); | |
577 | 577 | for (ib = 0; ib < nb; ib++) { |
578 | - printf(" %d %d\n", ib + 1, ntri[ib]); | |
578 | + *terminal << wxString::Format(wxT(" %d %d\n"), ib + 1, ntri[ib]); | |
579 | 579 | } |
580 | 580 | /* |
581 | 581 | Allocation of triangler patches |
@@ -606,6 +606,6 @@ void fermi_patch() | ||
606 | 606 | }/*for (ib = 0; ib < nb; ++ib)*/ |
607 | 607 | }/*if (query == 1)*/ |
608 | 608 | else { |
609 | - printf(" ... Done\n"); | |
609 | + *terminal << wxT(" ... Done\n"); | |
610 | 610 | } |
611 | 611 | } /* fermi_patch */ |
@@ -226,6 +226,9 @@ wxString window_name; | ||
226 | 226 | wxString batch_name; |
227 | 227 | wxString frmsf_file_name; |
228 | 228 | int lbatch; |
229 | + | |
230 | +wxTextCtrl* terminal; | |
231 | + | |
229 | 232 | /** |
230 | 233 | @brief Glut Display function |
231 | 234 | called by glutDisplayFunc |
@@ -274,13 +277,15 @@ bool MyApp::OnInit() | ||
274 | 277 | |
275 | 278 | if (!wxApp::OnInit()) return false; |
276 | 279 | |
277 | - printf("\n"); | |
278 | - printf("###########################################\n"); | |
279 | - printf("## ##\n"); | |
280 | - printf("## Welocome to FermiSurfer ver. %s ##\n", VERSION); | |
281 | - printf("## ##\n"); | |
282 | - printf("###########################################\n"); | |
283 | - printf("\n"); | |
280 | + new MyFrame(NULL, argv[1]); | |
281 | + | |
282 | + *terminal << wxT("###########################################\n"); | |
283 | + *terminal << wxT("## ##\n"); | |
284 | + *terminal << wxT("## Welocome to FermiSurfer ver. ") << | |
285 | + wxT(VERSION) << wxT(" ##\n"); | |
286 | + *terminal << wxT("## ##\n"); | |
287 | + *terminal << wxT("###########################################\n"); | |
288 | + *terminal << wxT("\n"); | |
284 | 289 | if (argc < 2) { |
285 | 290 | printf("\n"); |
286 | 291 | printf(" Input file is not specified !\n"); |
@@ -296,10 +301,10 @@ bool MyApp::OnInit() | ||
296 | 301 | #else |
297 | 302 | nthreads = 1; |
298 | 303 | #endif |
299 | - printf(" Number of threads : %d\n", nthreads); | |
300 | - printf("\n"); | |
301 | - printf(" Initialize variables ...\n"); | |
302 | - printf("\n"); | |
304 | + *terminal << wxT(" Number of threads : ") << nthreads << wxT("\n"); | |
305 | + *terminal << wxT("\n"); | |
306 | + *terminal << wxT(" Initialize variables ...\n"); | |
307 | + *terminal << wxT("\n"); | |
303 | 308 | /**/ |
304 | 309 | color_scale = read_file(); |
305 | 310 | if (color_scale == 0)color_scale = 4; |
@@ -318,17 +323,16 @@ bool MyApp::OnInit() | ||
318 | 323 | /* |
319 | 324 | Description |
320 | 325 | */ |
321 | - printf("\n"); | |
322 | - printf(" ## How to handle ###################\n"); | |
323 | - printf("\n"); | |
324 | - printf(" mouse drag : Rotate objects\n"); | |
325 | - printf(" mousewheel : Resize objects\n"); | |
326 | - printf(" cursorkey : Move objects\n"); | |
327 | - printf(" mouse right button : Menu\n"); | |
328 | - printf("\n"); | |
326 | + *terminal << wxT("\n"); | |
327 | + *terminal << wxT(" ## How to handle ###################\n"); | |
328 | + *terminal << wxT("\n"); | |
329 | + *terminal << wxT(" mouse drag : Rotate objects\n"); | |
330 | + *terminal << wxT(" mousewheel : Resize objects\n"); | |
331 | + *terminal << wxT(" cursorkey : Move objects\n"); | |
332 | + *terminal << wxT(" mouse right button : Menu\n"); | |
333 | + *terminal << wxT("\n"); | |
329 | 334 | /**/ |
330 | 335 | //if (argc > 4)glutInitWindowSize(atoi(argv[3]), atoi(argv[4])); |
331 | - new MyFrame(NULL, argv[1]); | |
332 | 336 | lbatch = 0; |
333 | 337 | if (argc > 2) { |
334 | 338 | lbatch = 1; |
@@ -336,7 +340,6 @@ bool MyApp::OnInit() | ||
336 | 340 | batch_name = argv[2]; |
337 | 341 | batch_draw(); |
338 | 342 | } |
339 | - //MyFrame::m_canvas->PostSizeEventToParent(); | |
340 | 343 | return true; |
341 | 344 | } /* main */ |
342 | 345 |
@@ -134,14 +134,14 @@ void max_and_min() | ||
134 | 134 | min_th[ithread] = new GLfloat[3]; |
135 | 135 | } |
136 | 136 | |
137 | - printf("\n"); | |
138 | - if (color_scale == 1) printf(" ## Color Scale as Input Quantity (Real) #############\n"); | |
139 | - else if (color_scale == 2) printf(" ## Color Scale as Input Quantity (Complex) #############\n"); | |
140 | - else if (color_scale == 3) printf(" ## Color Scale as Fermi Velocity #############\n"); | |
141 | - else if (color_scale == 4) printf(" ## Color Scale as Band Index #############\n"); | |
142 | - else if (color_scale == 5) printf(" ## Gray Scale as Input Quantity (Real) #############\n"); | |
143 | - else if (color_scale == 6) printf(" ## Gray Scale as Fermi Velocity #############\n"); | |
144 | - printf("\n"); | |
137 | + *terminal << wxT("\n"); | |
138 | + if (color_scale == 1) *terminal << wxT(" ## Color Scale as Input Quantity (Real) #############\n"); | |
139 | + else if (color_scale == 2) *terminal << wxT(" ## Color Scale as Input Quantity (Complex) #############\n"); | |
140 | + else if (color_scale == 3) *terminal << wxT(" ## Color Scale as Fermi Velocity #############\n"); | |
141 | + else if (color_scale == 4) *terminal << wxT(" ## Color Scale as Band Index #############\n"); | |
142 | + else if (color_scale == 5) *terminal << wxT(" ## Gray Scale as Input Quantity (Real) #############\n"); | |
143 | + else if (color_scale == 6) *terminal << wxT(" ## Gray Scale as Fermi Velocity #############\n"); | |
144 | + *terminal << wxT("\n"); | |
145 | 145 | /* |
146 | 146 | Search max and min. |
147 | 147 | */ |
@@ -273,14 +273,14 @@ shared(nb,ntri,nmlp,max_th,min_th) private(itri,ithread) | ||
273 | 273 | |
274 | 274 | if (color_scale == 1 || color_scale == 4 |
275 | 275 | || color_scale == 6 || color_scale == 7) { |
276 | - printf(" Min. and Max. value : %f %f\n", patch_min[0], patch_max[0]); | |
276 | + *terminal << wxString::Format(wxT(" Min. and Max. value : %f %f\n"), patch_min[0], patch_max[0]); | |
277 | 277 | } |
278 | 278 | else if (color_scale == 2) { |
279 | - printf(" Max. absolute value : %f\n", patch_max[0]); | |
279 | + *terminal << wxString::Format(wxT(" Max. absolute value : %f\n"), patch_max[0]); | |
280 | 280 | } |
281 | 281 | else if (color_scale == 3) { |
282 | 282 | for (itri = 0; itri < 3; ++itri) { |
283 | - printf(" Min. and Max. value for axis %d : %f %f\n", | |
283 | + *terminal << wxString::Format(wxT(" Min. and Max. value for axis %d : %f %f\n"), | |
284 | 284 | itri, patch_min[itri], patch_max[itri]); |
285 | 285 | } |
286 | 286 | } |
@@ -229,7 +229,7 @@ void bragg_vector() { | ||
229 | 229 | for (ibr = 1; ibr < 26; ibr++) { |
230 | 230 | if (brnrm_min > brnrm[ibr]) brnrm_min = brnrm[ibr]; |
231 | 231 | } |
232 | - printf(" Minimum Bragg norm : %f\n", brnrm_min); | |
232 | + *terminal << wxString::Format(wxT(" Minimum Bragg norm : %f\n"), brnrm_min); | |
233 | 233 | }/* bragg_vector */ |
234 | 234 | /** |
235 | 235 | @brief Print max and minimum @f$\varepsilon_{n k}, \Delta_{n k}@f$ |
@@ -239,10 +239,10 @@ void max_and_min_bz() { | ||
239 | 239 | int ib, i0, i1, i2; |
240 | 240 | GLfloat eigmin, eigmax, matmin, matmax; |
241 | 241 | /**/ |
242 | - printf("\n"); | |
243 | - printf(" ## Max. and Min. of each bands #######################\n"); | |
244 | - printf("\n"); | |
245 | - printf(" Band Eig_Min. Eig_Max Mat_Min Mat_Max\n"); | |
242 | + *terminal << wxT("\n"); | |
243 | + *terminal << wxT(" ## Max. and Min. of each bands #######################\n"); | |
244 | + *terminal << wxT("\n"); | |
245 | + *terminal << wxT(" Band Eig_Min. Eig_Max Mat_Min Mat_Max\n"); | |
246 | 246 | for (ib = 0; ib < nb; ib++) { |
247 | 247 | eigmax = eig0[0][0][0][0]; |
248 | 248 | eigmin = eig0[0][0][0][0]; |
@@ -258,6 +258,7 @@ void max_and_min_bz() { | ||
258 | 258 | }/*for (i2 = 0; i2 < ng0[2]; ++i2)*/ |
259 | 259 | }/*for (i1 = 0; i1 < ng0[1]; ++i1)*/ |
260 | 260 | }/*for (i0 = 0; i0 < ng0[0]; ++i0)*/ |
261 | - printf(" %d %f %f %f %f\n", ib + 1, eigmin, eigmax, matmin, matmax); | |
261 | + *terminal << wxString::Format(wxT(" %d %f %f %f %f\n"), | |
262 | + ib + 1, eigmin, eigmax, matmin, matmax); | |
262 | 263 | }/*for (ib = 0; ib < nb; ib++)*/ |
263 | 264 | }/* max_and_min_bz */ |
@@ -65,7 +65,7 @@ static void kumo_coef( | ||
65 | 65 | void interpol_energy() { |
66 | 66 | int ib, i0, i1, i2, ii; |
67 | 67 | |
68 | - printf(" Interpolating ... "); | |
68 | + *terminal << wxT(" Interpolating ... "); | |
69 | 69 | /* |
70 | 70 | Reallocate |
71 | 71 | */ |
@@ -224,5 +224,5 @@ void interpol_energy() { | ||
224 | 224 | }/*for (i0 = 0; i0 < ng[0]; i0++)*/ |
225 | 225 | }/*for (ib = 0; ib < nb; ib++)*/ |
226 | 226 | }/*End of parallel region*/ |
227 | - printf("Done\n\n"); | |
227 | + *terminal << wxT("Done\n\n"); | |
228 | 228 | }/*void interpol_energy() */ |
@@ -589,6 +589,7 @@ MyFrame::MyFrame(wxFrame* frame, const wxString& title, const wxPoint& pos, | ||
589 | 589 | Bind(wxEVT_COMMAND_MENU_SELECTED, &MyFrame::menu_background, this, menu_background_radio2); |
590 | 590 | imenu_background->AppendRadioItem(menu_background_radio2, wxT("White")); |
591 | 591 | |
592 | + nb = 10;// debug | |
592 | 593 | wxMenu* imenu_band = new wxMenu; |
593 | 594 | for (ib = 0; ib < nb; ib++) { |
594 | 595 | Bind(wxEVT_COMMAND_MENU_SELECTED, &MyFrame::menu_band, this, menu_band_check + ib); |
@@ -719,6 +720,23 @@ MyFrame::MyFrame(wxFrame* frame, const wxString& title, const wxPoint& pos, | ||
719 | 720 | |
720 | 721 | m_canvas = new TestGLCanvas(this, wxID_ANY, gl_attrib); |
721 | 722 | |
723 | + wxBoxSizer* insizer = new wxBoxSizer(wxVERTICAL); | |
724 | + insizer->Add(m_canvas, 1, wxEXPAND, 1); | |
725 | + | |
726 | + terminal = new wxTextCtrl(this, wxID_ANY, wxT(""), | |
727 | + wxPoint(0, 250), wxSize(100, 50), wxTE_MULTILINE); | |
728 | + insizer->Add(terminal, 1, wxEXPAND, 1); | |
729 | + | |
730 | + wxBoxSizer* outsizer = new wxBoxSizer(wxHORIZONTAL); | |
731 | + outsizer->Add(insizer, 1, wxEXPAND, 1); | |
732 | + | |
733 | + wxPanel* panel = new wxPanel(this); | |
734 | + wxButton* select_two = new wxButton(panel, menu_nodeline_check, wxT("Select #&2")); | |
735 | + | |
736 | + outsizer->Add(panel, 1, wxEXPAND, 1); | |
737 | + SetSizer(outsizer); | |
738 | + SetAutoLayout(true); | |
739 | + | |
722 | 740 | // Show the frame |
723 | 741 | Show(true); |
724 | 742 | Raise(); |
@@ -54,41 +54,42 @@ int read_file() | ||
54 | 54 | /* |
55 | 55 | Open input file. |
56 | 56 | */ |
57 | - printf(" Openning %s ...\n", frmsf_file_name.mb_str()); | |
57 | + *terminal << wxT(" Openning ") << frmsf_file_name << wxT(" ...\n"); | |
58 | 58 | if ((fp = fopen(frmsf_file_name.mb_str(), "r")) == NULL) { |
59 | - printf("file open error!!\n"); | |
60 | - printf(" Press any key to exit.\n"); | |
59 | + *terminal << wxT("file open error!!\n"); | |
60 | + *terminal << wxT(" Press any key to exit.\n"); | |
61 | 61 | ierr = getchar(); |
62 | 62 | exit(EXIT_FAILURE); |
63 | 63 | } |
64 | - printf("\n"); | |
65 | - printf(" ## Brillouin zone informations ###########\n"); | |
66 | - printf("\n"); | |
64 | + *terminal << wxT("\n"); | |
65 | + *terminal << wxT(" ## Brillouin zone informations ###########\n"); | |
66 | + *terminal << wxT("\n"); | |
67 | 67 | /* |
68 | 68 | k-point grid |
69 | 69 | */ |
70 | 70 | ctemp1 = fgets(ctemp2, 256, fp); |
71 | 71 | ierr = sscanf(ctemp2, "%d%d%d", &ng0[0], &ng0[1], &ng0[2]); |
72 | 72 | |
73 | - if (ierr == 0) printf("error ! reading ng"); | |
74 | - printf(" k point grid : %d %d %d \n", ng0[0], ng0[1], ng0[2]); | |
73 | + if (ierr == 0) *terminal << wxT("error ! reading ng\n"); | |
74 | + *terminal << wxString::Format(wxT(" k point grid : %d %d %d\n"), | |
75 | + ng0[0], ng0[1], ng0[2]); | |
75 | 76 | for (i = 0; i < 3; i++) ng[i] = ng0[i]; |
76 | 77 | /* |
77 | 78 | Shift of k-point grid |
78 | 79 | */ |
79 | 80 | ierr = fscanf(fp, "%d", &lshift); |
80 | - if (ierr == 0) printf("error ! reading lshift"); | |
81 | + if (ierr == 0) *terminal << wxT("error ! reading lshift\n"); | |
81 | 82 | |
82 | 83 | if (lshift == 0) { |
83 | - printf(" k point grid is the Monkhorst-Pack grid. \n"); | |
84 | + *terminal << wxT(" k point grid is the Monkhorst-Pack grid.\n"); | |
84 | 85 | for (i = 0; i < 3; i++) shiftk[i] = (ng0[i] + 1) % 2; |
85 | 86 | } |
86 | 87 | else if (lshift == 1) { |
87 | - printf(" k point grid starts from Gamma. \n"); | |
88 | + *terminal << wxT(" k point grid starts from Gamma.\n"); | |
88 | 89 | for (i = 0; i < 3; i++) shiftk[i] = 0; |
89 | 90 | } |
90 | 91 | else if (lshift == 2) { |
91 | - printf(" k point grid starts from Gamma + a half grid. \n"); | |
92 | + *terminal << wxT(" k point grid starts from Gamma + a half grid.\n"); | |
92 | 93 | for (i = 0; i < 3; i++) shiftk[i] = 1; |
93 | 94 | } |
94 | 95 | else { |
@@ -98,8 +99,8 @@ int read_file() | ||
98 | 99 | # of bands |
99 | 100 | */ |
100 | 101 | ierr = fscanf(fp, "%d", &nb); |
101 | - if (ierr == 0) printf("error ! reading nb"); | |
102 | - printf(" # of bands : %d\n", nb); | |
102 | + if (ierr == 0) *terminal << wxT("error ! reading nb\n"); | |
103 | + *terminal << wxString::Format(wxT(" # of bands : %d\n"), nb); | |
103 | 104 | ntri = new int[nb]; |
104 | 105 | ntri_th = new int*[nb]; |
105 | 106 | for (ib = 0; ib < nb; ib++) ntri_th[ib] = new int[nthreads]; |
@@ -113,8 +114,8 @@ int read_file() | ||
113 | 114 | */ |
114 | 115 | for (i = 0; i < 3; ++i) { |
115 | 116 | ierr = fscanf(fp, "%e%e%e", &bvec[i][0], &bvec[i][1], &bvec[i][2]); |
116 | - if (ierr == 0) printf("error ! reading bvec"); | |
117 | - printf(" bvec %d : %f %f %f \n", i + 1, bvec[i][0], bvec[i][1], bvec[i][2]); | |
117 | + if (ierr == 0) *terminal << wxT("error ! reading bvec\n"); | |
118 | + *terminal << wxString::Format(wxT(" bvec %d : %f %f %f \n"), i + 1, bvec[i][0], bvec[i][1], bvec[i][2]); | |
118 | 119 | }/*for (i = 0; i < 3; ++i)*/ |
119 | 120 | scl /= sqrtf(bvec[0][0] * bvec[0][0] + bvec[0][1] * bvec[0][1] + bvec[0][2] * bvec[0][2]); |
120 | 121 | linewidth /= scl; |
@@ -125,7 +126,8 @@ int read_file() | ||
125 | 126 | for (j = 0; j < 3; ++j) avec[i][j] = 0.0f; |
126 | 127 | avec[i][i] = 1.0f; |
127 | 128 | solve3(bvec, avec[i]); |
128 | - printf(" avec %d : %f %f %f \n", i + 1, avec[i][0], avec[i][1], avec[i][2]); | |
129 | + *terminal << wxString::Format(wxT(" avec %d : %f %f %f \n"), | |
130 | + i + 1, avec[i][0], avec[i][1], avec[i][2]); | |
129 | 131 | }/*for (i = 0; i < 3; ++i)*/ |
130 | 132 | for (i = 0; i < 3; ++i) { |
131 | 133 | secvec[i] = bvec[2][i]; |
@@ -357,9 +357,9 @@ void calc_section() { | ||
357 | 357 | } |
358 | 358 | ntri_th[ib][0] = 0; |
359 | 359 | } |
360 | - printf(" band # of Fermi-line\n"); | |
360 | + *terminal << wxT(" band # of Fermi-line\n"); | |
361 | 361 | for (ib = 0; ib < nb; ib++) { |
362 | - printf(" %d %d\n", ib + 1, n2d[ib]); | |
362 | + *terminal << wxString::Format(wxT(" %d %d\n"), ib + 1, n2d[ib]); | |
363 | 363 | } |
364 | 364 | /* |
365 | 365 | Allocation of Fermi-lines |
@@ -172,4 +172,6 @@ extern wxString batch_name; | ||
172 | 172 | extern wxString frmsf_file_name; |
173 | 173 | extern int lbatch; |
174 | 174 | |
175 | +extern wxTextCtrl* terminal; | |
176 | + | |
175 | 177 | #endif |