You can subscribe to this list here.
2003 |
Jan
|
Feb
(22) |
Mar
(6) |
Apr
(1) |
May
|
Jun
|
Jul
(1) |
Aug
(3) |
Sep
(1) |
Oct
(15) |
Nov
(13) |
Dec
(3) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2004 |
Jan
(2) |
Feb
(2) |
Mar
|
Apr
|
May
(1) |
Jun
(1) |
Jul
|
Aug
(2) |
Sep
|
Oct
|
Nov
|
Dec
|
2005 |
Jan
|
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: Max B. <be...@ma...> - 2005-02-25 16:08:39
|
http://www.livejournal.com/users/mugzbel/2621.html?mode=reply Наткнулся на довольно интересную ветку. Вкратце: некто попробовал сконвертить свою ASP страничку на js на ASPX и в результате получил 50 секунд вместо 1-2. Народ предложил ему лечение и в конце концов он добился такого же результата: "I finally got around to making this change. At this point, I am actually slightly faster (for my reports) than before I converted to .net. To recount: my original wsc jscript reports were 1-2 seconds typically. After my initial conversion to .net, they were 35+ seconds. By making db, stringbuilder, etc, this came down to 25+ seconds. By remaking my regular expressions processing down to 5-6+ seconds, and by finally making the above global change with an associated function processing, 1-2 seconds. Thanks for your assistance." -- Best regards, Max mailto:be...@ma... http://belugin.newmail.ru ICQ:9406811 |
From: Max B. <be...@ma...> - 2004-08-02 14:21:28
|
def cp1251to8859(x): try: return ord(unicode(chr(x), 'cp1251').encode('iso8859-5')) except: return x print map(cp1251to8859, range(0,255)) кто может сделать короче/красивей? -- Best regards, Max mailto:be...@ma... http://belugin.newmail.ru ICQ:9406811 |
From: Max B. <be...@ma...> - 2004-08-02 14:01:40
|
было пари между питоном и перротом (то есть гвидо ван россумом и еще каким-то хреном - автором перрота) - кто быстрее. питона порвал перрота как тузик грелку. во результатом испытаний автору перрота (который сам на пари и напросился) зафигачили тортом фото см.: http://www.onlamp.com/lpt/wlg/5346 PS пэррот - новая универсальная виртульная машина -- Best regards, Max mailto:be...@ma... http://belugin.newmail.ru ICQ:9406811 |
From: G r u N T X P <gr...@na...> - 2004-06-02 07:39:00
|
О, великий All! Немного Offtop, но оно стоит того: www.bluej.org На мой взгляд _лучшая_ тулза для создания небольших PureJava-проектов... -- G═r═u═N═T═══X═P |
From: Max B. <be...@ma...> - 2004-05-28 06:29:12
|
Hello winscript-talks, http://www.neowin.net/articles.php?action=more&id=88 Over the last couple of months, Neowin has tracked the development of perhaps one of the most promising open source projects for a long time : Mozilla Firefox, or Firefox. We've managed to have a talk to Ben Goodger, chief developer of Firefox, about whats new in the upcoming release, and much much more. Q. Hi Ben, great to speak to you again. As Firefox has gone from strength to strength, how have the last few months been in your role as chief developer? Busy. Stressful. Action Packed. Q. Sounds fun! Has the enormous popularly of the 0.8 release had any adverse effects? The popularity of 0.8 - especially within the first few days - surprised all of us. Our FTP mirror network experienced load problems that caused many people to have a lot of trouble getting the software. Our community/news partner MozillaZine also experienced a number of problems as people rushed in to find out more about new release. A lot of people also began experiencing problems upgrading incompatible extensions also. We tend to see such things as learning experiences - so we're planning for a much beefier distribution network for 1.0 and more stable treatment of add-ons. Sites like MozillaZine rely on community support to stay running so all I can say to people is give generously if you value the services they provide. Q. With 0.8 must come a 0.9; whats new and exciting in the upcoming release? Tom, this is our biggest release yet. I know I've said that for pretty much every release we've done so far, but it continues to be true. Here's some of what's new in 0.9: Stability: New Extension and Theme systems that allow extension developers to design more ambitious extensions, and to provide a stable scalable method of keeping extensions and themes up to date and ensuring incompatible extensions or themes do not break the application. Countless bug fixes, visual appearance updates and other refinements Easing the Transition: Dramatically smaller download size (now only 4.6MB) Migration of data for users of Internet Explorer, Opera, Netscape 7.x and Mozilla 1.x, and Netscape 4.x on Windows, Netscape 7.x and Opera on Mac and Linux (with more import sources to come in 1.0). People using IE now will find that all of their user data - Favorites, Passwords, Cookies, right down to form data, browsing history, and search keywords. Improvements to make Searching, Bookmarks The ability to launch your default email/news readers from the browser Q. Although you mentioned last time that you didn't use many extensions, have you found any since then that are particularly useful to you, or themes for that matter? Do you have any plans to bundle some of the more popular extensions with future releases? I still find nothing that I absolutely rely upon. I think as long as most people can get their work done with the standard configuration we're doing a good job. We already bundle Inspector as an optional installable component for web developers. In the future we might look at other add-ons but it's something we don't really have time to investigate right now. Q. Some readers might have noticed your blog has some news on the new extensions manager- can you tell us a bit more about whats new there? Will it let people uninstall extensions rather than just disable them? Yes. The new Extension Manager lets users install extensions into their profile (especially useful on multi-user systems where some extensions before would only install into non-accessible areas of the disk) and also does comprehensive version checking to make sure that incompatible extensions are not installed. Users can also elect to be notified of updates to their extensions so they can upgrade them when newer versions come out. There is also a "safe mode" whereby the user can start the application with the "-no-extensions" switch and have all extensions disabled in the event that there are ever any problems. We are also developing a user friendly centralized distribution site that ties into the update checking system and allows trusted extension developers to release updates to their extensions themselves. Q. So after 0.9, whats the plan towards 1.0 and after? Will we loose the Firefox name and see Mozilla Browser and Mozilla Mail? No - we'll be continuing to use Firefox and Thunderbird as the product names. After 0.9 work will continue on driving the list of 1.0 bugs to zero, which includes a lot of polish and stability work, some more low-opportunity-cost UI changes, and other stuff. Don't expect any more big features, but expect Firefox to work better and better. Q. How does the Firefox team feel about all the optimized builds that the community puts out on it's own. Do you think it helps the development of Firefox? We've looked at a few optimized builds and notice some of them feel faster, and have begun evaluating some of the options used to create them. In this regard they're beneficial in the same way extensions are - they allow community members to experiment with new features and configurations that we perhaps don't have time to look at ourselves and prove the merits of them. Q. Is the Mozilla team going to implement a new look and feel for Firefox, similar to what Opera have done for their latest release? On that note- have you seen the new Opera browser? What do you think of it? Do you feel that the appearance of applications play a major role when users make a decision of which product to use? We may make ongoing theme improvements and running UI changes as the need arises. We aren't planning any large scale changes before 1.0. The new Opera browser has a lot of improvements that I'm sure its users will enjoy. While I feel that there is a set of users who place a high importance on looks or "feature count", ultimately most people prefer a tool that lets them accomplish what they want to accomplish with minimal intrusion. Q. This one is particularly directed to you by one of our neowin staff! He wondered what usually happens in the day for the guy who is the chief developer of Firefox. I work from home a little in the (late) morning, reading my email, etc; travel the short distance to the Mozilla Foundation's Mountain View headquarters. There I spend my time writing code and interacting with the other engineers that work out of that office, including Mozilla CTO Brendan Eich, Johnny Stenback, David Baron, my Thunderbird counterpart Scott MacGregor, Myk Melez, Asa Dotzler, and Brian Ryner and Darin Fisher from IBM. Depending on the day of the week there may be meetings (e.g. the Monday Mozilla Staff meeting or any number of other formal or informal engineering discussions) where we meet in our "war room" - a set of tables at the far end of our offices with people local and remote. With the increased amount of work lately and the deadlines for 1.0, I've been doing more and more work in the evenings as well. Q. Stepping back from Firefox for a second; I often thought how it would be a great idea to have a 'common Mozilla code base', allowing perhaps 1 big download, but very small files for Firefox / Thunderbird / the suite and other XUL programs. Does foundation have any plans to do something like this? One thing we eventually want to pursue is a "XUL Runtime Environment" that is independent from any particular application front end whereby just the application level components (front ends) can be downloaded. In that instance the browser might be only 2MB if you already have the runtime installed. Thunderbird might be as small as 4MB. Q. Since we last spoke, Microsoft have been making a big show of Longhorn and it's new technologies like XAML. Some readers might have noticed Mozilla forging tight links with the Gnome people; asides from this what else is Mozilla doing to promote XUL (more) and provide effective competition to Longhorn? One of the things we want to pursue aggressively in the next 12 months is improving the XUL toolkit to a) polish the feature set (adding any missing widgets, smoothing over the rough edges, etc) b) add new graphics capabilities that offer more flexibility to application developers using XUL, and c) make it easier for developers to start using XUL and develop and debug with their favorite language. Q. In terms of XUL, the language Firefox is written in, how do you see the foundation encouraging its use? Many coders find it hard to get into due to lack of documentation / support / examples - how would you respond to this? We lack the immense documentation resources that companies like Microsoft have to throw behind their technologies. XUL was originally designed to solve a problem that Netscape had - and as a result the set of features it had and the tools that existed to develop with it were generally only as sophisticated as Netscape needed for its software. With this second round - "XUL2" - we are a bit more experienced in the world of toolkits, and are tackling this with a more general approach. XUL2 is part of a larger API effort - "Mozilla 2.0" (that has no relation to any Mozilla product line e.g. Mozilla 1.7 - it is merely meant to indicate a new set of stable APIs) for which we hope to have more of a focus on XUL application development, more useful stable APIs for application development, and documentation of those APIs with a new project called "devmo". Q. A recent blog entry of yours called for more people to get involved with the project; have you had any thoughts on how to do this successfully? Are things like bug day the answer? Contributions in the form of good bug reports, reduced test cases and other things that help engineers are great. People supplying patches to their favorite bugs is great. In my blog I was talking more to the big picture future of Mozilla, relating to some of the things Brendan talked about in his presentation at the first Mozilla Foundation developer day in February (slides: here)... to progress towards those goals, and to create new and innovative applications we need more big thinkers dedicated engineers and designers passionate about the technology we work with, and passionate about the applications we create. It's really the sort of thing that requires more than casual or occasional contribution. We're trying to find ways to get plugged into the various communities where people that fit this bill live Thanks again Ben for taking the time to chat with us! Best of luck with the up-coming releases, and i look forward to talking to you again a couple of months down the road Neowin readers, stay tuned for the Firefox release around early-mid June for 0.9 and 1.0 in the late summer/early fall, and a revised guide on the best extensions, themes, and how to get the most out of your browser with those releases, exclusivly from Neowin. View: Firefox Homepage View: Firefox Development Roadmap Download: Win / Nix / Mac View: Previous chat with Ben View: Neowin's essential guide to Firefox Back to Neowin.net -- Best regards, Max mailto:be...@ma... http://belugin.newmail.ru ICQ:9406811 |
From: Peter B. S. <vs...@ho...> - 2004-02-22 21:01:25
|
Max Belugin wrote: > =CE=C1=C4=CF =C2=D9=CC=CF =D3=C4=C5=CC=C1=D4=D8 =DE=D4=CF=C2=D9 =CF=CB=CE= =CF HTA =C2=D9=CC =D4=C1=CB=CF=C7=CF =D6=C5 =D2=C1=DA=CD=C5=D2=C1 =CB=C1=CB= =C9 =C5=C7=CF > =D3=CF=C4=C5=D2=D6=C9=CD=CF=C5 (=D4=C1=CB =CF=CE=CF =CE=C1=CD=CE=CF=C7=CF= =C2=CF=CC=D8=DB=C5). =F0=CF=CC=D5=DE=C9=CC=CF=D3=D8 =C4=CF=D7=CF=CC=D8=CE= =CF =CB=CF=D3=D4=D9=CC=D8=CE=CF: =EE=C9=DE=C5=C7=CF =CE=C5 =CB=CF=D3=D4=D9=CC=D8=CE=CF, =D0=CF-=CD=CF=C5=CD= =D5. =E4=CC=D1 =CE=C5=C2=CF=CC=D8=DB=C9=C8 =C4=CF=CB=D5=CD=C5=CE=D4=CF=D7= =D4=C1=C2=CC=C9=C3=D5 =CD=CF=D6=CE=CF =D7=CF=CF=C2=DD=C5 =D3=CB=D2=C9=D0=D4=CF=CD =D3=CF=DA=C4=C1=D7=C1=D4=D8. = =F1 =DA=CE=C1=C0 =C4=D2=D5=C7=C9=C5 =CB=CF=D3=D4=D9=CC=C9 =C4=CC=D1 IE 6:= =D5=CB=C1=DA=D9=D7=C1=C5=CD =CB=C1=CB=CF=CA-=CE=C9=D4=D8 =D3=D4=C1=CE=C4=C1=D2=D4=CE=D9=CA DOCTYPE, =C7= =CF=D7=CF=D2=C9=CD <body style=3D"display:inline"> =C9 =D3=CD=CF=D4=D2=C9=CD document.body.offsetWidth. =E5=D3=CC=C9 =CE=C5 = =C9=D3=D0=CF=CC=D8=DA=CF=D7=C1=D4=D8 hr, =D4=CF =D0=D2=CF=CB=C1=D4=C9=D4. -- 0xdeadbeef |
From: Max B. <be...@ma...> - 2004-02-19 10:35:06
|
Hello winscript-talks, надо было сделать чтобы окно HTA был такого же размера как и его содержимое (так оно намного больше). Получилось довольно костыльно: 1. создаем всеобъемлющую таблицу без бордера <TABLE ID="ttt" WIDTH="" CELLPADDING="0" BORDER="0" CELLSPACING="0"> 2. В самый конец вставляем: <SCRIPT LANGUAGE="JavaScript"><!-- window.resizeBy(ttt.offsetWidth-document.body.clientWidth, ttt.offsetHeight-document.body.clientHeight); //--> </SCRIPT> Полный текст hta в атаче (подсчет трафика за неделю по логам TMeter). Если хотите добиться работоспособности без TMeter - закомментируйте вызов refresh() -- Best regards, Max mailto:be...@ma... http://belugin.newmail.ru ICQ:9406811 |
From: Max B. <be...@ma...> - 2004-01-08 15:14:20
|
Hello Max, Thursday, January 8, 2004, 12:50:35 PM, you wrote: MB> http://www.digitalmars.com/dscript/index.html Попробовал поставить, SHPCE сразу свалился и я его убрал из режима замены JScript -- Best regards, Max mailto:be...@ma... http://belugin.newmail.ru ICQ:9406811 |
From: Max B. <be...@ma...> - 2004-01-08 09:50:41
|
Hello winscript-talks, http://www.digitalmars.com/dscript/index.html What is DMDScript? DMDScript is Digital Mars' implementation of the ECMA 262 scripting language. Netscape's implementation is called JavaScript, Microsoft's implementation is called JScript. DMDScript is much faster than other implementations, which you can verify with the included benchmark. Note: DMDScript is not the D Programming Language, nor is it Java. Here is the FAQ for ECMAScript. Key Benefits of DMDScript Implementation of ECMA 262 with JScript extensions. More than twice as fast as JScript, as measured by included benchmark. Both standalone and COM versions built from the same source. Ideal for embedded systems - standalone version is not dependent on Windows COM API. Ideal for ECMAscript enabling browsers, email clients, and any application that needs a scripting language. -- Best regards, Max mailto:be...@ma... http://belugin.newmail.ru ICQ:9406811 |
From: Max B. <be...@ma...> - 2003-12-30 13:03:54
|
Hello winscript-talks, С помощью Славы Печенина и Грунта сделал простенький профилировщик для скриптов: http://winscript.sourceforge.net/modules.php?op=modload&name=News&file=article&sid=8&mode=thread&order=0&thold=0 -- Best regards, Max mailto:be...@ma... http://belugin.newmail.ru ICQ:9406811 |
From: Max B. <be...@ma...> - 2003-12-10 12:22:04
|
This is a forwarded message From: Дьяков Константин Михайлович <ko...@ga...> To: Max Belugin <be...@ma...> Date: Wednesday, December 10, 2003, 3:18:52 PM Subject: Using .NET Languages to make your Application Scriptable ===8<==============Original message text=============== http://www.divil.co.uk/net/articles/plugins/scripting.asp ===8<===========End of original message text=========== -- Best regards, Max mailto:be...@ma... http://belugin.newmail.ru ICQ:9406811 |
From: Max B. <be...@ma...> - 2003-11-25 12:57:25
|
Hello winscript-talks, Mozilla 1.5 ActiveX Control Released http://mozillazine.org/talkback.html?article=4008 Daniel Wang wrote in to tell us that Adam Lock of the Mozilla ActiveX Project has released version 1.5 of the Mozilla ActiveX Control, which allows developers to embed Gecko into applications in much the same way that they can embed Internet Explorer. The control supports most of the API of the IE control for easy porting. The Mozilla 1.5 ActiveX Control can be downloaded from www.iol.ie/~locka/mozilla/MozillaControl15.exe. -- Best regards, Max mailto:be...@ma... http://belugin.newmail.ru ICQ:9406811 |
From: Max B. <be...@ma...> - 2003-11-25 09:15:30
|
Hello winscript-talks, Для своей программы (http://platwar.banksoft.ru) делаю скриптоплагин с интерфейсом пользователя на основе IE. Как сделать так, чтобы окно растягивалось по размеру контролов в окне? вот как я открываю окно: function showTemplate(name){ var ie=new ActiveXObject("InternetExplorer.Application"); ie.menubar = 0; ie.toolbar = 0; ie.statusbar = 0; ie.addressbar = 0; ie.Navigate(template(name)); ie.Visible = true; while(ie.Busy); return ie; } -- Best regards, Max mailto:be...@ma... http://belugin.newmail.ru ICQ:9406811 |
From: Max B. <be...@ma...> - 2003-11-20 13:34:39
|
Hello winscript-talks, http://www.artima.com/intv/tuesday.html ... Bill Venners: In Ruby, I can add methods and variables to objects at runtime. I have certainly added methods and variables to classes, which become objects at runtime, in other languages. But in Java, for example, once a class is loaded or an object is instantiated, its interface stays the same. Allowing the interface to change at runtime seems a bit scary to me. I'm curious how I would use that feature in Ruby. What's the benefit of being able to add methods at runtime? Yukihiro Matsumoto: First of all, you don't have to use that feature. The most useful application of dynamic features, such as adding methods to objects, is meta-programming. Such features allow you to create a library that adapts to the environment, but they are not for casual uses. Bill Venners: What's an example of a library that adapts to the environment? Yukihiro Matsumoto: One example is a proxy. Instead of designing individual proxy classes for each particular class, in Ruby you can create an all purpose proxy that can wrap any object. The proxy can probe the object inside of it and just morph into the proxy for that object. The proxy can add methods to itself so it has the same interface as the wrapped object, and each of those methods can delegate to the corresponding method in the wrapped object. So an all-purpose proxy, which can be used to wrap any object, is an example of how a library class can adapt to the environment. Adding methods to objects can also be used in Ruby in situations where Java programmers use inner classes. For example, if you need to pass a listener object to some method, in Java you often instantiate an anonymous inner class that defines the listener methods and pass it. In Ruby, you can just create a plain object≈an instance of class Object≈add the needed listener methods to it dynamically, and pass it. ... Кстати, я помню такой же довод от В. Метелицы, он говорил, что в Java версии TopLink приходится для каждого класса генерировать несколько Proxy -- Best regards, Max mailto:be...@ma... http://belugin.newmail.ru ICQ:9406811 |
From: Max B. <be...@ma...> - 2003-11-20 13:30:30
|
Hello winscript-talks, Третья международная конференция по Ruby. Слайды: http://www.rubyist.net/~matz/slides/rc2003/ -- Best regards, Max mailto:be...@ma... http://belugin.newmail.ru ICQ:9406811 |
From: Max B. <be...@ma...> - 2003-11-20 10:55:21
|
This is a forwarded message From: Max Belugin <be...@ma...> To: fid...@ta... <fid...@ta...> Date: Wednesday, November 19, 2003, 11:13:03 AM Subject: ===8<==============Original message text=============== Hello fido7, SU> Задача: Есть куча тестовых файлов. Требуется просканировать все эти SU> текстовые файлы и получить список всех строк, содержащих определенную SU> подстроку и записать его в текстовый файл log-файл в следующем формате: SU> <Имя файла1>: SU> строка1 SU> строка2 SU> ... SU> <Имя файла2>: SU> строка1 SU> строка2 SU> ... SU> итд. SU> Есть готовое решение? Желательно привести реальный пример. Это простой скрипт. Вот например на Питоне, а ниже на js searcher.py: # -*- coding: cp1251 -*- import os import re searchString="test" # для всех файлов в текущей папке for fileName in os.listdir("."): fileNamePrinted=False # если совпадает с маской if re.match(".*\.txt$", fileName, re.I): # для каждой строки файла for line in file(fileName): # если есть строка поиска if line.find(searchString)!=-1: # если еще не напечатали имя файла if not fileNamePrinted: # печатаем его print fileName+":" # и запоминаем этот факт fileNamePrinted=True # печатаем строку print line searcher.js: var searchString="test"; var fs //: FileSystemObject = new ActiveXObject("Scripting.FileSystemObject"); var folder // : Folder = fs.GetFolder("."); var eFiles=new Enumerator(folder.Files); for (;!eFiles.atEnd(); eFiles.moveNext()){ var fileNamePrinted=false; var file //:File = eFiles.item(); if(file.Name.match(/.*\.txt$/i)){ var src //:TextStream =file.OpenAsTextStream(); while(!src.AtEndOfStream){ var s // :String =src.ReadLine(); if(s.indexOf(searchString)!=-1){ if(!fileNamePrinted){ WScript.Echo(file.Name+":"); fileNamePrinted=true; } WScript.Echo(s); } } } } //Files collection Best regards, Max http://farplugins.sf.net ICQ:9406811 ===8<===========End of original message text=========== -- Best regards, Max mailto:be...@ma... http://belugin.newmail.ru ICQ:9406811 |
From: Peter B. S. <vs...@ho...> - 2003-11-20 05:24:28
|
"G r u N T X P" wrote: > RTFM до просветления: Рассказать, куда засунуть этот FM? Точнее, эту его часть. === wscript.idl === // Generated .IDL file (by the OLE/COM Object Viewer) // // typelib filename: <could not determine filename> [ uuid(60254CA0-953B-11CF-8C96-00AA00B8708C), version(5.6), helpstring("Windows Script Host (Ver 5.6)") ] library IHost { interface IHost : IDispatch { [id(0x000007d5)] HRESULT ConnectObject( [in] IDispatch* Object, [in] BSTR Prefix); Ответ нашелся здесь: http://groups.google.com/groups?hl=en&lr=&ie=UTF-8&th=f48daee6f30e3935 -- 0xdeadbeef |
From: G r u N T X P <gr...@na...> - 2003-11-18 07:44:11
|
Приветствую, Peter B. Shalimoff. PBS> Почему может не работать сабжевый метод? А зачем он тебе? PBS> var IE = new ActiveXObject("InternetExplorer.Application"); PBS> WScript.ConnectObject(IE, "IE_"); PBS> получаю исключение "WScript.CreateObject: Could not connect object." Кто бы думал! %) PBS> А если делать так: PBS> var IE = WScript.CreateObject("InternetExplorer.Application", "IE_"); PBS> то все работает. С ReGet'ом (например) - такая же ерунда происходит. PBS> Надо WSH как-то хитро настраивать? RTFM до просветления: Connects the object's event sources to functions with a given prefix. object.ConnectObject(strObject, strPrefix) Arguments object WScript object. strObject vvvvvv Required. >String< value indicating the name of the object you want to connect. strPrefix ^^^^^^ Required. String value indicating the function prefix. Remarks Connected objects are useful when you want to sync an object's events. The ConnectObject method connects the object's outgoing interface to the script file after creating the object. Event functions are a combination of this prefix and the event name. PBS> -- ^ one space here -- G═r═u═N═T═══X═P |
From: Peter B. S. <vs...@ho...> - 2003-11-17 23:38:50
|
Здравствуйте. Почему может не работать сабжевый метод? var IE = new ActiveXObject("InternetExplorer.Application"); WScript.ConnectObject(IE, "IE_"); получаю исключение "WScript.CreateObject: Could not connect object." А если делать так: var IE = WScript.CreateObject("InternetExplorer.Application", "IE_"); то все работает. С ReGet'ом (например) - такая же ерунда происходит. Надо WSH как-то хитро настраивать? -- 0xdeadbeef |
From: Max B. <be...@ma...> - 2003-11-10 09:29:50
|
Hello winscript-talks, http://ruby.boxload.net/lection.php?lect=f21 Сравнение Ruby и Python'а Python и Ruby оба являются объектно-ориентированными языками программирования, которые обеспечивают плавный переход от процедурного стиля к объектно-ориентированному. Smalltalk же, напротив, является исключительно объектно-ориентированным -- вы не сможете ничего сделать, пока не поймете суть объектов, наследование и внушительную иерархию классов Smalltalk'а. Допуская процедурный подход в качестве некоторого подспорья на время изучения OO, Python и Ruby исправляют то, что мешало Smalltalk'у стать широко используемым, но они отличаются тем, что решают эту проблему разными способами. Python -- смешанный язык. В нем есть функции для процедурного программирования и объекты для объектно-ориентированности. Python соединяет эти два мира, позволяя функциям и методам преобразовываться друг в друга, используя эксплицитный параметр self в каждом определении метода. Когда функция помещается в класс, первый аргумент автоматически становиться ссылкой на сам объект. Ruby -- это полностью объектно-ориентированный язык, который может ``притворяться'' процедурным. В нем нет функций, есть только методы. В методе Ruby сам объект, также называемый self, является скрытым аргументом, как this в С++. Определение (def) вне тела класса (то, что в Python является функцией) -- это на самом деле метод. Эти заменители функций становятся private методами класса Object, верхнего класса в иерархии классов Ruby. Проблема процедурного программирования элегантно решена с другого конца -- все есть объект. Если пользователь пока не понимает объекты, он может использовать def как определение функции, и все будет работать. Полная объектно-ориентированность Ruby порождает некоторое количество свойств, отсутствующих в Python, или только появляющихся в нем: единая иерархия типов/классов, возможность наследоваться от всех классов, и единый способ вызова методов (нет такого, что len() -- это функция, а items() -- это метод). Ruby, как и Smalltalk, допускает только единичное наследование, но имеет очень мощное средство -- mix-in, суть его в том, что класс может включить в себя модуль, и все методы и переменные модуля становятся методами и переменными класса. Ruby, опять же как Smalltalk, имеет замыкания и блоки кода, и использует их так же хорошо, как и Smalltalk. Классы коллекций в Ruby просто выдающиеся, намного более мощные и элегантные, чем аналогичные ad hoc решения в Python -- лямбда и обработка списков. На синтаксис и дизайн Ruby сильно повлиял Perl. Ruby имеет синтаксическую вариативность. Модификаторы выражений (if, unless, while, until и другие) могут следовать после любого выражения. Некоторые служебные слова опциональны (например, then в условной конструкции). Скобки в вызове метода могут быть иногда опущены. self может быть опущен. Довольно многие вещи пришли прямо из Perl. Встроенные регулярные выражения, /usr/local/apache/bin/httpd и его друзья, встроенные документы, разница между двойными и одинарными кавычками, префиксы $ и @ для различения разных типов переменных и так далее. Если вам нравится Perl, c синтаксисом Ruby вы сразу почувствуете себя дома. Если вам нравится Smalltalk, вы почувствуете себя дома благодаря семантике Ruby. Если вам нравится Python, может случится такое (а может, и нет), что Ruby вам не пойдет, так как дизайн Python сильно отличается от дизайна Ruby/Perl. Ruby гораздо более сложный, чем Python, но его особенности в основном очень хорошо сочетаются друг с другом. Дизайн Ruby очень хорош и полон элегантных идей, которые следует рассмотреть для следующей версии Python. Хотя я и не знаю, насколько многим программистам на Python они понравятся. Но Ruby достоин серьезного изучения и мог бы стать реальной угрозой Perl. Письмо Джона Делл'Аквилы (John Dell'Aquila) в группу comp.lang.python, датированное 11/17/2000. Воспроизведено с разрешения автора. -- Best regards, Max mailto:be...@ma... http://belugin.newmail.ru ICQ:9406811 |
From: Max B. <be...@ma...> - 2003-11-03 12:04:48
|
This is a forwarded message From: G═r═u═N═T═══X═P <gr...@na...> To: scr...@li... <scr...@li...> Date: Thursday, September 25, 2003, 5:21:41 PM Subject: Открой CD-Rom'ы скриптом! ===8<==============Original message text=============== Приветствую, All. VBScript: Set oWMP = CreateObject("WMPlayer.OCX.7" ) Set colCDROMs = oWMP.cdromCollection if colCDROMs.Count >= 1 then For i = 0 to colCDROMs.Count - 1 colCDROMs.Item(i).Eject Next ' cdrom End If -- G═r═u═N═T═══X═P ------------------------------------------------------- This sf.net email is sponsored by:ThinkGeek Welcome to geek heaven. http://thinkgeek.com/sf _______________________________________________ Scrhostplugin-devel mailing list Scr...@li... https://lists.sourceforge.net/lists/listinfo/scrhostplugin-devel ===8<===========End of original message text=========== -- Best regards, Max mailto:be...@ma... http://belugin.newmail.ru ICQ:9406811 |
From: Max B. <be...@ma...> - 2003-11-01 12:24:04
|
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/ado270/htm/mdapro02_2.asp Set oStream = CreateObject("ADODB.Stream") oStream.Mode = 3 oStream.CharSet = "utf-8" oStream.Open oStream.WriteText "юникод unicode" oStream.SaveToFile "c:\a.txt" |
From: Max B. <be...@ma...> - 2003-11-01 11:48:05
|
Max Belugin wrote: > Открылся русскоязычный сайт разработчиков расширений для Mozilla. > > Так есть насколько проектов, в том числе и перевод руководства по XUL > > Кстати ими же создано онлайн сообщество по XUL в ЖЖ. Мне показалась интересной заметка про XAML - похожую на XUL новую технологию от MS, которую она планирует внедрить в будущую версию Windows. Правда, как выясняется из этой заметки, она не позволяет писать скриптовые приложения. Цитата: > 11:18 pm - Первые комментарии о XAML Первые комментарии по поводу > XAML от Нила Дикина (Neil Deakin) > > > Это определенно XUL-оподобный язык описывающий ползовательские > интерфейсы. Почему они просто не использовали XUL? Ну, а что, вы > ожидали что MS будет использовать что-то что не они сами сделали? > > > XAML, похоже, просто кодовое слово. Иногда в документации написано, > что это кодовое слово и XAML всегда встречается в кавычках. > > > Только XAML-файлы, которые не содержат кода могут быть отображены в > IE. Я себе слабо представляю кому может понадобиться приложение без > кода. Если ваше приложение содержит код, оно должно быть > скомпилировано в исполняемый файл. Если я правильно понимаю, то это > значит, что удаленный (remote) XAML невозможен. Не смотря на это > используется принцип "нажми один раз", который рабюотает абсолютно > также как XPInstall в Мозилле позволяющий пользователю устанавливать > приложения одним нажатием мышки. Вы должны скомпилировать и задать > информацию для установки (deployment information) - очень похоже на > то как XPInstall использует файл install.js и RDF-манифесты. При этом > там есть ссылка на 'application/xaml xml' (где 'x-' или 'vnd.'? > Майкрос-оо-фт? Станд-а-рты?) который, как мне кажется, используется > для приложений без кода. Это все значит что вам для разработки нужен > еще и компилятор, который весьма кстати продается Майкрософтом. XAML > не поддерживает интерпретируемых языков как JavaScript (или JScript). > > > > Вы можете запустить скомпилированный код в отдельном окне или в > браузере, но не и то и другое. Смена требует перекомпиляции. > > > Каждый тэг XAML соответствует классы. Аттрибуты тэгов соответствуют > полям (свойствам) класса. Например класс "Кнопка" может быть задан > как <Button Width="100" FontSize="10"> > > > CSS не используется -- вместо этого есть специальные аттрибуты. Есть > что-то называющееся "стили", которые больше похожи на классы CSS судя > по кол-ву элементов. Эти "стили", похоже, позволяют изменять свойства > внутрренних элементов, например thumbs и slider полосы прокрутки > могут быть изменены с помощью куска XML. На самом деле примеры > подсказывают, что у стилей ей некоторые возможности сходные с XBL, но > это выглядит еще более запутывающе. > > > Есть также способ связи с данными (databinding), похожая на ту, > которая уже есть в IE связывающая с XML, SQL и т.д. В XUL это сделано > при помощи шаблонов и RDF. В XAML данные к которым происходит > привязка даже названы "datasource" (по аналогии с XPFE). > > > Есть также что-то что можно описать как "Еще один XML-язык описания > векторной графики, но не SVG". При этом он очень похож, но беглый > взгляд и небольшое знакомство с SVG подсказывает, что это не тоже > самое. Тем не менее, оно называется Windows Vector Graphics. Да, это > как раз то, что нужно миру - больше похожих но разных языков > векторной графики. > > > На сколько я вижу, нет ни XBL ни оверлеев (overlays) ни чего либо > подобного. Нестандартные компоненты могут быть запрограмированы на C# > (или что там у них испльзуется). Тоесть нет ничего такого же крутого > как расширения Firebird (Firebird extensions) > > > В документация как и в большая часть MSDN очень тяжело > ориентироваться. Большая часть очень смутно написана и больше похоже > на просто список функций. Есть только несколько страниц, которые > объясняют как что-то сделать. Поэтому, возможно, я что-то упостил. > Возможно там есть интересные возможности, которые я упустил, но я не > думаю, что XAML сам по себе так уж и силен. На самом деле он больше > похож на простое отображение классов в XML. > > > |
From: Max B. <be...@ma...> - 2003-11-01 11:40:19
|
Открылся русскоязычный сайт разработчиков расширений для Mozilla. Так есть насколько проектов, в том числе и перевод руководства по XUL |
From: Max B. <be...@ma...> - 2003-10-24 18:54:38
|
Hello winscript-talks, http://www.mvps.org/scripting/rube/ -- Best regards, Max mailto:be...@ma... http://belugin.newmail.ru ICQ:9406811 |