Giáo trình hình thành phân mạch ứng dụng điều chế thiết bị bán dẫn chứa các mạch logic điện tử p7
Số trang: 10
Loại file: pdf
Dung lượng: 182.67 KB
Lượt xem: 7
Lượt tải: 0
Xem trước 2 trang đầu tiên của tài liệu này:
Thông tin tài liệu:
Tham khảo tài liệu giáo trình hình thành phân mạch ứng dụng điều chế thiết bị bán dẫn chứa các mạch logic điện tử p7, kỹ thuật - công nghệ, điện - điện tử phục vụ nhu cầu học tập, nghiên cứu và làm việc hiệu quả
Nội dung trích xuất từ tài liệu:
Giáo trình hình thành phân mạch ứng dụng điều chế thiết bị bán dẫn chứa các mạch logic điện tử p7. 67 LUAÂÄN VAÊN TOÁT NGHIEÄP if ((buf = farmalloc(size)) == NULL) { OutMessage(Error: not enough heap space in save_screen().); getch(); closegraph(); exit(1); } else { getimage(x1,y,x,y1,buf); OutMessage(Click a drive name in the list); } setfillstyle(SOLID_FILL,WHITE); bar(x1,y,x,y1); setcolor(BLACK); rectangle(x,y,x1,y1); setcolor(LIGHTGRAY); line(x-1,y+1,x-1,y1-1); line(x1+1,y1-1,x-1,y1-1); setcolor(BLACK); char Temp[3]; for(int i=0;i=x1+1&&LpEvent->PosxPosy>=y+7+i*14&&LpEvent->PosyMsg!=1); putimage(x1,y,buf,COPY_PUT); farfree(buf); return LpEvent; } //--------------------------------------------------------- char *FileType(TEXTBOX *b) { char s[15];. LUAÂÄN VAÊN TOÁT NGHIEÄP 68 b->Path(); b->OutTextBox(); b->GetS(s); return s; } VI.CLASS LIST.HPP #include textbox.hpp #include disklist.hpp #if !defined __LIST__ #define __LIST__ class LIST { private: int l,t,r,b; int Color; public: void InitList(int x1,int y1,int x2,int y2,int Color); void Show(); int Press(char s[],TEXTBOX *Box,unsigned *attrib,char *DiskName,char *DName,char *ftype); int GetList(char s[],TEXTBOX *Box,unsigned *attrib,char *DiskName,char *DName,TEXTBOX *Box2,char *ftype); int Left(){return l;}; int Right(){return r;}; int Top(){return t;}; int Bottom(){return b;}; }; #endif VII.MODULE LIST.CPP #include #include #include #include #include #include #include #include #include #include mouse.h #include list.hpp //--------------------------------------------------------- void LIST::InitList(int x1,int y1,int x2,int y2,int col) { Color=col; l=x1;t=y1;r=x2;b=y2; } //--------------------------------------------------------- void LIST::Show() { setfillstyle(SOLID_FILL,Color); bar(l,t,r,b); int hor=(r-l)/3,ver=(b-t)/3; int x1=l+hor,x2=r-hor,x3=l+(r-l)/2,y1=t+ver,y2=t+ver,y3=b-ver; setcolor(WHITE); line(x1,y1,x2,y2); line(x2,y2,x3,y3); line(x1,y1,x3,y3); setfillstyle(SOLID_FILL,WHITE); floodfill(x1+(x2-x1)/2,y1+(y3-y2)/2,WHITE);. 69 LUAÂÄN VAÊN TOÁT NGHIEÄP setfillstyle(SOLID_FILL,Color); setcolor(BLACK); line(l,b,r,b); line(r,t,r,b); setcolor(WHITE); line(l,t,r,t); line(l,t,l,b); } //--------------------------------------------------------- int LIST::Press(char s[],TEXTBOX *Box,unsigned *attrib,char *DiskName,char *DName,char *ftype) //tra ve 0:nhan Cancel //tra ve 1:nhan OK { TEXTBOX Box2; HideMouse(); int hor=(r-l)/3,ver=(b-t)/3; int x1=l+hor,x2=r-hor,x3=l+(r-l)/2,y1=t+ver,y2=t+ver,y3=b-ver; setcolor(BLACK); line(x1,y1,x2,y2); line(x2,y2,x3,y3); line(x1,y1,x3,y3); setfillstyle(SOLID_FILL,BLACK); floodfill(x1+(x2-x1)/2,y1+(y3-y2)/2,BLACK); setfillstyle(SOLID_FILL,Color); setcolor(WHITE);//vien cho nut bi nhan line(l,b,r,b); line(r,t,r,b); setcolor(BLACK);//vien cho nut bi nhan line(l,t,r,t); line(l,t,l,b); int k=0; *DName=Disk(DiskName); do { char buffer[MAXPATH]; k=GetList(s,Box,attrib,DiskName,DName,&Box2,ftype); getcwd(buffer, MAXPATH); Box->GetS_in(buffer); Box->OutTextBox(); }while(k==2); ShowMouse(); return k;//k=0: nhan Cancel, k=1:nhan OK } //--------------------------------------------------------- int LIST::GetList(char s[],TEXTBOX *Box,unsigned *attrib,char *DiskName,char *DName,TEXTBOX *Box2,char *ftype) { int x11=l-300,y11=b,x12=r+100,y12=b+300;//toa do bang ngoai //600 x 300 la kich thuoc bang ngoai int Kiemtra=0;//bien de kiem tra truong hop chon OK truoc khi chon file LPEVENT lpEvent;//kiem tra bang thu muc void far *buf;//con tro chi vung luu tru man hinh. 70 LUAÂÄN VAÊN TOÁT NGHIEÄP unsigned int size = imagesize(x11,y11,x12,y12); if ((buf = farmalloc(size)) == NULL) { OutMessage(Error: not enough heap space in save_screen().); getch(); closegraph(); exit(1); } else { getimage(x11,y11,x12,y12, buf); OutMessage(Choose a file name then click OK to accept or click Cancel to ignore); ...
Nội dung trích xuất từ tài liệu:
Giáo trình hình thành phân mạch ứng dụng điều chế thiết bị bán dẫn chứa các mạch logic điện tử p7. 67 LUAÂÄN VAÊN TOÁT NGHIEÄP if ((buf = farmalloc(size)) == NULL) { OutMessage(Error: not enough heap space in save_screen().); getch(); closegraph(); exit(1); } else { getimage(x1,y,x,y1,buf); OutMessage(Click a drive name in the list); } setfillstyle(SOLID_FILL,WHITE); bar(x1,y,x,y1); setcolor(BLACK); rectangle(x,y,x1,y1); setcolor(LIGHTGRAY); line(x-1,y+1,x-1,y1-1); line(x1+1,y1-1,x-1,y1-1); setcolor(BLACK); char Temp[3]; for(int i=0;i=x1+1&&LpEvent->PosxPosy>=y+7+i*14&&LpEvent->PosyMsg!=1); putimage(x1,y,buf,COPY_PUT); farfree(buf); return LpEvent; } //--------------------------------------------------------- char *FileType(TEXTBOX *b) { char s[15];. LUAÂÄN VAÊN TOÁT NGHIEÄP 68 b->Path(); b->OutTextBox(); b->GetS(s); return s; } VI.CLASS LIST.HPP #include textbox.hpp #include disklist.hpp #if !defined __LIST__ #define __LIST__ class LIST { private: int l,t,r,b; int Color; public: void InitList(int x1,int y1,int x2,int y2,int Color); void Show(); int Press(char s[],TEXTBOX *Box,unsigned *attrib,char *DiskName,char *DName,char *ftype); int GetList(char s[],TEXTBOX *Box,unsigned *attrib,char *DiskName,char *DName,TEXTBOX *Box2,char *ftype); int Left(){return l;}; int Right(){return r;}; int Top(){return t;}; int Bottom(){return b;}; }; #endif VII.MODULE LIST.CPP #include #include #include #include #include #include #include #include #include #include mouse.h #include list.hpp //--------------------------------------------------------- void LIST::InitList(int x1,int y1,int x2,int y2,int col) { Color=col; l=x1;t=y1;r=x2;b=y2; } //--------------------------------------------------------- void LIST::Show() { setfillstyle(SOLID_FILL,Color); bar(l,t,r,b); int hor=(r-l)/3,ver=(b-t)/3; int x1=l+hor,x2=r-hor,x3=l+(r-l)/2,y1=t+ver,y2=t+ver,y3=b-ver; setcolor(WHITE); line(x1,y1,x2,y2); line(x2,y2,x3,y3); line(x1,y1,x3,y3); setfillstyle(SOLID_FILL,WHITE); floodfill(x1+(x2-x1)/2,y1+(y3-y2)/2,WHITE);. 69 LUAÂÄN VAÊN TOÁT NGHIEÄP setfillstyle(SOLID_FILL,Color); setcolor(BLACK); line(l,b,r,b); line(r,t,r,b); setcolor(WHITE); line(l,t,r,t); line(l,t,l,b); } //--------------------------------------------------------- int LIST::Press(char s[],TEXTBOX *Box,unsigned *attrib,char *DiskName,char *DName,char *ftype) //tra ve 0:nhan Cancel //tra ve 1:nhan OK { TEXTBOX Box2; HideMouse(); int hor=(r-l)/3,ver=(b-t)/3; int x1=l+hor,x2=r-hor,x3=l+(r-l)/2,y1=t+ver,y2=t+ver,y3=b-ver; setcolor(BLACK); line(x1,y1,x2,y2); line(x2,y2,x3,y3); line(x1,y1,x3,y3); setfillstyle(SOLID_FILL,BLACK); floodfill(x1+(x2-x1)/2,y1+(y3-y2)/2,BLACK); setfillstyle(SOLID_FILL,Color); setcolor(WHITE);//vien cho nut bi nhan line(l,b,r,b); line(r,t,r,b); setcolor(BLACK);//vien cho nut bi nhan line(l,t,r,t); line(l,t,l,b); int k=0; *DName=Disk(DiskName); do { char buffer[MAXPATH]; k=GetList(s,Box,attrib,DiskName,DName,&Box2,ftype); getcwd(buffer, MAXPATH); Box->GetS_in(buffer); Box->OutTextBox(); }while(k==2); ShowMouse(); return k;//k=0: nhan Cancel, k=1:nhan OK } //--------------------------------------------------------- int LIST::GetList(char s[],TEXTBOX *Box,unsigned *attrib,char *DiskName,char *DName,TEXTBOX *Box2,char *ftype) { int x11=l-300,y11=b,x12=r+100,y12=b+300;//toa do bang ngoai //600 x 300 la kich thuoc bang ngoai int Kiemtra=0;//bien de kiem tra truong hop chon OK truoc khi chon file LPEVENT lpEvent;//kiem tra bang thu muc void far *buf;//con tro chi vung luu tru man hinh. 70 LUAÂÄN VAÊN TOÁT NGHIEÄP unsigned int size = imagesize(x11,y11,x12,y12); if ((buf = farmalloc(size)) == NULL) { OutMessage(Error: not enough heap space in save_screen().); getch(); closegraph(); exit(1); } else { getimage(x11,y11,x12,y12, buf); OutMessage(Choose a file name then click OK to accept or click Cancel to ignore); ...
Tìm kiếm theo từ khóa liên quan:
giáo trình vật lý tài liệu vật lý phương pháp quang học kỹ năng quang học thủ thuật quang họcGợi ý tài liệu liên quan:
-
Giáo trình Vật lý đại cương A2: Phần 2 - ThS. Trương Thành
78 trang 121 0 0 -
Giáo trình hình thành ứng dụng điện thế âm vào Jfet với tín hiệu xoay chiều p2
10 trang 55 0 0 -
Giáo trình giải thích việc nôn mửa do phản xạ hoặc do trung khu thần kinh bị kích thích p10
5 trang 54 0 0 -
Giáo trình hình thành đặc tính kỹ thuật của bộ cánh khuấy Mycom trong hệ số truyền nhiệt p2
5 trang 48 0 0 -
Giáo trình Vật lý phân tử và nhiệt học: Phần 1
54 trang 47 0 0 -
Giáo trình hình thành nguyên lý ứng dụng hệ số góc phân bố năng lượng phóng xạ p4
10 trang 42 0 0 -
13. TƯƠNG TÁC GIỮA HAI DÒNG ĐIỆN THẲNG SONG SONG. ĐỊNH NGHĨA ĐƠN VỊ AM-PE
4 trang 37 0 0 -
Giáo trình Vật lý phân tử và nhiệt học: Phần 2
72 trang 35 0 0 -
Giáo trình hình thành phân đoạn ứng dụng cấu tạo đoạn nhiệt theo dòng lưu động một chiều p5
10 trang 30 0 0 -
35 trang 29 0 0