diff --git a/README.md b/README.md index e1e2e03..82c4648 100644 --- a/README.md +++ b/README.md @@ -1,14 +1,14 @@ # Ring_WinCReg -Ring WinCReg extension is a very light, easy, and powerful extension for Ring Programming Language that has been made to bring all means of easiness in the dealing with Windows Registry. It gives you the ability to do from minor registry needs like saving or restoring settings to more superior goals like reaching and controlling every single key or value in the whole registry tree. +Ring WinCReg extension is a very light, easy, and powerful extension for Ring Programming Language that has been made to bring all means of easiness in the dealing with Windows Registry. It gives you the ability to do from minor registry needs like saving or restoring settings to more superior goals like reaching and manipulating every single key or value in the whole registry tree. This extension has been made on top of previously created C++ language class called “Registry Wrapper Class(CRegisry Class)” that has been published on CodeProject in [this article](http://www.codeproject.com/Articles/8953/Registry-Wrapper-Class-CRegistry). -## RCRegistry Class +## RCRegistry Class Library RCRegistry class, stands for Ring CRegistry Class or CRegistry Class for Ring, is a Ring Class that has been made to make using ring_wincreg extension functions easier by using the style of using “Registry Wrapper Class” in C++. I found this style is reasonable and readable better than just using the ring_wincreg original functions. It can be used by loading the file that contain it (wincreg.ring). - Note: RCRegistry Class in Ring_WinCReg Extension is now compatible with Ring 1.1 only. + Note: RCRegistry Class in Ring_WinCReg Extension is now compatible with Ring 1.1 and above. It will show errors if used with Ring 1.0. @@ -50,7 +50,9 @@ This is a simple ring code that use this extension: 3- [The documentation website](http://ring-wincreg.sourceforge.net/) -4- [The article of the original C++ Class (CRegistry Wrapper)](http://www.codeproject.com/Articles/8953/Registry-Wrapper-Class-CRegistry) +4- [The Ring Programming Language](http://ring-lang.net/) + +5- [The article of the original C++ Class (CRegistry Wrapper)](http://www.codeproject.com/Articles/8953/Registry-Wrapper-Class-CRegistry) ## How to Compile diff --git a/docs/PrepareStyle.bat b/docs/PrepareStyle.bat new file mode 100644 index 0000000..71ad6d9 --- /dev/null +++ b/docs/PrepareStyle.bat @@ -0,0 +1,32 @@ +@echo off + +echo backing up "bizstyle" old files + +IF EXIST C:\Python27\Lib\site-packages\sphinx\themes\bizstyle\static\bizstyle.js_t.bak ( + IF NOT EXIST C:\Python27\Lib\site-packages\sphinx\themes\bizstyle\static\bizstyle.js_t.bak.old ( + REM if there is more than one time building, original bizstyle.js_t file will be untouched + copy C:\Python27\Lib\site-packages\sphinx\themes\bizstyle\static\bizstyle.js_t.bak C:\Python27\Lib\site-packages\sphinx\themes\bizstyle\static\bizstyle.js_t.bak.old + echo bizstyle.js_t.bak.old file created + ) +) +copy C:\Python27\Lib\site-packages\sphinx\themes\bizstyle\static\bizstyle.js_t C:\Python27\Lib\site-packages\sphinx\themes\bizstyle\static\bizstyle.js_t.bak +echo bisstyle.js_t.bak file created + +IF EXIST C:\Python27\Lib\site-packages\sphinx\themes\bizstyle\layout.html.bak ( + IF NOT EXIST C:\Python27\Lib\site-packages\sphinx\themes\bizstyle\layout.html.bak.old ( + REM if there is more than one time building, original layout.html file will be untouched + copy C:\Python27\Lib\site-packages\sphinx\themes\bizstyle\layout.html.bak C:\Python27\Lib\site-packages\sphinx\themes\bizstyle\layout.html.bak.old + echo layout.html.bak.old file created + ) +) +copy C:\Python27\Lib\site-packages\sphinx\themes\bizstyle\layout.html C:\Python27\Lib\site-packages\sphinx\themes\bizstyle\layout.html.bak +echo layout.html.bak file created + +echo Copying the modified files to be used instead +copy bizstyle.js_t C:\Python27\Lib\site-packages\sphinx\themes\bizstyle\static\bizstyle.js_t +copy layout.html C:\Python27\Lib\site-packages\sphinx\themes\bizstyle\layout.html + +echo Copying Ring_WinCReg logo to be used by documentation +copy logo.png .\build\html\logo.png + +echo NOW you are ready to build docs :) diff --git a/docs/README.md b/docs/README.md new file mode 100644 index 0000000..ee23215 --- /dev/null +++ b/docs/README.md @@ -0,0 +1,21 @@ +# Ring_WinCReg Documentation + +This directory contains files of ring_wincreg documentation as source and those which are already built. + +## Building the source + +You can build this documentation source using [Sphinx extension of Python Programming Language](http://www.sphinx-doc.org/en/stable/tutorial.html) . + +BOFORE building we may need to prepare "bizstyle" theme of sphinx documentation that's used in this project to add Ring_WinCReg extension logo and home website link by running "PrepareStyle.bat" batch file. + +## Building steps + +1- Setup Python and its extension Sphinx. + +2- (Optional) run "PrepareStyle.bat" batch file. + +3- Run this command in COMMAND LINE(cmd): + + make html + +4- Enjoy ^_^ diff --git a/docs/bizstyle.js_t b/docs/bizstyle.js_t new file mode 100644 index 0000000..206c35c --- /dev/null +++ b/docs/bizstyle.js_t @@ -0,0 +1,41 @@ +// +// bizstyle.js +// ~~~~~~~~~~~ +// +// Sphinx javascript -- for bizstyle theme. +// +// This theme was created by referring to 'sphinxdoc' +// +// :copyright: Copyright 2012-2014 by Sphinx team, see AUTHORS. +// :license: BSD, see LICENSE for details. +// +$(document).ready(function(){ + if (navigator.userAgent.indexOf('iPhone') > 0 || + navigator.userAgent.indexOf('Android') > 0) { + $("li.nav-item-0 a").text("Top"); + } + + $("div.related:first ul li:not(.right) a").slice(1).each(function(i, item){ + if (item.text.length > 30) { + var tmpstr = item.text + $(item).attr("title", tmpstr); + $(item).text(tmpstr.substr(0, 27) + "..."); + } + }); + $("div.related:last ul li:not(.right) a").slice(1).each(function(i, item){ + if (item.text.length > 30) { + var tmpstr = item.text + $(item).attr("title", tmpstr); + $(item).text(tmpstr.substr(0, 27) + "..."); + } + }); +}); + +$(window).resize(function(){ + if ($(window).width() <= 776) { + $("li.nav-item-0 a").text("Top"); + } + else { + $("li.nav-item-0 a").text("{{ shorttitle|e }}"); + } +}); diff --git a/docs/build/doctrees/entries.doctree b/docs/build/doctrees/entries.doctree index 7c7c3d3..7916d83 100644 Binary files a/docs/build/doctrees/entries.doctree and b/docs/build/doctrees/entries.doctree differ diff --git a/docs/build/doctrees/environment.pickle b/docs/build/doctrees/environment.pickle index 91485d0..e651bc5 100644 Binary files a/docs/build/doctrees/environment.pickle and b/docs/build/doctrees/environment.pickle differ diff --git a/docs/build/doctrees/extensionfunctions.doctree b/docs/build/doctrees/extensionfunctions.doctree index 45bf3fc..485d81b 100644 Binary files a/docs/build/doctrees/extensionfunctions.doctree and b/docs/build/doctrees/extensionfunctions.doctree differ diff --git a/docs/build/doctrees/implementation&usage.doctree b/docs/build/doctrees/implementation&usage.doctree index 8445657..03bcd15 100644 Binary files a/docs/build/doctrees/implementation&usage.doctree and b/docs/build/doctrees/implementation&usage.doctree differ diff --git a/docs/build/doctrees/index.doctree b/docs/build/doctrees/index.doctree index 4be9d38..5081f4c 100644 Binary files a/docs/build/doctrees/index.doctree and b/docs/build/doctrees/index.doctree differ diff --git a/docs/build/doctrees/introduction.doctree b/docs/build/doctrees/introduction.doctree index e67b713..c55f1bd 100644 Binary files a/docs/build/doctrees/introduction.doctree and b/docs/build/doctrees/introduction.doctree differ diff --git a/docs/build/doctrees/keys.doctree b/docs/build/doctrees/keys.doctree index a252bc5..470288e 100644 Binary files a/docs/build/doctrees/keys.doctree and b/docs/build/doctrees/keys.doctree differ diff --git a/docs/build/doctrees/values.doctree b/docs/build/doctrees/values.doctree index 8ca11a6..1dd0623 100644 Binary files a/docs/build/doctrees/values.doctree and b/docs/build/doctrees/values.doctree differ diff --git a/docs/build/html/.buildinfo b/docs/build/html/.buildinfo index 9a36cc2..f3c1863 100644 --- a/docs/build/html/.buildinfo +++ b/docs/build/html/.buildinfo @@ -1,4 +1,4 @@ # Sphinx build info version 1 # This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done. -config: 332d1bf1530bce63fde0231b3aa662f5 +config: 053fba15b894ea567d12f56542c977f5 tags: 645f666f9bcd5a90fca523b33c5a78b7 diff --git a/docs/build/html/_sources/entries.txt b/docs/build/html/_sources/entries.txt index cc9fc90..b4f77d5 100644 --- a/docs/build/html/_sources/entries.txt +++ b/docs/build/html/_sources/entries.txt @@ -2,7 +2,7 @@ Dealing with Entries ===================== -Here, we are going to learn how to deal with registry entries by using "ring_wincreg" extension capabilities through RCRegistry class. +Here, we are going to learn how to deal with registry entries by using "ring_wincreg" extension capabilities through RCRegistry class library. .. index:: pair: Dealing with Entries; Create Entry diff --git a/docs/build/html/_sources/extensionfunctions.txt b/docs/build/html/_sources/extensionfunctions.txt index e447f01..cf9c88f 100644 --- a/docs/build/html/_sources/extensionfunctions.txt +++ b/docs/build/html/_sources/extensionfunctions.txt @@ -77,6 +77,8 @@ Here we are going to know the whole list of functions that could be called direc void cregsetexpandsz( CRegistry* keyhandle , string valuename , string value ) + string creggetexpandedsz( CRegistry* keyhandle , string valuename ) + void cregsetqword( CRegistry* keyhandle , string valuename , number\string value ) string creggetqword( CRegistry* keyhandle , string valuename ) diff --git a/docs/build/html/_sources/implementation&usage.txt b/docs/build/html/_sources/implementation&usage.txt index 99a1769..b3a76e0 100644 --- a/docs/build/html/_sources/implementation&usage.txt +++ b/docs/build/html/_sources/implementation&usage.txt @@ -8,12 +8,11 @@ Implementation and Usage Download and Implementation ============================ -To use this extension you have to start with downloading it from GitHub following next steps: +To use this extension you have to start with downloading it following next steps: -1. Go to `the extension GitHub project `_ page. -2. Download the project using the green button on the right upper corner of the page as a ZIP file. -3. Extract the contents of the bin folder and copy them to the bin folder that is present in the ring language folder ( where the "ring.exe" file is located ). -4. Load the extension and its features in the ring code by using load command as: +1. Download the extension from `GitHub `_ or `Sourceforge `_ pages. +2. Extract the contents of the bin folder and copy them to the bin folder that is present in the ring language folder ( where the "ring.exe" file is located ). +3. Load the extension and its features in the ring code by using load command as: .. code-block:: none @@ -29,9 +28,9 @@ In order to use "ring_wincreg" extension you have two options to start with: * Using the functions of the extension directly -* Using the extension through RCRegistry Class +* Using the extension through RCRegistry Class Library -I would prefer to use the second option as you can read in RCRegistry Class section :ref:`RCRegistry-class-usage` and because I have added some other nice features using Ring that can be used only with RCRegistry class. +I would prefer to use the second option as you can read in (:ref:`RCRegistry-class-library-usage`) section and because I have added some other nice features using Ring that can be used only with RCRegistry class library. .. index:: pair: Implementation and Usage; Direct extension's functions usage @@ -72,14 +71,14 @@ This example does the following: * Close the key "oKey". .. index:: - pair: Implementation and Usage; RCRegistry class usage + pair: Implementation and Usage; RCRegistry class library usage -.. _RCRegistry-class-usage: +.. _RCRegistry-class-library-usage: -RCRegistry class usage -======================= +RCRegistry class library usage +=============================== -RCRegistry class has been made to simplify using "ring_wincreg" extension by avoid using its long function's names and give a nice template for dealing with entries. +RCRegistry class library has been made to simplify using "ring_wincreg" extension by avoid using its long function's names and introduce a nice template for dealing with entries. .. code-block:: none @@ -87,11 +86,11 @@ RCRegistry class has been made to simplify using "ring_wincreg" extension by avo Also it reduces the pain of repeatedly mentioning the key handle and typing other parameters with each function call of this extension. -In a nutshell, this class brings a special, readable and nice coding experience throughout "ring_wincreg" extension usage. +In a nutshell, this class library brings a special, readable and nice coding experience throughout "ring_wincreg" extension usage. -It has been written in a ring library file called "wincreg.ring" which contains also another class named "RCRegEntry" class that is needed by RCRegistry class to deal with entries. +It has been written in a ring file called "wincreg.ring" which contains also another class named "RCRegEntry" that is needed by RCRegistry class to deal with entries. -To use "ring_wincreg" extension using this method you have to load "wincreg.ring" file. Because this file will load "ring_wincreg.dll" extension file and "wincreg.rh" file that it needs. +To use "ring_wincreg" extension using this library you have to load "wincreg.ring" file to your code, because this file will load "ring_wincreg.dll" extension file and "wincreg.rh" header file that it needs. .. code-block:: none @@ -117,7 +116,7 @@ Now we have to apply the previous example using this method to clarify the diffe .. note:: - RCRegistry class can represent and deal with one open key. So in case of dealing with more than one key at the same time we should define a separate RCRegistry Object for each key. + RCRegistry class can represent and deal with one opened key. So in case of dealing with more than one key at the same time we should define a separate RCRegistry Object for each key. As we are really lucky using Ring, we can write the same previous example without creating any object like this: @@ -137,4 +136,4 @@ As we are really lucky using Ring, we can write the same previous example withou } -In the next sections I'm going to explain how to use "ring_wincreg" extension using RCRegistry class but I should also list all of the extension functions later on. \ No newline at end of file +In the next sections I'm going to explain how to use "ring_wincreg" extension using RCRegistry class library but I should also list all of the extension functions later on. \ No newline at end of file diff --git a/docs/build/html/_sources/introduction.txt b/docs/build/html/_sources/introduction.txt index 2ac796e..cdedfc6 100644 --- a/docs/build/html/_sources/introduction.txt +++ b/docs/build/html/_sources/introduction.txt @@ -17,17 +17,17 @@ Absolutely, Supporting Windows Registry will give a big chance for the all commu Ring_WinCReg Extension ======================= -Ring WinCReg extension is a very light, easy, and powerful extension for Ring Programming Language that has been made to bring all means of easiness in the dealing with Windows Registry. It gives you the ability to do from minor registry needs like saving or restoring settings to more superior goals like reaching and controlling every single key or value in the whole registry tree. +Ring WinCReg extension is a very light, easy, and powerful extension for Ring Programming Language that has been made to bring all means of easiness in regard to the dealing with Windows Registry. It gives you the ability to do from minor registry needs like saving or restoring settings to more superior goals like reaching and manipulating every single key or value in the whole registry tree. -This extension has been made on top of previously created C++ language class called "Registry Wrapper Class(CRegisry Class)" that has been published on `CodeProject in this article `_. +This extension has been made on top of previously created C++ language class called "Registry Wrapper Class (CRegisry Class)" that has been published on `CodeProject in this article `_. .. index:: pair: Introduction; RCRegistry Class -RCRegistry Class -================= +RCRegistry Class Library +========================= -RCRegistry class, stands for Ring CRegistry Class or CRegistry Class for Ring, is a Ring Class that has been made to make using ring_wincreg extension functions easier by using the style of using "Registry Wrapper Class" in C++. I found this style is reasonable and readable better than just using the ring_wincreg original functions. It can be used by loading the file that contain it (wincreg.ring). +RCRegistry class, stands for Ring CRegistry Class or CRegistry Class for Ring, is a Ring Class that has been made to make using ring_wincreg extension functions easier by using the same style of "Registry Wrapper Class" usage in C++. I found this style reasonable and readable better than just using the ring_wincreg original functions (:ref:`RCRegistry-class-library-usage`). It can be used by loading the file that contains it (wincreg.ring). .. index:: pair: Introduction; Simple Example @@ -35,7 +35,7 @@ RCRegistry class, stands for Ring CRegistry Class or CRegistry Class for Ring, i Simple Example =============== -This is a simple ring code that use this extension: +This is a simple ring code that uses this extension: .. code-block:: none @@ -44,7 +44,7 @@ This is a simple ring code that use this extension: Reg = new RCRegistry Reg.OpenKey([HKEY_CURRENT_USER, "Software\MyApp"]) - # This will create the Key "MyApp" if its not present then it will be Opened + # This will create a key called "MyApp" if its not present then it will be Opened Reg["AppVersion"].SetValue("2.3") diff --git a/docs/build/html/_sources/keys.txt b/docs/build/html/_sources/keys.txt index 8ef6b4b..604e277 100644 --- a/docs/build/html/_sources/keys.txt +++ b/docs/build/html/_sources/keys.txt @@ -2,7 +2,7 @@ Dealing with Keys ================== -Here, we are going to learn how to deal with registry keys by using "ring_wincreg" extension capabilities through RCRegistry class. +Here, we are going to learn how to deal with registry keys by using "ring_wincreg" extension capabilities through RCRegistry class library. .. index:: pair: Dealing with Keys; Create Key @@ -39,7 +39,7 @@ We can check whether a specific key existed before we open it by using **KeyExis .. _Open-Keys: Open Key -=========== +========= We can open a registry key using more than one function and option. @@ -51,42 +51,48 @@ OpenKey() Function This function is the primary open key function in the RCRegistry class that could be used to open keys. -This Function accepts parameters as a list so we should pass one list parameter that contains other parameters. The number of parameters allowed are 2-4. These parameters are: +This function accepts parameters as a list so we should pass one list parameter that contains other parameters. The number of parameters allowed are 2-4. These parameters are: -1. The HKEY root of the windows registry, which could either be: +1. The HKEY root indexes: of the windows registry which could either be: * HKEY_CLASSES_ROOT * HKEY_CURRENT_USER * HKEY_LOCAL_MACHINE * HKEY_USERS * HKEY_CURRENT_CONFIG -.. note:: - ROOT HKEY indexes are numbers for each HKEY root, this index has been defined depending on the root organization in Windows Registry Editor but it starts with one. The complete list of HKEY roots indexes is: - - * HKEY_CLASSES_ROOT = 1 - * HKCR = 1 - * HKEY_CURRENT_USER = 2 - * HKCU = 2 - * HKEY_LOCAL_MACHINE = 3 - * HKLM = 3 - * HKEY_USERS = 4 - * HKU = 4 - * HKEY_CURRENT_CONFIG = 5 - * HKCC = 5 - - Note that each HKEY root has been shorten for easier call. + .. note:: + ROOT HKEY indexes are numbers for each HKEY root, this index has been defined depending on the root organization in Windows Registry Editor but it starts with one. The complete list of HKEY roots indexes is: + + * HKEY_CLASSES_ROOT = 1 + * HKCR = 1 + * HKEY_CURRENT_USER = 2 + * HKCU = 2 + * HKEY_LOCAL_MACHINE = 3 + * HKLM = 3 + * HKEY_USERS = 4 + * HKU = 4 + * HKEY_CURRENT_CONFIG = 5 + * HKCC = 5 + + Note that each HKEY root has been shorten for easier call. -2. The sub key path which is the key that we want to open under the specified root. It is a complete path to the required key under the specified root. -3. Flags that control how we want to use this library functions. These Flags could be one or more of the follow: - * CREG_READONLY : open the key if it is existed but will not create it if it is not. This flag cannot be used with others in the same time. - * CREG_CREATE : this flag will make the function to create the key if its not exist. ( This Flag is Used by default when calling OpenKey function ) - * CREG_AUTOOPEN : activate the auto open mechanism of CRegistry Class, which help in repeatedly open and close functions calling. - * CREG_NOCACHE : deactivate the caching mechanism of the CRegistry Class. ( Activated by default ) -4. The option to access Wow64 tree. It could be true for access or false for opposite. +2. The sub key path: which is the key that we want to open under the specified root. It is a complete path to the required key under the specified root. +3. Flags: which are numerical values represent specific behaviour that should extension assume. These flags allow more control over extension behaviour. They could be one or more of the follow: + * CREG_CREATE = 1 : this flag will make the function to create the key if its not exist. (This flag used by default if no flags have been set) + * CREG_READONLY = 0 : this flag opens the key if it is existed but will not create it if it is not. It cannot be used with CREG_CREATE flag at the same time. + * CREG_AUTOOPEN = 2 : this flag activates the auto open mechanism of this extension, which helps faster performance by automatic close and then open the key whenever it is needed. This is useful in case of repeatedly calling key open and close functions. + * CREG_NOCACHE = 4 : deactivate the caching mechanism of the CRegistry Class. ( Activated by default ) + + .. note:: + Till now, the first three flags are only effective in the process of opening and closing the key, and the last one is effective in dealing with entries and values. To know how to use flags in more details go to (:ref:`SetAndGetFlags`) section. -.. hint:: - Wow64 tree is an automatically created tree of keys inside windows registry for 32 bit applications that run on an 64 bit windows. So opening/creating "Software\\MyApp" under the HKEY_LOCAL_MACHINE root will not open/create it as expected but it will be opened/created as "Software\\Wow6432Node\\MyApp". `(Registry Redirection) `_ +4. The option to access Wow64 tree: which could be true for access or false for opposite. It has been set "False" by default. +.. hint:: + Wow64 tree is an automatically created tree of keys inside windows registry for 32 bit programs that run on an 64 bit windows. So opening/creating "Software\\MyApp" under the HKEY_LOCAL_MACHINE root will not open/create it as expected but it will be opened/created as "Software\\Wow6432Node\\MyApp". `(Registry Redirection) `_ + + Till now any windows application created by Ring Programming Language is considered to be 32 bit application because Ring is built as 32 bit program. + Now lets have some examples for how to use **OpenKey()** function. Example 1 @@ -105,6 +111,8 @@ Example 1 Reg.CloseKey() +This example opens "Software" key in the "HKEY_CURRENT_USER" HKEY root for reading only which means it will not auto create sub key if its not existed. Then it checks for "Microsoft" sub key whether it exists under "Software" key or not. + Example 2 .. code-block:: none @@ -121,10 +129,15 @@ Example 2 Reg.CloseKey() +This example does the same task that the previous example do. The main difference is that it opens the key in the Wow64 tree not the regular tree due to adding the forth parameter with "True" value. + .. note:: - This example may show access denied error. You can get around it by running Ring as Administrator. + This example may show access denied error (if Registry Virtualization has been disabled by manifest file). You can get around it by running Ring as Administrator. You can use `"Ring_WINAPI" `_ extension to help elevating Ring. +.. note:: + In case you want to reach Wow64 tree without changing flags you can open the key first by calling **OpenKey()** function with two parameters then use **Access64Tree()** function (:ref:`Access64Tree`) to access Wow64 tree. + .. index:: pair: Open Key; OpenKey2() Function @@ -209,7 +222,7 @@ Example Reg.CloseKey() -After opening the key it will be saved in an attribute in RCRegistry object named **(Key)**, So that it could be used by other functions easily. +After opening the key it will be saved in an attribute as a pointer in RCRegistry object named **(Key)**, So that it could be used by other functions easily. .. code-block:: none @@ -270,10 +283,12 @@ We can close any opened key by using **CloseKey()** function. It is recommended .. index:: pair: Dealing with Keys; Set and Get Flags +.. _SetAndGetFlags: + Set and Get Flags ================== -We can Set or Get flags any time in the code using special functions. This may be useful if we opened a key without specifying enough flags that we want. +We can Set or Get flags any time in the code using special functions. This may be useful if we opened a key without specifying enough flags that we want. This can be done using **SetFlags()** and **GetFlags()** functions as follow: @@ -286,17 +301,75 @@ This can be done using **SetFlags()** and **GetFlags()** functions as follow: Reg.OpenKey([HKEY_CURRENT_USER, "Software\MyApp"]) See "The flags that has been already set are : " + Reg.GetFlags() + NL + # Reg.GetFlags() will return 1 because CREG_CREATE flag has been set by default Reg.SetFlags(Reg.GetFlags() | CREG_AUTOOPEN) - See "The flags after correction are : " + Reg.GetFlags() + See "The flags after addition of CREG_AUTOOPEN are : " + Reg.GetFlags() + NL + + Reg.SetFlags(Reg.GetFlags() & ~CREG_AUTOOPEN) + + See "The flags after subtraction of CREG_AUTOOPEN are : " + Reg.GetFlags() Reg.CloseKey() +It is a must to know that setting new flags will omit any previously set flags. + +You can set multiple flags using bitwise operators as following (check previous example): + - OR "|" operator : will sum any flags. You can use "+" operator to do the same task. + - AND plus COMPLEMENT " & ~ " operators : will cause subtraction of any previously set flag. These operators reduce the possibility of creating unexpected flags than using "-" operator that may lead to unexpected behaviour if subtracted flags are not set initially. + + The most important thing is that subtracting using bitwise operators should be segmented if you want to remove more than one flag as follow: + + .. code-block:: none + + SetFlags( GetFlags() & ~CREG_AUTOOPEN ) + SetFlags( GetFlags() & ~CREG_CREATE ) + + OR + + .. code-block:: none + + SetFlags( (GetFlags() & ~CREG_AUTOOPEN) & ~CREG_CREATE ) + +.. note:: + Setting multiple flags inappropriately may lead to unexpected behaviour. + +**CREG_CREATE** and **CREG_READONLY** flags **are not allowed** to be used together in the same flag setting context to avoid unexpected behaviour. +The accepted ways to use them are: + + * (CREG_CREATE) : This flag, alone or with other flags, will allow creating new keys. + * (CREG_READONLY) : This flag, alone or with other flags, will not permit creating keys if they are not existed. + * (GetFlags() & ~CREG_CREATE) : This expression will switch from **CREG_CREATE** situation into **CREG_READONLY** one in a key previously set to allow creating new keys. Providing that GetFlags() function returns multiple flags containing **CREG_CREATE** flag. + * (GetFlags() | CREG_CREATE) : this expression will switch from **CREG_READONLY** situation into **CREG_CREATE** one in a key previously set to prevent creating new keys. Providing that GetFlags() function returns multiple flags containing **CREG_READONLY** flag. + + The last two conditions help reset flags in case that there are already used multiple flags, but if you want to set flags completely from scratch use the previous two individual flags. + +**CREG_CREATE** flag is used by default when calling OpenKey() function without setting flags. But if you set **CREG_AUTOOPEN** and\\or **CREG_NOCACHE** flags alone without setting any one of the previous two flags (**CREG_CREATE** or **CREG_READONLY**), the extension will use **CREG_READONLY** by default. + +As we highlighted before in (:ref:`Open-Keys`) section, using **CREG_AUTOOPEN** flag will help opening and closing the key automatically whenever it is needed, unless the key is manually closed or deleted. Now we will have a quick example showing the benefit of this: + +.. code-block:: none + + Load "wincreg.ring" + + Reg = New RCRegistry { OpenKey([HKCU, "Software\MyApp", CREG_CREATE | CREG_AUTOOPEN]) } + # After opening the key it will be closed automatically + + Reg["version"].SetValue("5.5") + # Here the key will be opened, setting the value, and then closed automatically + + See "The version of my app is : " + Reg["version"].GetValue() + # Here the key will be opened again, retrieving the value, and then closed automatically + +**CREG_NOCACHE** flag may rarely be used if you want to relieve some load from RAM if the application is suspected to run on old computers, because this extension load all entries of the opened key by default for better responsiveness and performance. + .. index:: pair: Dealing with Keys; Accessing 64 Bit Tree (Registry Redirection) -Accessing 64 Bit Tree (Registry Redirection) +.. _Access64Tree: + +Accessing Wow64 Tree (Registry Redirection) ============================================= We can change the setting that let us access the 64 bit applications registry tree any time if we miss to set it during key opening. diff --git a/docs/build/html/_sources/values.txt b/docs/build/html/_sources/values.txt index 9f95361..9eab78b 100644 --- a/docs/build/html/_sources/values.txt +++ b/docs/build/html/_sources/values.txt @@ -2,7 +2,7 @@ Dealing with Values ===================== -Here, we are going to learn how to deal with registry values by using "ring_wincreg" extension capabilities through RCRegistry class. +Here, we are going to learn how to deal with registry values by using "ring_wincreg" extension capabilities through RCRegistry class library. .. index:: pair: Dealing with Values; Set Value @@ -27,6 +27,9 @@ This general function can set values smartly according to entry existence. If th * Numbers not in the range of DWORD will be converted to string then saved as (REG_SZ). * Floated numbers will automatically be converted to string and saved as (REG_SZ). +.. note:: + Setting new value to a previously existed entry with different data type will give error message because this function automatically use data type specific function of the already existed entry type for setting new values. + This function has been used in the previous examples to save strings, but now will try to save DWORD value. .. code-block:: none @@ -208,7 +211,7 @@ This function can set(substitute) any item of the list with any given value. MultiAdd() Function -------------------- -This function can add a value to a list pre existed multi string value or can establish a new multi string value list with help of SetMulti() function. +This function can add a value as new item to pre existed multi string value list or can establish a new multi string value list with help of SetMulti() function. .. code-block:: none @@ -505,8 +508,8 @@ Here is an example that will clarify all of what we said. This example show the power of these functions in dealing with Ring Objects. But there are some points that we should know about: -1. We can save objects by saving their attributes and their values. -2. These two functions can smartly save attribute that are lists and objects. +1. These functions save and retrieve objects by saving their attributes and their values. +2. They can smartly save attributes that are lists and objects. 3. They take dynamic nature of Ring Language in account so that new created attributes are also saved and retrieved correctly. 4. Attributes that are not strings, numbers, lists, or objects will be ignored. 5. Objects are saved in registry as a binary values. diff --git a/docs/build/html/_static/background_b01.png b/docs/build/html/_static/background_b01.png new file mode 100644 index 0000000..353f26d Binary files /dev/null and b/docs/build/html/_static/background_b01.png differ diff --git a/docs/build/html/_static/basic.css b/docs/build/html/_static/basic.css index 2b513f0..dc88b5a 100644 --- a/docs/build/html/_static/basic.css +++ b/docs/build/html/_static/basic.css @@ -4,7 +4,7 @@ * * Sphinx stylesheet -- basic theme. * - * :copyright: Copyright 2007-2016 by the Sphinx team, see AUTHORS. + * :copyright: Copyright 2007-2017 by the Sphinx team, see AUTHORS. * :license: BSD, see LICENSE for details. * */ @@ -122,6 +122,8 @@ ul.keywordmatches li.goodmatch a { table.contentstable { width: 90%; + margin-left: auto; + margin-right: auto; } table.contentstable p.biglink { @@ -149,9 +151,14 @@ table.indextable td { vertical-align: top; } -table.indextable dl, table.indextable dd { +table.indextable ul { margin-top: 0; margin-bottom: 0; + list-style-type: none; +} + +table.indextable > tbody > tr > td > ul { + padding-left: 0em; } table.indextable tr.pcap { @@ -183,6 +190,13 @@ div.genindex-jumpbox { padding: 0.4em; } +/* -- domain module index --------------------------------------------------- */ + +table.modindextable td { + padding: 2px; + border-collapse: collapse; +} + /* -- general body styles --------------------------------------------------- */ div.body p, div.body dd, div.body li, div.body blockquote { @@ -217,10 +231,6 @@ div.body td { text-align: left; } -.field-list ul { - padding-left: 1em; -} - .first { margin-top: 0 !important; } @@ -337,10 +347,6 @@ table.docutils td, table.docutils th { border-bottom: 1px solid #aaa; } -table.field-list td, table.field-list th { - border: 0 !important; -} - table.footnote td, table.footnote th { border: 0 !important; } @@ -377,6 +383,20 @@ div.figure p.caption span.caption-number { div.figure p.caption span.caption-text { } +/* -- field list styles ----------------------------------------------------- */ + +table.field-list td, table.field-list th { + border: 0 !important; +} + +.field-list ul { + margin: 0; + padding-left: 1em; +} + +.field-list p { + margin: 0; +} /* -- other body styles ----------------------------------------------------- */ @@ -427,15 +447,6 @@ dl.glossary dt { font-size: 1.1em; } -.field-list ul { - margin: 0; - padding-left: 1em; -} - -.field-list p { - margin: 0; -} - .optional { font-size: 1.3em; } @@ -494,6 +505,13 @@ pre { overflow-y: hidden; /* fixes display issues on Chrome browsers */ } +span.pre { + -moz-hyphens: none; + -ms-hyphens: none; + -webkit-hyphens: none; + hyphens: none; +} + td.linenos pre { padding: 5px 0px; border: 0; @@ -585,6 +603,16 @@ span.eqno { float: right; } +span.eqno a.headerlink { + position: relative; + left: 0px; + z-index: 1; +} + +div.math:hover a.headerlink { + visibility: visible; +} + /* -- printout stylesheet --------------------------------------------------- */ @media print { diff --git a/docs/build/html/_static/bizstyle.css b/docs/build/html/_static/bizstyle.css new file mode 100644 index 0000000..0464a74 --- /dev/null +++ b/docs/build/html/_static/bizstyle.css @@ -0,0 +1,490 @@ +/* + * bizstyle.css_t + * ~~~~~~~~~~~~~~ + * + * Sphinx stylesheet -- business style theme. + * + * :copyright: Copyright 2011-2014 by Sphinx team, see AUTHORS. + * :license: BSD, see LICENSE for details. + * + */ + +@import url("basic.css"); + +/* -- page layout ----------------------------------------------------------- */ + +body { + font-family: 'Lucida Grande', 'Lucida Sans Unicode', 'Geneva', + 'Verdana', sans-serif; + font-size: 14px; + letter-spacing: -0.01em; + line-height: 150%; + text-align: center; + background-color: white; + background-image: url(background_b01.png); + color: black; + padding: 0; + border-right: 1px solid #336699; + border-left: 1px solid #336699; + + margin: 0px 40px 0px 40px; +} + +div.document { + background-color: white; + text-align: left; + background-repeat: repeat-x; + + -moz-box-shadow: 2px 2px 5px #000; + -webkit-box-shadow: 2px 2px 5px #000; +} + +div.bodywrapper { + margin: 0 0 0 240px; + border-left: 1px solid #ccc; +} + +div.body { + margin: 0; + padding: 0.5em 20px 20px 20px; +} + +div.related { + font-size: 1em; + + -moz-box-shadow: 2px 2px 5px #000; + -webkit-box-shadow: 2px 2px 5px #000; +} + +div.related ul { + background-color: #336699; + height: 100%; + overflow: hidden; + border-top: 1px solid #ddd; + border-bottom: 1px solid #ddd; +} + +div.related ul li { + color: white; + margin: 0; + padding: 0; + height: 2em; + float: left; +} + +div.related ul li.right { + float: right; + margin-right: 5px; +} + +div.related ul li a { + margin: 0; + padding: 0 5px 0 5px; + line-height: 1.75em; + color: #fff; +} + +div.related ul li a:hover { + color: #fff; + text-decoration: underline; +} + +div.sphinxsidebarwrapper { + padding: 0; +} + +div.sphinxsidebar { + margin: 0; + padding: 0.5em 12px 12px 12px; + width: 210px; + font-size: 1em; + text-align: left; +} + +div.sphinxsidebar h3, div.sphinxsidebar h4 { + margin: 1em 0 0.5em 0; + font-size: 1em; + padding: 0.1em 0 0.1em 0.5em; + color: white; + border: 1px solid #336699; + background-color: #336699; +} + +div.sphinxsidebar h3 a { + color: white; +} + +div.sphinxsidebar ul { + padding-left: 1.5em; + margin-top: 7px; + padding: 0; + line-height: 130%; +} + +div.sphinxsidebar ul ul { + margin-left: 20px; +} + +div.sphinxsidebar input { + border: 1px solid #336699; +} + +div.footer { + background-color: white; + color: #336699; + padding: 3px 8px 3px 0; + clear: both; + font-size: 0.8em; + text-align: right; + border-bottom: 1px solid #336699; + + -moz-box-shadow: 2px 2px 5px #000; + -webkit-box-shadow: 2px 2px 5px #000; +} + +div.footer a { + color: #336699; + text-decoration: underline; +} + +/* -- body styles ----------------------------------------------------------- */ + +p { + margin: 0.8em 0 0.5em 0; +} + +a { + color: #336699; + text-decoration: none; +} + +a:hover { + color: #336699; + text-decoration: underline; +} + +div.body a { + text-decoration: underline; +} + +h1, h2, h3 { + color: #336699; +} + +h1 { + margin: 0; + padding: 0.7em 0 0.3em 0; + font-size: 1.5em; +} + +h2 { + margin: 1.3em 0 0.2em 0; + font-size: 1.35em; + padding-bottom: .5em; + border-bottom: 1px solid #336699; +} + +h3 { + margin: 1em 0 -0.3em 0; + font-size: 1.2em; + padding-bottom: .3em; + border-bottom: 1px solid #CCCCCC; +} + +div.body h1 a, div.body h2 a, div.body h3 a, +div.body h4 a, div.body h5 a, div.body h6 a { + color: black!important; +} + +h1 a.anchor, h2 a.anchor, h3 a.anchor, +h4 a.anchor, h5 a.anchor, h6 a.anchor { + display: none; + margin: 0 0 0 0.3em; + padding: 0 0.2em 0 0.2em; + color: #aaa!important; +} + +h1:hover a.anchor, h2:hover a.anchor, h3:hover a.anchor, h4:hover a.anchor, +h5:hover a.anchor, h6:hover a.anchor { + display: inline; +} + +h1 a.anchor:hover, h2 a.anchor:hover, h3 a.anchor:hover, h4 a.anchor:hover, +h5 a.anchor:hover, h6 a.anchor:hover { + color: #777; + background-color: #eee; +} + +a.headerlink { + color: #c60f0f!important; + font-size: 1em; + margin-left: 6px; + padding: 0 4px 0 4px; + text-decoration: none!important; +} + +a.headerlink:hover { + background-color: #ccc; + color: white!important; +} + +cite, code, tt { + font-family: 'Consolas', 'Deja Vu Sans Mono', + 'Bitstream Vera Sans Mono', monospace; + font-size: 0.95em; + letter-spacing: 0.01em; +} + +code { + background-color: #F2F2F2; + border-bottom: 1px solid #ddd; + color: #333; +} + +code.descname, code.descclassname, code.xref { + border: 0; +} + +hr { + border: 1px solid #abc; + margin: 2em; +} + +a code { + border: 0; + color: #CA7900; +} + +a code:hover { + color: #2491CF; +} + +pre { + background-color: transparent !important; + font-family: 'Consolas', 'Deja Vu Sans Mono', + 'Bitstream Vera Sans Mono', monospace; + font-size: 0.95em; + letter-spacing: 0.015em; + line-height: 120%; + padding: 0.5em; + border-right: 5px solid #ccc; + border-left: 5px solid #ccc; +} + +pre a { + color: inherit; + text-decoration: underline; +} + +td.linenos pre { + padding: 0.5em 0; +} + +div.quotebar { + background-color: #f8f8f8; + max-width: 250px; + float: right; + padding: 2px 7px; + border: 1px solid #ccc; +} + +div.topic { + background-color: #f8f8f8; +} + +table { + border-collapse: collapse; + margin: 0 -0.5em 0 -0.5em; +} + +table td, table th { + padding: 0.2em 0.5em 0.2em 0.5em; +} + +div.admonition { + font-size: 0.9em; + margin: 1em 0 1em 0; + border: 3px solid #cccccc; + background-color: #f7f7f7; + padding: 0; +} + +div.admonition p { + margin: 0.5em 1em 0.5em 1em; + padding: 0; +} + +div.admonition li p { + margin-left: 0; +} + +div.admonition pre, div.warning pre { + margin: 0; +} + +div.highlight { + margin: 0.4em 1em; +} + +div.admonition p.admonition-title { + margin: 0; + padding: 0.1em 0 0.1em 0.5em; + color: white; + border-bottom: 3px solid #cccccc; + font-weight: bold; + background-color: #165e83; +} + +div.danger { border: 3px solid #f0908d; background-color: #f0cfa0; } +div.error { border: 3px solid #f0908d; background-color: #ede4cd; } +div.warning { border: 3px solid #f8b862; background-color: #f0cfa0; } +div.caution { border: 3px solid #f8b862; background-color: #ede4cd; } +div.attention { border: 3px solid #f8b862; background-color: #f3f3f3; } +div.important { border: 3px solid #f0cfa0; background-color: #ede4cd; } +div.note { border: 3px solid #f0cfa0; background-color: #f3f3f3; } +div.hint { border: 3px solid #bed2c3; background-color: #f3f3f3; } +div.tip { border: 3px solid #bed2c3; background-color: #f3f3f3; } + +div.danger p.admonition-title, div.error p.admonition-title { + background-color: #b7282e; + border-bottom: 3px solid #f0908d; +} + +div.caution p.admonition-title, +div.warning p.admonition-title, +div.attention p.admonition-title { + background-color: #f19072; + border-bottom: 3px solid #f8b862; +} + +div.note p.admonition-title, div.important p.admonition-title { + background-color: #f8b862; + border-bottom: 3px solid #f0cfa0; +} + +div.hint p.admonition-title, div.tip p.admonition-title { + background-color: #7ebea5; + border-bottom: 3px solid #bed2c3; +} + +div.admonition ul, div.admonition ol, +div.warning ul, div.warning ol { + margin: 0.1em 0.5em 0.5em 3em; + padding: 0; +} + +div.versioninfo { + margin: 1em 0 0 0; + border: 1px solid #ccc; + background-color: #DDEAF0; + padding: 8px; + line-height: 1.3em; + font-size: 0.9em; +} + +.viewcode-back { + font-family: 'Lucida Grande', 'Lucida Sans Unicode', 'Geneva', + 'Verdana', sans-serif; +} + +div.viewcode-block:target { + background-color: #f4debf; + border-top: 1px solid #ac9; + border-bottom: 1px solid #ac9; +} + +p.versionchanged span.versionmodified { + font-size: 0.9em; + margin-right: 0.2em; + padding: 0.1em; + background-color: #DCE6A0; +} + +/* -- table styles ---------------------------------------------------------- */ + +table.docutils { + margin: 1em 0; + padding: 0; + border: 1px solid white; + background-color: #f7f7f7; +} + +table.docutils td, table.docutils th { + padding: 1px 8px 1px 5px; + border-top: 0; + border-left: 0; + border-right: 1px solid white; + border-bottom: 1px solid white; +} + +table.docutils td p { + margin-top: 0; + margin-bottom: 0.3em; +} + +table.field-list td, table.field-list th { + border: 0 !important; + word-break: break-word; +} + +table.footnote td, table.footnote th { + border: 0 !important; +} + +th { + color: white; + text-align: left; + padding-right: 5px; + background-color: #82A0BE; +} + +div.literal-block-wrapper div.code-block-caption { + background-color: #EEE; + border-style: solid; + border-color: #CCC; + border-width: 1px 5px; +} + +/* WIDE DESKTOP STYLE */ +@media only screen and (min-width: 1176px) { +body { + margin: 0 40px 0 40px; +} +} + +/* TABLET STYLE */ +@media only screen and (min-width: 768px) and (max-width: 991px) { +body { + margin: 0 40px 0 40px; +} +} + +/* MOBILE LAYOUT (PORTRAIT/320px) */ +@media only screen and (max-width: 767px) { +body { + margin: 0; +} +div.bodywrapper { + margin: 0; + width: 100%; + border: none; +} +div.sphinxsidebar { + display: none; +} +} + +/* MOBILE LAYOUT (LANDSCAPE/480px) */ +@media only screen and (min-width: 480px) and (max-width: 767px) { +body { + margin: 0 20px 0 20px; +} +} + +/* RETINA OVERRIDES */ +@media +only screen and (-webkit-min-device-pixel-ratio: 2), +only screen and (min-device-pixel-ratio: 2) { +} + +/* -- end ------------------------------------------------------------------- */ \ No newline at end of file diff --git a/docs/build/html/_static/bizstyle.js b/docs/build/html/_static/bizstyle.js new file mode 100644 index 0000000..8e94bbe --- /dev/null +++ b/docs/build/html/_static/bizstyle.js @@ -0,0 +1,41 @@ +// +// bizstyle.js +// ~~~~~~~~~~~ +// +// Sphinx javascript -- for bizstyle theme. +// +// This theme was created by referring to 'sphinxdoc' +// +// :copyright: Copyright 2012-2014 by Sphinx team, see AUTHORS. +// :license: BSD, see LICENSE for details. +// +$(document).ready(function(){ + if (navigator.userAgent.indexOf('iPhone') > 0 || + navigator.userAgent.indexOf('Android') > 0) { + $("li.nav-item-0 a").text("Top"); + } + + $("div.related:first ul li:not(.right) a").slice(1).each(function(i, item){ + if (item.text.length > 30) { + var tmpstr = item.text + $(item).attr("title", tmpstr); + $(item).text(tmpstr.substr(0, 27) + "..."); + } + }); + $("div.related:last ul li:not(.right) a").slice(1).each(function(i, item){ + if (item.text.length > 30) { + var tmpstr = item.text + $(item).attr("title", tmpstr); + $(item).text(tmpstr.substr(0, 27) + "..."); + } + }); +}); + +$(window).resize(function(){ + if ($(window).width() <= 776) { + $("li.nav-item-0 a").text("Top"); + } + else { + $("li.nav-item-0 a").text("Ring_WinCReg 1.1 documentation"); + } +}); \ No newline at end of file diff --git a/docs/build/html/_static/bizstyle.js_t.bak b/docs/build/html/_static/bizstyle.js_t.bak new file mode 100644 index 0000000..206c35c --- /dev/null +++ b/docs/build/html/_static/bizstyle.js_t.bak @@ -0,0 +1,41 @@ +// +// bizstyle.js +// ~~~~~~~~~~~ +// +// Sphinx javascript -- for bizstyle theme. +// +// This theme was created by referring to 'sphinxdoc' +// +// :copyright: Copyright 2012-2014 by Sphinx team, see AUTHORS. +// :license: BSD, see LICENSE for details. +// +$(document).ready(function(){ + if (navigator.userAgent.indexOf('iPhone') > 0 || + navigator.userAgent.indexOf('Android') > 0) { + $("li.nav-item-0 a").text("Top"); + } + + $("div.related:first ul li:not(.right) a").slice(1).each(function(i, item){ + if (item.text.length > 30) { + var tmpstr = item.text + $(item).attr("title", tmpstr); + $(item).text(tmpstr.substr(0, 27) + "..."); + } + }); + $("div.related:last ul li:not(.right) a").slice(1).each(function(i, item){ + if (item.text.length > 30) { + var tmpstr = item.text + $(item).attr("title", tmpstr); + $(item).text(tmpstr.substr(0, 27) + "..."); + } + }); +}); + +$(window).resize(function(){ + if ($(window).width() <= 776) { + $("li.nav-item-0 a").text("Top"); + } + else { + $("li.nav-item-0 a").text("{{ shorttitle|e }}"); + } +}); diff --git a/docs/build/html/_static/bizstyle.js_t.bak.old b/docs/build/html/_static/bizstyle.js_t.bak.old new file mode 100644 index 0000000..206c35c --- /dev/null +++ b/docs/build/html/_static/bizstyle.js_t.bak.old @@ -0,0 +1,41 @@ +// +// bizstyle.js +// ~~~~~~~~~~~ +// +// Sphinx javascript -- for bizstyle theme. +// +// This theme was created by referring to 'sphinxdoc' +// +// :copyright: Copyright 2012-2014 by Sphinx team, see AUTHORS. +// :license: BSD, see LICENSE for details. +// +$(document).ready(function(){ + if (navigator.userAgent.indexOf('iPhone') > 0 || + navigator.userAgent.indexOf('Android') > 0) { + $("li.nav-item-0 a").text("Top"); + } + + $("div.related:first ul li:not(.right) a").slice(1).each(function(i, item){ + if (item.text.length > 30) { + var tmpstr = item.text + $(item).attr("title", tmpstr); + $(item).text(tmpstr.substr(0, 27) + "..."); + } + }); + $("div.related:last ul li:not(.right) a").slice(1).each(function(i, item){ + if (item.text.length > 30) { + var tmpstr = item.text + $(item).attr("title", tmpstr); + $(item).text(tmpstr.substr(0, 27) + "..."); + } + }); +}); + +$(window).resize(function(){ + if ($(window).width() <= 776) { + $("li.nav-item-0 a").text("Top"); + } + else { + $("li.nav-item-0 a").text("{{ shorttitle|e }}"); + } +}); diff --git a/docs/build/html/_static/comment-bright.png b/docs/build/html/_static/comment-bright.png index 551517b..15e27ed 100644 Binary files a/docs/build/html/_static/comment-bright.png and b/docs/build/html/_static/comment-bright.png differ diff --git a/docs/build/html/_static/comment-close.png b/docs/build/html/_static/comment-close.png index 09b54be..4d91bcf 100644 Binary files a/docs/build/html/_static/comment-close.png and b/docs/build/html/_static/comment-close.png differ diff --git a/docs/build/html/_static/comment.png b/docs/build/html/_static/comment.png index 92feb52..dfbc0cb 100644 Binary files a/docs/build/html/_static/comment.png and b/docs/build/html/_static/comment.png differ diff --git a/docs/build/html/_static/css3-mediaqueries.js b/docs/build/html/_static/css3-mediaqueries.js new file mode 100644 index 0000000..59735f5 --- /dev/null +++ b/docs/build/html/_static/css3-mediaqueries.js @@ -0,0 +1 @@ +if(typeof Object.create!=="function"){Object.create=function(e){function t(){}t.prototype=e;return new t}}var ua={toString:function(){return navigator.userAgent},test:function(e){return this.toString().toLowerCase().indexOf(e.toLowerCase())>-1}};ua.version=(ua.toString().toLowerCase().match(/[\s\S]+(?:rv|it|ra|ie)[\/: ]([\d.]+)/)||[])[1];ua.webkit=ua.test("webkit");ua.gecko=ua.test("gecko")&&!ua.webkit;ua.opera=ua.test("opera");ua.ie=ua.test("msie")&&!ua.opera;ua.ie6=ua.ie&&document.compatMode&&typeof document.documentElement.style.maxHeight==="undefined";ua.ie7=ua.ie&&document.documentElement&&typeof document.documentElement.style.maxHeight!=="undefined"&&typeof XDomainRequest==="undefined";ua.ie8=ua.ie&&typeof XDomainRequest!=="undefined";var domReady=function(){var e=[];var t=function(){if(!arguments.callee.done){arguments.callee.done=true;for(var t=0;t=200&&r.status<300||r.status===304||navigator.userAgent.indexOf("Safari")>-1&&typeof r.status==="undefined"){t(r.responseText)}else{n()}document.documentElement.style.cursor="";r=null}};r.send("")};var l=function(t){t=t.replace(e.REDUNDANT_COMPONENTS,"");t=t.replace(e.REDUNDANT_WHITESPACE,"$1");t=t.replace(e.WHITESPACE_IN_PARENTHESES,"($1)");t=t.replace(e.MORE_WHITESPACE," ");t=t.replace(e.FINAL_SEMICOLONS,"}");return t};var c={stylesheet:function(t){var n={};var r=[],i=[],s=[],o=[];var u=t.cssHelperText;var a=t.getAttribute("media");if(a){var f=a.toLowerCase().split(",")}else{var f=["all"]}for(var l=0;l-1&&a.href&&a.href.length!==0&&!a.disabled){r[r.length]=a}}if(r.length>0){var c=0;var d=function(){c++;if(c===r.length){i()}};var v=function(t){var n=t.href;f(n,function(r){r=l(r).replace(e.RELATIVE_URLS,"url("+n.substring(0,n.lastIndexOf("/"))+"/$1)");t.cssHelperText=r;d()},d)};for(u=0;u0){r.setAttribute("media",t.join(","))}document.getElementsByTagName("head")[0].appendChild(r);if(r.styleSheet){r.styleSheet.cssText=e}else{r.appendChild(document.createTextNode(e))}r.addedWithCssHelper=true;if(typeof n==="undefined"||n===true){cssHelper.parsed(function(t){var n=p(r,e);for(var i in n){if(n.hasOwnProperty(i)){g(i,n[i])}}a("newStyleParsed",r)})}else{r.parsingDisallowed=true}return r},removeStyle:function(e){return e.parentNode.removeChild(e)},parsed:function(e){if(n){s(e)}else{if(typeof t!=="undefined"){if(typeof e==="function"){e(t)}}else{s(e);d()}}},stylesheets:function(e){cssHelper.parsed(function(t){e(m.stylesheets||y("stylesheets"))})},mediaQueryLists:function(e){cssHelper.parsed(function(t){e(m.mediaQueryLists||y("mediaQueryLists"))})},rules:function(e){cssHelper.parsed(function(t){e(m.rules||y("rules"))})},selectors:function(e){cssHelper.parsed(function(t){e(m.selectors||y("selectors"))})},declarations:function(e){cssHelper.parsed(function(t){e(m.declarations||y("declarations"))})},properties:function(e){cssHelper.parsed(function(t){e(m.properties||y("properties"))})},broadcast:a,addListener:function(e,t){if(typeof t==="function"){if(!u[e]){u[e]={listeners:[]}}u[e].listeners[u[e].listeners.length]=t}},removeListener:function(e,t){if(typeof t==="function"&&u[e]){var n=u[e].listeners;for(var r=0;r=a||s&&l0}}else if("device-height"===e.substring(r-13,r)){c=screen.height;if(t!==null){if(u==="length"){return i&&c>=a||s&&c0}}else if("width"===e.substring(r-5,r)){l=document.documentElement.clientWidth||document.body.clientWidth;if(t!==null){if(u==="length"){return i&&l>=a||s&&l0}}else if("height"===e.substring(r-6,r)){c=document.documentElement.clientHeight||document.body.clientHeight;if(t!==null){if(u==="length"){return i&&c>=a||s&&c0}}else if("device-aspect-ratio"===e.substring(r-19,r)){return u==="aspect-ratio"&&screen.width*a[1]===screen.height*a[0]}else if("color-index"===e.substring(r-11,r)){var h=Math.pow(2,screen.colorDepth);if(t!==null){if(u==="absolute"){return i&&h>=a||s&&h0}}else if("color"===e.substring(r-5,r)){var p=screen.colorDepth;if(t!==null){if(u==="absolute"){return i&&p>=a||s&&p0}}else if("resolution"===e.substring(r-10,r)){var d;if(f==="dpcm"){d=o("1cm")}else{d=o("1in")}if(t!==null){if(u==="resolution"){return i&&d>=a||s&&d0}}else{return false}};var a=function(e){var t=e.getValid();var n=e.getExpressions();var r=n.length;if(r>0){for(var i=0;i0){u=false;for(var f=0;f0){l[c++]=","}l[c++]=h}}if(l.length>0){r[r.length]=cssHelper.addStyle("@media "+l.join("")+"{"+e.getCssText()+"}",t,false)}};var l=function(e,t){for(var n=0;n0}}var o=[],u=[];for(var f in i){if(i.hasOwnProperty(f)){o[o.length]=f;if(i[f]){u[u.length]=f}if(f==="all"){n=true}}}if(u.length>0){r[r.length]=cssHelper.addStyle(e.getCssText(),u,false)}var c=e.getMediaQueryLists();if(n){l(c)}else{l(c,o)}};var h=function(e){for(var t=0;td||Math.abs(s-t)>d){e=n;t=s;clearTimeout(r);r=setTimeout(function(){if(!i()){p()}else{cssHelper.broadcast("cssMediaQueriesTested")}},500)}};window.onresize=function(){var e=window.onresize||function(){};return function(){e();s()}}()};var m=document.documentElement;m.style.marginLeft="-32767px";setTimeout(function(){m.style.marginLeft=""},5e3);return function(){if(!i()){cssHelper.addListener("newStyleParsed",function(e){c(e.cssHelperParsed.stylesheet)});cssHelper.addListener("cssMediaQueriesTested",function(){if(ua.ie){m.style.width="1px"}setTimeout(function(){m.style.width="";m.style.marginLeft=""},0);cssHelper.removeListener("cssMediaQueriesTested",arguments.callee)});s();p()}else{m.style.marginLeft=""}v()}}());try{document.execCommand("BackgroundImageCache",false,true)}catch(e){} diff --git a/docs/build/html/_static/css3-mediaqueries_src.js b/docs/build/html/_static/css3-mediaqueries_src.js new file mode 100644 index 0000000..65b4482 --- /dev/null +++ b/docs/build/html/_static/css3-mediaqueries_src.js @@ -0,0 +1,1104 @@ +/* +css3-mediaqueries.js - CSS Helper and CSS3 Media Queries Enabler + +author: Wouter van der Graaf +version: 1.0 (20110330) +license: MIT +website: http://code.google.com/p/css3-mediaqueries-js/ + +W3C spec: http://www.w3.org/TR/css3-mediaqueries/ + +Note: use of embedded