1 / 21

Chapter 6. Graphical User Interface GUI 환경 (X 윈도우 시스템 )

Chapter 6. Graphical User Interface GUI 환경 (X 윈도우 시스템 ). GUI 란 ?. Command-line interface 전형적인 Unix 사용자 접속 배우고 사용하기 어렵다 . 명령어를 정확히 기억해야 한다 . GUI 환경 한 개의 터미널 화면에 여러 개의 윈도우를 개설 대화는 한 순간에 한 개의 프로그램 ( 윈도우 ) 과만 가능. GUI 구성 요소. Bit-mapped display (vs. character-based display) keyboard

hidi
Download Presentation

Chapter 6. Graphical User Interface GUI 환경 (X 윈도우 시스템 )

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Chapter 6.Graphical User InterfaceGUI 환경 (X 윈도우 시스템)

  2. GUI란? • Command-line interface • 전형적인 Unix 사용자 접속 • 배우고 사용하기 어렵다. • 명령어를 정확히 기억해야 한다. • GUI 환경 • 한 개의 터미널 화면에 여러 개의 윈도우를 개설 • 대화는 한 순간에 한 개의 프로그램(윈도우)과만 가능

  3. GUI 구성 요소 • Bit-mapped display (vs. character-based display) • keyboard • mouse • mouse pointer, click, double click, drag and release • windows • terminal emulator • shell command-line interface • title bar • 프로그램 이름 • buttons • on/off attributes

  4. GUI 구성 요소 (2) • Sliders • 범위를 가진 attribute 값을 조정 • scroll bars • 윈도우 크기보다 큰 내용을 볼 때 • icons • 윈도우를 나타내는 조그만 그림 • menus • 일련의 선택사항 • pull-down menu • pop-up menu • cascading menu

  5. GUI 구성 요소 (3) minimize button title bar maximize button menu pull-down menu button scroll bar icon cascade-down menu

  6. GUI 구성 요소 (4) • dialog boxes • 수행 결과나 메시지를 보여주는 작은 윈도우 • 스크린의 배치 • overlapping vs. tiling

  7. Manager in GUI • 윈도우 관리자 • 윈도우의 모양, 조작 방법 등을 정의 • open, close, move, resize • 데스크탑 관리자 • 아이콘의 조작으로 파일의 복제, 이동, 삭제 • 작업 공간 관리자 • 일련의 작업 집합간에 전환이 가능하도록

  8. X 윈도우 시스템 • 1984, developed at MIT (athena project) • 1993, X11R5 (version 11, release 5) • 현재, X11R6 • X는 원래 워크스테이션용으로 개발 • bit-mapped 그래픽 화면, 키보드, 마우스, LAN 환경 • Network based graphic window system • 기존의 window system의 약점인 network상에서의 traffic을 최소화하는데 역점 • 몇 개의 메시지를 교환함으로써 network상에서 window system을 운용

  9. X windows basics • X server • Window Manager • terminal emulator • 그외 각종 client

  10. X 터미널 • 그래픽 화면, 키보드, 마우스로 구성 • 하드 디스크나 프린터 등은 가지지 않음 • 제어 프로그램(작은 OS)를 수행하는 CPU와 기억장치 소유 • 가격 저렴, 설치 및 관리의 용이 • LAN과 연결된 모든 컴퓨터에 access 가능

  11. X 윈도우 관리자 • Window의 모양, 운용방식 등을 결정짓는 client이다. • OSF/Motif • mwm (Motif Window Manager by OSF) • Open Look by AT&T and SUN • olwm (Open Look Window Manager) • Tab Window Manager • twm • Virtual Tab Window Manager • vtwm, 실제 화면보다 더 큰 작업공간을 관리할 수 있다.

  12. Motif 윈도우 관리자(mwm)의 사용법 • X 응용 프로그램의 위치 • /usr/bin/X11 /usr/openwin/bin /usr/dt/bin • 마우스 포인터의 종류 (1) X (2) I-beam (3) arrow • 현재 윈도우의 선택 방식 (1) pointer (2) explicit: click-to-type (default) • 세션의 시작과 종료 • 새로운 윈도우의 개설 (1) [오른쪽 마우스 버튼] click  “New Window” [오른쪽 마우스 버튼] click  “프로그램”  “단말기” (2) 쉘에서 xterm& 또는 dtterm& 수행

  13. Motif 윈도우 관리자(mwm)의 사용법 (2) • 타이틀 바 • 메뉴 버튼 • Maximize 버튼 • Minimize 버튼 • Closing a window • window menu. • exit command • Moving window or Changing window size • left mouse button • Raising and lowering window • left mouse button

  14. Motif 윈도우 관리자(mwm)의 사용법 (3) • Using icons • window minimize button • Copying and pasting text • select with left, and paste with middle button • CDE에서는 [오른쪽버튼]  “편집(Edit)” ”복사(Copy)” [오른쪽버튼]  “편집(Edit)” ”붙여넣기(Paste)” • Scrolling text • xterm에서는 스크롤바에 마우스 포인터를 가져 간다. • [왼쪽버튼] : 아래로 • [오른쪽버튼] : 위로 • [가운데버튼] : 끌고가기

  15. xterm • X window 상에서 돌아가는 terminal emulator • 한 개의 xterm은 한 개의 session을 의미 • 여러 개의 xterm을 띄우면 여러 dummy terminal로부터 login한 것과 같은 상태가 된다. • Xterm자체에서 블록 지정이나 복사가 가능하다. • 한글 사용을 위해 hanterm 등이 구현되어 있다.

  16. X 작업 환경의 설정 • 마우스 버튼의 순서 변경 % xmodmap -e ‘pointer = 3 2 1’ • 화면의 색깔 변경 % xterm -bg blue -fg yellow -title “Hard to read!” • 윈도우 크기 설정 % xterm -geometry 132x30 & % xclock -geometry 200x200 & • 윈도우의 위치 설정 % xterm -geometry +25+15 & (왼쪽 위) % xterm -geometry 135x50-10-10& (오른쪽 아래)

  17. Resource in X windows • Resource란? • 각 client가 display될 때 나타날 특성들을 지정해 주는 것 • 테두리, 배경 색깔, 글자 모양, 등을 server에게 미리 알려준다. • .Xresource나 .Xdefaults 파일에 저장해둔다. • .Xdefaults나 .Xresource 파일들은 xinit시 xrdb에 의해 읽혀져서 특정영역에 저장된다. • 스타일 관리자 • [오른쪽버튼]  프로그램  스타일관리자 • 배색, 배경, 폰트, 모양 등을 변경 • 스타일관리자  시작 • 현재 화면의 구성을 보존

  18. .xsession 파일 • 로그인 시 자동으로 시작되는 X응용을 지정 • xdm (X Display manager) 은 홈 디렉토리에 있는 .xsession을 수행 exec /usr/bin/X11/mwm & exec /usr/bin/X11/xlock -bg White -geometry 100x100& exec /usr/bin/X11/xload -geometry 150x100-0+0 & exec /usr/bin/X11/xbiff -geometry -0+150& exec xterm -geometry 80x22+10-0 -ls -sb -fn 8x3 -title “xterm window” &

  19. .Xdefaults 파일 • Command-line attribute를 항상 입력하는 대신, 응용 프로그램이 사용하는 선택사용을 미리 지정 • 홈디렉토리에 있는 .Xdefaults가 /usr/lib/X11/app-defaults보다 우선 • 포맷: name-of-application*name-of-resource: value Xterm*background: blue Xterm*foreground: yellow Xterm*scrollBar: True Xterm*Font: 10x20

  20. Remote 화면 출력 • 본인의 호스트에서 다른 호스트에로의 출력 • 다른 호스트로부터 현재의 호스트에 화면 출력 % setenv DISPLAY term1:0.0 % echo $DISPLAY term1:0.0 % xclock -display comp76:0.0& [1] 29747 • Display의 허락 % xhost comp222 (comp222에게만 허락) % xhost + (모든 호스트에게 허락)

  21. X 응용의 종류 (교과서 Fig 6-16 참조) appres showrgb xcalc xclipboard xclock xfontset xhost xload xlsfonts xmag xman xmodmap xpr xrdb xset xsetroot xterm xwd xwininfo

More Related