today i finally figured out what the "T method" is :)
it's a part of Orchard CMS and is used for localization (translating strings to other languages/locales):
example:
<br/>
@T("Price"): <b>$@Model.Price</b><br />
@Model.Sku<br/>
from the orchard article "Building the Templates":
This is very plain rendering of the shape. Notice the use of the T method call to wrap the "Price" string literal. This enables localization of that text.
from the orchard article "Localizing the Orchard Application and Orchard Modules":
All strings in the Orchard application are output through a single T() method that can look up a translated string based on the default site culture.
from the orchard article "How Orchard Works":
Localization of the application and its modules is done by wrapping string resources in a call to the T method: <%: T("This string can be localized") %>
IT, computer and programming tutorials and tips that i couldnt find anywhere else using google, from my daily work as a Senior Developer of solutions using Java and Linux.
The best place to *find* answers to programming/development questions, imo, however it's the *worst* place to *ask* questions (if your first question/comment doesn't get any up-rating/response, then u can't ask anymore questions--ridiculously unrealistic), but again, a great reference for *finding* answers.
My Music (Nickleus)
20140606
20140604
orchard asp.net c# mvc - how to include jquery-ui.min.css file
in your view file, e.g. myView.cshtml:
@{
Style.Include("jquery-ui.min.css").AtHead();
}
thanks to Adding jquery ui themes Question for help.
UPDATE 20140610
orchard has a jQuery module already, so all i actually had to do was this:
thanks to Nicholas Mayne
@{
Style.Include("jquery-ui.min.css")
}
put the jquery-ui.min.css file in your MyModule/Styles/ folder:
MyModule/Styles/jquery-ui.min.css
the rendered HTML will look like this:
<link href="/Modules/MyModule/Styles/jquery-ui.min.css" rel="stylesheet" type="text/css" />
thanks to Adding jquery ui themes Question for help.
UPDATE 20140610
orchard has a jQuery module already, so all i actually had to do was this:
@{
Style.Require("jQueryUI").AtHead();
Script.Require("jQueryUI").AtHead();
}
thanks to Nicholas Mayne
20140523
windows 8.1 useful shortcuts under mac boot camp
windows 8.1 useful shortcuts under mac boot camp
for norwegian users (mac with norwegian keyboard keys)
##########
CHROME
##########
MOVE TO TAB LEFT/RIGHT: fn+ctrl+arrow up/down
##########
INPUT
##########
BACKSLASH ( \ ): (right)alt+(right)shift+/
##########
NAVIGATION
##########
LINE HOME/END: fn+arrow left/right
##########
SYSTEM ACTIONS
##########
...more to come as i find more useful shortcuts
for norwegian users (mac with norwegian keyboard keys)
##########
CHROME
##########
MOVE TO TAB LEFT/RIGHT: fn+ctrl+arrow up/down
##########
INPUT
##########
BACKSLASH ( \ ): (right)alt+(right)shift+/
##########
NAVIGATION
##########
LINE HOME/END: fn+arrow left/right
##########
SYSTEM ACTIONS
##########
LOCK SCREEN: fn+cmd+L
PRINT SCREEN: fn+shift+F11
20140522
[SOLVED] mac boot camp windows 8.1 can't select text, context menu pops up
i installed windows 8.1 through boot camp on my mac (mavericks) and was having trouble selecting text because when i would select something, then hold left finger in to be able to select more text by using my second finger, a context menu would pop up right away when i tried expanding the selected text by moving my second finger.
i finally figured out how to configure the keyboard settings through boot camp so that text selection and expansion works as described above:
1. open "boot camp control panel" in windows
2. select the "trackpad" tab
configure it as shown in the image above:
One Finger > Tap to click: unchecked
One Finger > Secondary click: checked > choose either Bottom right corner or Bottom left corner
Two Fingers > Secondary click: unchecked
click Apply or OK
i finally figured out how to configure the keyboard settings through boot camp so that text selection and expansion works as described above:
1. open "boot camp control panel" in windows
2. select the "trackpad" tab
configure it as shown in the image above:
One Finger > Tap to click: unchecked
One Finger > Secondary click: checked > choose either Bottom right corner or Bottom left corner
Two Fingers > Secondary click: unchecked
click Apply or OK
20140516
mac boot camp install windows 8 - additional important info/steps
i originally tried installing windows 8.1 on my mac macbook pro osx mavericks and thought that a 32GB partition would be large enough, but after installing, there was only like 4GB left, os i started over and made the partition 80GB instead (i am going to install visual studio + some other large programs).
when boot camp loads the window install, i scrolled down to the partition i made while in boot camp in mac, selected it and clicked Next:
then i got this error message:
windows can't be installed on drive 0 partition 4
so i clicked the Format link (see screenshot above), and was warned that it was about to format the drive (this is normal)
click Next again:
then the installation proceeded as normal:
when boot camp loads the window install, i scrolled down to the partition i made while in boot camp in mac, selected it and clicked Next:
then i got this error message:
windows can't be installed on drive 0 partition 4
so i clicked the Format link (see screenshot above), and was warned that it was about to format the drive (this is normal)
click Next again:
then the installation proceeded as normal:
[SOLVED] gimp mac can't export png - saving failed, error while saving, could not save image
i installed gimp on mac and tried exporting an image to png, but got this error:
Saving '/Users/me/Documents/nick-cv-img2.png' failed:
Error while saving '/Users/me/Documents/nick-cv-img2.png'. Could not save image.
the solution was simple:
https://bugs.archlinux.org/task/35363#comment110197
Menu > Image > Mode > Convert to Color Profile ...
Then just click "Convert" to convert it to "RGB workspace (sRGB built-in)"
Now exporting to PNG just works flawlessly.
thanks to Felix Yan (felixonmars)
Saving '/Users/me/Documents/nick-cv-img2.png' failed:
Error while saving '/Users/me/Documents/nick-cv-img2.png'. Could not save image.
the solution was simple:
https://bugs.archlinux.org/task/35363#comment110197
Menu > Image > Mode > Convert to Color Profile ...
Then just click "Convert" to convert it to "RGB workspace (sRGB built-in)"
Now exporting to PNG just works flawlessly.
thanks to Felix Yan (felixonmars)
20140505
mac - mule studio - where is maven home?
i'm testing out mule studio and got a warning/error about maven, that it needed to be installed/configured, so to find out where the maven home folder was, i ran this in Terminal:
mvn -version
which returned the following:
...
Apache Maven 3.2.1 (ea8b2b07643dbb1b84b6d16e1f08391b666bc1e9; 2014-02-14T18:37:52+01:00)
Maven home: /usr/local/Cellar/maven/3.2.1/libexec
...
Subscribe to:
Posts (Atom)


