annotate etc/TUTORIAL.hr @ 4899:aa8197436fdb

Make #'find-function behave better with dumped functions, installed XEmacs 2010-01-30 Aidan Kehoe <kehoea@parhasard.net> * loadup.el: If any filename in load-history starts with the value of source-lisp, delete that part of the string, so that #'find-function works better with dumped functions in an installed XEmacs (it will look in lisp-directory instead, where it will probably succeed).
author Aidan Kehoe <kehoea@parhasard.net>
date Sat, 30 Jan 2010 15:47:37 +0000
parents 3ecd8885ac67
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
428
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1 Copyright (c) 1985, 1996 Free Software Foundation, Inc. Uvjeti
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
2 kopiranja na kraju.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
3
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
4 Ovo su osnovne upute za Emacs.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
5
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
6 Općenito, Emacsove naredbe sadrže tipku CONTROL (ponekad označenu CTRL
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
7 ili CTL) ili tipku META. Na nekim tipkovnicama tipka META je označena
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
8 kao ALT ili EDIT, ili nešto treće (na primjer, na Sunovim tipkovnicama
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
9 karo znak lijevo od razmaknice je META). Ako nemate tipku META,
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
10 umjesto nje možete koristiti ESC. Da ne pišemo META ili CONTROL svaki
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
11 put kad mislimo na prefiksnu tipku, koristit ćemo sljedeće skraćenice:
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
12
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
13 C-<znak> znači držeći tipku CONTROL, stisnite znak <znak>. Tako bi
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
14 C-f bilo: Držeći tipku CONTROL, napišite f.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
15 M-<znak> znači držeći tipku META, pritisnite <znak>. Ako nema tipke
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
16 META, pritisnite <ESC>, otpustite ga, i napišite znak
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
17 <znak>.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
18
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
19 Napomena: za izlazak iz Emacsa, utipkajte C-x C-c. (Dva znaka.)
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
20 Znakovi ">>" na lijevom rubu naznačuju uputstva da pokušate koristiti
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
21 neku naredbu. Na primjer:
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
22 <<Sredina stranice namjerno ostavljena prazna. Tekst se nastavlja dolje.>>
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
23 >> Sad utipkajte C-v za pomak na sljedeći ekran.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
24 (samo naprijed, učinite to tako da držite tipku control i
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
25 pritisnite 'v'). Od sad, ovo trebate napraviti kad god završite
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
26 sa čitanjem stranice teksta.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
27
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
28 Uočite dva reda koja se preklapaju kad se pomaknete s ekrana na ekran;
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
29 preklapanje osigurava kontinuitet koji vam olakšava čitanje teksta.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
30
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
31 Prva stvar koju trebate znati jest kako se micati s mjesta na mjesto u
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
32 tekstu. Već znate kako se pomaknuti ekran naprijed, pomoću C-v. Da
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
33 biste se pomakli ekran natrag, pritisnite M-v (držite tipku META i
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
34 pritisnite v, ili upišite <ESC>v ako nemate tipke META, EDIT ili ALT).
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
35
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
36 >> Pokušajte tipkati M-v, zatim C-v, nekoliko puta.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
37
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
38
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
39 * SAŽETAK
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
40 ---------
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
41
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
42 Sljedeće naredbe su korisne za pregledavanje stranica teksta:
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
43
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
44 C-v Pomiče stranicu naprijed
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
45 M-v Pomiče stranicu natrag
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
46 C-l Briše ekran, i ponovno iscrtava sve, stavljajući tekst
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
47 pokraj kursora u sredinu.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
48 (to je control-L, a ne control-1.)
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
49
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
50 >> Nađite kursor, i pogledajte tekst pokraj njega.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
51 Sada stisnite C-l.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
52 Opet nađite kursor, i uočite da se pokraj kursora nalazi isti
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
53 tekst.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
54
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
55
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
56 * OSNOVE KONTROLE KURSORA
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
57 -------------------------
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
58
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
59 Pomaci s ekrana na ekran su korisni, ali kako se pomaknuti na pojedino
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
60 mjesto u tekstu na ekranu?
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
61
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
62 To možete učiniti na nekoliko načina. Najosnovniji način je
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
63 upotrijebiti naredbe C-p, C-b, C-f i C-n. Svaka od ovih naredbi
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
64 pomiče kursor jedan redak ili stupac u pojedinom smjeru. Evo tablice
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
65 koja pokazuje ove četiri naredbe i smjerove u kojem pomiču.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
66
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
67 Prethodni red, C-p
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
68 (eng. previous line)
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
69 :
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
70 :
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
71 Natrag, C-b .... Trenutni položaj kursora .... Naprijed, C-f
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
72 (eng. backward) : (eng. forward)
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
73 :
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
74 Sljedeći red, C-n
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
75 (eng. next line)
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
76
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
77 >> Pomaknite kursor do retka u sredini tablice koristeći C-n i C-p.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
78 Tada stisnite C-l da vidite cijelu tablicu u središtu ekrana.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
79
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
80 Ove su naredbe temeljene na engleskim mnemonicima: P za previous, N za
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
81 next, B za backward i F za forward. Ovo su osnovne naredbe za
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
82 pomicanje kursora, i s vremenom ćete ih SVE koristiti, pa bi bilo vrlo
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
83 korisno da ih sada naučite.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
84
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
85 >> Stisnite C-n nekoliko puta, tako da dovedete kursor do ovog retka.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
86
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
87 >> Pomaknite se na red s C-f-ovima, i onda gore do C-p-ova.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
88 Uočite što C-p radi kad je kursor na sredini reda.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
89
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
90 Svaki red teksta završava znakom Newline (novi red), čime ga se odvaja
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
91 od sljedećeg reda. Zadnji red u datoteci bi trebao imati Newline na
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
92 kraju (ali Emacs to ne zahtijeva).
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
93
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
94 >> Pokušajte stisnuti C-b na početku reda. Trebalo bi vas pomaknuti
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
95 na kraj prethodnog reda. To se događa zato što ste se pomakli
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
96 unatrag, preko znaka Newline.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
97
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
98 C-f se miče preko Newline-a, baš kao i C-b.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
99
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
100 >> Pritisnite još nekoliko puta C-b, da steknete osjećaj za kursor.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
101 Tad stišćite C-f dok se ne vratite na kraj reda.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
102 Zatim se još jednim C-f-om pomaknite na početak sljedećeg reda.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
103
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
104 Kad se pomaknete preko gornjeg ili donjeg ruba ekrana, tekst iza ruba
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
105 se pomakne na ekran. Ovo se naziva "pomak" (eng. scrolling). Njime
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
106 Emacs može pomaknuti kursor na neko mjesto u tekstu bez uklanjanja
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
107 kursora s ekrana.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
108
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
109 >> Pokušajte pomaknuti kursor s donjeg ruba sa C-n, i pogledajte što
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
110 se događa.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
111
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
112 Ako je micanje po znakovima presporo, možete se micati po riječima.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
113 M-f (Meta-f) miče riječ naprijed, a M-b miče riječ natrag.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
114
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
115 >> Pritisnite nekoliko puta M-f i M-b.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
116
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
117 Kad se nalazite u sredini riječi, M-f pomiče na kraj riječi. Kad se
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
118 nalazite u praznom prostoru između riječi, M-f pomiče na kraj sljedeće
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
119 riječi. M-b se ponaša na isti način, ali u suprotnom smjeru.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
120
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
121 >> Pritisnite M-f i M-b nekoliko puta, izmiješano s C-f i C-b, tako da
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
122 možete promotriti kako se M-f i M-b ponašaju na različitim mjestima
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
123 unutar i između riječi.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
124
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
125 Uočite paralelu između C-f i C-b na jednoj strani, i M-f i M-b na
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
126 drugoj. Meta znakovi se često koriste za operacije vezane uz jedinice
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
127 definirane jezikom (riječi, rečenice, paragrafi), dok Control znakovi
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
128 rade na osnovnim jedinicama, neovisno o onome što editirate (znakovi,
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
129 redovi, itd.)
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
130
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
131 Analogija vrijedi i između redova i rečenica: C-a i C-e pomiču na
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
132 početak, odnosno na kraj reda, dok M-a i M-e pomiču na početak, odnosno
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
133 kraj rečenice.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
134
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
135 >> Iskušajte C-a nekoliko puta, potom C-e nekoliko puta.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
136 >> Iskupajte M-a nekoliko puta, potom M-e nekoliko puta.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
137
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
138 Uočite kako ponovljeni C-a ne rade ništa, dok ponovljeni M-a
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
139 nastavljaju micati po rečenicama. Iako ovo nije sasvim analogno,
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
140 svaka se naredba doima prirodnom.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
141
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
142 Položaj kursora u tekstu se također naziva "točka" (eng. point).
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
143 Drugačije rečeno, kursor pokazuje na ekranu gdje se point nalazi u
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
144 tekstu.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
145
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
146 Evo sažetka jednostavnih operacija za micanje kursora, uključujući i
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
147 naredbe za pomicanje preko riječi i rečenica:
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
148
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
149 C-f Znak naprijed
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
150 C-b Znak natrag
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
151
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
152 M-f Riječ naprijed
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
153 M-b Riječ natrag
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
154
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
155 C-n Sljedeći red
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
156 C-p Prethodni red
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
157
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
158 C-a Početak reda
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
159 C-e Kraj reda
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
160
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
161 M-a Početak rečenice
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
162 M-e Kraj rečenice
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
163
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
164 >> Iskušajte sve ove naredbe još nekoliko puta, za vježbu.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
165 To su najčešće rabljene naredbe.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
166
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
167 Dvije druge važne naredbe za pomicanje kursora su M-< (Meta Manje),
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
168 koja pomiče na početak cijelog teksta, i M-> (Meta Veće), koja pomiče
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
169 na kraj cijelog teksta.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
170
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
171 Na većini terminala, "<" je iznad zareza, tako da morate koristiti
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
172 tipku shift da biste ga utipkali. Na tim terminalima morate koristiti
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
173 tipku shift i da biste utipkali M-<; bez shifta, pisali biste M-zarez.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
174
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
175 >> Sada iskušajte M-<, da biste se pomaknuli na početak uputa.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
176 Potom upotrijebite C-v nekoliko puta da se vratite ovamo.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
177
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
178 >> Sada iskušajte M->, pomaknuvši se na kraj uputa.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
179 Potom upotrijebite M-v nekoliko puta da se vratite ovamo.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
180
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
181 Ako vaš terminal ima kursorske tipke, možete kursor pomicati njima.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
182 Preporučujemo da naučite C-b, C-f, C-n i C-p iz tri razloga. Prvo,
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
183 rade na svim vrstama terminala. Drugo, kad steknete rutinu korištenja
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
184 Emacsa, primijetit ćete da je tipkanje ovih CTRL znakova brže od
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
185 uporabe kursorskih tipki (jer ne morate odmicati prste od položaja za
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
186 tipkanje). Treće, jednom kad se naviknete koristiti CTRL znakovne
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
187 naredbe, lako ćete naučiti koristiti druge napredne naredbe za micanje
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
188 kursora.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
189
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
190 Većina Emacsovih naredbi prihvaća numerički argument; za većinu njih
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
191 ovo služi kao brojač ponavljanja. Brojač ponavljanja zadajete tako da
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
192 utipkate C-u i potom znamenke prije nego što utipkate naredbu. Ako
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
193 imate tipku META (ili EDIT ili ALT), postoji još jedan alternativan
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
194 način unošenja numeričkog argumenta: tipkajte znamenke držeći svo vrijeme
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
195 tipku META. Preporučujemo učenje metode pomoću C-u, jer radi na svim
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
196 terminalima.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
197
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
198 Primjerice, C-u 8 C-f pomiče osam znakova naprijed.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
199
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
200 >> Pokušajte koristiti C-n ili C-p s numeričkim argumentom, tako da
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
201 pomaknete kursor na liniju blisku ovoj samo jednom naredbom.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
202
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
203 Većina naredbi koristi numerički argument kao brojač ponavljanja.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
204 Neke ga naredbe, izunimno, koriste drugačije. C-v i M-v su među
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
205 iznimkama. Kad im se proslijedi argument, one pomaknu ekran gore ili
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
206 dolje, za toliko redova, a ne stranica. Na primjer, C-u 4 C-v pomiče
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
207 ekran za četiri reda.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
208
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
209 >> Sada pokušajte upisati C-u 8 C-v.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
210
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
211 Ovo je trebalo pomaknuti ekran za 8 redova. Ako ga hoćete pomaknuti
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
212 natrag, možete dati isti argument M-v.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
213
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
214 Ako koristite X Window sistem, vjerojatno se na desnoj strani Emacsova
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
215 prozora nalazi pravokutno područje nazvano "vrpca za pomicanje"
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
216 (eng. scroll-bar). Možete pomicati tekst mišem povlačeći klizač
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
217 unutar vrpce.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
218
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
219 >> Pokušajte pritisnuti srednju tipku miša na vrh klizača unutar
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
220 scroll-bara. Ovo bi trebalo pomaknuti tekst do položaja određenog
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
221 visinom točke pritiska.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
222
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
223 >> Pomaknite miša na točku scroll-bara otprilike tri reda od vrha, i
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
224 pritisnite lijevu tipku miša nekoliko puta.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
225
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
226
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
227 * KONTROLA KURSORA NA X TERMINALU
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
228 ---------------------------------
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
229
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
230 Ako imate X terminal, vjerojatno će vam biti lakše koristiti tipke
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
231 kursorskog bloka. Lijeva, desna, gornja i donja strelica pomiču u
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
232 očekivanom smjeru; one funkcioniraju jednako kao i C-b, C-f, C-p i
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
233 C-n, ali ih je lakše tipkati i zapamtiti. Također možete koristiti
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
234 C-lijevo i C-desno za pomake po riječima, a C-gore i C-dolje za pomake
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
235 po blokovima (npr. paragrafima, ako editirate tekst). Ako imate tipke
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
236 označene s HOME (ili BEGIN) i END, one će vas pomaknuti na početak
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
237 odnosno kraj reda, a C-home i C-end će vas pomaknuti na početak
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
238 odnosno kraj datoteke. Ako vaša tipkovnica ima tipke PgUp i PgDn,
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
239 možete ih koristiti za pomicanje gore i dolje po stranicama, kao M-v i
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
240 C-v.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
241
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
242 Sve ove naredbe mogu primiti numeričke argumente, kao što je gore
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
243 opisano. Možete taj argument unijeti kraćim putem: samo držite tipku
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
244 CONTROL ili META, i upišite broj. Na primjer, za pomak 12 riječi
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
245 desno, tipkajte C-1 C-2 C-desno. Uočite da je ovo jako lako utipkati,
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
246 jer ne morate otpuštati tipku CONTROL između pritisaka tipki.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
247
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
248
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
249 * KAD EMACS BLOKIRA
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
250 -------------------
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
251
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
252 Ako Emacs prestane odgovarati na vaše naredbe, možete ga zaustaviti
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
253 utipkavši C-g. Možete koristiti C-g da zaustavite naredbu koja predugo
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
254 traje.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
255
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
256 Također s C-g možete odbaciti numerički argument, ili početak naredbe
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
257 koju ne želite završiti.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
258
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
259 >> Upišite C-u 100 da napravite numerički argument 100, zatim stisnite C-g.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
260 Sad upišite C-f. Pomaknut će se samo za jedan znak, jer ste
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
261 argument odbacili s C-g.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
262
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
263 Ako greškom stisnete <ESC>, možete ga se riješiti s C-g.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
264
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
265
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
266 * ONEMOGUĆENE NAREDBE
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
267 ---------------------
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
268
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
269 Neke Emacsove naredbe su "onemogućene", tako da ih početnici ne mogu
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
270 pokrenuti greškom.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
271
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
272 Ako utipkate jednu od onemogućenih naredbi, Emacs će vas porukom
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
273 obavijestiti koju ste naredbu pokušali pokrenuti, i pitati vas želite
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
274 li je ipak izvršiti.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
275
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
276 Ako je zaista želite isprobati, pritisnite razmaknicu kao odgovor na
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
277 pitanje. Inače, ako ne želite izvršiti onemogućenu naredbu,
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
278 odgovorite na pitanje s "n".
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
279
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
280 >> Pritisnite `C-x n p' (što je onemogućena naredba),
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
281 zatim na pitanje odgovorite s "n".
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
282
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
283
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
284 * PROZORI
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
285 ---------
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
286
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
287 Emacs može imati nekoliko prozora, svaki s vlastitim tekstom. Uočite
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
288 da se pojam "prozora" kako ga koristi Emacs ne odnosi na odvojene
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
289 preklapajuće prozore windowing sustava, već na razdvojene dijelove
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
290 unutar jednog X prozora. (Emacs također može prikazati više X
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
291 prozora, odnosno "okvira", u Emacsovoj terminologiji. To je opisano
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
292 kasnije.)
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
293
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
294 Za sada je bolje ne ulaziti u tehnike korištenja više prozora. Ono
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
295 što trebate znati jest kako se riješiti dodatnih prozora koji se mogu
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
296 javiti za prikaz pomoći, ili kao izlaz nekih naredbi.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
297 Jednostavno:
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
298
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
299 C-x 1 Jedan prozor (tj. ubij sve druge prozore)
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
300
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
301 To je Control-x praćen znamenkom 1. C-x 1 proširuje prozor u kojem je
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
302 kursor, tako da on zauzme cijeli ekran. Pobriše, također, i ostale
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
303 prozore.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
304
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
305 >> Pomaknite kursor na ovu liniju i upišite C-u 0 C-l.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
306
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
307 (Sjetite se da C-l ponovno iscrtava ekran. Ako ovoj naredbi date
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
308 numerički argument, on znači "iscrtaj ekran i smjesti trenutni red
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
309 toliko linija od vrha ekrana." Tako C-u 0 C-l znači "iscrtaj ekran, i
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
310 stavi trenutni red na vrh.")
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
311
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
312 >> Pritisnite Control-x 2
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
313 Uočite kako se ovaj prozor smanjuje, dok se novi pojavljuje
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
314 prikazujući sadržaj ovog spremnika (buffera).
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
315
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
316 >> Upišite C-x 1 i gledajte kako novi prozor nestaje.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
317
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
318
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
319 * UMETANJE I BRISANJE
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
320 ---------------------
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
321
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
322 Želite li umetnuti tekst, samo ga utipkajte. Znakove koje vidite, kao
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
323 što su A, 7, *, itd. Emacs shvaća kao tekst i umeće trenutno.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
324 Pritisnite <Return> (znak za novi red) da umetnete znak Newline.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
325
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
326 Zadnji znak koji ste umetnuli možete izbrisati pritisnuvši <Delete>.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
327 <Delete> je tipka na tipkovnici koja može biti označena kao "Del". U
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
328 nekim slučajevima, tipka "Backspace" služi kao <Delete>, ali ne
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
329 uvijek!
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
330
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
331 Općenitije, <Delete> briše znak neposredno ispred trenutnog položaja
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
332 kursora.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
333
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
334 >> Učinite sljedeće: utipkajte nekoliko znakova, zatim ih izbrišite
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
335 stisnuvši <Delete> nekoliko puta. Ne brinite o promjeni ove
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
336 datoteke; nećete izmijeniti glavnu verziju uputa. Ovo je vaša
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
337 osobna kopija.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
338
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
339 Kad red teksta postane prevelik za jedan red na ekranu, red se
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
340 "nastavlja" na drugi ekranski red. Obrnuta kosa crta ("\") na desnom
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
341 rubu ukazuje na red koji je nastavljen.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
342
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
343 >> Upisujte tekst dok ne dođete do desnog ruba, i nastavite pisati.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
344 Vidjet ćete kako se pojavljuje nastavljeni red.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
345
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
346 >> Tipkom <Delete> brišite tekst dok red teksta opet ne stane na red
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
347 ekrana. Kontinuacijski red tada nestaje.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
348
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
349 Možete izbrisati znak Newline kao i bilo koji drugi znak. Brisanje
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
350 znaka Newline između dva reda ih spaja u jedan red. Ako je novonastali
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
351 zajednički red prevelik da stane na ekranski red, bit će prikazan
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
352 kontinuacijskim redom.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
353
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
354 >> Pomaknite kursor na početak reda i pritisnite <Delete>. Red će se
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
355 spojiti s redom iznad.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
356
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
357 >> Pritisnite <Return> tako da ponovno umetnete Newline koji ste
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
358 izbrisali.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
359
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
360 Upamtite da se većini Emacsovih naredbi može zadati brojač
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
361 ponavljanja; ovo uključuje znakove teksta. Ponavljanje znaka teksta
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
362 unosi ga nekoliko puta.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
363
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
364 >> Iskušajte sad -- upišite C-u 8 * da upišete ********.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
365
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
366 Sada ste naučili najosnovnije načine upisivanja u Emacs i ispravljanja
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
367 grešaka. Sada možete i brisati po riječima ili redovima. Evo sažetka
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
368 operacija brisanja:
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
369
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
370 <Delete> briši znak neposredno pred kursorom
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
371 C-d briši znak nakon kursora
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
372
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
373 M-<Delete> ubij riječ prije kursora
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
374 M-d ubij riječ poslije kursora
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
375
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
376 C-k ubij od pozicije kursora do kraja reda
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
377 M-k ubij do kraja trenutne rečenice
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
378
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
379 Uočite da <Delete> i C-d nasuprot M-<Delete> i M-d proširuju paralelu
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
380 začetu s C-f i M-f (dobro, <Delete> baš i nije kontrolni znak, ali
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
381 nemojmo brinuti o tome). C-k i M-k su na neki način slični C-e i M-e,
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
382 po operaciji na redovima, odnosno rečenicama.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
383
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
384 Kad brišete više od jednog znaka istovremeno, Emacs sprema izbrisani
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
385 tekst, tako da ga možete dobiti natrag. Vraćanje ubijenog teksta zove
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
386 se "dobavljanje" (eng. yanking). Možete dobaviti ubijeni tekst bilo
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
387 na isto mjesto gdje je bio ubijen, bilo na neko drugo mjesto u
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
388 tekstu. Možete dobaviti tekst nekoliko puta, čime ćete dobiti
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
389 višestruke kopije. Komanda za dobavljanje je C-y.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
390
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
391 Uočite da je razlika između "ubijanja" i "brisanja" nečega u tome što
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
392 se ubijeni tekst može dobaviti natrag, a izbrisani ne može. Općenito,
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
393 naredbe koje uklanjaju puno teksta spreme izbrisani tekst, dok ga
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
394 naredbe koje brišu samo jedan znak ili samo prazne linije i razmake ne
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
395 spremaju.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
396
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
397 >> Pomaknite kursor na početak reda koji nije prazan.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
398 Zatim pritisnite C-k da ubijete tekst u tom redu.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
399 >> Stisnite C-k drugi put. Vidjet ćete da ubija Newline koji prati
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
400 taj red.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
401
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
402 Uočite da jedan C-k ubija sadržaj reda, dok drugi C-k ubija sam red, i
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
403 miče sve druge redove prema gore. C-k tretira numerički argument na
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
404 specijalan način: ubija toliko redova, i njihov sadržaj. Ovo nije
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
405 obično ponavljanje. C-u 2 C-k ubija dva reda i njihove newline;
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
406 pritiskanje C-k dvaput ne bi dalo taj rezultat.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
407
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
408 Da povratite zadnji ubijeni tekst i stavite ga gdje je kursor
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
409 trenutno, pritisnite C-y.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
410
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
411 >> Pokušajte; pritisnite C-y da dobavite tekst.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
412
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
413 Gledajte na C-y kao da dobavljate natrag nešto što vam je netko uzeo.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
414 Uočite da ako ponovite C-k nekoliko puta, sav tekst bit će spremljen
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
415 zajedno, tako da će ga C-y dobaviti odjednom.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
416
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
417 >> Učinite to sad, pritisnite C-k nekoliko puta.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
418
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
419 Sad, da bi vratili ubijeni tekst:
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
420
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
421 >> Stisnite C-y. Tad spustite kursor nekoliko linija niže i opet
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
422 stisnite C-y. Sada vidite kako se kopira tekst.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
423
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
424 Što napraviti ako imate tekst koji želite dobaviti, ali onda ubijete
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
425 nešto drugo? C-y bi dobavio zadnji tekst. Ali prethodni tekst nije
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
426 izgubljen. Možete ga povratiti koristeći naredbu M-y. Nakon što
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
427 pritisnete C-y i dobijete zadnje ubijeni tekst, pritiskanje M-y ga
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
428 zamjenjuje s prethodno ubijenim tekstom. Uzastopno pozivanje M-y
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
429 dobavlja sve ranije i ranije tekstove. Kad dođete do teksta koji ste
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
430 tražili, ne morate učiniti ništa posebno da ga zadržite. Samo
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
431 nastavite s editiranjem, ostavivši dobavljeni tekst gdje jest.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
432
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
433 Ako pritisnete M-y dovoljno puta, vratit ćete se na polaznu točku
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
434 (zadnji ubijeni tekst).
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
435
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
436 >> Ubijte jedan red, pomičite se po tekstu, ubijte drugi red.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
437 Zatim pritisnite C-y da biste dobili natrag drugi ubijeni red.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
438 Zatim napravite M-y pa će taj tekst biti zamijenjen prvim ubijenim
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
439 redom. Napravite još par puta M-y i pogledajte što dobivate.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
440 Nastavite s M-y dok ne vratite drugi ubijeni red, a zatim M-y
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
441 pritisnite još par puta. Ako želite, možete pokušati proslijediti
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
442 naredbi M-y pozitivne i negativne argumente.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
443
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
444
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
445 * PONIŠTENJE
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
446 ------------
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
447
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
448 Ako napravite izmjenu u tekstu, pa se zatim predomislite, možete
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
449 poništiti (eng. "undo") promjenu naredbom undo, C-x u.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
450
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
451 Obično, C-x u poništava promjene koje su rezultat jedne naredbe; ako
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
452 ponovite C-x u nekoliko puta uzastopce, svako novo ponavljanje
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
453 poništava učinak još jedne naredbe.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
454
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
455 Ali, postoje dva izuzetka: naredbe koje ne mijenjaju tekst se ne
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
456 računaju (ovo uključuje naredbe koje miču kursor i pomiču tekst), a
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
457 samo-umećući znakovi se obično grupiraju u skupine od po 20 (da se
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
458 umanji broj C-x u koje morate stisnuti da biste poništili unos
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
459 teksta).
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
460
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
461 >> Ubijte ovu liniju s C-k, zatim utipkajte C-x u i trebala bi se
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
462 ponovno pojaviti.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
463
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
464 C-_ je alternativna naredba za poništenje; ona radi isto kao C-x u,
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
465 ali ju je lakše utipkati nekoliko puta za redom. Mana C-_ je da na
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
466 nekim tipkovnicama nije očigledno kako je utipkati. Zato ostavljamo i
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
467 C-x u. Na nekim terminalima možete dobiti C-_ kombinacijom CTRL i /.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
468
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
469 Numerički argument naredbi C-_ ili C-x u služi kao brojač ponavljanja.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
470
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
471
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
472 * DATOTEKE
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
473 ----------
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
474
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
475 Da biste za stalno spremili izmjene na tekstu koji editirate, morate ga
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
476 spremiti u datoteku. Ako to ne učinite, tekst će nestati kada izađete
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
477 iz Emacsa. Svoje izmjene stavljate u datoteku tako što je prvo
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
478 "nađete" (ovo se još naziva i "posjeta" datoteci).
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
479
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
480 Nalaženje datoteke znači da vidite sadržaj datoteke unutar Emacsa. U
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
481 neku ruku, ovo je kao da editirate samu datoteku. Međutim, izmjene
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
482 koje napravite koristeći Emacs ne postaju trajne dok niste "snimili"
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
483 datoteku. Tako možete izbjeći ostavljanje poluzavršene datoteke u
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
484 sustavu, ako to ne želite. Čak i kad snimate, Emacs ostavlja izvornu
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
485 datoteku pod promijenjenim imenom, za slučaj da se kasnije
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
486 predomislite.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
487
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
488 Ako pogledate pri dnu ekrana, vidjet ćete red koji počinje i završava
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
489 s crticama, i sadrži niz "XEmacs: TUTORIAL.hr". Ovaj dio ekrana
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
490 uvijek pokazuje naziv datoteke koju posjećujete. U ovom trenutku vi
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
491 posjećujete datoteku koja se zove "TUTORIAL", a koja je vaša osobna
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
492 kopija Emacsovih uputa. Koju god datoteku našli, njen će se naziv
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
493 pojaviti na tom istom mjestu.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
494
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
495 Naredbe za pronalaženje i spremanje datoteka se razlikuju od drugih
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
496 naredbi koje ste dosad upoznali, po tome što se sastoje od dva znaka.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
497 Obje počinju znakom Control-x; mnoge od njih rade s datotekama,
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
498 spremnicima i povezanim stvarima. Ove naredbe su dugačke dva, tri ili
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
499 četiri znaka.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
500
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
501 Još jedna stvar u vezi naredbe za nalaženje datoteke je da morate reći
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
502 koju datoteku želite. Kažemo da naredba "čita argument s terminala"
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
503 (u ovom slučaju, argument je naziv datoteke). Kad utipkate naredbu
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
504
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
505 C-x C-f Nađi datoteku
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
506
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
507 Emacs traži od vas da upišete naziv datoteke. Naziv datoteke koji
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
508 upišete pojavljuje se u donjem redu ekrana. Taj donji red naziva se
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
509 minispremnik (minibuffer) kad se koristi za tu vrstu unosa. Možete
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
510 koristiti uobičajene Emacsove naredbe da editirate naziv datoteke.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
511
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
512 Dok unosite naziv datoteke (ili za bilo kojeg unosa iz minispremnika),
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
513 možete otkazati naredbu pomoću C-g.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
514
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
515 >> Upišite C-x C-f, potom C-g. Ovo otkazuje minispremnik, a također
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
516 otkazuje i naredbu C-x C-f koja je koristila minispremnik. Tako
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
517 nijedna datoteka neće biti pronađena.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
518
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
519 Kad završite s upisom imena datoteke, stisnite <Return> za kraj. Tad
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
520 će naredba C-x C-f otpočeti svoj posao, i naći datoteku koju ste
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
521 izabrali. Minispremnik nestaje kad naredba C-x C-f završi.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
522
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
523 Ubrzo će se sadržaj datoteke pojaviti na ekranu, i moći ćete editirati
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
524 sadržaj. Kad poželite trajno sačuvati svoje izmjene, upišite naredbu
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
525
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
526 C-x C-s Spremi datoteku
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
527
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
528 Ovo kopira tekst unutar Emacsa u datoteku na disku. Prvi put kad ovo
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
529 učinite, Emacs će preimenovati izvornu datoteku u novo ime, tako da je
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
530 ne izgubite. Novo se ime tvori dodavanjem znaka ~ na izvorno ime
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
531 datoteke.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
532
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
533 Kad snimanje završi, Emacs ispiše ime snimljene datoteke. Trebali
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
534 biste snimati relativno često, tako da ne izgubite puno ako sustav
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
535 padne.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
536
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
537 >> Upisavši C-x C-s, spremite svoju kopiju uputa.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
538 Na dnu ekrana bi trebalo pisati "Wrote ...TUTORIAL.hr".
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
539
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
540 Primjedba: Na nekim sustavima, tipkanje C-x C-s će zamrznuti ekran, i
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
541 nećete više vidjeti Emacsov output. To znači da "prednost"
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
542 operativnog sustava zvana "kontrola toka" (eng. flow control) presreće
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
543 C-s i ne da mu da dođe do Emacsa. Odmrznite sustav tipkom C-q. Tada
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
544 pogledajte odjeljak "Spontaneous Entry to Incremental Search"
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
545 Emacsovog manuala za savjet kako se nositi s ovom "prednošću".
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
546
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
547 Možete naći postojeću datoteku, da je pogledate ili editirate. Možete
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
548 također naći i datoteku koja još ne postoji. Tako se stvaraju nove
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
549 datoteke Emacsom: nađite datoteku, koja će ispočetka biti prazna, i
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
550 počnite unositi tekst u datoteku. Kad zatražite "snimanje" datoteke,
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
551 Emacs će zaista stvoriti datoteku s tekstom koji ste unijeli. Od tad
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
552 pa nadalje, možete smatrati da editirate već postojeću datoteku.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
553
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
554
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
555 * SPREMNICI
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
556 -----------
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
557
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
558 Ako nađete još jednu datoteku s C-x C-f, ona prva ostaje unutar
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
559 Emacsa. Možete se vratiti natrag na nju nalazeći je opet s C-x C-f.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
560 Ovako možete otvoriti priličan broj datoteka unutar Emacsa.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
561
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
562 >> Stvorite datoteku imena "foo" tipkajući C-x C-f foo <Return>.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
563 Tad unesite neki tekst, editirajte ga, i snimite "foo" utipkavši
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
564 C-x C-s.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
565 Konačno, upišite C-x C-f TUTORIAL.hr <Return> da se vratite na
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
566 upute.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
567
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
568 Emacs pohranjuje tekst svake datoteke u objektu zvanom "spremnik"
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
569 (eng. buffer). Nalaženje datoteke otvara novi spremnik unutar
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
570 Emacsa. Popis spremnika koji se nalaze u trenutnom pozivu Emacsa
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
571 možete dobiti sa
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
572
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
573 C-x C-b Izlistaj spremnike
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
574
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
575 >> Sada iskušajte C-x C-b.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
576
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
577 Uočite kako svaki spremnik ima naziv, a može imati i ime datoteke koje
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
578 se odnosi na datoteku čiji sadržaj je u njemu. Neki spremnici ne
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
579 odgovaraju ni jednoj datoteci. Na primjer, spremnik "*Buffer List*" nema
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
580 ni jednu datoteku. To je spremnik koji sadrži spisak spremnika koji
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
581 je stvorila naredba C-x C-b. BILO KOJI tekst koji vidite u nekom
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
582 Emacsovom prozoru uvijek je dio nekog spremnika.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
583
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
584 >> Pritisnite C-x 1 da se riješite spiska spremnika.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
585
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
586 Ako promijenite tekst jedne datoteke, zatim nađete drugu datoteku, ova
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
587 prva neće biti snimljena. Njene promjene ostaju unutar Emacsa, u
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
588 spremniku te datoteke. Ovo je korisno, ali to i znači da je potreban
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
589 pogodan način snimanja datoteke prvog spremnika. Bilo bi nespretno
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
590 prebacivati se natrag u spremnik s C-x C-f samo zato da ga se snimi s
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
591 C-x C-s. Zato imamo
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
592
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
593 C-x s Snimi neke spremnike.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
594
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
595 C-x s vas pita za svaki spremnik koji sadrži izmjene koje niste
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
596 snimili. Za svaki takav spremnik pita vas da li ga želite snimiti.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
597
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
598 >> Upišite red teksta, potom upišite C-x s.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
599 Pitat će vas želite li snimiti spremnik s nazivom TUTORIAL.hr.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
600 Odgovorite potvrdno na pitanje, tipkajući "y".
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
601
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
602
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
603 * UPORABA IZBORNIKA
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
604 -------------------
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
605
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
606 Ako ste na X terminalu, uočit ćete izbornik na vrhu Emacsovog prozora.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
607 Možete koristiti izbornik za pristup svim uobičajenim Emacsovim
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
608 naredbama, kao što su "find file". Ovo će vam u početku biti lakše,
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
609 jer nećete morati pamtiti tipke za neku naredbu. Jednom kad vam rad u
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
610 Emacsu postane ugodan, lako ćete početi koristiti naredbe s
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
611 tipkovnice, jer svaka stavka izbornika sadrži i odgovarajuću tipku za
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
612 pokretanje naredbe.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
613
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
614 Uočite da postoji puno stavki koje nemaju ekvivalent na tipkovnici.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
615 Na primjer, izbornik "Buffers" prikazuje sve raspoložive spremnike
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
616 redosljedom posljednje uporabe. Možete se prebaciti na bilo koji
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
617 spremnik tako da jednostavno izaberete njegov naziv u izborniku
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
618 "Buffers".
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
619
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
620
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
621 * UPORABA MIŠA
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
622 --------------
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
623
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
624 Kad radite pod X-ima, Emacs je u potpunosti integriran s mišem.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
625 Možete pozicionirati tekstualni kursor pritisnuvši lijevu tipku miša
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
626 na željenom mjestu, možete izabrati tekst povlačeći lijevu tipku miša
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
627 po željenom tekstu. (Ili, na drugi način, pritisnuti lijevu tipku
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
628 miša s jedne strane, zatim se pomaknuti na drugu stranu, i koristiti
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
629 Shift i tipku miša za izbor teksta.)
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
630
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
631 Ako želite ubiti izabrani tekst, možete pritisnuti C-w, ili izabrati
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
632 Cut u izborniku Edit. Uočite da ovo dvoje *nije* isto: C-w samo
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
633 sprema tekst unutar Emacsa (slično C-k, kako je opisano gore), dok Cut
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
634 radi ovo, i još sprema tekst u X clipboard, gdje do njega mogu
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
635 pristupiti ostale aplikacije.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
636
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
637 Tekst s X clipboarda možete dobiti koristeći stavku Paste izbornika
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
638 Edit.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
639
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
640 Srednja tipka miša se obično koristi za izbor stvari koje su vidljive
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
641 na ekranu. Na primjer, ako uđete u Info (Emacsovu on-line
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
642 dokumentaciju) koristeći C-h i ili izbornik Help, možete pratiti
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
643 osvijetljeni link pritisnuvši srednju tipku miša na njemu. Slično,
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
644 ako tipkate naziv datoteke (npr. na "Find File" promptu) i pritisnete
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
645 TAB da vidite mogućnosti, možete stisnuti srednju tipku miša na neku
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
646 od mogućnosti, da je izaberete.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
647
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
648 Desna tipka miša poziva "skočni" izbornik. Sadržaj ovog izbornika
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
649 ovisi o modu u kojem se trenutno nalazite, i obično sadrži nekoliko
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
650 često korištenih naredbi, tako da se do njih lakše dođe.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
651
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
652 >> Sada pritisnite desnu tipku miša.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
653
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
654 Morat ćete držati tipku da zadržite izbornik.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
655
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
656
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
657 * PROŠIRENJE SKUPA NAREDBI
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
658 --------------------------
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
659
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
660 Emacsovih naredbi ima puno puno više nego što bi ikad moglo stati na
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
661 sve kontrolne i meta znakove. Emacs ovo zaobilazi proširenim
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
662 (eXtended) naredbama. One dolaze u dva oblika:
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
663
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
664 C-x Proširi znak. Praćena jednim znakom.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
665 M-x Proširena naredba s imenom. Praćena dugim imenom.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
666
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
667 Postoje naredbe koje jesu korisne, ali ih se rabi manje nego naredbe o
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
668 kojima smo dosad govorili. Već ste vidjeli dvije: naredbe s
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
669 datotekama C-x C-f za nalaženje i C-x C-s za snimanje. Još jedan
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
670 primjer je naredba kojom se izlazi iz Emacsa -- to je naredba C-x
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
671 C-c. (ne brinite o gubljenju izmjena koje ste napravili; C-x C-c vam
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
672 nudi da snimite svaku izmijenjenu datoteku prije no što izađe iz
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
673 Emacsa).
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
674
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
675 Naredbom C-z *privremeno* izlazite iz Emacsa -- tako da se možete
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
676 nakon nekog vremena opet vratiti u Emacs.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
677
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
678 Na sustavima koji to dozvoljavaju, C-z "suspendira" Emacs; to jest,
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
679 vraća se u ljusku, ali ne uništava Emacs. U većini ljuski, možete
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
680 nastaviti rad Emacsa naredbom `fg', ili s `%emacs'.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
681
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
682 Na sustavima koji ne podržavaju suspendiranje, C-z stvara podljusku
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
683 koja radi pod Emacsom, tako da možete pokrenuti druge programe i
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
684 naknadno se vratiti u Emacs; ona neće zaista "izaći" iz Emacsa. U
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
685 ovom slučaju, ljuskina naredba `exit' je uobičajen način povratka iz
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
686 podljuske u Emacs.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
687
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
688 Vrijeme za C-x C-c je onda kad se kanite odlogirati. Također, to je
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
689 ispravna stvar kad je Emacs pozvan iz čitača pošte, ili nekog drugog
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
690 programa, jer se oni ne moraju znati nositi sa suspendiranjem Emacsa.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
691 U normalnim okolnostima, međutim, ako se ne kanite odlogirati, bolje
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
692 je suspendirati Emacs s C-z nego izaći iz njega.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
693
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
694 Postoji puno C-x naredbi. Evo spiska onih koje ste naučili:
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
695
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
696 C-x C-f Nađi datoteku.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
697 C-x C-s Snimi datoteku.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
698 C-x C-b Popis spremnika.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
699 C-x C-c Izađi iz Emacsa.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
700 C-x u Poništi zadnju naredbu.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
701
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
702 Imenovane proširene naredbe su naredbe koje se još rjeđe koriste, ili
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
703 se koriste samo unutar stanovitih modova. Primjer je naredba
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
704 replace-string, koja globalno zamjenjuje jedan niz drugim. Kad
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
705 napišete M-x, Emacs će vam dati prompt na dnu ekrana, a vi trebate
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
706 samo napisati naziv naredbe. U ovom slučaju, "replace-string". Samo
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
707 napišite "repl s<TAB>", i Emacs će dovršiti ime. Završite naziv
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
708 naredbe s <Return>.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
709
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
710 Naredba replace-string traži dva argumenta -- niz koji se zamjenjuje,
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
711 i niz kojim će se zamijeniti. Završite svaki argument s <Return>.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
712
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
713 >> Pomaknite kursor na prazan red dva reda ispod ovoga. Zatim
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
714 napišite M-x repl s <Return>promijenio<Return>izmijenio<Return>.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
715
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
716 Primijetite kako se ovaj red promijenio: zamijenili ste riječ
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
717 p-r-o-m-i-j-e-n-i-o s "izmijenio" gdje god se ova pojavila, nakon
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
718 početnog položaja kursora.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
719
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
720
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
721 * AUTOMATSKO SNIMANJE
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
722 ---------------------
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
723
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
724 Kada ste promijenili datoteku, ali je još niste snimili, vaše bi
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
725 izmjene mogle biti izgubljene ako računalo padne. Da vas zaštiti od
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
726 ovoga, Emacs povremeno ispisuje "auto save" (automatsko snimanje)
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
727 datoteku za svaku datoteku koju editirate. Auto-save datoteka ima #
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
728 na početku i na kraju imena; na primjer, ako se vaša datoteka zove
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
729 "hello.c", njezina će se auto-save datoteka zvati "#hello.c#". Kad
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
730 snimite datoteku na normalan način, Emacs će izbrisati njezinu
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
731 auto-save datoteku.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
732
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
733 Ako računalo padne, možete obnoviti svoje automatski spremljene
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
734 promjene tako što normalno nađete datoteku, i napišete
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
735 M-x recover file <Return>. Kad vas pita za potvrdu, upišite
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
736 yes<return> za nastavak i vratite automatski snimljene podatke.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
737
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
738
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
739 * PROSTOR ZA PORUKE
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
740 -------------------
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
741
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
742 Ako Emacs vidi da pišete naredbe polako, pokazat će vam ih na dnu
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
743 ekrana na mjestu koje se zove "prostor za poruke" (eng. echo area).
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
744 Prostor za poruke je na najnižem redu ekrana.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
745
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
746
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
747 * STATUSNI RED
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
748 --------------
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
749
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
750 Red odmah iznad prostora za poruke se zove "statusni red"
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
751 (eng. modeline). Statusni red izgleda otprilike ovako:
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
752
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
753 --**-XEmacs: TUTORIAL.hr (Fundamental)--L670--58%----------------
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
754
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
755 Ovaj red pruža korisne informacije o statusu Emacsa i tekstu koji
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
756 editirate.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
757
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
758 Već znate što je ime datoteke -- to je datoteka koju ste našli.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
759 -NN%-- predstavlja vaš trenutni položaj u tekstu; to znači da je NN
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
760 postotaka teksta iznad vrha ekrana. Ako je vrh teksta na ekranu,
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
761 pisat će --Top-- umjesto --00%--. Ako je kraj teksta na ekranu, pisat
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
762 će --Bot--. Ako gledate u tako kratak tekst da sav stane na ekran, u
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
763 statusnoj liniji će pisati --All--.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
764
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
765 Zvjezdice na početku znače da ste napravili izmjene na tekstu.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
766 Neposredno po posjeti ili snimanju datoteke, taj dio statusne linije
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
767 nema zvjezdica, već samo crtice.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
768
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
769 Dio statusne linije u zagradama govori u kojem se modu editiranja
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
770 nalazite. Podrazumijeva se Fundamentalni mod, koji trenutno koristite.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
771 On je primjer "glavnog moda".
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
772
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
773 Emacs ima puno različitih glavnih modova. Neki od njih su predviđeni
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
774 za editiranje različitih jezika i/ili vrsta teksta, kao što je Lisp
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
775 mod, tekst mod, itd. U bilo kojem trenutku jedan i samo jedan glavni
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
776 mod je aktivan, i njegovo se ime nalazi na statusnom redu, gdje sada
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
777 stoji "Fundamental".
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
778
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
779 Svaki glavni mod čini da se nekoliko naredbi ponaša različito. Na
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
780 primjer, postoje naredbe za stvaranje komentara u programu, a budući
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
781 da svaki programski jezik ima drugačiju predodžbu o tome kako komentar
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
782 izgleda, svaki glavni mod različito unosi komentare. Svaki glavni mod
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
783 je ime jedne proširene naredbe, što je i način kako se možete
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
784 prebaciti u taj mod. Na primjer, M-x fundamental-mode je naredba koja
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
785 vas prebacuje u Fundamental mod.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
786
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
787 Ako editirate tekst na hrvatskom, kao što je ova datoteka, vjerojatno
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
788 biste trebali koristiti tekstualni mod.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
789 >> Napišite M-x text-mode<Return>.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
790
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
791 Ne brinite, nijedna od naredbi koje ste naučili neće promijeniti Emacs
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
792 na značajan način. Ali možete uočiti da M-f i M-b sad tretiraju
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
793 apostrofe kao dio riječi. U fundamentalnom modu M-f i M-b su
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
794 tretirali apostrofe kao separatore riječi.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
795
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
796 Glavni modovi obično rade suptilne izmjene poput navedene: većina
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
797 naredbi rade "isti posao" u svakom glavnom modu, ali funkcioniraju s
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
798 malom razlikom.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
799
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
800 Da biste vidjeli dokumentaciju trenutnog glavnog moda, pritisnite
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
801 C-h m.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
802
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
803 >> Pritisnite još jednom C-u C-v da dovedete ovu liniju do vrha ekrana.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
804 >> Utipkajte C-h m, da vidite kako se tekstualni mod razlikuje od
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
805 fundamentalnog moda.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
806 >> Pritisnite q da uklonite dokumentaciju s ekrana.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
807
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
808 Glavni modovi se nazivaju glavnima, jer postoje još i sporedni
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
809 modovi. Sporedni su modovi nisu zamjena za glavne modove, već njihova
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
810 usputna modifikacija. Svaki sporedni mod može biti uključen ili
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
811 isključen za sebe, neovisno o ostalim sporednim modovima, i neovisno o
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
812 glavnom modu. Tako možete ne biti niti u jednom sporednom modu, ili u
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
813 jednom sporednom modu, ili u kombinaciji nekoliko sporednih modova.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
814
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
815 Jedan vrlo koristan sporedni mod, naročito za editiranje hrvatskog
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
816 teksta, jest mod za automatsko popunjavanje (Auto Fill mode). Kad je
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
817 ovaj mod uključen, Emacs automatski lomi linije između riječi kad god
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
818 umetanjem teksta stvorite red koji je preširok.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
819
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
820 Možete uključiti Auto Fill mod pisanjem M-x auto-fill-mode<Return>.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
821 Kad je mod uključen, isključujete ga s M-x auto-fill-mode<Return>.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
822 Kad je mod isključen, ova ga naredba uključuje, kad je uključen, ona
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
823 ga isključuje.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
824
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
825 >> Napišite M-x auto-fill-mode<Return> sad. Potom umećite tekst "asdf "
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
826 dok god se red ne razdvoji na dva dijela. Morate stavljati razmake
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
827 između, jer Auto Fill lomi redove samo na razmacima.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
828
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
829 Rub je obično postavljen na 70 znakova, ali ga možete promijeniti
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
830 naredbom C-x f. Rub koji želite postaviti podešavate numeričkim
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
831 argumentom.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
832
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
833 >> Utipkajte C-x f s argumentom 20. (C-u 2 0 C-x f).
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
834 Potom upišite neki tekst, i gledajte kako Emacs lomi redove dulje
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
835 od 20 znakova. Tad postavite rub natrag na 70 ponovno
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
836 upotrijebivši C-x f.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
837
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
838 Ako napravite promjene u sredini paragrafa, Auto Fill mod ga neće
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
839 cijelog reformatirati.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
840 Za preoblikovanje paragrafa, utipkajte M-q (Meta-q) s kursorom unutar
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
841 paragrafa.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
842
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
843 >> Pomaknite kursor na prethodni paragraf, i stisnite M-q.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
844
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
845
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
846 * TRAŽENJE
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
847 ----------
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
848
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
849 Emacs može tražiti nizove (grupe uzastopnih znakova ili riječi) bilo
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
850 prema naprijed ili prema natrag kroz tekst. Traženje niza je naredba
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
851 kojom se pomiče kursor; ona će pomaknuti kursor do sljedećeg mjesta na
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
852 kom se niz pojavljuje.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
853
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
854 Emacsova naredba za traženje se razlikuje od sličnih naredbi većine
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
855 editora po tome što je "postupna" (eng. incremental). To znači da se
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
856 pretraživanje odvija dok upisujete niz koji tražite.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
857
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
858 Naredba kojom počinjete naredbu je C-s za traženje prema naprijed, i
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
859 C-r za traženje unatrag. ALI ČEKAJTE! Nemojte ih odmah isprobati.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
860
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
861 Kad utipkate C-s, primijetit ćete da se tekst "I-search" pojavljuje
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
862 kao prompt u prostoru za poruke. Ovo vam kaže da je Emacs u stanju
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
863 postupnog traženja, i da čeka da upišete što želite tražiti.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
864 <Return> zaustavlja traženje.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
865
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
866 >> Sad stisnite C-s da započnete pretraživanje. POLAKO, znak po znak,
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
867 utipkajte riječ `kursor', radeći stanku između znakova da uočite
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
868 što se događa s kursorom.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
869 Sad ste našli "kursor", jednom.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
870 >> Stisnite C-s opet, da nađete sljedeće pojavljivanje "kursora".
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
871 >> Sad stisnite <Delete> četiri puta, i gledajte kako se kursor
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
872 pomiče.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
873 >> Stisnite <RET> da prekinete traženje.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
874
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
875 Jeste li vidjeli što se dogodilo? Za vrijeme inkrementalnog traženja,
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
876 Emacs pokušava otići na mjesto gdje se pojavljuje niz kojeg ste do sad
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
877 utipkali, osvjetljavajući ga zbog preglednosti. Za odlazak na
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
878 sljedeće mjesto gdje se "kursor" pojavljuje, samo opet stisnite C-s.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
879 Ako ni jedno takvo mjesto ne postoji, Emacs će se oglasiti zvučnim
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
880 signalom i reći vam da pretraga niju uspjela ("failing"). Pretragu
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
881 možete prekinuti i pomoću C-g.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
882
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
883
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
884 PRIMJEDBA: Na nekim sustavima, tipkanje C-s će smrznuti sustav i više
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
885 nećete vidjeti daljnji Emacsov output. To pokazuje da "prednost"
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
886 operativnog sustava zvana "kontrola toka" (eng. flow control) presreće
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
887 C-s i ne da mu da dođe do Emacsa. Pritisak na C-q će odmrznuti ekran.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
888 Tad pogledajte odjeljak "Spontaneous Entry to Incremental Search"
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
889 Emacsovog manuala za savjet kako se nositi s ovom "prednošću".
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
890
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
891 Ako za vrijeme postupnog traženja pritisnete <Delete>, uočit ćete
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
892 da je zadnji znak niza izbrisan i da se pretraga vratila na zadnje
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
893 mjesto. Na primjer, pretpostavimo da ste stisnuli "k" ne bi li našli
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
894 prvo pojavljivanje "k". Ako sad stisnete "u", kursor će se pomaknuti
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
895 na mjesto prvog pojavljivanja "ku". Sad stisnite <Delete>. Ovo će
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
896 ukloniti "u" iz traženog niza, i pomaknuti kursor natrag na prvu
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
897 pojavu "k".
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
898
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
899 Ako ste usred traženja i stisnete kontrolni ili meta znak (s nekoliko
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
900 iznimki -- znakova koji imaju posebno značenje pri traženju, kao što
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
901 su C-s i C-r), traženje se zaustavlja.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
902
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
903 C-s započinje pretragu koja traži bilo koju pojavu traženog niza NAKON
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
904 trenutnog položaja kursora. Ako želite tražiti nešto što se
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
905 pojavljuje ranije u tekstu, stisnite C-r. Sve što smo rekli za C-s
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
906 vrijedi i za C-r, jedino što je smjer pretrage suprotan.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
907
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
908
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
909 * VIŠESTRUKI PROZORI
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
910 --------------------
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
911
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
912 Jedna od lijepih stvari u Emacsu je što možete prikazati više prozora
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
913 na ekranu istovremeno.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
914
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
915 >> Dovedite kursor do ovog reda i stisnite C-u 0 C-l.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
916
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
917 >> Sad stisnite C-x 2, što razdvaja ekran na dva prozora.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
918 Oba prozora prikazuju ove upute. Kursor ostaje u gornjem prozoru.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
919
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
920 >> Stisnite C-M-v da pomaknete donji prozor.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
921 (Ako nemate pravu tipku Meta, stisnite ESC C-v.)
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
922
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
923 >> Stisnite C-x o ("o" kao eng. "other", drugi) da pomaknete kursor u
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
924 donji prozor.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
925 >> U donjem se prozoru pomičite s C-v i M-v.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
926 Nastavite čitati ove upute u gornjem prozoru.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
927
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
928 >> Opet stisnite C-x o da pomaknete kursor natrag u gornji prozor.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
929 Kursor u gornjem prozoru je upravo gdje je prije bio.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
930
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
931 Možete stalno koristiti C-x o za pomicanje među prozorima. Svaki
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
932 prozor ima vlastiti položaj kursora, ali samo jedan prozor zapravo
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
933 prikazuje kursor. Sve uobičajene naredbe za editiranja djeluju na
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
934 prozoru u kojem je kursor. Taj prozor nazivamo "izabrani prozor"
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
935 (eng. selected window).
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
936
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
937 Naredba C-M-v korisna je kad editirate tekst u jednom prozoru, a drugi
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
938 koristite za referencu. Tada možete držati kursor uvijek u prozoru
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
939 gdje editirate, a napredovati kroz onaj drugi s C-M-v.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
940
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
941 C-M-v je primjer CONTROL-META znaka. Ako imate pravu tipku META,
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
942 možete dobiti C-M-v držeći zajedno i CTRL i META, dok tipkate v. Nema
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
943 veze da li je CTRL ili META "prvi", jer obje ove tipke rade
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
944 mijenjajući znakove koji pišete.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
945
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
946 Ako nemate pravu META tipku, a umjesto nje koristite ESC, tad je
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
947 poredak važan: morate stisnuti ESC praćen s CTRL-v; CTRL-ESC v neće
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
948 raditi. Razlog za ovo je što je ESC tipka za sebe, a ne modifikator.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
949
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
950 >> Pritisnite C-x 1 (u gornjem prozoru) da se riješite donjeg
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
951 prozora.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
952
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
953 (Da ste stisnuli C-x 1 u donjem prozoru, riješili biste se gornjeg.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
954 Ovu naredbu možete shvatiti kao "Ostavi samo jedan prozor -- onaj u
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
955 kojem već jesam.")
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
956
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
957 Ne morate prikazivati isti spremnik u oba prozora. Ako pritisnete C-x
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
958 C-f da nađete datoteku u jednom prozoru, drugi se prozor ne mijenja.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
959 Možete naći datoteku u svakom prozoru neovisno o drugima.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
960
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
961 Evo još jednog načina da upotrijebite dva prozora za prikaz dvije
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
962 različite stvari:
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
963
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
964 >> Utipkajte C-x 4 C-f, a zatim ime neke od vaših datoteka.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
965 Završite s <Return>. Uočite da se navedena datoteka pojavila u
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
966 donjem prozoru, a također i kursor.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
967
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
968 >> Pritisnite C-x o za povrat u gornji prozor, i C-x 1 da uklonite
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
969 donji.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
970
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
971
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
972 * REKURZIVNE RAZINE EDITIRANJA
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
973 ------------------------------
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
974
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
975 Ponekad ćete poželjeti ući u ono što se zove "rekurzivna razina
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
976 editiranja" (eng. recursive editing level). Ovo je naznačeno uglatim
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
977 zagradama u statusnom redu, koje okružuju okrugle zagrade oko naziva
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
978 moda. Na primjer, vidjeli biste [(Fundamental)] umjesto
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
979 (Fundamental).
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
980
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
981 Za izlazak iz rekurzivnog editiranja, pritisnite ESC ESC ESC. To je
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
982 višenamjenska naredba za "izlazak". Možete je koristiti i za
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
983 uklanjanje dodatnih prozora, kao i za izlazak iz minispremnika.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
984
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
985 >> Stisnite M-x za ulazak u minispremnik; potom utipkajte ESC ESC ESC
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
986 za izlaz.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
987
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
988 Iz rekurzivne razine editiranja ne možete izaći s C-g. To je zato što
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
989 se C-g koristi za otkazivanje naredbi i argumenata UNUTAR te razine
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
990 editiranja.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
991
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
992
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
993 * DODATNA POMOĆ
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
994 ---------------
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
995
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
996 U ovim smo uputama pokušali dati upravo toliko informacija da možete
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
997 početi koristiti Emacs. Toliko je toga prisutno u Emacsu da bi bilo
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
998 nemoguće sve to ovdje objasniti. Međutim, možda poželite naučiti više
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
999 o Emacsu, jer on ima još puno korisnih prednosti. Emacs ima naredbe
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1000 za čitanje dokumentacije o Emacsovim naredbama. Ove naredbe "pomoći"
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1001 sve počinju sa znakom Control-h, koji se zove "znak za pomoć"
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1002 (eng. the Help character).
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1003
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1004 Za korištenje naredbi pomoći, stisnite znak C-h, praćen znakom koji
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1005 kaže koju vrstu pomoći želite. Ako ste ZAISTA izgubljeni, stisnite
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1006 C-h ? i Emacs će vam reći koje vrste pomoći može dati. Ako stisnete
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1007 C-h, ali se predomislite, samo pritisnite C-g za otkaz pomoći.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1008
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1009 (Na nekim je sistemima promijenjeno značenje C-h. Ovo se zaista ne bi
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1010 smjelo raditi, pa se požalite sistemskom administratoru. U međuvremenu,
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1011 ako C-h ne prikazuje poruku o pomoći na dnu ekrana, pokušajte upisati
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1012 M-x help RET umjesto toga.)
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1013
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1014 Osnovna naredba pomoći je C-h c. Napišite C-h, potom c, i znak ili
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1015 niz znakova, i Emacs će pokazati vrlo kratak opis naredbe.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1016
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1017 >> Stisnite C-h c Control-p.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1018 Poruka bi trebala biti poput:
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1019
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1020 C-p runs the command previous-line
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1021
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1022 (C-p pokreće naredbu previous-line)
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1023
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1024 Ovo vam kaže "ime funkcije". Imena funkcija se koriste uglavnom za
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1025 mijenjanje i proširivanje Emacsa. Ali budući da se imena funkcija
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1026 biraju tako da pokazuju što naredba radi, ona mogu poslužiti i kao
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1027 vrlo kratka dokumentacija -- dovoljna da vas podsjeti na naredbu koju
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1028 već znate.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1029
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1030 Više-znakovne naredbe kao što su C-x C-s i (ako nemate tipku META,
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1031 EDIT ili ALT) <ESC>v su također dozvoljene nakon C-h c.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1032
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1033 Za više podataka o naredbi, pritisnite C-h k umjesto C-h c.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1034
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1035 >> Stisnite C-h k Control-p.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1036
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1037 Osim imena, sad vidite i dokumentaciju funkcije u Emacsovom prozoru.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1038 Kad završite s čitanjem ispisa, stisnite q da se riješite teksta.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1039
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1040 Evo nekoliko korisnih mogućnosti C-h:
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1041
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1042 C-h f Opiši funkciju. Upišete ime funkcije.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1043
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1044 >> Pokušajte stisnuti C-h f previous-line<Return>.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1045 Ovo će ispisati sve što Emacs zna o funkciji koja implementira
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1046 naredbu C-p.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1047
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1048 C-h a Hiper Apropos. Upišite riječ, i Emacs će popisati sve
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1049 funkcije i varijable čija imena sadrže riječ. Naredbe
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1050 koje se mogu izvršiti s Meta-x bit će označene
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1051 zvjezdicom slijeva.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1052
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1053 >> Utipkajte C-h a newline<Return>.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1054
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1055 Ovo prikazuje hipertekstualni spisak svih funkcija i varijabli s
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1056 "newline" u imenima. Stisnite <Return>, ili pritisnite srednju tipku
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1057 miša da saznate više o funkciji ili varijabli. Stisnite `q' za izlaz
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1058 iz hiper-aproposa.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1059
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1060
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1061 * ZAKLJUČAK
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1062 -----------
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1063
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1064 Upamtite, za trajan izlaz iz Emacsa stisnite C-x C-c. Za privremeni
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1065 izlaz u ljusku upotrijebite C-z. (pod X-ima, ovo ikonizira trenutni
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1066 Emacsov okvir.)
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1067
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1068 Ove upute su predviđene da budu razumljive svim novim korisnicima, pa
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1069 ako vam je nešto ovdje nejasno, nemojte sjediti i kriviti sebe -
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1070 žalite se!
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1071
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1072
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1073 KOPIRANJE
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1074 ---------
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1075
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1076 Ove upute potječu iz duge loze Emacsovih uputa, počevši od onih koje
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1077 je napisao Stuart Cracraft za izvorni Emacs. Ben Wing je dopisao
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1078 poglavlje o X Windowsima. Martin Buchholz i Hrvoje Nikšić su dodali
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1079 još ispravki vezanih uz XEmacs.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1080
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1081 Na Hrvatski preveo Hrvoje Nikšić, uz dodatnu lekturu Denisa Pleića.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1082
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1083 Ova verzija uputa je, kao i GNU Emacs, pod autorskim pravima, i dolazi
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1084 s dozvolom redistribuiranja uz sljedeće uvjete:
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1085
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1086 (c) 1985, 1996 Free Software Foundation, sva prava zadržana.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1087
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1088 Svakome je dozvoljeno praviti ili distribuirati nepromijenjene
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1089 kopije ovog dokumenta, na bilo kojem mediju, uz uvjet da su
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1090 sačuvane poruka o autorskim pravima i dozvolama, i da distributer
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1091 daje drugima prava za daljnju redistribuciju, kako ovdje piše.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1092
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1093 Dozvoljena je distribucija izmijenjenih verzija ovog dokumenta ili
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1094 njegovih djelova, pod gore navedenim uvjetima, uz dodatni uvjet da
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1095 sadrži obavijest o zadnjoj promjeni.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1096
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1097 Uvjeti kopiranja samog Emacsa su složeniji, ali u istom duhu. Molimo
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1098 vas da pročitate datoteku COPYING, i da podijelite kopije GNU Emacsa
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1099 svojim prijateljima. Pomozite nam zgaziti opstrukcionizam
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1100 ("vlasništvo") nad softverom koristeći, pišući i dijeleći slobodan
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1101 softver!
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1102
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1103
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1104 This tutorial descends from a long line of Emacs tutorials
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1105 starting with the one written by Stuart Cracraft for the original Emacs.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1106 Ben Wing updated the tutorial for X Windows. Martin Buchholz and
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1107 Hrvoje Niksic added more corrections for XEmacs.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1108
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1109 This version of the tutorial, like GNU Emacs, is copyrighted, and
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1110 comes with permission to distribute copies on certain conditions:
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1111
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1112 Copyright (c) 1985, 1996 Free Software Foundation
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1113
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1114 Permission is granted to anyone to make or distribute verbatim copies
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1115 of this document as received, in any medium, provided that the
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1116 copyright notice and permission notice are preserved,
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1117 and that the distributor grants the recipient permission
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1118 for further redistribution as permitted by this notice.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1119
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1120 Permission is granted to distribute modified versions
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1121 of this document, or of portions of it,
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1122 under the above conditions, provided also that they
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1123 carry prominent notices stating who last altered them.
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1124
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1125 The conditions for copying Emacs itself are more complex, but in the
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1126 same spirit. Please read the file COPYING and then do give copies of
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1127 GNU Emacs to your friends. Help stamp out software obstructionism
3ecd8885ac67 Import from CVS: tag r21-2-22
cvs
parents:
diff changeset
1128 ("ownership") by using, writing, and sharing free software!