Category: Windows
Building/Creating Google Chrome Themes: Manual Reshacker-Way
Google Chrome ships with a folder called theme and a file called default.dll in it.
There are plenty of themes popping up everywhere for the new browser, but actually nearly no documentation on how to make your own.
So the questions are: how to create my own default.dll, how to recompile default.dll or how to change images in default.dll. We won't talk about the second question now, but let's face how to create our own default.dll with changed images in the default.dll-file.
There is a very small and useful tool called ResHacker. Use it and open the default.dll. You'll see plenty of binary data and some icons. While looking at the svn repository of chrome, I noticed that all this files are actually .png files!
So let's have a look at how to replace the "Go"-Button in google chrome. By this table you can see, that the go button has the id 9025. So left click the binary data #9025/1033 and press "Action"->"Save Resource as binary fileÂ? ... " and call the file go.png.
Open the go.png with any image editor you like (even mspaint!). Change it and save it.
Now comes the final steps to add the new go-button:
- Press "Action"->"Replace other Resource"
- "Open file with new resource" and open the go.png.
- Use BINDATA as resource type, 9025 as resource name and 1033 as resource language and press "Replace".
- Press "File" -> "Save"
- Restart your Chrome Browser!
Now your default theme, should have the new Go-button we just created!
Extracting the files and replacing by hand is a very time intensive way to replace+make themes for google chrome, thatswhy psytoy created 2 batchfiles for automatic extract + replacing of the images in the .dll. So you can create your themes in no time!
Editing Chrome: Basics with Database
After you installed Google Chrome or downloaded latest version of chromium, you will notice a user data directory for chrome.
Most of this files, contain information in the sqlite3-database format. Using the free sqlite database browser, you can easily access/modify/delete data in that files.
I'll give you know a short information about what some of these files contain and where you should start, if you want to edit them by hand.
Cookies: Contains every information available about cookies. If you really need to get in touch with them, check the file on your own.
Web Data->keywords: All information about the search engines, auto suggest features and the categories for the search engines are configured here.
History->downloads: What files have been downloaded and when started the download.
History->urls: How often did you visited a page (vist_count), how often did you typed the uri on your own (typed_count), what was it's lastest title, is the url hidden?, when did you visited the page the last time.
History-visits: Each visit for a page (url). Contains for example: Time (visit_time) and previous page (from_visit).
Some of the files are not encoded with sqlite3-format. An other format is the JSONoation, so we'll continue with the json-user-data-files of Chrome in the next article.
Editing Chrome: Basics with JSON-Files
Since some of the chrome user-data is not saved as sqlite3-database, you will have notice also the json-format for files.
JSON is the javascript object notation and since chrome has a very fast javascript engine called V8, why shouldn't use the notation for datastorage, too? :)
We'll have a short information about what files are in the user-data directory, which are encoded as json-files.
Preferences:
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
"default_search_provider": {
"id": "2",
"name": "Google",
"search_url": "{google:baseURL}search?{google:RLZ}{google:acceptedSuggestion}{google:originalQueryForSuggestion}sourceid=chrome&ie={inputEncoding}&q={searchTerms}",
"suggest_url": "{google:baseSuggestURL}search?client=chrome&output=chrome&hl={language}&q={searchTerms}"
},
"download": {
"extensions_to_open": ""
},
"geoid_at_install": 94,
"profile": {
"exited_cleanly": true,
"id": "not-signed-in",
"name": "",
"nickname": ""
},
"search": {
"suggest_enabled": false
},
"session": {
"urls_to_restore_on_startup": [Â? ]
}
}
Bookmarks: Contains all bookmarks in an object with all folders and it's children-array.
2
3
4
5
6
"date_added": "12865081791713103",
"name": "DracoBlue",
"type": "url",
"url": "http://dracoblue.net/"
}
We'll go in details about theme-ing and extending chrome in next days.
Chromium vs. Google Chrome: Different UserData Directory
When using Chromium (the snapshots of google chrome) and Google Chrome, there are different default directories for the personal data (like bookmarks, recent searches and so on).
Chromium (replace dracoblue, with your login):
UserData: C:\Users\dracoblue\AppData\Local\Chromium\User Data
Google Chrome (replace dracoblue, with your login):
UserData: C:\Users\dracoblue\AppData\Local\Google\Chrome\User Data
Chrome.exe: C:\Users\dracoblue\AppData\Local\Google\Chrome\Application
This paths are for Windows VISTA, in XP you usually have to C:\Documents and Settings\dracoblue\... .
Chromium: Downloading latest Version of Google Chrome
It's possible to download always (even though not always recommended) version of Chromium from the automaticly build sites by the chromium project.
Head over to the official build directory and pick the latest folder.
Download the chrome-win32.zip and unzip it to for example (replace dracoblue with your loginname):
C:\Users\dracoblue\AppData\Local\Chromium\Application
Launch chrome.exe, now you are running the latest version!
You will not see your bookmarks from the chrome installation, for more information check the differences of google chrome user data directories.
Getting LaTeX to work on Windows
After I got the following errors:
when trying:
2
3
...
\includegraphics{filename.jpg}
And those errors on a .tex file (a friend gave me):
2
3
I found no \bibdata command
I found no \bibstyle command
and several other issues with my latex editors on windows machines, I finally figured out to convert that tex to pdf.
First of all I installed the miktex latex command line tools. I downloaded basic version here, worked fine.
TexnicCenter and LEd can't manage to edit UTF-8 files. So I needed to stick with texmaker (which works also on linux and mac os). To get utf-8 working there, I switched to Options -> Configure Texmaker and turned Font to utf-8.
After I got those issues with includegraphics tags, I changed the 'fast translation'-key F1 to PdfLatex -> ViewPDF (in options) and: It workes well, even with those images.


