2013년 7월 18일 목요일

블로그에 하이라이트 기능 넣기

델파이 관련 자료를 많이 다루다 보니 소스 코드가 많은데 보기에 별로여서 보기 좋게 꾸미려고 구굴링해보았더니 있더군요. 해서 따라 해보았습니다.

Adding Syntax Highlighting to Blogger 를 참조하세요. 

막상 따라해보니 이해가 잘 안되는 곳도 있더군요.

먼저

1. Go to http://syntaxhighlighter.googlecode.com/svn/trunk/Styles/SyntaxHighlighter.css, then perform a "select all" and "copy". The css information is now in the clipboard.

링크 따라가서 복사 한다음
[템플릿  > 사용중인 디자인 > HTML 편집] 한다음

2. Paste the css information at the end of the css section of your blogger html template (i.e., after <b:skin><!--[CDATA[/* and before ]]--></b:skin>).

]] 껏쇠 바로 앞부분에 넣으라는 이야기고..

3. [Updated March 25, 2009 to include closing script tags] Before the </head> tag, paste the following:

부분 코드 박스 위쪽에 있는  [View plain / Copy to Clipboard / Print / ?] 에서 Copy to Clipboard 를 선택하여 복사 한다음 </head> 바로 앞부분에 붙여 넣고

4. [Updated to add final /script] Before the </body> tag, insert the following:
역시 Copy to Clipboard 를 선택하여 복사 한다음  </body> 바로 앞에 붙여 넣습니다.

코드 작성 할때
<pre name="code" class="delphi">
...Your html-escaped code goes here...
</pre>
이렇게 하면 됩니다.

(4) 에서 아래와 같이 코드를 수정하면 Copy To Clipboard 가 활성화 됩니다.

<script language='javascript'>
dp.SyntaxHighlighter.BloggerMode();
dp.SyntaxHighlighter.ClipboardSwf = '/flash/clipboard.swf'; 
dp.SyntaxHighlighter.HighlightAll('code');
</script>

** 복사하여 붙여 넣기 하면 ' 문자가 바뀌여 들어 가더군요.

tensorflow gpu 사용하기에서

 tensorflow 설치시 주의해야 한다. # Anything above 2.10 is not supported on the GPU on Windows Native python - m pip install "tensorflow<2.11...