{"id":532,"date":"2008-05-10T13:14:18","date_gmt":"2008-05-10T13:14:18","guid":{"rendered":"http:\/\/6teen.ru\/?p=565"},"modified":"2008-05-10T13:14:18","modified_gmt":"2008-05-10T13:14:18","slug":"8880","status":"publish","type":"post","link":"http:\/\/pblog.ru\/lab\/?p=532","title":{"rendered":"\u041e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 \u0432\u0438\u0434\u0435\u043e\u0441\u0438\u0441\u0442\u0435\u043c\u044b"},"content":{"rendered":"<p>\u041e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 \u0432\u0438\u0434\u0435\u043e\u0441\u0438\u0441\u0442\u0435\u043c\u044b<br \/>\n<!--more--><\/p>\n<pre class=\"alt2\" style=\"margin:0px; padding:6px; border:1px inset; width:580px; height:320px; overflow:auto\"><div>\u041e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 \u0432\u0438\u0434\u0435\u043e\u0441\u0438\u0441\u0442\u0435\u043c\u044b\n\nprocedure TForm1.FormCreate(Sender: TObject);\nvar\nlpDisplayDevice: TDisplayDevice; \/\/\u0434\u043b\u044f \u0438\u043c\u0435\u043d\u0438 \u0432\u0438\u0434\u0435\u043e\u043a\u0430\u0440\u0442\u044b\n\nReg:TRegistry;        \/\/\u0434\u043b\u044f \u0438\u043c\u0435\u043d\u0438 \u043c\u043e\u043d\u0438\u0442\u043e\u0440\u0430\nSubKeys:TStringList;  \/\/\u0434\u043b\u044f \u0438\u043c\u0435\u043d\u0438 \u043c\u043e\u043d\u0438\u0442\u043e\u0440\u0430\nMonitorName:string;   \/\/\u0434\u043b\u044f \u0438\u043c\u0435\u043d\u0438 \u043c\u043e\u043d\u0438\u0442\u043e\u0440\u0430\n\nH,W,B,F:integer;  \/\/\u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u043c\u043e\u043d\u0438\u0442\u043e\u0440\u0430\n\nbegin\n\n\/\/\u0438\u043c\u044f \u0432\u0438\u0434\u0435\u043e\u043a\u0430\u0440\u0442\u044b\nlpDisplayDevice.cb := sizeof(lpDisplayDevice);\nif  EnumDisplayDevices(nil, 0, lpDisplayDevice, 0) then\nLabel2.Caption:='\u0412\u0438\u0434\u0435\u043e\u0430\u0434\u0430\u043f\u0442\u0435\u0440: '+lpDisplayDevice.DeviceString;\n\n\/\/\u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u043c\u043e\u043d\u0438\u0442\u043e\u0440\u0430\nh:=screen.Height;\nw:=screen.Width;\nb:=GetDeviceCaps(Form1.Canvas.Handle, BITSPIXEL);\nf:=GetDeviceCaps(Form1.Canvas.Handle, VREFRESH);\nLabel4.Caption:='\u0412\u0438\u0434\u0435\u043e\u0440\u0435\u0436\u0438\u043c: '+inttostr(w)+'x'+inttostr(h)+' '\n+inttostr(b)+'bit '+inttostr(f)+'Hz';\n\n\/\/\u0438\u043c\u044f \u043c\u043e\u043d\u0438\u0442\u043e\u0440\u0430\nReg:=TRegistry.Create;\nwith Reg do\nbegin\ntry\nRootKey := HKEY_LOCAL_MACHINE;\nOpenKeyReadOnly('SYSTEM\\ControlSet001\\Enum\\DISPLAY\\Default_Monitor');\nSubKeys := TStringList.Create;\nGetKeyNames(SubKeys);\nOpenKeyReadOnly(SubKeys[0]);\nMonitorName:=ReadString('DeviceDesc');\nif MonitorName='' then \/\/\u0435\u0441\u043b\u0438 \u043d\u0435 \u0443\u0434\u0430\u043b\u043e\u0441\u044c \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0438\u043c\u0435\u043d\u0438 \u043c\u043e\u043d\u0438\u0442\u043e\u0440\u0430\nbegin\nLabel3.Caption:='\u041c\u043e\u043d\u0438\u0442\u043e\u0440:  \u043d\u0435 \u0443\u0434\u0430\u043b\u043e\u0441\u044c \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u044c';\nexit;\nend;\nLabel3.Caption:='\u041c\u043e\u043d\u0438\u0442\u043e\u0440: '+MonitorName; \/\/\u0435\u0441\u043b\u0438 \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u0438 \u0438\u043c\u044f \u043c\u043e\u043d\u0438\u0442\u043e\u0440\u0430 \u0432\u044b\u0432\u043e\u0434\u0438\u043c\nSubKeys.Free;\nFree;\nExcept \/\/\u0435\u0441\u043b\u0438 \u043f\u0440\u043e\u0438\u0437\u043e\u0448\u0435\u043b \u0432\u043e\u043e\u0431\u0449\u0435 \u043a\u0430\u043a\u043e\u0439-\u0442\u043e \u0433\u043b\u044e\u043a \u043f\u0440\u0438 \u0440\u0430\u0431\u043e\u0442\u0435 \u0441 \u0440\u0435\u0435\u0441\u0442\u0440\u043e\u043c\nLabel3.Caption:= '\u041c\u043e\u043d\u0438\u0442\u043e\u0440:  \u043d\u0435 \u0443\u0434\u0430\u043b\u043e\u0441\u044c \u043e\u043f\u0440\u0435\u0434\u0435\u043b\u0438\u0442\u044c';\nend;\n\nend;\n<\/div><\/pre>\n<p><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u041e\u043f\u0440\u0435\u0434\u0435\u043b\u0435\u043d\u0438\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 \u0432\u0438\u0434\u0435\u043e\u0441\u0438\u0441\u0442\u0435\u043c\u044b<\/p>\n","protected":false},"author":3,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[433,1081],"tags":[1240,874,886],"_links":{"self":[{"href":"http:\/\/pblog.ru\/lab\/index.php?rest_route=\/wp\/v2\/posts\/532"}],"collection":[{"href":"http:\/\/pblog.ru\/lab\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/pblog.ru\/lab\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/pblog.ru\/lab\/index.php?rest_route=\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"http:\/\/pblog.ru\/lab\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=532"}],"version-history":[{"count":0,"href":"http:\/\/pblog.ru\/lab\/index.php?rest_route=\/wp\/v2\/posts\/532\/revisions"}],"wp:attachment":[{"href":"http:\/\/pblog.ru\/lab\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=532"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/pblog.ru\/lab\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=532"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/pblog.ru\/lab\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=532"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}