2009/06/19 13:12

눈꽃 컴백~~~~~~

눈꽃 컴백 임박.......이번엔 FLEX의 세계로~~~~~~~
Trackback 0 Comment 0
2008/09/09 14:51

Ubuntu 8.04 에 Eclipse Ganymede 설치시 오류

아..오랜만에 포스팅...
개발환경을 우분투로 갈아타기위해... 윈도우에서 작업한 녀석을
버추어머신에 설치된 우분투에서 확인하기 위해.. 이클립스를 설치했다..
이게 왠일-_-;;
이상한 창이 하나 생기면서... 먹통이 되어버린다.. 아래의 그림.. 먹통된 이클립스=_=;
사용자 삽입 이미지

sudo apt-get install xulrunner 잽하게 이녀석을 설치한후..

홈디렉토리로 가서 vi .bashrc 로 수정.....
제일아래에

export MOZILLA_FIVE_HOME=/usr/lib/xulrunner
export LD_LIBRARY_PATH=$MOZILLA_FIVE_HOME:$LD_LIBRARY_PATH

추가한다...
사용자 삽입 이미지
사용자 삽입 이미지

그리고.... eclipse설치폴더에 eclipse.ini파일에 아래내용을 추가한다
-Dorg.eclipse.swt.browser.XULRunnerPath=/dev/nul

사용자 삽입 이미지


끝..로그오프 한후 다시 실행!
Trackback 0 Comment 3
2008/08/02 12:58

두 점 사이의 각도 구하기

훔... 고달푸다.......아.. 고딩 수학시간에 왜 잠만 잤을가;;;
눼입어 지식인에 감사(__)

  private static double getAngle(int x1,int y1, int x2,int y2){
   int dx = x2 - x1;
   int dy = y2 - y1;
  
   double rad= Math.atan2(dx, dy);
   double degree = (rad*180)/Math.PI ;
 
   return degree;
  }
Trackback 0 Comment 1
2008/07/29 09:01

Graphical Modeling Framework (GMF) 개발순서

1. New GMF Project 생성
2. Model로 사용할 Ecore 생성
3. Ecore 파일로 EMF Model 생성
3.1. Generate Model Code
3.2. Generate Edit Code
4. Simple Graphical Definition Model 생성
5. Simple ToolingDefinition Model 생성
6. Guide Mapping Model Creation 생성
6.1. Create generator Model
6.2. Generate Diagram Code
Trackback 0 Comment 0
2008/06/03 13:52

TableView 의 table에 체크버튼 넣기

 item = new TableItem(table, SWT.NONE);
     
 TableEditor editor = new TableEditor(table);

 Button checkButton = new Button(table, SWT.CHECK);
 checkButton.pack();

 editor.minimumWidth = checkButton.getSize().x;
 editor.horizontalAlignment = SWT.CENTER;
 item.setText(0, str[i]);
 editor.setEditor(checkButton, item, 1);

Trackback 0 Comment 0
2008/03/06 09:04

Editor Open( wizard에서 파일을 editor에 연결)

 void openEditor() {
  getShell().getDisplay().asyncExec(new Runnable() {
   public void run() {
//만들어진파일의 경로
    String path = getPath();
    IResource workspaceResource = ResourcesPlugin.getWorkspace()
      .getRoot().findMember(path);
    if (workspaceResource instanceof IFile) {
     IWorkbenchPage page = PlatformUI.getWorkbench()
       .getActiveWorkbenchWindow().getActivePage();
     try {
      BasicNewResourceWizard.selectAndReveal(workspaceResource,
            page.getWorkbenchWindow());
//editor id
      page.openEditor(new FileEditorInput(
        (IFile) workspaceResource),
        Editor.ID);
     } catch (PartInitException e) {
      e.printStackTrace();
     }
    }
   }
  });
 }
Trackback 0 Comment 0
2008/03/05 13:18

org.eclipse.swt.SWTException: Invalid thread access

다른Thread에서 접근해서 swt에서 예외를 던지는것.

Display display = parent.getDisplay();
  display.syncExec(
    new Runnable() {
     public void run(){
            ........요기다가 수정을 하던지 위젯에 접근하는 코드를 넣어서 사용
     }
    }
  );
Trackback 0 Comment 1
2008/02/25 10:32

editor close

        final IEditorPart editor = findEditorFor(delta.getFullPath().toPortableString(),
          PlatformUI.getWorkbench());

        if (editor != null) {
         PlatformUI.getWorkbench().getDisplay().syncExec(new Runnable() {
          public void run() {
           editor.getEditorSite().getPage().closeEditor(
               editor,
               false);
          }
         });
        }

Trackback 0 Comment 0
2008/02/22 15:25

FormPage에서 ScrolledForm 의 해더추가

 protected void createFormContent(IManagedForm managedForm) {
  final ScrolledForm form = managedForm.getForm();
  FormToolkit toolkit = managedForm.getToolkit();
  toolkit.decorateFormHeading(form.getForm());

}
Trackback 0 Comment 0
2008/02/21 11:31

NewWizard로 파일생성후 Explorer 뷰에서 파일 선택

org.eclipse.ui.wizards.newresource.BasicNewResourceWizard
selectAndReveal(IResource resource, IWorkbenchWindow window)
          Attempts to select and reveal the specified resource in all parts within the supplied workbench window's active page.
Trackback 0 Comment 0