From 3aa17f2430c422f59bd50f742ee49d1d86fbcef9 Mon Sep 17 00:00:00 2001 From: Bartosz Leper Date: Wed, 24 Jun 2015 01:03:12 +0200 Subject: Initial commit for the LaTeX version of the manual --- help/manual/.gitignore | 5 + help/manual/move-10-steps.png | Bin 0 -> 2595 bytes help/manual/snap-manual.tex | 182 +++++++++++++++++++++++++++++++++++ help/manual/snapping-blocks.png | Bin 0 -> 12054 bytes help/manual/typical-script-inner.png | Bin 0 -> 4610 bytes help/manual/typical-script.png | Bin 0 -> 11063 bytes help/manual/window-regions.png | Bin 0 -> 142052 bytes 7 files changed, 187 insertions(+) create mode 100644 help/manual/.gitignore create mode 100644 help/manual/move-10-steps.png create mode 100644 help/manual/snap-manual.tex create mode 100644 help/manual/snapping-blocks.png create mode 100644 help/manual/typical-script-inner.png create mode 100644 help/manual/typical-script.png create mode 100644 help/manual/window-regions.png diff --git a/help/manual/.gitignore b/help/manual/.gitignore new file mode 100644 index 0000000..4c0ef4d --- /dev/null +++ b/help/manual/.gitignore @@ -0,0 +1,5 @@ +*.aux +*.log +*.out +*.toc +*.pdf diff --git a/help/manual/move-10-steps.png b/help/manual/move-10-steps.png new file mode 100644 index 0000000..3d276da Binary files /dev/null and b/help/manual/move-10-steps.png differ diff --git a/help/manual/snap-manual.tex b/help/manual/snap-manual.tex new file mode 100644 index 0000000..6ca387c --- /dev/null +++ b/help/manual/snap-manual.tex @@ -0,0 +1,182 @@ +\documentclass{report} + +\usepackage{baskervald} % Default font +\usepackage{cabin} % Sans serif font +\usepackage[T1]{fontenc} +\usepackage{setspace} \onehalfspacing +\usepackage{graphicx} +\usepackage{textcomp} +\usepackage{hyperref} + +\newcommand{\Snap}{{\sf Snap{\it !}}} +\newcommand{\code}[1]{\textsf{#1}} +\newcommand{\defaultGraphicsScale}{0.6} + +\newcommand{\inlinepic}[1]{% + \raisebox{-4pt}{% + \includegraphics[scale=\defaultGraphicsScale]{#1}% + }% +} + +\newcommand{\bigpic}[1]{ + \begin{center} + \includegraphics[scale=\defaultGraphicsScale]{#1} + \end{center} +} + + +\renewcommand{\thechapter}{\Roman{chapter}} +\renewcommand{\thesection}{\Alph{section}} +\renewcommand{\thesubsection}{} + +\begin{document} + +\title{\Snap{} Reference Manual} +\author{Brian Harvey \and Jens M\"{o}nig} +\date{} + +\maketitle + +\tableofcontents + +\chapter*{} +\section*{Acknowledgements} + +We have been extremely lucky in our mentors. Jens cut his teeth in the company of the Smalltalk pioneers: Alan Kay, Dan Ingalls, and the rest of the gang who invented personal computing and object oriented programming in the great days of Xerox PARC. He worked with John Maloney, of the MIT Scratch Team, who developed the Morphic graphics framework that's still at the heart of \Snap{}. The brilliant design of Scratch, from the Lifelong Kindergarten Group at the MIT Media Lab, is crucial to \Snap{}. + +{\bf\em Our earlier version, BYOB, was a direct modification of the Scratch source code. \Snap{} is a complete rewrite, but its code structure and its user interface remain deeply indebted to Scratch. And the Scratch Team, who could have seen us as rivals, have been entirely supportive and welcoming to us.} + +Brian grew up at the MIT and Stanford Artificial Intelligence Labs, learning from Lisp inventor John McCarthy, Scheme inventors Gerald J. Sussman and Guy Steele, and the authors of the world's best computer science book, \emph{Structure and Interpretation of Computer Programs}, Hal Abelson and Gerald J. Sussman with Julie Sussman, among many other heroes of computer science. + +{\bf\em In the glory days of the MIT Logo Lab, we used to say, ``Logo is Lisp disguised as BASIC.'' Now, with its first class procedures, lexical scope, and first class continuations, \Snap{} is Scheme disguised as Scratch.} + +We have been fortunate to get to know an amazing group of brilliant middle school(!) and high school students through the Scratch Advanced Topics forum, several of whom have contributed code to \Snap{}: Kartik Chandra, Nathan Dinsmore, Connor Hudson, and Ian Reynolds. Many more have contributed ideas and alpha-testing bug reports. UC Berkeley students who've contributed code include Michael Ball, Achal Dave. Kyle Hotchkiss, Ivan Motyashov, and Yuan Yuan. Contributors of translations are too numerous to list here, but they're in the ``About...'' box in \Snap{} itself. This work was supported in part by the National Science Foundation grant 1143566, and in part by MioSoft. + +\begin{titlepage} + +\begin{center} +\bf \Huge \Snap{} Reference Manual \\ \huge Version 4.0 \vspace{40pt} +\end{center} + +\Snap{} (formerly BYOB) is an extended reimplementation of Scratch (\url{http://scratch.mit.edu}) that allows you to Build Your Own Blocks. It also features first class lists, first class procedures, and continuations. These added capabilities make it suitable for a serious introduction to computer science for high school or college students. To run \Snap{}, open a browser window and connect to either \url{http://snap.berkeley.edu/run} to start with a minimal set of blocks or \url{http://snap.berkeley.edu/init} to load a small set of additional blocks (a little slower startup, but recommended for convenience and assumed in this manual). + +\end{titlepage} + +\chapter{Blocks, Scripts, and Sprites} + +This chapter describes the \Snap{} features inherited from Scratch; experienced Scratch users can skip to section B. + +\Snap{} is a programming language---a notation in which you can tell a computer what you want it to do. Unlike most programming languages, though, \Snap{} is a visual language; instead of writing a program using the keyboard, the \Snap{} programmer uses the same drag-and-drop interface familiar to computer users. + +Start \Snap{}. You should see the following arrangement of regions in the window: + +\begin{center} +\includegraphics[width=\textwidth]{window-regions} +\end{center} + +(The proportions of these areas may be different, depending on the size and shape of your browser window.) + +A \Snap{} program consists of one or more \emph{scripts}, each of which is made of \emph{blocks}. Here's a typical script: + +\bigpic{typical-script} + +The five blocks that make up this script have three different colors, corresponding to three of the eight \emph{palettes} in which blocks can be found. The palette area at the left edge of the window shows one palette at a time, chosen with the eight buttons just above the palette area. In this script, the gold blocks are from the Control palette; the green block is from the Pen palette; and the blue blocks are from the Motion palette. A script is assembled by dragging blocks from a palette into the \emph{scripting area} in the middle part of the window. Blocks snap together (hence the name \Snap{} for the language) when you drag a block so that its indentation is near the tab of the one above it: + +\bigpic{snapping-blocks} + +The white horizontal line is a signal that if you let go of the green block it will snap into the tab of the gold one. + +\subsection{Hat Blocks and Command Blocks} + +At the top of the script is a \emph{hat} block, which indicates when the script should be carried out. Hat block names typically start with the word ``\code{when}''; in this example, the script should be run when the green flag near the right end of the \Snap{} tool bar is clicked. (The \Snap{} tool bar is part of the \Snap{} window, not the same as the browser's or operating system's menu bar.) A script isn't required to have a hat block, but if not, then the script will be run only if the user clicks on the script itself. A script can't have more than one hat block, and the hat block can be used only at the top of the script; its distinctive shape is meant to remind you of that. + +The other blocks in this script are \emph{command} blocks. Each command block corresponds to an action that \Snap{} already knows how to carry out. For example, the block \inlinepic{move-10-steps} tells the sprite (the arrowhead shape on the \emph{stage} at the right end of the window) to move ten steps (a step is a very small unit of distance) in the direction in which the arrowhead is pointing. We'll see shortly that there can be more than one sprite, and that each sprite has its own scripts. Also, a sprite doesn't have to look like an arrowhead, but can have any picture as a costume. The shape of the \code{move} block is meant to remind you of a Lego\texttrademark{} brick; a script is a stack of blocks. (The word ``block'' denotes both the graphical shape on the screen and the procedure, the action, that the block carries out.) + +The number 10 in the \code{move} block above is called an \emph{input} to the block. By clicking on the white oval, you can type any number in place of the 10. The sample script on the previous page uses 100 as the input value. We'll see later that inputs can have non-oval shapes that accept values other than numbers. We'll also see that you can compute input values, instead of typing a particular value into the oval. A block can have more than one input slot. For example, the \code{glide} block located about halfway down the Motion palette has three inputs. + +Most command blocks have that brick shape, but some, like the \code{repeat} block in the sample script, are \emph{C-shaped}. Most C-shaped blocks are found in the Control palette. The slot inside the C shape is a special kind of input slot that accepts a \emph{script} as the input. In the sample script, the \code{repeat} block has two inputs: the number 4 and the script + +\bigpic{typical-script-inner} + + + +\section{Sprites and Parallelism} +\subsection{Costumes and Sounds} +\subsection{Inter-Sprite Communication with Broadcast} +\section{Nesting Sprites: Anchors and Parts} +\section{Reporter Blocks and Expressions} +\section{Predicates and Conditional Evaluation} +\section{Variables} +\subsection{Global Variables} +\subsection{Script Variables} +\section{Etcetera} +\chapter{Saving and Loading Projects and Media} +\section{Local Storage} +\subsection{Localstore} +\subsection{XML Export} +\section{Cloud Storage} +\section{Loading Saved Projects} +\chapter{Building a Block} +\section{Simple Blocks} +\subsection{Custom Blocks with Inputs} +\section{Recursion} +\section{Block Libraries} +\chapter{First Class Lists} +\section{The list Block} +\section{Lists of Lists} +\section{Functional and Imperative List Programming} +\section{Higher Order List Operations and Rings} +\chapter{Typed Inputs} +\section{Scratch's Type Notation} +\section{The \Snap{} Input Type Dialog} +\subsection{Procedure Types} +\subsection{Pulldown inputs} +\subsection{Input variants} +\subsection{Prototype Hints} +\subsection{Title Text and Symbols} +\chapter{Procedures as Data} +\section{Call and Run} +\subsection{Call/Run with inputs} +\subsection{Variables in Ring Slots} +\section{Writing Higher Order Procedures} +\subsection{Recursive Calls to Multiple-Input Blocks} +\section{Formal Parameters} +\section{Procedures as Data} +\section{Special Forms} +\subsection{Special Forms in Scratch} +\chapter{Object Oriented Programming} +\section{Local State with Script Variables} +\section{Messages and Dispatch Procedures} +\section{Inheritance via Delegation} +\section{An Implementation of Prototyping OOP} +\chapter{The Outside World} +\section{The World Wide Web} +\section{Hardware Devices} +\section{Date and Time} +\chapter{Continuations} +\section{Continuation Passing Style} +\section{Call/Run w/Continuation} +\subsection{Nonlocal exit} +\chapter{User Interface Elements} +\section{Tool Bar Features} +\subsection{The \Snap{} Logo Menu} +\subsection{The File Menu} +\subsection{The Cloud Menu} +\subsection{The Settings Menu} +\subsection{Stage Resizing Buttons} +\subsection{Project Control Buttons} +\section{The Palette Area} +\subsection{Context Menus for Palette Blocks} +\subsection{Context Menu for the Palette Background} +\section{The Scripting Area} +\subsection{Sprite Appearance and Behavior Controls} +\subsection{Scripting Area Tabs} +\subsection{Scripts and Blocks Within Scripts} +\subsection{Scripting Area Background Context Menu} +\subsection{Controls in the Costumes Tab} +\subsection{The Paint Editor} +\subsection{Controls in the Sounds Tab} +\section{Controls on the Stage} +\section{The Sprite Corral and Sprite Creation Buttons} + +\end{document} diff --git a/help/manual/snapping-blocks.png b/help/manual/snapping-blocks.png new file mode 100644 index 0000000..0dc5922 Binary files /dev/null and b/help/manual/snapping-blocks.png differ diff --git a/help/manual/typical-script-inner.png b/help/manual/typical-script-inner.png new file mode 100644 index 0000000..b5503f7 Binary files /dev/null and b/help/manual/typical-script-inner.png differ diff --git a/help/manual/typical-script.png b/help/manual/typical-script.png new file mode 100644 index 0000000..6763aad Binary files /dev/null and b/help/manual/typical-script.png differ diff --git a/help/manual/window-regions.png b/help/manual/window-regions.png new file mode 100644 index 0000000..7fe4e98 Binary files /dev/null and b/help/manual/window-regions.png differ -- cgit v1.3.1 From 5944c36d5598db663df1af74e212662843eb0dc1 Mon Sep 17 00:00:00 2001 From: Bartosz Leper Date: Wed, 24 Jun 2015 01:14:59 +0200 Subject: Update .gitignore --- help/manual/.gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/help/manual/.gitignore b/help/manual/.gitignore index 4c0ef4d..a0bdfac 100644 --- a/help/manual/.gitignore +++ b/help/manual/.gitignore @@ -3,3 +3,4 @@ *.out *.toc *.pdf +*.synctex.gz -- cgit v1.3.1 From b08f7bad1b00e26df910d0fbbfdfe86aded8abec Mon Sep 17 00:00:00 2001 From: Bartosz Leper Date: Wed, 24 Jun 2015 01:17:46 +0200 Subject: Move the manual to English subdirectory --- help/manual/en/move-10-steps.png | Bin 0 -> 2595 bytes help/manual/en/snap-manual.tex | 182 ++++++++++++++++++++++++++++++++ help/manual/en/snapping-blocks.png | Bin 0 -> 12054 bytes help/manual/en/typical-script-inner.png | Bin 0 -> 4610 bytes help/manual/en/typical-script.png | Bin 0 -> 11063 bytes help/manual/en/window-regions.png | Bin 0 -> 142052 bytes help/manual/move-10-steps.png | Bin 2595 -> 0 bytes help/manual/snap-manual.tex | 182 -------------------------------- help/manual/snapping-blocks.png | Bin 12054 -> 0 bytes help/manual/typical-script-inner.png | Bin 4610 -> 0 bytes help/manual/typical-script.png | Bin 11063 -> 0 bytes help/manual/window-regions.png | Bin 142052 -> 0 bytes 12 files changed, 182 insertions(+), 182 deletions(-) create mode 100644 help/manual/en/move-10-steps.png create mode 100644 help/manual/en/snap-manual.tex create mode 100644 help/manual/en/snapping-blocks.png create mode 100644 help/manual/en/typical-script-inner.png create mode 100644 help/manual/en/typical-script.png create mode 100644 help/manual/en/window-regions.png delete mode 100644 help/manual/move-10-steps.png delete mode 100644 help/manual/snap-manual.tex delete mode 100644 help/manual/snapping-blocks.png delete mode 100644 help/manual/typical-script-inner.png delete mode 100644 help/manual/typical-script.png delete mode 100644 help/manual/window-regions.png diff --git a/help/manual/en/move-10-steps.png b/help/manual/en/move-10-steps.png new file mode 100644 index 0000000..3d276da Binary files /dev/null and b/help/manual/en/move-10-steps.png differ diff --git a/help/manual/en/snap-manual.tex b/help/manual/en/snap-manual.tex new file mode 100644 index 0000000..6ca387c --- /dev/null +++ b/help/manual/en/snap-manual.tex @@ -0,0 +1,182 @@ +\documentclass{report} + +\usepackage{baskervald} % Default font +\usepackage{cabin} % Sans serif font +\usepackage[T1]{fontenc} +\usepackage{setspace} \onehalfspacing +\usepackage{graphicx} +\usepackage{textcomp} +\usepackage{hyperref} + +\newcommand{\Snap}{{\sf Snap{\it !}}} +\newcommand{\code}[1]{\textsf{#1}} +\newcommand{\defaultGraphicsScale}{0.6} + +\newcommand{\inlinepic}[1]{% + \raisebox{-4pt}{% + \includegraphics[scale=\defaultGraphicsScale]{#1}% + }% +} + +\newcommand{\bigpic}[1]{ + \begin{center} + \includegraphics[scale=\defaultGraphicsScale]{#1} + \end{center} +} + + +\renewcommand{\thechapter}{\Roman{chapter}} +\renewcommand{\thesection}{\Alph{section}} +\renewcommand{\thesubsection}{} + +\begin{document} + +\title{\Snap{} Reference Manual} +\author{Brian Harvey \and Jens M\"{o}nig} +\date{} + +\maketitle + +\tableofcontents + +\chapter*{} +\section*{Acknowledgements} + +We have been extremely lucky in our mentors. Jens cut his teeth in the company of the Smalltalk pioneers: Alan Kay, Dan Ingalls, and the rest of the gang who invented personal computing and object oriented programming in the great days of Xerox PARC. He worked with John Maloney, of the MIT Scratch Team, who developed the Morphic graphics framework that's still at the heart of \Snap{}. The brilliant design of Scratch, from the Lifelong Kindergarten Group at the MIT Media Lab, is crucial to \Snap{}. + +{\bf\em Our earlier version, BYOB, was a direct modification of the Scratch source code. \Snap{} is a complete rewrite, but its code structure and its user interface remain deeply indebted to Scratch. And the Scratch Team, who could have seen us as rivals, have been entirely supportive and welcoming to us.} + +Brian grew up at the MIT and Stanford Artificial Intelligence Labs, learning from Lisp inventor John McCarthy, Scheme inventors Gerald J. Sussman and Guy Steele, and the authors of the world's best computer science book, \emph{Structure and Interpretation of Computer Programs}, Hal Abelson and Gerald J. Sussman with Julie Sussman, among many other heroes of computer science. + +{\bf\em In the glory days of the MIT Logo Lab, we used to say, ``Logo is Lisp disguised as BASIC.'' Now, with its first class procedures, lexical scope, and first class continuations, \Snap{} is Scheme disguised as Scratch.} + +We have been fortunate to get to know an amazing group of brilliant middle school(!) and high school students through the Scratch Advanced Topics forum, several of whom have contributed code to \Snap{}: Kartik Chandra, Nathan Dinsmore, Connor Hudson, and Ian Reynolds. Many more have contributed ideas and alpha-testing bug reports. UC Berkeley students who've contributed code include Michael Ball, Achal Dave. Kyle Hotchkiss, Ivan Motyashov, and Yuan Yuan. Contributors of translations are too numerous to list here, but they're in the ``About...'' box in \Snap{} itself. This work was supported in part by the National Science Foundation grant 1143566, and in part by MioSoft. + +\begin{titlepage} + +\begin{center} +\bf \Huge \Snap{} Reference Manual \\ \huge Version 4.0 \vspace{40pt} +\end{center} + +\Snap{} (formerly BYOB) is an extended reimplementation of Scratch (\url{http://scratch.mit.edu}) that allows you to Build Your Own Blocks. It also features first class lists, first class procedures, and continuations. These added capabilities make it suitable for a serious introduction to computer science for high school or college students. To run \Snap{}, open a browser window and connect to either \url{http://snap.berkeley.edu/run} to start with a minimal set of blocks or \url{http://snap.berkeley.edu/init} to load a small set of additional blocks (a little slower startup, but recommended for convenience and assumed in this manual). + +\end{titlepage} + +\chapter{Blocks, Scripts, and Sprites} + +This chapter describes the \Snap{} features inherited from Scratch; experienced Scratch users can skip to section B. + +\Snap{} is a programming language---a notation in which you can tell a computer what you want it to do. Unlike most programming languages, though, \Snap{} is a visual language; instead of writing a program using the keyboard, the \Snap{} programmer uses the same drag-and-drop interface familiar to computer users. + +Start \Snap{}. You should see the following arrangement of regions in the window: + +\begin{center} +\includegraphics[width=\textwidth]{window-regions} +\end{center} + +(The proportions of these areas may be different, depending on the size and shape of your browser window.) + +A \Snap{} program consists of one or more \emph{scripts}, each of which is made of \emph{blocks}. Here's a typical script: + +\bigpic{typical-script} + +The five blocks that make up this script have three different colors, corresponding to three of the eight \emph{palettes} in which blocks can be found. The palette area at the left edge of the window shows one palette at a time, chosen with the eight buttons just above the palette area. In this script, the gold blocks are from the Control palette; the green block is from the Pen palette; and the blue blocks are from the Motion palette. A script is assembled by dragging blocks from a palette into the \emph{scripting area} in the middle part of the window. Blocks snap together (hence the name \Snap{} for the language) when you drag a block so that its indentation is near the tab of the one above it: + +\bigpic{snapping-blocks} + +The white horizontal line is a signal that if you let go of the green block it will snap into the tab of the gold one. + +\subsection{Hat Blocks and Command Blocks} + +At the top of the script is a \emph{hat} block, which indicates when the script should be carried out. Hat block names typically start with the word ``\code{when}''; in this example, the script should be run when the green flag near the right end of the \Snap{} tool bar is clicked. (The \Snap{} tool bar is part of the \Snap{} window, not the same as the browser's or operating system's menu bar.) A script isn't required to have a hat block, but if not, then the script will be run only if the user clicks on the script itself. A script can't have more than one hat block, and the hat block can be used only at the top of the script; its distinctive shape is meant to remind you of that. + +The other blocks in this script are \emph{command} blocks. Each command block corresponds to an action that \Snap{} already knows how to carry out. For example, the block \inlinepic{move-10-steps} tells the sprite (the arrowhead shape on the \emph{stage} at the right end of the window) to move ten steps (a step is a very small unit of distance) in the direction in which the arrowhead is pointing. We'll see shortly that there can be more than one sprite, and that each sprite has its own scripts. Also, a sprite doesn't have to look like an arrowhead, but can have any picture as a costume. The shape of the \code{move} block is meant to remind you of a Lego\texttrademark{} brick; a script is a stack of blocks. (The word ``block'' denotes both the graphical shape on the screen and the procedure, the action, that the block carries out.) + +The number 10 in the \code{move} block above is called an \emph{input} to the block. By clicking on the white oval, you can type any number in place of the 10. The sample script on the previous page uses 100 as the input value. We'll see later that inputs can have non-oval shapes that accept values other than numbers. We'll also see that you can compute input values, instead of typing a particular value into the oval. A block can have more than one input slot. For example, the \code{glide} block located about halfway down the Motion palette has three inputs. + +Most command blocks have that brick shape, but some, like the \code{repeat} block in the sample script, are \emph{C-shaped}. Most C-shaped blocks are found in the Control palette. The slot inside the C shape is a special kind of input slot that accepts a \emph{script} as the input. In the sample script, the \code{repeat} block has two inputs: the number 4 and the script + +\bigpic{typical-script-inner} + + + +\section{Sprites and Parallelism} +\subsection{Costumes and Sounds} +\subsection{Inter-Sprite Communication with Broadcast} +\section{Nesting Sprites: Anchors and Parts} +\section{Reporter Blocks and Expressions} +\section{Predicates and Conditional Evaluation} +\section{Variables} +\subsection{Global Variables} +\subsection{Script Variables} +\section{Etcetera} +\chapter{Saving and Loading Projects and Media} +\section{Local Storage} +\subsection{Localstore} +\subsection{XML Export} +\section{Cloud Storage} +\section{Loading Saved Projects} +\chapter{Building a Block} +\section{Simple Blocks} +\subsection{Custom Blocks with Inputs} +\section{Recursion} +\section{Block Libraries} +\chapter{First Class Lists} +\section{The list Block} +\section{Lists of Lists} +\section{Functional and Imperative List Programming} +\section{Higher Order List Operations and Rings} +\chapter{Typed Inputs} +\section{Scratch's Type Notation} +\section{The \Snap{} Input Type Dialog} +\subsection{Procedure Types} +\subsection{Pulldown inputs} +\subsection{Input variants} +\subsection{Prototype Hints} +\subsection{Title Text and Symbols} +\chapter{Procedures as Data} +\section{Call and Run} +\subsection{Call/Run with inputs} +\subsection{Variables in Ring Slots} +\section{Writing Higher Order Procedures} +\subsection{Recursive Calls to Multiple-Input Blocks} +\section{Formal Parameters} +\section{Procedures as Data} +\section{Special Forms} +\subsection{Special Forms in Scratch} +\chapter{Object Oriented Programming} +\section{Local State with Script Variables} +\section{Messages and Dispatch Procedures} +\section{Inheritance via Delegation} +\section{An Implementation of Prototyping OOP} +\chapter{The Outside World} +\section{The World Wide Web} +\section{Hardware Devices} +\section{Date and Time} +\chapter{Continuations} +\section{Continuation Passing Style} +\section{Call/Run w/Continuation} +\subsection{Nonlocal exit} +\chapter{User Interface Elements} +\section{Tool Bar Features} +\subsection{The \Snap{} Logo Menu} +\subsection{The File Menu} +\subsection{The Cloud Menu} +\subsection{The Settings Menu} +\subsection{Stage Resizing Buttons} +\subsection{Project Control Buttons} +\section{The Palette Area} +\subsection{Context Menus for Palette Blocks} +\subsection{Context Menu for the Palette Background} +\section{The Scripting Area} +\subsection{Sprite Appearance and Behavior Controls} +\subsection{Scripting Area Tabs} +\subsection{Scripts and Blocks Within Scripts} +\subsection{Scripting Area Background Context Menu} +\subsection{Controls in the Costumes Tab} +\subsection{The Paint Editor} +\subsection{Controls in the Sounds Tab} +\section{Controls on the Stage} +\section{The Sprite Corral and Sprite Creation Buttons} + +\end{document} diff --git a/help/manual/en/snapping-blocks.png b/help/manual/en/snapping-blocks.png new file mode 100644 index 0000000..0dc5922 Binary files /dev/null and b/help/manual/en/snapping-blocks.png differ diff --git a/help/manual/en/typical-script-inner.png b/help/manual/en/typical-script-inner.png new file mode 100644 index 0000000..b5503f7 Binary files /dev/null and b/help/manual/en/typical-script-inner.png differ diff --git a/help/manual/en/typical-script.png b/help/manual/en/typical-script.png new file mode 100644 index 0000000..6763aad Binary files /dev/null and b/help/manual/en/typical-script.png differ diff --git a/help/manual/en/window-regions.png b/help/manual/en/window-regions.png new file mode 100644 index 0000000..7fe4e98 Binary files /dev/null and b/help/manual/en/window-regions.png differ diff --git a/help/manual/move-10-steps.png b/help/manual/move-10-steps.png deleted file mode 100644 index 3d276da..0000000 Binary files a/help/manual/move-10-steps.png and /dev/null differ diff --git a/help/manual/snap-manual.tex b/help/manual/snap-manual.tex deleted file mode 100644 index 6ca387c..0000000 --- a/help/manual/snap-manual.tex +++ /dev/null @@ -1,182 +0,0 @@ -\documentclass{report} - -\usepackage{baskervald} % Default font -\usepackage{cabin} % Sans serif font -\usepackage[T1]{fontenc} -\usepackage{setspace} \onehalfspacing -\usepackage{graphicx} -\usepackage{textcomp} -\usepackage{hyperref} - -\newcommand{\Snap}{{\sf Snap{\it !}}} -\newcommand{\code}[1]{\textsf{#1}} -\newcommand{\defaultGraphicsScale}{0.6} - -\newcommand{\inlinepic}[1]{% - \raisebox{-4pt}{% - \includegraphics[scale=\defaultGraphicsScale]{#1}% - }% -} - -\newcommand{\bigpic}[1]{ - \begin{center} - \includegraphics[scale=\defaultGraphicsScale]{#1} - \end{center} -} - - -\renewcommand{\thechapter}{\Roman{chapter}} -\renewcommand{\thesection}{\Alph{section}} -\renewcommand{\thesubsection}{} - -\begin{document} - -\title{\Snap{} Reference Manual} -\author{Brian Harvey \and Jens M\"{o}nig} -\date{} - -\maketitle - -\tableofcontents - -\chapter*{} -\section*{Acknowledgements} - -We have been extremely lucky in our mentors. Jens cut his teeth in the company of the Smalltalk pioneers: Alan Kay, Dan Ingalls, and the rest of the gang who invented personal computing and object oriented programming in the great days of Xerox PARC. He worked with John Maloney, of the MIT Scratch Team, who developed the Morphic graphics framework that's still at the heart of \Snap{}. The brilliant design of Scratch, from the Lifelong Kindergarten Group at the MIT Media Lab, is crucial to \Snap{}. - -{\bf\em Our earlier version, BYOB, was a direct modification of the Scratch source code. \Snap{} is a complete rewrite, but its code structure and its user interface remain deeply indebted to Scratch. And the Scratch Team, who could have seen us as rivals, have been entirely supportive and welcoming to us.} - -Brian grew up at the MIT and Stanford Artificial Intelligence Labs, learning from Lisp inventor John McCarthy, Scheme inventors Gerald J. Sussman and Guy Steele, and the authors of the world's best computer science book, \emph{Structure and Interpretation of Computer Programs}, Hal Abelson and Gerald J. Sussman with Julie Sussman, among many other heroes of computer science. - -{\bf\em In the glory days of the MIT Logo Lab, we used to say, ``Logo is Lisp disguised as BASIC.'' Now, with its first class procedures, lexical scope, and first class continuations, \Snap{} is Scheme disguised as Scratch.} - -We have been fortunate to get to know an amazing group of brilliant middle school(!) and high school students through the Scratch Advanced Topics forum, several of whom have contributed code to \Snap{}: Kartik Chandra, Nathan Dinsmore, Connor Hudson, and Ian Reynolds. Many more have contributed ideas and alpha-testing bug reports. UC Berkeley students who've contributed code include Michael Ball, Achal Dave. Kyle Hotchkiss, Ivan Motyashov, and Yuan Yuan. Contributors of translations are too numerous to list here, but they're in the ``About...'' box in \Snap{} itself. This work was supported in part by the National Science Foundation grant 1143566, and in part by MioSoft. - -\begin{titlepage} - -\begin{center} -\bf \Huge \Snap{} Reference Manual \\ \huge Version 4.0 \vspace{40pt} -\end{center} - -\Snap{} (formerly BYOB) is an extended reimplementation of Scratch (\url{http://scratch.mit.edu}) that allows you to Build Your Own Blocks. It also features first class lists, first class procedures, and continuations. These added capabilities make it suitable for a serious introduction to computer science for high school or college students. To run \Snap{}, open a browser window and connect to either \url{http://snap.berkeley.edu/run} to start with a minimal set of blocks or \url{http://snap.berkeley.edu/init} to load a small set of additional blocks (a little slower startup, but recommended for convenience and assumed in this manual). - -\end{titlepage} - -\chapter{Blocks, Scripts, and Sprites} - -This chapter describes the \Snap{} features inherited from Scratch; experienced Scratch users can skip to section B. - -\Snap{} is a programming language---a notation in which you can tell a computer what you want it to do. Unlike most programming languages, though, \Snap{} is a visual language; instead of writing a program using the keyboard, the \Snap{} programmer uses the same drag-and-drop interface familiar to computer users. - -Start \Snap{}. You should see the following arrangement of regions in the window: - -\begin{center} -\includegraphics[width=\textwidth]{window-regions} -\end{center} - -(The proportions of these areas may be different, depending on the size and shape of your browser window.) - -A \Snap{} program consists of one or more \emph{scripts}, each of which is made of \emph{blocks}. Here's a typical script: - -\bigpic{typical-script} - -The five blocks that make up this script have three different colors, corresponding to three of the eight \emph{palettes} in which blocks can be found. The palette area at the left edge of the window shows one palette at a time, chosen with the eight buttons just above the palette area. In this script, the gold blocks are from the Control palette; the green block is from the Pen palette; and the blue blocks are from the Motion palette. A script is assembled by dragging blocks from a palette into the \emph{scripting area} in the middle part of the window. Blocks snap together (hence the name \Snap{} for the language) when you drag a block so that its indentation is near the tab of the one above it: - -\bigpic{snapping-blocks} - -The white horizontal line is a signal that if you let go of the green block it will snap into the tab of the gold one. - -\subsection{Hat Blocks and Command Blocks} - -At the top of the script is a \emph{hat} block, which indicates when the script should be carried out. Hat block names typically start with the word ``\code{when}''; in this example, the script should be run when the green flag near the right end of the \Snap{} tool bar is clicked. (The \Snap{} tool bar is part of the \Snap{} window, not the same as the browser's or operating system's menu bar.) A script isn't required to have a hat block, but if not, then the script will be run only if the user clicks on the script itself. A script can't have more than one hat block, and the hat block can be used only at the top of the script; its distinctive shape is meant to remind you of that. - -The other blocks in this script are \emph{command} blocks. Each command block corresponds to an action that \Snap{} already knows how to carry out. For example, the block \inlinepic{move-10-steps} tells the sprite (the arrowhead shape on the \emph{stage} at the right end of the window) to move ten steps (a step is a very small unit of distance) in the direction in which the arrowhead is pointing. We'll see shortly that there can be more than one sprite, and that each sprite has its own scripts. Also, a sprite doesn't have to look like an arrowhead, but can have any picture as a costume. The shape of the \code{move} block is meant to remind you of a Lego\texttrademark{} brick; a script is a stack of blocks. (The word ``block'' denotes both the graphical shape on the screen and the procedure, the action, that the block carries out.) - -The number 10 in the \code{move} block above is called an \emph{input} to the block. By clicking on the white oval, you can type any number in place of the 10. The sample script on the previous page uses 100 as the input value. We'll see later that inputs can have non-oval shapes that accept values other than numbers. We'll also see that you can compute input values, instead of typing a particular value into the oval. A block can have more than one input slot. For example, the \code{glide} block located about halfway down the Motion palette has three inputs. - -Most command blocks have that brick shape, but some, like the \code{repeat} block in the sample script, are \emph{C-shaped}. Most C-shaped blocks are found in the Control palette. The slot inside the C shape is a special kind of input slot that accepts a \emph{script} as the input. In the sample script, the \code{repeat} block has two inputs: the number 4 and the script - -\bigpic{typical-script-inner} - - - -\section{Sprites and Parallelism} -\subsection{Costumes and Sounds} -\subsection{Inter-Sprite Communication with Broadcast} -\section{Nesting Sprites: Anchors and Parts} -\section{Reporter Blocks and Expressions} -\section{Predicates and Conditional Evaluation} -\section{Variables} -\subsection{Global Variables} -\subsection{Script Variables} -\section{Etcetera} -\chapter{Saving and Loading Projects and Media} -\section{Local Storage} -\subsection{Localstore} -\subsection{XML Export} -\section{Cloud Storage} -\section{Loading Saved Projects} -\chapter{Building a Block} -\section{Simple Blocks} -\subsection{Custom Blocks with Inputs} -\section{Recursion} -\section{Block Libraries} -\chapter{First Class Lists} -\section{The list Block} -\section{Lists of Lists} -\section{Functional and Imperative List Programming} -\section{Higher Order List Operations and Rings} -\chapter{Typed Inputs} -\section{Scratch's Type Notation} -\section{The \Snap{} Input Type Dialog} -\subsection{Procedure Types} -\subsection{Pulldown inputs} -\subsection{Input variants} -\subsection{Prototype Hints} -\subsection{Title Text and Symbols} -\chapter{Procedures as Data} -\section{Call and Run} -\subsection{Call/Run with inputs} -\subsection{Variables in Ring Slots} -\section{Writing Higher Order Procedures} -\subsection{Recursive Calls to Multiple-Input Blocks} -\section{Formal Parameters} -\section{Procedures as Data} -\section{Special Forms} -\subsection{Special Forms in Scratch} -\chapter{Object Oriented Programming} -\section{Local State with Script Variables} -\section{Messages and Dispatch Procedures} -\section{Inheritance via Delegation} -\section{An Implementation of Prototyping OOP} -\chapter{The Outside World} -\section{The World Wide Web} -\section{Hardware Devices} -\section{Date and Time} -\chapter{Continuations} -\section{Continuation Passing Style} -\section{Call/Run w/Continuation} -\subsection{Nonlocal exit} -\chapter{User Interface Elements} -\section{Tool Bar Features} -\subsection{The \Snap{} Logo Menu} -\subsection{The File Menu} -\subsection{The Cloud Menu} -\subsection{The Settings Menu} -\subsection{Stage Resizing Buttons} -\subsection{Project Control Buttons} -\section{The Palette Area} -\subsection{Context Menus for Palette Blocks} -\subsection{Context Menu for the Palette Background} -\section{The Scripting Area} -\subsection{Sprite Appearance and Behavior Controls} -\subsection{Scripting Area Tabs} -\subsection{Scripts and Blocks Within Scripts} -\subsection{Scripting Area Background Context Menu} -\subsection{Controls in the Costumes Tab} -\subsection{The Paint Editor} -\subsection{Controls in the Sounds Tab} -\section{Controls on the Stage} -\section{The Sprite Corral and Sprite Creation Buttons} - -\end{document} diff --git a/help/manual/snapping-blocks.png b/help/manual/snapping-blocks.png deleted file mode 100644 index 0dc5922..0000000 Binary files a/help/manual/snapping-blocks.png and /dev/null differ diff --git a/help/manual/typical-script-inner.png b/help/manual/typical-script-inner.png deleted file mode 100644 index b5503f7..0000000 Binary files a/help/manual/typical-script-inner.png and /dev/null differ diff --git a/help/manual/typical-script.png b/help/manual/typical-script.png deleted file mode 100644 index 6763aad..0000000 Binary files a/help/manual/typical-script.png and /dev/null differ diff --git a/help/manual/window-regions.png b/help/manual/window-regions.png deleted file mode 100644 index 7fe4e98..0000000 Binary files a/help/manual/window-regions.png and /dev/null differ -- cgit v1.3.1 From 2676521231679cfd24114d38ce6c5b2208568530 Mon Sep 17 00:00:00 2001 From: Bartosz Leper Date: Wed, 24 Jun 2015 01:27:03 +0200 Subject: Move some stuff to the common directory --- help/manual/common/defs.tex | 23 +++++++++++++++++++++++ help/manual/en/snap-manual.tex | 25 +------------------------ 2 files changed, 24 insertions(+), 24 deletions(-) create mode 100644 help/manual/common/defs.tex diff --git a/help/manual/common/defs.tex b/help/manual/common/defs.tex new file mode 100644 index 0000000..4453b67 --- /dev/null +++ b/help/manual/common/defs.tex @@ -0,0 +1,23 @@ +\usepackage{baskervald} % Default font +\usepackage{cabin} % Sans serif font +\usepackage[T1]{fontenc} +\usepackage{setspace} \onehalfspacing +\usepackage{graphicx} +\usepackage{textcomp} +\usepackage{hyperref} + +\newcommand{\Snap}{{\sf Snap{\it !}}} +\newcommand{\code}[1]{\textsf{#1}} +\newcommand{\defaultGraphicsScale}{0.6} + +\newcommand{\inlinepic}[1]{% + \raisebox{-4pt}{% + \includegraphics[scale=\defaultGraphicsScale]{#1}% + }% +} + +\newcommand{\bigpic}[1]{ + \begin{center} + \includegraphics[scale=\defaultGraphicsScale]{#1} + \end{center} +} \ No newline at end of file diff --git a/help/manual/en/snap-manual.tex b/help/manual/en/snap-manual.tex index 6ca387c..3b5fe98 100644 --- a/help/manual/en/snap-manual.tex +++ b/help/manual/en/snap-manual.tex @@ -1,29 +1,6 @@ \documentclass{report} -\usepackage{baskervald} % Default font -\usepackage{cabin} % Sans serif font -\usepackage[T1]{fontenc} -\usepackage{setspace} \onehalfspacing -\usepackage{graphicx} -\usepackage{textcomp} -\usepackage{hyperref} - -\newcommand{\Snap}{{\sf Snap{\it !}}} -\newcommand{\code}[1]{\textsf{#1}} -\newcommand{\defaultGraphicsScale}{0.6} - -\newcommand{\inlinepic}[1]{% - \raisebox{-4pt}{% - \includegraphics[scale=\defaultGraphicsScale]{#1}% - }% -} - -\newcommand{\bigpic}[1]{ - \begin{center} - \includegraphics[scale=\defaultGraphicsScale]{#1} - \end{center} -} - +\input{../common/defs.tex} \renewcommand{\thechapter}{\Roman{chapter}} \renewcommand{\thesection}{\Alph{section}} -- cgit v1.3.1 From b0995850dabfd95a268cbab0ba5f09cd8dba7a77 Mon Sep 17 00:00:00 2001 From: Bartosz Leper Date: Wed, 24 Jun 2015 18:33:43 +0200 Subject: First batch of translation --- help/manual/common/defs.tex | 22 ++++- help/manual/en/snap-manual.tex | 8 +- help/manual/pl/move-10-steps.png | Bin 0 -> 2595 bytes help/manual/pl/snap-podrecznik.tex | 157 ++++++++++++++++++++++++++++++++ help/manual/pl/snapping-blocks.png | Bin 0 -> 12054 bytes help/manual/pl/typical-script-inner.png | Bin 0 -> 4610 bytes help/manual/pl/typical-script.png | Bin 0 -> 11063 bytes help/manual/pl/window-regions.png | Bin 0 -> 142052 bytes 8 files changed, 180 insertions(+), 7 deletions(-) create mode 100644 help/manual/pl/move-10-steps.png create mode 100644 help/manual/pl/snap-podrecznik.tex create mode 100644 help/manual/pl/snapping-blocks.png create mode 100644 help/manual/pl/typical-script-inner.png create mode 100644 help/manual/pl/typical-script.png create mode 100644 help/manual/pl/window-regions.png diff --git a/help/manual/common/defs.tex b/help/manual/common/defs.tex index 4453b67..b35b373 100644 --- a/help/manual/common/defs.tex +++ b/help/manual/common/defs.tex @@ -1,15 +1,35 @@ \usepackage{baskervald} % Default font \usepackage{cabin} % Sans serif font \usepackage[T1]{fontenc} +\usepackage[utf8]{inputenc} \usepackage{setspace} \onehalfspacing \usepackage{graphicx} \usepackage{textcomp} \usepackage{hyperref} -\newcommand{\Snap}{{\sf Snap{\it !}}} +% This macro produces a "Snap!" logo. +% +% Note that in Polish (and other languages), nouns are inflected. The form "Snap!" with suffix looks plain stupid, so the macro takes a suffix as argument. If the suffix is non-empty, no exclamation mark is generated, and the suffix is used instead. +\newcommand{\Snap}[1]{% + {% + \sf% + Snap% + \ifx\\#1\\{\it !}% + \else #1% + \fi% + }% +} +\newcommand{\Foo}[1]{ +\ifx\\#1\\foo\else bar\fi +} + \newcommand{\code}[1]{\textsf{#1}} \newcommand{\defaultGraphicsScale}{0.6} +\renewcommand{\thechapter}{\Roman{chapter}} +\renewcommand{\thesection}{\Alph{section}} +\renewcommand{\thesubsection}{} + \newcommand{\inlinepic}[1]{% \raisebox{-4pt}{% \includegraphics[scale=\defaultGraphicsScale]{#1}% diff --git a/help/manual/en/snap-manual.tex b/help/manual/en/snap-manual.tex index 3b5fe98..3b088d7 100644 --- a/help/manual/en/snap-manual.tex +++ b/help/manual/en/snap-manual.tex @@ -2,10 +2,6 @@ \input{../common/defs.tex} -\renewcommand{\thechapter}{\Roman{chapter}} -\renewcommand{\thesection}{\Alph{section}} -\renewcommand{\thesubsection}{} - \begin{document} \title{\Snap{} Reference Manual} @@ -23,11 +19,11 @@ We have been extremely lucky in our mentors. Jens cut his teeth in the company o {\bf\em Our earlier version, BYOB, was a direct modification of the Scratch source code. \Snap{} is a complete rewrite, but its code structure and its user interface remain deeply indebted to Scratch. And the Scratch Team, who could have seen us as rivals, have been entirely supportive and welcoming to us.} -Brian grew up at the MIT and Stanford Artificial Intelligence Labs, learning from Lisp inventor John McCarthy, Scheme inventors Gerald J. Sussman and Guy Steele, and the authors of the world's best computer science book, \emph{Structure and Interpretation of Computer Programs}, Hal Abelson and Gerald J. Sussman with Julie Sussman, among many other heroes of computer science. +Brian grew up at the MIT and Stanford Artificial Intelligence Labs, learning from Lisp inventor John McCarthy, Scheme inventors Gerald J. Sussman and Guy Steele, and the authors of the world's best computer science book, \textit{Structure and Interpretation of Computer Programs}, Hal Abelson and Gerald J. Sussman with Julie Sussman, among many other heroes of computer science. {\bf\em In the glory days of the MIT Logo Lab, we used to say, ``Logo is Lisp disguised as BASIC.'' Now, with its first class procedures, lexical scope, and first class continuations, \Snap{} is Scheme disguised as Scratch.} -We have been fortunate to get to know an amazing group of brilliant middle school(!) and high school students through the Scratch Advanced Topics forum, several of whom have contributed code to \Snap{}: Kartik Chandra, Nathan Dinsmore, Connor Hudson, and Ian Reynolds. Many more have contributed ideas and alpha-testing bug reports. UC Berkeley students who've contributed code include Michael Ball, Achal Dave. Kyle Hotchkiss, Ivan Motyashov, and Yuan Yuan. Contributors of translations are too numerous to list here, but they're in the ``About...'' box in \Snap{} itself. This work was supported in part by the National Science Foundation grant 1143566, and in part by MioSoft. +We have been fortunate to get to know an amazing group of brilliant middle school (!\@) and high school students through the Scratch Advanced Topics forum, several of whom have contributed code to \Snap{}: Kartik Chandra, Nathan Dinsmore, Connor Hudson, and Ian Reynolds. Many more have contributed ideas and alpha-testing bug reports. UC Berkeley students who've contributed code include Michael Ball, Achal Dave, Kyle Hotchkiss, Ivan Motyashov, and Yuan Yuan. Contributors of translations are too numerous to list here, but they're in the ``About...'' box in \Snap{} itself. This work was supported in part by the National Science Foundation grant 1143566, and in part by MioSoft. \begin{titlepage} diff --git a/help/manual/pl/move-10-steps.png b/help/manual/pl/move-10-steps.png new file mode 100644 index 0000000..3d276da Binary files /dev/null and b/help/manual/pl/move-10-steps.png differ diff --git a/help/manual/pl/snap-podrecznik.tex b/help/manual/pl/snap-podrecznik.tex new file mode 100644 index 0000000..69b9e09 --- /dev/null +++ b/help/manual/pl/snap-podrecznik.tex @@ -0,0 +1,157 @@ +\documentclass{report} + +\input{../common/defs.tex} + +\begin{document} + +\title{\Snap{} \\ Podręcznik użytkownika} +\author{Brian Harvey \and Jens M\"{o}nig} +\date{} + +\maketitle + +\tableofcontents + +\chapter*{} +\section*{Acknowledgements} + +Mieliśmy ogromne szczęście do mentorów. Jens zdobył dużo doświadczenia pracując wśród pionierów Smalltalka: Alana Kaya, Dana Ingallsa i reszty ekipy, która wynalazła komputery osobiste i programowanie obiektowe w najlepszych dniach firmy Xerox PARC. Pracował z Johnem Maloneyem z zespołu Scratcha w MIT\footnote{Massachusetts Institute of Technology, amerykańska uczelnia techniczna --- przyp. tłum.} , autorem platformy graficznej Morphic, wciąż stanowiącej fundament \Snap{a}. Znakomity projekt języka Scratch, autorstwa Lifelong Kindergarten Group z MIT Media Lab, odgrywa w \Snap{ie} kluczową rolę. + +{\bf\em Nasza poprzednia wersja, BYOB, była bezpośrednią modyfikacją kodu źródłowego Scratcha. \Snap{} został napisany od zera, lecz struktura jego kodu oraz interfejs użytkownika pozostają mocno zakorzenione w Scratchu. Z kolei zespół Scratcha, który mógłby widzieć w nas rywali, przyjął nas ciepło i okazał nam całkowite wsparcie.} + +Brian zdobywał szlify w MIT oraz Stanford Artificial Intelligence Labs\footnote{Laboratorium sztucznej inteligencji na Uniwersytecie Stanforda --- przyp. tłum.}, gdzie uczył się pod okiem Johna McCarthy'ego, twórcy Lispa, oraz Geralda J. Sussmana i Guya Steele'a, twórców języka Scheme. Zdobywał również wiedzę od wielu innych wybitnych informatyków, w tym autorów najlepszej książki z zakresu informatyki --- \emph{Struktury i interpretacji programów komputerowych}: Hala Abelsona, Geralda J. Sussmana i Julie Sussman. + +{\bf\em Za starych dobrych czasów mawialiśmy w MIT Logo Lab: ,,Język Logo to Lisp w przebraniu BASIC-a''. Dziś, ze swoimi pierwszoklasowymi procedurami, zasięgami leksykalnymi i pierwszoklasowymi kontynuacjami, \Snap{} jest jak Scheme w przebraniu Scratcha.} + +Szczęśliwym zrządzeniem losu, poprzez forum Scratch Advanced Topics, poznaliśmy wspaniałą grupę błyskotliwych uczniów gimnazjów (!) i liceów. Kilku z nich wniosło swój wkład w kod \Snap{a}: Kartik Chandra, Nathan Dinsmore, Connor Hudson i Ian Reynolds. Ponadto, wielu zgłosiło pomysły i raporty błędów podczas testowania wersji alfa. Wśród studentów Uniwersytetu Kalifornijskiego w Berkeley, którzy przyczynili się do rozwoju kodu, znajdują się Michael Ball, Achal Dave, Kyle Hotchkiss, Ivan Motyashov i Yuan Yuan. Wymienianie wszystkich tłumaczy zajeło by zbyt wiele miejsca, ale można ich odnaleźć w okienku ,,O Snap!...'' dostępnym w programie. Niniejsze dzieło powstało częściowo w ramach grantu 1143566 udzielonego przez National Science Foundation, a częściowo przy wsparciu firmy MioSoft. + +\begin{titlepage} + +\begin{center} +\bf \Huge \Snap{} \\ Podręcznik użytkownika \\ \huge Wersja 4.0 \vspace{40pt} +\end{center} + +\Snap{} (dawniej BYOB) to rozszerzona reimplementacja języka Scratch (\url{http://scratch.mit.edu}), która pozwala na tworzenie własnych bloków (ang. \textit{Build Your Own Blocks}). + +\Snap{} (formerly BYOB) is an extended reimplementation of Scratch (\url{http://scratch.mit.edu}) that allows you to Build Your Own Blocks. It also features first class lists, first class procedures, and continuations. These added capabilities make it suitable for a serious introduction to computer science for high school or college students. To run \Snap{}, open a browser window and connect to either \url{http://snap.berkeley.edu/run} to start with a minimal set of blocks or \url{http://snap.berkeley.edu/init} to load a small set of additional blocks (a little slower startup, but recommended for convenience and assumed in this manual). + +\end{titlepage} + +\chapter{Blocks, Scripts, and Sprites} + +This chapter describes the \Snap{} features inherited from Scratch; experienced Scratch users can skip to section B. + +\Snap{} is a programming language---a notation in which you can tell a computer what you want it to do. Unlike most programming languages, though, \Snap{} is a visual language; instead of writing a program using the keyboard, the \Snap{} programmer uses the same drag-and-drop interface familiar to computer users. + +Start \Snap{}. You should see the following arrangement of regions in the window: + +\begin{center} +\includegraphics[width=\textwidth]{window-regions} +\end{center} + +(The proportions of these areas may be different, depending on the size and shape of your browser window.) + +A \Snap{} program consists of one or more \emph{scripts}, each of which is made of \emph{blocks}. Here's a typical script: + +\bigpic{typical-script} + +The five blocks that make up this script have three different colors, corresponding to three of the eight \emph{palettes} in which blocks can be found. The palette area at the left edge of the window shows one palette at a time, chosen with the eight buttons just above the palette area. In this script, the gold blocks are from the Control palette; the green block is from the Pen palette; and the blue blocks are from the Motion palette. A script is assembled by dragging blocks from a palette into the \emph{scripting area} in the middle part of the window. Blocks snap together (hence the name \Snap{} for the language) when you drag a block so that its indentation is near the tab of the one above it: + +\bigpic{snapping-blocks} + +The white horizontal line is a signal that if you let go of the green block it will snap into the tab of the gold one. + +\subsection{Hat Blocks and Command Blocks} + +At the top of the script is a \emph{hat} block, which indicates when the script should be carried out. Hat block names typically start with the word ``\code{when}''; in this example, the script should be run when the green flag near the right end of the \Snap{} tool bar is clicked. (The \Snap{} tool bar is part of the \Snap{} window, not the same as the browser's or operating system's menu bar.) A script isn't required to have a hat block, but if not, then the script will be run only if the user clicks on the script itself. A script can't have more than one hat block, and the hat block can be used only at the top of the script; its distinctive shape is meant to remind you of that. + +The other blocks in this script are \emph{command} blocks. Each command block corresponds to an action that \Snap{} already knows how to carry out. For example, the block \inlinepic{move-10-steps} tells the sprite (the arrowhead shape on the \emph{stage} at the right end of the window) to move ten steps (a step is a very small unit of distance) in the direction in which the arrowhead is pointing. We'll see shortly that there can be more than one sprite, and that each sprite has its own scripts. Also, a sprite doesn't have to look like an arrowhead, but can have any picture as a costume. The shape of the \code{move} block is meant to remind you of a Lego\texttrademark{} brick; a script is a stack of blocks. (The word ``block'' denotes both the graphical shape on the screen and the procedure, the action, that the block carries out.) + +The number 10 in the \code{move} block above is called an \emph{input} to the block. By clicking on the white oval, you can type any number in place of the 10. The sample script on the previous page uses 100 as the input value. We'll see later that inputs can have non-oval shapes that accept values other than numbers. We'll also see that you can compute input values, instead of typing a particular value into the oval. A block can have more than one input slot. For example, the \code{glide} block located about halfway down the Motion palette has three inputs. + +Most command blocks have that brick shape, but some, like the \code{repeat} block in the sample script, are \emph{C-shaped}. Most C-shaped blocks are found in the Control palette. The slot inside the C shape is a special kind of input slot that accepts a \emph{script} as the input. In the sample script, the \code{repeat} block has two inputs: the number 4 and the script + +\bigpic{typical-script-inner} + + + +\section{Sprites and Parallelism} +\subsection{Costumes and Sounds} +\subsection{Inter-Sprite Communication with Broadcast} +\section{Nesting Sprites: Anchors and Parts} +\section{Reporter Blocks and Expressions} +\section{Predicates and Conditional Evaluation} +\section{Variables} +\subsection{Global Variables} +\subsection{Script Variables} +\section{Etcetera} +\chapter{Saving and Loading Projects and Media} +\section{Local Storage} +\subsection{Localstore} +\subsection{XML Export} +\section{Cloud Storage} +\section{Loading Saved Projects} +\chapter{Building a Block} +\section{Simple Blocks} +\subsection{Custom Blocks with Inputs} +\section{Recursion} +\section{Block Libraries} +\chapter{First Class Lists} +\section{The list Block} +\section{Lists of Lists} +\section{Functional and Imperative List Programming} +\section{Higher Order List Operations and Rings} +\chapter{Typed Inputs} +\section{Scratch's Type Notation} +\section{The \Snap{} Input Type Dialog} +\subsection{Procedure Types} +\subsection{Pulldown inputs} +\subsection{Input variants} +\subsection{Prototype Hints} +\subsection{Title Text and Symbols} +\chapter{Procedures as Data} +\section{Call and Run} +\subsection{Call/Run with inputs} +\subsection{Variables in Ring Slots} +\section{Writing Higher Order Procedures} +\subsection{Recursive Calls to Multiple-Input Blocks} +\section{Formal Parameters} +\section{Procedures as Data} +\section{Special Forms} +\subsection{Special Forms in Scratch} +\chapter{Object Oriented Programming} +\section{Local State with Script Variables} +\section{Messages and Dispatch Procedures} +\section{Inheritance via Delegation} +\section{An Implementation of Prototyping OOP} +\chapter{The Outside World} +\section{The World Wide Web} +\section{Hardware Devices} +\section{Date and Time} +\chapter{Continuations} +\section{Continuation Passing Style} +\section{Call/Run w/Continuation} +\subsection{Nonlocal exit} +\chapter{User Interface Elements} +\section{Tool Bar Features} +\subsection{The \Snap{} Logo Menu} +\subsection{The File Menu} +\subsection{The Cloud Menu} +\subsection{The Settings Menu} +\subsection{Stage Resizing Buttons} +\subsection{Project Control Buttons} +\section{The Palette Area} +\subsection{Context Menus for Palette Blocks} +\subsection{Context Menu for the Palette Background} +\section{The Scripting Area} +\subsection{Sprite Appearance and Behavior Controls} +\subsection{Scripting Area Tabs} +\subsection{Scripts and Blocks Within Scripts} +\subsection{Scripting Area Background Context Menu} +\subsection{Controls in the Costumes Tab} +\subsection{The Paint Editor} +\subsection{Controls in the Sounds Tab} +\section{Controls on the Stage} +\section{The Sprite Corral and Sprite Creation Buttons} + +\end{document} diff --git a/help/manual/pl/snapping-blocks.png b/help/manual/pl/snapping-blocks.png new file mode 100644 index 0000000..0dc5922 Binary files /dev/null and b/help/manual/pl/snapping-blocks.png differ diff --git a/help/manual/pl/typical-script-inner.png b/help/manual/pl/typical-script-inner.png new file mode 100644 index 0000000..b5503f7 Binary files /dev/null and b/help/manual/pl/typical-script-inner.png differ diff --git a/help/manual/pl/typical-script.png b/help/manual/pl/typical-script.png new file mode 100644 index 0000000..6763aad Binary files /dev/null and b/help/manual/pl/typical-script.png differ diff --git a/help/manual/pl/window-regions.png b/help/manual/pl/window-regions.png new file mode 100644 index 0000000..7fe4e98 Binary files /dev/null and b/help/manual/pl/window-regions.png differ -- cgit v1.3.1 From 132ccdb35e0d2795cc2353b01c3caaf73b04389a Mon Sep 17 00:00:00 2001 From: Bartosz Leper Date: Wed, 24 Jun 2015 18:49:13 +0200 Subject: Use Polish typographic conventions --- help/manual/pl/snap-podrecznik.tex | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/help/manual/pl/snap-podrecznik.tex b/help/manual/pl/snap-podrecznik.tex index 69b9e09..a07a889 100644 --- a/help/manual/pl/snap-podrecznik.tex +++ b/help/manual/pl/snap-podrecznik.tex @@ -2,6 +2,11 @@ \input{../common/defs.tex} +\usepackage[polish]{babel} +\usepackage{polski} +\frenchspacing +\usepackage{indentfirst} + \begin{document} \title{\Snap{} \\ Podręcznik użytkownika} @@ -13,17 +18,17 @@ \tableofcontents \chapter*{} -\section*{Acknowledgements} +\section*{Podziękowania} Mieliśmy ogromne szczęście do mentorów. Jens zdobył dużo doświadczenia pracując wśród pionierów Smalltalka: Alana Kaya, Dana Ingallsa i reszty ekipy, która wynalazła komputery osobiste i programowanie obiektowe w najlepszych dniach firmy Xerox PARC. Pracował z Johnem Maloneyem z zespołu Scratcha w MIT\footnote{Massachusetts Institute of Technology, amerykańska uczelnia techniczna --- przyp. tłum.} , autorem platformy graficznej Morphic, wciąż stanowiącej fundament \Snap{a}. Znakomity projekt języka Scratch, autorstwa Lifelong Kindergarten Group z MIT Media Lab, odgrywa w \Snap{ie} kluczową rolę. {\bf\em Nasza poprzednia wersja, BYOB, była bezpośrednią modyfikacją kodu źródłowego Scratcha. \Snap{} został napisany od zera, lecz struktura jego kodu oraz interfejs użytkownika pozostają mocno zakorzenione w Scratchu. Z kolei zespół Scratcha, który mógłby widzieć w nas rywali, przyjął nas ciepło i okazał nam całkowite wsparcie.} -Brian zdobywał szlify w MIT oraz Stanford Artificial Intelligence Labs\footnote{Laboratorium sztucznej inteligencji na Uniwersytecie Stanforda --- przyp. tłum.}, gdzie uczył się pod okiem Johna McCarthy'ego, twórcy Lispa, oraz Geralda J. Sussmana i Guya Steele'a, twórców języka Scheme. Zdobywał również wiedzę od wielu innych wybitnych informatyków, w tym autorów najlepszej książki z zakresu informatyki --- \emph{Struktury i interpretacji programów komputerowych}: Hala Abelsona, Geralda J. Sussmana i Julie Sussman. +Brian zdobywał szlify w MIT oraz Stanford Artificial Intelligence Labs\footnote{Laboratorium sztucznej inteligencji na Uniwersytecie Stanforda --- przyp. tłum.}, gdzie uczył się pod okiem Johna McCarthy'ego, twórcy Lispa, oraz Geralda J. Suss\-mana i Guya Steele'a, twórców języka Scheme. Zdobywał również wiedzę od wielu innych wybitnych informatyków, w tym autorów najlepszej książki z zakresu informatyki --- \emph{Struktury i interpretacji programów komputerowych}: Hala Abelsona, Geralda J. Suss\-mana i Julie Suss\-man. {\bf\em Za starych dobrych czasów mawialiśmy w MIT Logo Lab: ,,Język Logo to Lisp w przebraniu BASIC-a''. Dziś, ze swoimi pierwszoklasowymi procedurami, zasięgami leksykalnymi i pierwszoklasowymi kontynuacjami, \Snap{} jest jak Scheme w przebraniu Scratcha.} -Szczęśliwym zrządzeniem losu, poprzez forum Scratch Advanced Topics, poznaliśmy wspaniałą grupę błyskotliwych uczniów gimnazjów (!) i liceów. Kilku z nich wniosło swój wkład w kod \Snap{a}: Kartik Chandra, Nathan Dinsmore, Connor Hudson i Ian Reynolds. Ponadto, wielu zgłosiło pomysły i raporty błędów podczas testowania wersji alfa. Wśród studentów Uniwersytetu Kalifornijskiego w Berkeley, którzy przyczynili się do rozwoju kodu, znajdują się Michael Ball, Achal Dave, Kyle Hotchkiss, Ivan Motyashov i Yuan Yuan. Wymienianie wszystkich tłumaczy zajeło by zbyt wiele miejsca, ale można ich odnaleźć w okienku ,,O Snap!...'' dostępnym w programie. Niniejsze dzieło powstało częściowo w ramach grantu 1143566 udzielonego przez National Science Foundation, a częściowo przy wsparciu firmy MioSoft. +Szczęśliwym zrządzeniem losu, poprzez forum Scratch Advanced Topics, poznaliśmy wspaniałą grupę błyskotliwych uczniów gimnazjów (!\@) i liceów. Kilku z nich wniosło swój wkład w kod \Snap{a}: Kartik Chandra, Nathan Dinsmore, Connor Hudson i Ian Reynolds. Ponadto, wielu zgłosiło pomysły i raporty błędów podczas testowania wersji alfa. Wśród studentów Uniwersytetu Kalifornijskiego w Berkeley, którzy przyczynili się do rozwoju kodu, znajdują się Michael Ball, Achal Dave, Kyle Hotchkiss, Ivan Motyashov i Yuan Yuan. Wymienianie wszystkich tłumaczy zajeło by zbyt wiele miejsca, ale można ich odnaleźć w okienku ,,O Snap!...'' dostępnym w programie. Niniejsze dzieło powstało częściowo w ramach grantu nr 1143566 udzielonego przez National Science Foundation, a częściowo przy wsparciu firmy MioSoft. \begin{titlepage} -- cgit v1.3.1 From d430bac6d6fa6bfc340fee665185e4ef9ccb9a67 Mon Sep 17 00:00:00 2001 From: Bartosz Leper Date: Wed, 24 Jun 2015 18:55:24 +0200 Subject: Improve typesetting of Snap logo --- help/manual/common/defs.tex | 8 ++------ help/manual/pl/snap-podrecznik.tex | 2 +- 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/help/manual/common/defs.tex b/help/manual/common/defs.tex index b35b373..50f0c24 100644 --- a/help/manual/common/defs.tex +++ b/help/manual/common/defs.tex @@ -11,17 +11,13 @@ % % Note that in Polish (and other languages), nouns are inflected. The form "Snap!" with suffix looks plain stupid, so the macro takes a suffix as argument. If the suffix is non-empty, no exclamation mark is generated, and the suffix is used instead. \newcommand{\Snap}[1]{% - {% - \sf% + \textsf{% Snap% - \ifx\\#1\\{\it !}% + \ifx\\#1\\\textit{!}% \else #1% \fi% }% } -\newcommand{\Foo}[1]{ -\ifx\\#1\\foo\else bar\fi -} \newcommand{\code}[1]{\textsf{#1}} \newcommand{\defaultGraphicsScale}{0.6} diff --git a/help/manual/pl/snap-podrecznik.tex b/help/manual/pl/snap-podrecznik.tex index a07a889..1e2c78a 100644 --- a/help/manual/pl/snap-podrecznik.tex +++ b/help/manual/pl/snap-podrecznik.tex @@ -36,7 +36,7 @@ Szczęśliwym zrządzeniem losu, poprzez forum Scratch Advanced Topics, poznali \bf \Huge \Snap{} \\ Podręcznik użytkownika \\ \huge Wersja 4.0 \vspace{40pt} \end{center} -\Snap{} (dawniej BYOB) to rozszerzona reimplementacja języka Scratch (\url{http://scratch.mit.edu}), która pozwala na tworzenie własnych bloków (ang. \textit{Build Your Own Blocks}). +\Snap{} (dawniej BYOB) to rozszerzona reimplementacja języka Scratch (\url{http://scratch.mit.edu}), która pozwala na tworzenie własnych bloków (ang. \textit{Build Your Own Blocks}). \Snap{} (formerly BYOB) is an extended reimplementation of Scratch (\url{http://scratch.mit.edu}) that allows you to Build Your Own Blocks. It also features first class lists, first class procedures, and continuations. These added capabilities make it suitable for a serious introduction to computer science for high school or college students. To run \Snap{}, open a browser window and connect to either \url{http://snap.berkeley.edu/run} to start with a minimal set of blocks or \url{http://snap.berkeley.edu/init} to load a small set of additional blocks (a little slower startup, but recommended for convenience and assumed in this manual). -- cgit v1.3.1 From b2fd1ade3133684d6665fcd7002c22b2da304ebb Mon Sep 17 00:00:00 2001 From: Bartosz Leper Date: Wed, 24 Jun 2015 18:58:51 +0200 Subject: Minor typographic corrections --- help/manual/en/snap-manual.tex | 4 ++-- help/manual/pl/snap-podrecznik.tex | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/help/manual/en/snap-manual.tex b/help/manual/en/snap-manual.tex index 3b088d7..fc1dfc7 100644 --- a/help/manual/en/snap-manual.tex +++ b/help/manual/en/snap-manual.tex @@ -17,11 +17,11 @@ We have been extremely lucky in our mentors. Jens cut his teeth in the company of the Smalltalk pioneers: Alan Kay, Dan Ingalls, and the rest of the gang who invented personal computing and object oriented programming in the great days of Xerox PARC. He worked with John Maloney, of the MIT Scratch Team, who developed the Morphic graphics framework that's still at the heart of \Snap{}. The brilliant design of Scratch, from the Lifelong Kindergarten Group at the MIT Media Lab, is crucial to \Snap{}. -{\bf\em Our earlier version, BYOB, was a direct modification of the Scratch source code. \Snap{} is a complete rewrite, but its code structure and its user interface remain deeply indebted to Scratch. And the Scratch Team, who could have seen us as rivals, have been entirely supportive and welcoming to us.} +\textbf{\emph{Our earlier version, BYOB, was a direct modification of the Scratch source code. \Snap{} is a complete rewrite, but its code structure and its user interface remain deeply indebted to Scratch. And the Scratch Team, who could have seen us as rivals, have been entirely supportive and welcoming to us.}} Brian grew up at the MIT and Stanford Artificial Intelligence Labs, learning from Lisp inventor John McCarthy, Scheme inventors Gerald J. Sussman and Guy Steele, and the authors of the world's best computer science book, \textit{Structure and Interpretation of Computer Programs}, Hal Abelson and Gerald J. Sussman with Julie Sussman, among many other heroes of computer science. -{\bf\em In the glory days of the MIT Logo Lab, we used to say, ``Logo is Lisp disguised as BASIC.'' Now, with its first class procedures, lexical scope, and first class continuations, \Snap{} is Scheme disguised as Scratch.} +\textbf{\emph{In the glory days of the MIT Logo Lab, we used to say, ``Logo is Lisp disguised as BASIC.'' Now, with its first class procedures, lexical scope, and first class continuations, \Snap{} is Scheme disguised as Scratch.}} We have been fortunate to get to know an amazing group of brilliant middle school (!\@) and high school students through the Scratch Advanced Topics forum, several of whom have contributed code to \Snap{}: Kartik Chandra, Nathan Dinsmore, Connor Hudson, and Ian Reynolds. Many more have contributed ideas and alpha-testing bug reports. UC Berkeley students who've contributed code include Michael Ball, Achal Dave, Kyle Hotchkiss, Ivan Motyashov, and Yuan Yuan. Contributors of translations are too numerous to list here, but they're in the ``About...'' box in \Snap{} itself. This work was supported in part by the National Science Foundation grant 1143566, and in part by MioSoft. diff --git a/help/manual/pl/snap-podrecznik.tex b/help/manual/pl/snap-podrecznik.tex index 1e2c78a..8da7eb0 100644 --- a/help/manual/pl/snap-podrecznik.tex +++ b/help/manual/pl/snap-podrecznik.tex @@ -22,11 +22,11 @@ Mieliśmy ogromne szczęście do mentorów. Jens zdobył dużo doświadczenia pracując wśród pionierów Smalltalka: Alana Kaya, Dana Ingallsa i reszty ekipy, która wynalazła komputery osobiste i programowanie obiektowe w najlepszych dniach firmy Xerox PARC. Pracował z Johnem Maloneyem z zespołu Scratcha w MIT\footnote{Massachusetts Institute of Technology, amerykańska uczelnia techniczna --- przyp. tłum.} , autorem platformy graficznej Morphic, wciąż stanowiącej fundament \Snap{a}. Znakomity projekt języka Scratch, autorstwa Lifelong Kindergarten Group z MIT Media Lab, odgrywa w \Snap{ie} kluczową rolę. -{\bf\em Nasza poprzednia wersja, BYOB, była bezpośrednią modyfikacją kodu źródłowego Scratcha. \Snap{} został napisany od zera, lecz struktura jego kodu oraz interfejs użytkownika pozostają mocno zakorzenione w Scratchu. Z kolei zespół Scratcha, który mógłby widzieć w nas rywali, przyjął nas ciepło i okazał nam całkowite wsparcie.} +\textbf{\emph{Nasza poprzednia wersja, BYOB, była bezpośrednią modyfikacją kodu źródłowego Scratcha. \Snap{} został napisany od zera, lecz struktura jego kodu oraz interfejs użytkownika pozostają mocno zakorzenione w Scratchu. Z kolei zespół Scratcha, który mógłby widzieć w nas rywali, przyjął nas ciepło i okazał nam całkowite wsparcie.}} Brian zdobywał szlify w MIT oraz Stanford Artificial Intelligence Labs\footnote{Laboratorium sztucznej inteligencji na Uniwersytecie Stanforda --- przyp. tłum.}, gdzie uczył się pod okiem Johna McCarthy'ego, twórcy Lispa, oraz Geralda J. Suss\-mana i Guya Steele'a, twórców języka Scheme. Zdobywał również wiedzę od wielu innych wybitnych informatyków, w tym autorów najlepszej książki z zakresu informatyki --- \emph{Struktury i interpretacji programów komputerowych}: Hala Abelsona, Geralda J. Suss\-mana i Julie Suss\-man. -{\bf\em Za starych dobrych czasów mawialiśmy w MIT Logo Lab: ,,Język Logo to Lisp w przebraniu BASIC-a''. Dziś, ze swoimi pierwszoklasowymi procedurami, zasięgami leksykalnymi i pierwszoklasowymi kontynuacjami, \Snap{} jest jak Scheme w przebraniu Scratcha.} +\textbf{\emph{Za starych dobrych czasów mawialiśmy w MIT Logo Lab: ,,Język Logo to Lisp w przebraniu BASIC-a''. Dziś, ze swoimi pierwszoklasowymi procedurami, zasięgami leksykalnymi i pierwszoklasowymi kontynuacjami, \Snap{} jest jak Scheme w przebraniu Scratcha.}} Szczęśliwym zrządzeniem losu, poprzez forum Scratch Advanced Topics, poznaliśmy wspaniałą grupę błyskotliwych uczniów gimnazjów (!\@) i liceów. Kilku z nich wniosło swój wkład w kod \Snap{a}: Kartik Chandra, Nathan Dinsmore, Connor Hudson i Ian Reynolds. Ponadto, wielu zgłosiło pomysły i raporty błędów podczas testowania wersji alfa. Wśród studentów Uniwersytetu Kalifornijskiego w Berkeley, którzy przyczynili się do rozwoju kodu, znajdują się Michael Ball, Achal Dave, Kyle Hotchkiss, Ivan Motyashov i Yuan Yuan. Wymienianie wszystkich tłumaczy zajeło by zbyt wiele miejsca, ale można ich odnaleźć w okienku ,,O Snap!...'' dostępnym w programie. Niniejsze dzieło powstało częściowo w ramach grantu nr 1143566 udzielonego przez National Science Foundation, a częściowo przy wsparciu firmy MioSoft. -- cgit v1.3.1 From ca05f779b645485d39df1642e75d9ad2e5066d22 Mon Sep 17 00:00:00 2001 From: Bartosz Leper Date: Wed, 24 Jun 2015 19:15:41 +0200 Subject: Finish translating introduction --- help/manual/en/snap-manual.tex | 4 +++- help/manual/pl/snap-podrecznik.tex | 8 ++++---- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/help/manual/en/snap-manual.tex b/help/manual/en/snap-manual.tex index fc1dfc7..f44b713 100644 --- a/help/manual/en/snap-manual.tex +++ b/help/manual/en/snap-manual.tex @@ -28,7 +28,9 @@ We have been fortunate to get to know an amazing group of brilliant middle schoo \begin{titlepage} \begin{center} -\bf \Huge \Snap{} Reference Manual \\ \huge Version 4.0 \vspace{40pt} +\bf \Huge \Snap{} Reference Manual \\ +\huge Version 4.0 +\vspace{40pt} \end{center} \Snap{} (formerly BYOB) is an extended reimplementation of Scratch (\url{http://scratch.mit.edu}) that allows you to Build Your Own Blocks. It also features first class lists, first class procedures, and continuations. These added capabilities make it suitable for a serious introduction to computer science for high school or college students. To run \Snap{}, open a browser window and connect to either \url{http://snap.berkeley.edu/run} to start with a minimal set of blocks or \url{http://snap.berkeley.edu/init} to load a small set of additional blocks (a little slower startup, but recommended for convenience and assumed in this manual). diff --git a/help/manual/pl/snap-podrecznik.tex b/help/manual/pl/snap-podrecznik.tex index 8da7eb0..8d74782 100644 --- a/help/manual/pl/snap-podrecznik.tex +++ b/help/manual/pl/snap-podrecznik.tex @@ -33,12 +33,12 @@ Szczęśliwym zrządzeniem losu, poprzez forum Scratch Advanced Topics, poznali \begin{titlepage} \begin{center} -\bf \Huge \Snap{} \\ Podręcznik użytkownika \\ \huge Wersja 4.0 \vspace{40pt} +\bf \Huge \Snap{} \\ +Podręcznik użytkownika \\ +\huge Wersja 4.0 \vspace{40pt} \end{center} -\Snap{} (dawniej BYOB) to rozszerzona reimplementacja języka Scratch (\url{http://scratch.mit.edu}), która pozwala na tworzenie własnych bloków (ang. \textit{Build Your Own Blocks}). - -\Snap{} (formerly BYOB) is an extended reimplementation of Scratch (\url{http://scratch.mit.edu}) that allows you to Build Your Own Blocks. It also features first class lists, first class procedures, and continuations. These added capabilities make it suitable for a serious introduction to computer science for high school or college students. To run \Snap{}, open a browser window and connect to either \url{http://snap.berkeley.edu/run} to start with a minimal set of blocks or \url{http://snap.berkeley.edu/init} to load a small set of additional blocks (a little slower startup, but recommended for convenience and assumed in this manual). +\Snap{} to rozszerzona reimplementacja języka Scratch (\url{http://scratch.mit.edu}), która pozwala na tworzenie własnych bloków (ang.\ \textit{Build Your Own Blocks}; stąd dawna nazwa \Snap{a} --- BYOB). Opisywany tu język obsługuje pierwszoklasowe listy, procedury i kontynuacje. Te dodatkowe możliwości sprawiają, że nadaje się on do przeprowadzenia poważnego wstępu do informatyki dla uczniów liceów i szkół wyższych. Aby uruchomić środowisko \Snap{}, wystarczy otworzyć przeglądarkę internetową i wpisać adres \url{http://snap.berkeley.edu/run}, aby zacząć pracę z minimalnym zestawem bloków. Można też użyć adresu \url{http://snap.berkeley.edu/init}, aby załadować niewielki zestaw dodatkowych bloków. Wiąże się to z nieco wolniejszym ładowaniem, ale jest zalecane dla wygody użytkowników (w dalszej części podręcznika będziemy zakładali korzystanie z tej właśnie metody). \end{titlepage} -- cgit v1.3.1 From ba062ac14843eb2dc747799c2a522e6622fd542b Mon Sep 17 00:00:00 2001 From: Bartosz Leper Date: Wed, 24 Jun 2015 19:46:59 +0200 Subject: Add TexStudio language comment --- help/manual/pl/snap-podrecznik.tex | 2 ++ 1 file changed, 2 insertions(+) diff --git a/help/manual/pl/snap-podrecznik.tex b/help/manual/pl/snap-podrecznik.tex index 8d74782..9de4094 100644 --- a/help/manual/pl/snap-podrecznik.tex +++ b/help/manual/pl/snap-podrecznik.tex @@ -1,3 +1,5 @@ +% !TeX spellcheck = pl_PL + \documentclass{report} \input{../common/defs.tex} -- cgit v1.3.1 From 029aaeb82708b67d1dd0b3e86e8980e5caa37b15 Mon Sep 17 00:00:00 2001 From: Bartosz Leper Date: Wed, 24 Jun 2015 20:09:22 +0200 Subject: Some non-breaking spaces and refs --- help/manual/en/snap-manual.tex | 5 +++-- help/manual/pl/snap-podrecznik.tex | 21 ++++++++++++--------- 2 files changed, 15 insertions(+), 11 deletions(-) diff --git a/help/manual/en/snap-manual.tex b/help/manual/en/snap-manual.tex index f44b713..b59e4e3 100644 --- a/help/manual/en/snap-manual.tex +++ b/help/manual/en/snap-manual.tex @@ -19,7 +19,7 @@ We have been extremely lucky in our mentors. Jens cut his teeth in the company o \textbf{\emph{Our earlier version, BYOB, was a direct modification of the Scratch source code. \Snap{} is a complete rewrite, but its code structure and its user interface remain deeply indebted to Scratch. And the Scratch Team, who could have seen us as rivals, have been entirely supportive and welcoming to us.}} -Brian grew up at the MIT and Stanford Artificial Intelligence Labs, learning from Lisp inventor John McCarthy, Scheme inventors Gerald J. Sussman and Guy Steele, and the authors of the world's best computer science book, \textit{Structure and Interpretation of Computer Programs}, Hal Abelson and Gerald J. Sussman with Julie Sussman, among many other heroes of computer science. +Brian grew up at the MIT and Stanford Artificial Intelligence Labs, learning from Lisp inventor John McCarthy, Scheme inventors Gerald~J. Sussman and Guy Steele, and the authors of the world's best computer science book, \textit{Structure and Interpretation of Computer Programs}, Hal Abelson and Gerald~J. Sussman with Julie Sussman, among many other heroes of computer science. \textbf{\emph{In the glory days of the MIT Logo Lab, we used to say, ``Logo is Lisp disguised as BASIC.'' Now, with its first class procedures, lexical scope, and first class continuations, \Snap{} is Scheme disguised as Scratch.}} @@ -39,7 +39,7 @@ We have been fortunate to get to know an amazing group of brilliant middle schoo \chapter{Blocks, Scripts, and Sprites} -This chapter describes the \Snap{} features inherited from Scratch; experienced Scratch users can skip to section B. +This chapter describes the \Snap{} features inherited from Scratch; experienced Scratch users can skip to section~\ref{sec:nesting-sprites}. \Snap{} is a programming language---a notation in which you can tell a computer what you want it to do. Unlike most programming languages, though, \Snap{} is a visual language; instead of writing a program using the keyboard, the \Snap{} programmer uses the same drag-and-drop interface familiar to computer users. @@ -79,6 +79,7 @@ Most command blocks have that brick shape, but some, like the \code{repeat} bloc \subsection{Costumes and Sounds} \subsection{Inter-Sprite Communication with Broadcast} \section{Nesting Sprites: Anchors and Parts} +\label{sec:nesting-sprites} \section{Reporter Blocks and Expressions} \section{Predicates and Conditional Evaluation} \section{Variables} diff --git a/help/manual/pl/snap-podrecznik.tex b/help/manual/pl/snap-podrecznik.tex index 9de4094..d8c1a76 100644 --- a/help/manual/pl/snap-podrecznik.tex +++ b/help/manual/pl/snap-podrecznik.tex @@ -1,4 +1,4 @@ -% !TeX spellcheck = pl_PL +% !TeX spellcheck = pl \documentclass{report} @@ -22,15 +22,15 @@ \chapter*{} \section*{Podziękowania} -Mieliśmy ogromne szczęście do mentorów. Jens zdobył dużo doświadczenia pracując wśród pionierów Smalltalka: Alana Kaya, Dana Ingallsa i reszty ekipy, która wynalazła komputery osobiste i programowanie obiektowe w najlepszych dniach firmy Xerox PARC. Pracował z Johnem Maloneyem z zespołu Scratcha w MIT\footnote{Massachusetts Institute of Technology, amerykańska uczelnia techniczna --- przyp. tłum.} , autorem platformy graficznej Morphic, wciąż stanowiącej fundament \Snap{a}. Znakomity projekt języka Scratch, autorstwa Lifelong Kindergarten Group z MIT Media Lab, odgrywa w \Snap{ie} kluczową rolę. +Mieliśmy ogromne szczęście do mentorów. Jens zdobył dużo doświadczenia pracując wśród pionierów Smalltalka: Alana Kaya, Dana Ingallsa i~reszty ekipy, która wynalazła komputery osobiste i~programowanie obiektowe w~najlepszych dniach firmy Xerox PARC. Pracował z~Johnem Maloneyem z~zespołu Scratcha w~MIT\footnote{Massachusetts Institute of Technology, amerykańska uczelnia techniczna --- przyp. tłum.}, autorem platformy graficznej Morphic, wciąż stanowiącej fundament \Snap{a}. Znakomity projekt języka Scratch, autorstwa Lifelong Kindergarten Group z~MIT Media Lab, odgrywa w~\Snap{ie} kluczową rolę. -\textbf{\emph{Nasza poprzednia wersja, BYOB, była bezpośrednią modyfikacją kodu źródłowego Scratcha. \Snap{} został napisany od zera, lecz struktura jego kodu oraz interfejs użytkownika pozostają mocno zakorzenione w Scratchu. Z kolei zespół Scratcha, który mógłby widzieć w nas rywali, przyjął nas ciepło i okazał nam całkowite wsparcie.}} +\textbf{\emph{Nasza poprzednia wersja, BYOB, była bezpośrednią modyfikacją kodu źródłowego Scratcha. \Snap{} został napisany od zera, lecz struktura jego kodu oraz interfejs użytkownika pozostają mocno zakorzenione w~Scratchu. Z~kolei zespół Scratcha, który mógłby widzieć w~nas rywali, przyjął nas ciepło i~okazał nam całkowite wsparcie.}} -Brian zdobywał szlify w MIT oraz Stanford Artificial Intelligence Labs\footnote{Laboratorium sztucznej inteligencji na Uniwersytecie Stanforda --- przyp. tłum.}, gdzie uczył się pod okiem Johna McCarthy'ego, twórcy Lispa, oraz Geralda J. Suss\-mana i Guya Steele'a, twórców języka Scheme. Zdobywał również wiedzę od wielu innych wybitnych informatyków, w tym autorów najlepszej książki z zakresu informatyki --- \emph{Struktury i interpretacji programów komputerowych}: Hala Abelsona, Geralda J. Suss\-mana i Julie Suss\-man. +Brian zdobywał szlify w~MIT oraz Stanford Artificial Intelligence Labs\footnote{Laboratorium sztucznej inteligencji na Uniwersytecie Stanforda --- przyp. tłum.}, gdzie uczył się pod okiem Johna McCarthy'ego, twórcy Lispa, oraz Geralda~J. Suss\-mana i~Guya Steele'a, twórców języka Scheme. Zdobywał również wiedzę od wielu innych wybitnych informatyków, w~tym autorów najlepszej książki z zakresu informatyki --- \emph{Struktury i~interpretacji programów komputerowych}: Hala Abelsona, Geralda~J. Suss\-mana i~Julie Suss\-man. -\textbf{\emph{Za starych dobrych czasów mawialiśmy w MIT Logo Lab: ,,Język Logo to Lisp w przebraniu BASIC-a''. Dziś, ze swoimi pierwszoklasowymi procedurami, zasięgami leksykalnymi i pierwszoklasowymi kontynuacjami, \Snap{} jest jak Scheme w przebraniu Scratcha.}} +\textbf{\emph{Za starych dobrych czasów mawialiśmy w~MIT Logo Lab: ,,Język Logo to Lisp w przebraniu BASIC-a''. Dziś, ze swoimi pierwszoklasowymi procedurami, zasięgami leksykalnymi~i pierwszoklasowymi kontynuacjami, \Snap{} jest jak Scheme w~przebraniu Scratcha.}} -Szczęśliwym zrządzeniem losu, poprzez forum Scratch Advanced Topics, poznaliśmy wspaniałą grupę błyskotliwych uczniów gimnazjów (!\@) i liceów. Kilku z nich wniosło swój wkład w kod \Snap{a}: Kartik Chandra, Nathan Dinsmore, Connor Hudson i Ian Reynolds. Ponadto, wielu zgłosiło pomysły i raporty błędów podczas testowania wersji alfa. Wśród studentów Uniwersytetu Kalifornijskiego w Berkeley, którzy przyczynili się do rozwoju kodu, znajdują się Michael Ball, Achal Dave, Kyle Hotchkiss, Ivan Motyashov i Yuan Yuan. Wymienianie wszystkich tłumaczy zajeło by zbyt wiele miejsca, ale można ich odnaleźć w okienku ,,O Snap!...'' dostępnym w programie. Niniejsze dzieło powstało częściowo w ramach grantu nr 1143566 udzielonego przez National Science Foundation, a częściowo przy wsparciu firmy MioSoft. +Szczęśliwym zrządzeniem losu, poprzez forum Scratch Advanced Topics, poznaliśmy wspaniałą grupę błyskotliwych uczniów gimnazjów~(!\@) i liceów. Kilku z nich wniosło swój wkład w~kod \Snap{a}: Kartik Chandra, Nathan Dinsmore, Connor Hudson i~Ian Reynolds. Ponadto, wielu zgłosiło pomysły i~raporty błędów podczas testowania wersji alfa. Wśród studentów Uniwersytetu Kalifornijskiego w~Berkeley, którzy przyczynili się do rozwoju kodu, znajdują się Michael Ball, Achal Dave, Kyle Hotchkiss, Ivan Motyashov i~Yuan Yuan. Wymienianie wszystkich tłumaczy zajęłoby zbyt wiele miejsca, ale można ich odnaleźć w~okienku ,,O Snap!...'' dostępnym w~programie. Niniejsze dzieło powstało częściowo w~ramach grantu nr~1143566 udzielonego przez National Science Foundation, a częściowo przy wsparciu firmy MioSoft. \begin{titlepage} @@ -40,11 +40,13 @@ Podręcznik użytkownika \\ \huge Wersja 4.0 \vspace{40pt} \end{center} -\Snap{} to rozszerzona reimplementacja języka Scratch (\url{http://scratch.mit.edu}), która pozwala na tworzenie własnych bloków (ang.\ \textit{Build Your Own Blocks}; stąd dawna nazwa \Snap{a} --- BYOB). Opisywany tu język obsługuje pierwszoklasowe listy, procedury i kontynuacje. Te dodatkowe możliwości sprawiają, że nadaje się on do przeprowadzenia poważnego wstępu do informatyki dla uczniów liceów i szkół wyższych. Aby uruchomić środowisko \Snap{}, wystarczy otworzyć przeglądarkę internetową i wpisać adres \url{http://snap.berkeley.edu/run}, aby zacząć pracę z minimalnym zestawem bloków. Można też użyć adresu \url{http://snap.berkeley.edu/init}, aby załadować niewielki zestaw dodatkowych bloków. Wiąże się to z nieco wolniejszym ładowaniem, ale jest zalecane dla wygody użytkowników (w dalszej części podręcznika będziemy zakładali korzystanie z tej właśnie metody). +\Snap{} to rozszerzona reimplementacja języka Scratch (\url{http://scratch.mit.edu}), która pozwala na tworzenie własnych bloków (ang.\ \textit{Build Your Own Blocks}; stąd dawna nazwa \Snap{a} --- BYOB). Opisywany tu język obsługuje pierwszoklasowe listy, procedury i~kontynuacje. Te dodatkowe możliwości sprawiają, że nadaje się on do przeprowadzenia poważnego wstępu do informatyki dla uczniów liceów i szkół wyższych. Aby uruchomić środowisko \Snap{}, wystarczy otworzyć przeglądarkę internetową i~wpisać adres \url{http://snap.berkeley.edu/run}, aby zacząć pracę z~minimalnym zestawem bloków. Można też użyć adresu \url{http://snap.berkeley.edu/init}, aby załadować niewielki zestaw dodatkowych bloków. Wiąże się to z~nieco wolniejszym ładowaniem, ale jest zalecane dla wygody użytkowników (w~dalszej części podręcznika będziemy zakładali korzystanie z~tej właśnie metody). \end{titlepage} -\chapter{Blocks, Scripts, and Sprites} +\chapter{Bloki, skrypty i duszki} + +W~tym rozdziale poznamy kilka cech języka \Snap{} odziedziczonych po Scratchu; doświadczeni użytkownicy Scratcha powinni przejść od razu do sekcji~\ref{sec:zagnieżdżanie-duszków}. This chapter describes the \Snap{} features inherited from Scratch; experienced Scratch users can skip to section B. @@ -85,7 +87,8 @@ Most command blocks have that brick shape, but some, like the \code{repeat} bloc \section{Sprites and Parallelism} \subsection{Costumes and Sounds} \subsection{Inter-Sprite Communication with Broadcast} -\section{Nesting Sprites: Anchors and Parts} +\section{Zagnieżdżanie duszków: kotwice i części} +\label{sec:zagnieżdżanie-duszków} \section{Reporter Blocks and Expressions} \section{Predicates and Conditional Evaluation} \section{Variables} -- cgit v1.3.1 From 809e1a4673a275ed2adebb3e1b30610654585d98 Mon Sep 17 00:00:00 2001 From: Bartosz Leper Date: Thu, 25 Jun 2015 09:50:52 +0200 Subject: Don't treat the exclamation point in Snap logo as sentence-ending character --- help/manual/common/defs.tex | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/help/manual/common/defs.tex b/help/manual/common/defs.tex index 50f0c24..52fe21d 100644 --- a/help/manual/common/defs.tex +++ b/help/manual/common/defs.tex @@ -13,7 +13,7 @@ \newcommand{\Snap}[1]{% \textsf{% Snap% - \ifx\\#1\\\textit{!}% + \ifx\\#1\\\textit{!\@}% \else #1% \fi% }% -- cgit v1.3.1 From 2f0d52d7dbf0a962a986df6226ad3ded58480ab0 Mon Sep 17 00:00:00 2001 From: Bartosz Leper Date: Thu, 25 Jun 2015 12:03:26 +0200 Subject: Don't use Cabin; it doesn't have Polish characters. --- help/manual/common/defs.tex | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/help/manual/common/defs.tex b/help/manual/common/defs.tex index 52fe21d..d086975 100644 --- a/help/manual/common/defs.tex +++ b/help/manual/common/defs.tex @@ -1,7 +1,6 @@ -\usepackage{baskervald} % Default font -\usepackage{cabin} % Sans serif font \usepackage[T1]{fontenc} \usepackage[utf8]{inputenc} +\usepackage{baskervald} % Default font \usepackage{setspace} \onehalfspacing \usepackage{graphicx} \usepackage{textcomp} @@ -36,4 +35,4 @@ \begin{center} \includegraphics[scale=\defaultGraphicsScale]{#1} \end{center} -} \ No newline at end of file +} -- cgit v1.3.1 From f39b274fdee8c0a50362945c12bcf2fadd326aeb Mon Sep 17 00:00:00 2001 From: Bartosz Leper Date: Thu, 25 Jun 2015 23:30:38 +0200 Subject: Translated until section A of chapter I --- help/manual/en/snap-manual.tex | 3 ++- help/manual/pl/snap-podrecznik.tex | 29 ++++++++++++++--------------- 2 files changed, 16 insertions(+), 16 deletions(-) diff --git a/help/manual/en/snap-manual.tex b/help/manual/en/snap-manual.tex index b59e4e3..140e552 100644 --- a/help/manual/en/snap-manual.tex +++ b/help/manual/en/snap-manual.tex @@ -53,6 +53,7 @@ Start \Snap{}. You should see the following arrangement of regions in the window A \Snap{} program consists of one or more \emph{scripts}, each of which is made of \emph{blocks}. Here's a typical script: +\label{fig:typical-script} \bigpic{typical-script} The five blocks that make up this script have three different colors, corresponding to three of the eight \emph{palettes} in which blocks can be found. The palette area at the left edge of the window shows one palette at a time, chosen with the eight buttons just above the palette area. In this script, the gold blocks are from the Control palette; the green block is from the Pen palette; and the blue blocks are from the Motion palette. A script is assembled by dragging blocks from a palette into the \emph{scripting area} in the middle part of the window. Blocks snap together (hence the name \Snap{} for the language) when you drag a block so that its indentation is near the tab of the one above it: @@ -67,7 +68,7 @@ At the top of the script is a \emph{hat} block, which indicates when the script The other blocks in this script are \emph{command} blocks. Each command block corresponds to an action that \Snap{} already knows how to carry out. For example, the block \inlinepic{move-10-steps} tells the sprite (the arrowhead shape on the \emph{stage} at the right end of the window) to move ten steps (a step is a very small unit of distance) in the direction in which the arrowhead is pointing. We'll see shortly that there can be more than one sprite, and that each sprite has its own scripts. Also, a sprite doesn't have to look like an arrowhead, but can have any picture as a costume. The shape of the \code{move} block is meant to remind you of a Lego\texttrademark{} brick; a script is a stack of blocks. (The word ``block'' denotes both the graphical shape on the screen and the procedure, the action, that the block carries out.) -The number 10 in the \code{move} block above is called an \emph{input} to the block. By clicking on the white oval, you can type any number in place of the 10. The sample script on the previous page uses 100 as the input value. We'll see later that inputs can have non-oval shapes that accept values other than numbers. We'll also see that you can compute input values, instead of typing a particular value into the oval. A block can have more than one input slot. For example, the \code{glide} block located about halfway down the Motion palette has three inputs. +The number~10 in the \code{move} block above is called an \emph{input} to the block. By clicking on the white oval, you can type any number in place of the 10. The sample script on page~\pageref{fig:typical-script} uses 100 as the input value. We'll see later that inputs can have non-oval shapes that accept values other than numbers. We'll also see that you can compute input values, instead of typing a particular value into the oval. A block can have more than one input slot. For example, the \code{glide} block located about halfway down the Motion palette has three inputs. Most command blocks have that brick shape, but some, like the \code{repeat} block in the sample script, are \emph{C-shaped}. Most C-shaped blocks are found in the Control palette. The slot inside the C shape is a special kind of input slot that accepts a \emph{script} as the input. In the sample script, the \code{repeat} block has two inputs: the number 4 and the script diff --git a/help/manual/pl/snap-podrecznik.tex b/help/manual/pl/snap-podrecznik.tex index d8c1a76..0e0cb16 100644 --- a/help/manual/pl/snap-podrecznik.tex +++ b/help/manual/pl/snap-podrecznik.tex @@ -30,7 +30,7 @@ Brian zdobywał szlify w~MIT oraz Stanford Artificial Intelligence Labs\footnote \textbf{\emph{Za starych dobrych czasów mawialiśmy w~MIT Logo Lab: ,,Język Logo to Lisp w przebraniu BASIC-a''. Dziś, ze swoimi pierwszoklasowymi procedurami, zasięgami leksykalnymi~i pierwszoklasowymi kontynuacjami, \Snap{} jest jak Scheme w~przebraniu Scratcha.}} -Szczęśliwym zrządzeniem losu, poprzez forum Scratch Advanced Topics, poznaliśmy wspaniałą grupę błyskotliwych uczniów gimnazjów~(!\@) i liceów. Kilku z nich wniosło swój wkład w~kod \Snap{a}: Kartik Chandra, Nathan Dinsmore, Connor Hudson i~Ian Reynolds. Ponadto, wielu zgłosiło pomysły i~raporty błędów podczas testowania wersji alfa. Wśród studentów Uniwersytetu Kalifornijskiego w~Berkeley, którzy przyczynili się do rozwoju kodu, znajdują się Michael Ball, Achal Dave, Kyle Hotchkiss, Ivan Motyashov i~Yuan Yuan. Wymienianie wszystkich tłumaczy zajęłoby zbyt wiele miejsca, ale można ich odnaleźć w~okienku ,,O Snap!...'' dostępnym w~programie. Niniejsze dzieło powstało częściowo w~ramach grantu nr~1143566 udzielonego przez National Science Foundation, a częściowo przy wsparciu firmy MioSoft. +Szczęśliwym zrządzeniem losu, poprzez forum Scratch Advanced Topics, poznaliśmy wspaniałą grupę błyskotliwych uczniów gimnazjów~(!\@) i liceów. Kilku z nich wniosło swój wkład w~kod \Snap{a}: Kartik Chandra, Nathan Dinsmore, Connor Hudson i~Ian Reynolds. Ponadto wielu zgłosiło pomysły i~raporty błędów podczas testowania wersji alfa. Wśród studentów Uniwersytetu Kalifornijskiego w~Berkeley, którzy przyczynili się do rozwoju kodu, znajdują się Michael Ball, Achal Dave, Kyle Hotchkiss, Ivan Motyashov i~Yuan Yuan. Wymienianie wszystkich tłumaczy zajęłoby zbyt wiele miejsca, ale można ich odnaleźć w~okienku ,,O Snap!...'' dostępnym w~programie. Niniejsze dzieło powstało częściowo w~ramach grantu nr~1143566 udzielonego przez National Science Foundation, a częściowo przy wsparciu firmy MioSoft. \begin{titlepage} @@ -46,39 +46,38 @@ Podręcznik użytkownika \\ \chapter{Bloki, skrypty i duszki} -W~tym rozdziale poznamy kilka cech języka \Snap{} odziedziczonych po Scratchu; doświadczeni użytkownicy Scratcha powinni przejść od razu do sekcji~\ref{sec:zagnieżdżanie-duszków}. +W~tym rozdziale poznamy kilka cech języka \Snap{} odziedziczonych po Scratchu; doświadczeni użytkownicy Scratcha mogą przejść od razu do sekcji~\ref{sec:zagnieżdżanie-duszków}. -This chapter describes the \Snap{} features inherited from Scratch; experienced Scratch users can skip to section B. +\Snap{} jest językiem programowania --- notacją, przy pomocy której możemy powiedzieć komputerowi, co ma zrobić. Jednak w~odróżnieniu od większości innych, \Snap{} jest językiem wizualnym; programując w~nim, zamiast posługiwać się klawiaturą, używamy metody ,,przeciągnij i~upuść'', dobrze znanej użytkownikom komputerów. -\Snap{} is a programming language---a notation in which you can tell a computer what you want it to do. Unlike most programming languages, though, \Snap{} is a visual language; instead of writing a program using the keyboard, the \Snap{} programmer uses the same drag-and-drop interface familiar to computer users. - -Start \Snap{}. You should see the following arrangement of regions in the window: +Uruchom teraz środowisko \Snap{}. Powinieneś zobaczyć ekran podzielony na kilka obszarów: \begin{center} \includegraphics[width=\textwidth]{window-regions} \end{center} -(The proportions of these areas may be different, depending on the size and shape of your browser window.) +(Proporcje tych stref mogą się różnić, w~zależności od rozmiaru i~kształtu okna przeglądarki.) -A \Snap{} program consists of one or more \emph{scripts}, each of which is made of \emph{blocks}. Here's a typical script: +Program w~języku \Snap{} składa się z~jednego lub więcej \emph{skryptów}, te zaś z~kolei --- z~\emph{bloków}. Oto przykładowy skrypt: +\label{fig:typical-script} \bigpic{typical-script} -The five blocks that make up this script have three different colors, corresponding to three of the eight \emph{palettes} in which blocks can be found. The palette area at the left edge of the window shows one palette at a time, chosen with the eight buttons just above the palette area. In this script, the gold blocks are from the Control palette; the green block is from the Pen palette; and the blue blocks are from the Motion palette. A script is assembled by dragging blocks from a palette into the \emph{scripting area} in the middle part of the window. Blocks snap together (hence the name \Snap{} for the language) when you drag a block so that its indentation is near the tab of the one above it: +Na powyższy skrypt składa się pięć bloków w~trzech różnych kolorach, odpowiadających trzem z~ośmiu \emph{palet} z~blokami. Obszar palet, znajdujący się po lewej stronie okna, pokazuje jedną paletę na raz. Do zmiany widocznej palety służy osiem przycisków znajdujących się tuż nad tym obszarem. Bloki ciemnożółte, widoczne w~naszym skrypcie, pochodzą z~palety Kontrola; zielone z~palety Pisak, a~niebieskie --- z~palety Ruch. Aby złożyć taki skrypt, należy poprzeciągać odpowiednie bloki z~palet do \emph{obszaru skryptu}, umiejscowionego na środku okna. Kiedy układamy jeden blok pod drugim w~taki sposób, aby wcięcie dolnego bloku znalazło się w~pobliżu wypustki tego powyżej, bloki łączą się ze sobą (ang. \textit{snap together}; stąd nazwa języka \Snap{}): \bigpic{snapping-blocks} -The white horizontal line is a signal that if you let go of the green block it will snap into the tab of the gold one. +Pozioma biała linia sygnalizuje, że jeśli puścimy zielony blok, połączy się on z~wypustką ciemnożółtego. -\subsection{Hat Blocks and Command Blocks} +\subsection{Bloki-czapki i bloki poleceń} -At the top of the script is a \emph{hat} block, which indicates when the script should be carried out. Hat block names typically start with the word ``\code{when}''; in this example, the script should be run when the green flag near the right end of the \Snap{} tool bar is clicked. (The \Snap{} tool bar is part of the \Snap{} window, not the same as the browser's or operating system's menu bar.) A script isn't required to have a hat block, but if not, then the script will be run only if the user clicks on the script itself. A script can't have more than one hat block, and the hat block can be used only at the top of the script; its distinctive shape is meant to remind you of that. +Na górze skryptu znajduje się \emph{blok-czapka}, który określa, kiedy skrypt ma zostać wykonany. Nazwy bloków-czapek zazwyczaj zaczynają się słowem ,,\code{kiedy}''; nasz przykładowy skrypt powinien zostać uruchomiony w~momencie kliknięcia zielonej flagi, znajdującej się w pobliżu prawej strony paska narzędzi \Snap{a}. (Pasek ten jest częścią okna programu \Snap{}; nie chodzi tutaj o pasek menu przeglądarki lub systemu operacyjnego.) Skrypt nie musi posiadać czapki, jednak w~takim przypadku zostanie wykonany tylko wtedy, gdy użytkownik sam go kliknie. Skrypt nie może mieć więcej niż jednej czapki; jej charakterystyczny kształt służy łatwiejszemu zapamiętaniu tej szczególnej własności. -The other blocks in this script are \emph{command} blocks. Each command block corresponds to an action that \Snap{} already knows how to carry out. For example, the block \inlinepic{move-10-steps} tells the sprite (the arrowhead shape on the \emph{stage} at the right end of the window) to move ten steps (a step is a very small unit of distance) in the direction in which the arrowhead is pointing. We'll see shortly that there can be more than one sprite, and that each sprite has its own scripts. Also, a sprite doesn't have to look like an arrowhead, but can have any picture as a costume. The shape of the \code{move} block is meant to remind you of a Lego\texttrademark{} brick; a script is a stack of blocks. (The word ``block'' denotes both the graphical shape on the screen and the procedure, the action, that the block carries out.) +Pozostałe bloki w naszym skrypcie to \emph{bloki poleceń}. Każdy z~nich oznacza jakąś akcję, którą \Snap{} potrafi wykonać. Na przykład blok \inlinepic{move-10-steps} nakazuje duszkowi\footnote{W grafice komputerowej słowem ,,duszek'' (ang. \textit{sprite}) nazywa się ruchomy obiekt na ekranie --- przyp. tłum.}, czyli strzałce na \emph{scenie} po prawej stronie okna, aby przesunął się o~dziesięć kroków do przodu w~kierunku, w~którym jest zwrócony. Każdy krok to niewielka odległość na ekranie. Wkrótce przekonamy się, że na scenie może być więcej duszków, a~każdy z nich może mieć własne skrypty. Ponadto duszki nie muszą wyglądać jak strzałki; ich kostiumy mogą być dowolnymi obrazkami. Kształt bloku \code{przesuń} ma za zadanie przypominać klocek, skrypt zaś jest jak wieża z klocków. Słowa ,,blok'' będziemy używać dla oznaczenia zarówno graficznego symbolu na ekranie, jak i~procedury (akcji) jaką ten blok wykonuje. -The number 10 in the \code{move} block above is called an \emph{input} to the block. By clicking on the white oval, you can type any number in place of the 10. The sample script on the previous page uses 100 as the input value. We'll see later that inputs can have non-oval shapes that accept values other than numbers. We'll also see that you can compute input values, instead of typing a particular value into the oval. A block can have more than one input slot. For example, the \code{glide} block located about halfway down the Motion palette has three inputs. +Liczbę 10 w powyższym bloku \code{przesuń} nazywamy jego \emph{parametrem}. Kliknąwszy na białym, zaokrąglonym polu, możemy wpisać w~jej miejsce dowolną inną. W przykładowym skrypcie ze strony \pageref{fig:typical-script} parametrem jest liczba 100. Jak się później okaże, pola parametrów mogą mieć kształty inne od zaokrąglonych; oznacza to wtedy, że akceptują one wartości inne niż liczby. Zobaczymy również, że zamiast wpisywać konkretne wartości w~pola, możemy nakazać komputerowi je obliczać. Ponadto blok może mieć więcej niż jeden parametr. Na przykład blok \code{leć}, znajdujący się mniej więcej w~połowie palety Ruch, przyjmuje trzy parametry. -Most command blocks have that brick shape, but some, like the \code{repeat} block in the sample script, are \emph{C-shaped}. Most C-shaped blocks are found in the Control palette. The slot inside the C shape is a special kind of input slot that accepts a \emph{script} as the input. In the sample script, the \code{repeat} block has two inputs: the number 4 and the script +Większość bloków poleceń ma kształt klocków, lecz niektóre, jak \code{powtórz} z~tego samego przykładu, wyglądają jak \emph{klamry}. Większość bloków klamrowych można znaleźć na palecie Kontrola. Wnętrze klamry jest szczególnym rodzajem pola parametru, który przyjmuje \emph{skrypt} jako parametr. W przykładowym skrypcie blok \code{powtórz} ma dwa parametry: liczbę 4 oraz skrypt \bigpic{typical-script-inner} -- cgit v1.3.1 From 7c3d3decdb296acb5d821360f25026ece694458b Mon Sep 17 00:00:00 2001 From: Bartosz Leper Date: Thu, 25 Jun 2015 23:31:12 +0200 Subject: W --- help/manual/pl/snap-podrecznik.tex | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/help/manual/pl/snap-podrecznik.tex b/help/manual/pl/snap-podrecznik.tex index 0e0cb16..03675dd 100644 --- a/help/manual/pl/snap-podrecznik.tex +++ b/help/manual/pl/snap-podrecznik.tex @@ -77,7 +77,7 @@ Pozostałe bloki w naszym skrypcie to \emph{bloki poleceń}. Każdy z~nich oznac Liczbę 10 w powyższym bloku \code{przesuń} nazywamy jego \emph{parametrem}. Kliknąwszy na białym, zaokrąglonym polu, możemy wpisać w~jej miejsce dowolną inną. W przykładowym skrypcie ze strony \pageref{fig:typical-script} parametrem jest liczba 100. Jak się później okaże, pola parametrów mogą mieć kształty inne od zaokrąglonych; oznacza to wtedy, że akceptują one wartości inne niż liczby. Zobaczymy również, że zamiast wpisywać konkretne wartości w~pola, możemy nakazać komputerowi je obliczać. Ponadto blok może mieć więcej niż jeden parametr. Na przykład blok \code{leć}, znajdujący się mniej więcej w~połowie palety Ruch, przyjmuje trzy parametry. -Większość bloków poleceń ma kształt klocków, lecz niektóre, jak \code{powtórz} z~tego samego przykładu, wyglądają jak \emph{klamry}. Większość bloków klamrowych można znaleźć na palecie Kontrola. Wnętrze klamry jest szczególnym rodzajem pola parametru, który przyjmuje \emph{skrypt} jako parametr. W przykładowym skrypcie blok \code{powtórz} ma dwa parametry: liczbę 4 oraz skrypt +Większość bloków poleceń ma kształt klocków, lecz niektóre, jak \code{powtórz} z~tego samego przykładu, wyglądają jak \emph{klamry}. Większość bloków klamrowych można znaleźć na palecie Kontrola. Wnętrze klamry jest szczególnym rodzajem pola parametru, który przyjmuje \emph{skrypt} jako parametr. W~przykładowym skrypcie blok \code{powtórz} ma dwa parametry: liczbę 4 oraz skrypt \bigpic{typical-script-inner} -- cgit v1.3.1 From 58187d0c67ebaddb4297edbe1b4b107d01f9f901 Mon Sep 17 00:00:00 2001 From: Bartosz Leper Date: Thu, 25 Jun 2015 23:36:29 +0200 Subject: Fix page numbering --- help/manual/en/snap-manual.tex | 4 ++-- help/manual/pl/snap-podrecznik.tex | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/help/manual/en/snap-manual.tex b/help/manual/en/snap-manual.tex index 140e552..036ad1e 100644 --- a/help/manual/en/snap-manual.tex +++ b/help/manual/en/snap-manual.tex @@ -25,7 +25,7 @@ Brian grew up at the MIT and Stanford Artificial Intelligence Labs, learning fro We have been fortunate to get to know an amazing group of brilliant middle school (!\@) and high school students through the Scratch Advanced Topics forum, several of whom have contributed code to \Snap{}: Kartik Chandra, Nathan Dinsmore, Connor Hudson, and Ian Reynolds. Many more have contributed ideas and alpha-testing bug reports. UC Berkeley students who've contributed code include Michael Ball, Achal Dave, Kyle Hotchkiss, Ivan Motyashov, and Yuan Yuan. Contributors of translations are too numerous to list here, but they're in the ``About...'' box in \Snap{} itself. This work was supported in part by the National Science Foundation grant 1143566, and in part by MioSoft. -\begin{titlepage} +\clearpage \begin{center} \bf \Huge \Snap{} Reference Manual \\ @@ -35,7 +35,7 @@ We have been fortunate to get to know an amazing group of brilliant middle schoo \Snap{} (formerly BYOB) is an extended reimplementation of Scratch (\url{http://scratch.mit.edu}) that allows you to Build Your Own Blocks. It also features first class lists, first class procedures, and continuations. These added capabilities make it suitable for a serious introduction to computer science for high school or college students. To run \Snap{}, open a browser window and connect to either \url{http://snap.berkeley.edu/run} to start with a minimal set of blocks or \url{http://snap.berkeley.edu/init} to load a small set of additional blocks (a little slower startup, but recommended for convenience and assumed in this manual). -\end{titlepage} +\clearpage \chapter{Blocks, Scripts, and Sprites} diff --git a/help/manual/pl/snap-podrecznik.tex b/help/manual/pl/snap-podrecznik.tex index 03675dd..2ab21cd 100644 --- a/help/manual/pl/snap-podrecznik.tex +++ b/help/manual/pl/snap-podrecznik.tex @@ -32,7 +32,7 @@ Brian zdobywał szlify w~MIT oraz Stanford Artificial Intelligence Labs\footnote Szczęśliwym zrządzeniem losu, poprzez forum Scratch Advanced Topics, poznaliśmy wspaniałą grupę błyskotliwych uczniów gimnazjów~(!\@) i liceów. Kilku z nich wniosło swój wkład w~kod \Snap{a}: Kartik Chandra, Nathan Dinsmore, Connor Hudson i~Ian Reynolds. Ponadto wielu zgłosiło pomysły i~raporty błędów podczas testowania wersji alfa. Wśród studentów Uniwersytetu Kalifornijskiego w~Berkeley, którzy przyczynili się do rozwoju kodu, znajdują się Michael Ball, Achal Dave, Kyle Hotchkiss, Ivan Motyashov i~Yuan Yuan. Wymienianie wszystkich tłumaczy zajęłoby zbyt wiele miejsca, ale można ich odnaleźć w~okienku ,,O Snap!...'' dostępnym w~programie. Niniejsze dzieło powstało częściowo w~ramach grantu nr~1143566 udzielonego przez National Science Foundation, a częściowo przy wsparciu firmy MioSoft. -\begin{titlepage} +\clearpage \begin{center} \bf \Huge \Snap{} \\ @@ -42,7 +42,7 @@ Podręcznik użytkownika \\ \Snap{} to rozszerzona reimplementacja języka Scratch (\url{http://scratch.mit.edu}), która pozwala na tworzenie własnych bloków (ang.\ \textit{Build Your Own Blocks}; stąd dawna nazwa \Snap{a} --- BYOB). Opisywany tu język obsługuje pierwszoklasowe listy, procedury i~kontynuacje. Te dodatkowe możliwości sprawiają, że nadaje się on do przeprowadzenia poważnego wstępu do informatyki dla uczniów liceów i szkół wyższych. Aby uruchomić środowisko \Snap{}, wystarczy otworzyć przeglądarkę internetową i~wpisać adres \url{http://snap.berkeley.edu/run}, aby zacząć pracę z~minimalnym zestawem bloków. Można też użyć adresu \url{http://snap.berkeley.edu/init}, aby załadować niewielki zestaw dodatkowych bloków. Wiąże się to z~nieco wolniejszym ładowaniem, ale jest zalecane dla wygody użytkowników (w~dalszej części podręcznika będziemy zakładali korzystanie z~tej właśnie metody). -\end{titlepage} +\clearpage \chapter{Bloki, skrypty i duszki} -- cgit v1.3.1 From f35e6f1922dff2f5afb3333708bb9fcb08ae4749 Mon Sep 17 00:00:00 2001 From: Bartosz Leper Date: Fri, 26 Jun 2015 01:36:34 +0200 Subject: Polish version of the widnow regions drawing --- help/manual/.gitignore | 3 +- help/manual/common/defs.tex | 1 + help/manual/pl/obszary-okna.pdf | Bin 0 -> 65091 bytes help/manual/pl/obszary-okna.pdf_tex | 59 ++ help/manual/pl/obszary-okna.svg | 1388 +++++++++++++++++++++++++++++++++++ help/manual/pl/snap-podrecznik.tex | 5 +- help/manual/pl/window-regions.png | Bin 142052 -> 0 bytes 7 files changed, 1453 insertions(+), 3 deletions(-) create mode 100644 help/manual/pl/obszary-okna.pdf create mode 100644 help/manual/pl/obszary-okna.pdf_tex create mode 100644 help/manual/pl/obszary-okna.svg delete mode 100644 help/manual/pl/window-regions.png diff --git a/help/manual/.gitignore b/help/manual/.gitignore index a0bdfac..cb5f3c2 100644 --- a/help/manual/.gitignore +++ b/help/manual/.gitignore @@ -2,5 +2,6 @@ *.log *.out *.toc -*.pdf +en/snap-manual.pdf +pl/snap-podrecznik.pdf *.synctex.gz diff --git a/help/manual/common/defs.tex b/help/manual/common/defs.tex index d086975..bb4d785 100644 --- a/help/manual/common/defs.tex +++ b/help/manual/common/defs.tex @@ -3,6 +3,7 @@ \usepackage{baskervald} % Default font \usepackage{setspace} \onehalfspacing \usepackage{graphicx} +\usepackage{color} \usepackage{textcomp} \usepackage{hyperref} diff --git a/help/manual/pl/obszary-okna.pdf b/help/manual/pl/obszary-okna.pdf new file mode 100644 index 0000000..d4e5800 Binary files /dev/null and b/help/manual/pl/obszary-okna.pdf differ diff --git a/help/manual/pl/obszary-okna.pdf_tex b/help/manual/pl/obszary-okna.pdf_tex new file mode 100644 index 0000000..6fc4bdf --- /dev/null +++ b/help/manual/pl/obszary-okna.pdf_tex @@ -0,0 +1,59 @@ +%% Creator: Inkscape inkscape 0.48.4, www.inkscape.org +%% PDF/EPS/PS + LaTeX output extension by Johan Engelen, 2010 +%% Accompanies image file 'obszary-okna.pdf' (pdf, eps, ps) +%% +%% To include the image in your LaTeX document, write +%% \input{.pdf_tex} +%% instead of +%% \includegraphics{.pdf} +%% To scale the image, write +%% \def\svgwidth{} +%% \input{.pdf_tex} +%% instead of +%% \includegraphics[width=]{.pdf} +%% +%% Images with a different path to the parent latex file can +%% be accessed with the `import' package (which may need to be +%% installed) using +%% \usepackage{import} +%% in the preamble, and then including the image with +%% \import{}{.pdf_tex} +%% Alternatively, one can specify +%% \graphicspath{{/}} +%% +%% For more information, please see info/svg-inkscape on CTAN: +%% http://tug.ctan.org/tex-archive/info/svg-inkscape +%% +\begingroup% + \makeatletter% + \providecommand\color[2][]{% + \errmessage{(Inkscape) Color is used for the text in Inkscape, but the package 'color.sty' is not loaded}% + \renewcommand\color[2][]{}% + }% + \providecommand\transparent[1]{% + \errmessage{(Inkscape) Transparency is used (non-zero) for the text in Inkscape, but the package 'transparent.sty' is not loaded}% + \renewcommand\transparent[1]{}% + }% + \providecommand\rotatebox[2]{#2}% + \ifx\svgwidth\undefined% + \setlength{\unitlength}{855.2bp}% + \ifx\svgscale\undefined% + \relax% + \else% + \setlength{\unitlength}{\unitlength * \real{\svgscale}}% + \fi% + \else% + \setlength{\unitlength}{\svgwidth}% + \fi% + \global\let\svgwidth\undefined% + \global\let\svgscale\undefined% + \makeatother% + \begin{picture}(1,0.60243218)% + \put(0,0){\includegraphics[width=\unitlength]{obszary-okna.pdf}}% + \put(0.37031041,0.03597468){\color[rgb]{1,0,0}\makebox(0,0)[b]{\smash{\emph{\Large Obszar skryptów}}}}% + \put(0.42733084,0.57941921){\color[rgb]{1,0,0}\makebox(0,0)[b]{\smash{\emph{\small Pasek narzędzi}}}}% + \put(0.77489765,0.03597473){\color[rgb]{1,0,0}\makebox(0,0)[b]{\smash{\emph{\Large Zagroda duszków}}}}% + \put(0.09676227,0.03597473){\color[rgb]{1,0,0}\makebox(0,0)[b]{\smash{\emph{\Large Paleta}}}}% + \put(0.77708296,0.27919271){\color[rgb]{1,0,0}\makebox(0,0)[b]{\smash{\emph{\Large Scena}}}}% + \end{picture}% +\endgroup% diff --git a/help/manual/pl/obszary-okna.svg b/help/manual/pl/obszary-okna.svg new file mode 100644 index 0000000..f593e27 --- /dev/null +++ b/help/manual/pl/obszary-okna.svg @@ -0,0 +1,1388 @@ + + + + + + + + + + image/svg+xml + + + + + + + + + \emph{\Large Obszar skryptów} + \emph{\small Pasek narzędzi} + + + + + \emph{\Large Zagroda duszków} + \emph{\Large Paleta} + \emph{\Large Scena} + + diff --git a/help/manual/pl/snap-podrecznik.tex b/help/manual/pl/snap-podrecznik.tex index 2ab21cd..121ec9c 100644 --- a/help/manual/pl/snap-podrecznik.tex +++ b/help/manual/pl/snap-podrecznik.tex @@ -53,7 +53,8 @@ W~tym rozdziale poznamy kilka cech języka \Snap{} odziedziczonych po Scratchu; Uruchom teraz środowisko \Snap{}. Powinieneś zobaczyć ekran podzielony na kilka obszarów: \begin{center} -\includegraphics[width=\textwidth]{window-regions} +\def\svgwidth{\textwidth} +\input{obszary-okna.pdf_tex} \end{center} (Proporcje tych stref mogą się różnić, w~zależności od rozmiaru i~kształtu okna przeglądarki.) @@ -63,7 +64,7 @@ Program w~języku \Snap{} składa się z~jednego lub więcej \emph{skryptów}, t \label{fig:typical-script} \bigpic{typical-script} -Na powyższy skrypt składa się pięć bloków w~trzech różnych kolorach, odpowiadających trzem z~ośmiu \emph{palet} z~blokami. Obszar palet, znajdujący się po lewej stronie okna, pokazuje jedną paletę na raz. Do zmiany widocznej palety służy osiem przycisków znajdujących się tuż nad tym obszarem. Bloki ciemnożółte, widoczne w~naszym skrypcie, pochodzą z~palety Kontrola; zielone z~palety Pisak, a~niebieskie --- z~palety Ruch. Aby złożyć taki skrypt, należy poprzeciągać odpowiednie bloki z~palet do \emph{obszaru skryptu}, umiejscowionego na środku okna. Kiedy układamy jeden blok pod drugim w~taki sposób, aby wcięcie dolnego bloku znalazło się w~pobliżu wypustki tego powyżej, bloki łączą się ze sobą (ang. \textit{snap together}; stąd nazwa języka \Snap{}): +Na powyższy skrypt składa się pięć bloków w~trzech różnych kolorach, odpowiadających trzem z~ośmiu \emph{palet} z~blokami. Obszar palet, znajdujący się po lewej stronie okna, pokazuje jedną paletę na raz. Do zmiany widocznej palety służy osiem przycisków znajdujących się tuż nad tym obszarem. Bloki ciemnożółte, widoczne w~naszym skrypcie, pochodzą z~palety Kontrola; zielone z~palety Pisak, a~niebieskie --- z~palety Ruch. Aby złożyć taki skrypt, należy poprzeciągać odpowiednie bloki z~palet do \emph{obszaru skryptów}, umiejscowionego na środku okna. Kiedy układamy jeden blok pod drugim w~taki sposób, aby wcięcie dolnego bloku znalazło się w~pobliżu wypustki tego powyżej, bloki łączą się ze sobą (ang. \textit{snap together}; stąd nazwa języka \Snap{}): \bigpic{snapping-blocks} diff --git a/help/manual/pl/window-regions.png b/help/manual/pl/window-regions.png deleted file mode 100644 index 7fe4e98..0000000 Binary files a/help/manual/pl/window-regions.png and /dev/null differ -- cgit v1.3.1 From 12671a1fbd6044f22ba037347b6af1bf170af9da Mon Sep 17 00:00:00 2001 From: Bartosz Leper Date: Fri, 26 Jun 2015 20:29:21 +0200 Subject: Polish translations of other pictures --- help/manual/pl/laczenie-blokow.png | Bin 0 -> 5025 bytes help/manual/pl/move-10-steps.png | Bin 2595 -> 0 bytes help/manual/pl/przesun-o-10-krokow.png | Bin 0 -> 3149 bytes help/manual/pl/snap-podrecznik.tex | 16 ++++++++-------- help/manual/pl/snapping-blocks.png | Bin 12054 -> 0 bytes help/manual/pl/typical-script-inner.png | Bin 4610 -> 0 bytes help/manual/pl/typical-script.png | Bin 11063 -> 0 bytes help/manual/pl/typowy-skrypt-wnetrze.png | Bin 0 -> 5211 bytes help/manual/pl/typowy-skrypt.png | Bin 0 -> 12764 bytes 9 files changed, 8 insertions(+), 8 deletions(-) create mode 100644 help/manual/pl/laczenie-blokow.png delete mode 100644 help/manual/pl/move-10-steps.png create mode 100644 help/manual/pl/przesun-o-10-krokow.png delete mode 100644 help/manual/pl/snapping-blocks.png delete mode 100644 help/manual/pl/typical-script-inner.png delete mode 100644 help/manual/pl/typical-script.png create mode 100644 help/manual/pl/typowy-skrypt-wnetrze.png create mode 100644 help/manual/pl/typowy-skrypt.png diff --git a/help/manual/pl/laczenie-blokow.png b/help/manual/pl/laczenie-blokow.png new file mode 100644 index 0000000..b640b5f Binary files /dev/null and b/help/manual/pl/laczenie-blokow.png differ diff --git a/help/manual/pl/move-10-steps.png b/help/manual/pl/move-10-steps.png deleted file mode 100644 index 3d276da..0000000 Binary files a/help/manual/pl/move-10-steps.png and /dev/null differ diff --git a/help/manual/pl/przesun-o-10-krokow.png b/help/manual/pl/przesun-o-10-krokow.png new file mode 100644 index 0000000..ece840c Binary files /dev/null and b/help/manual/pl/przesun-o-10-krokow.png differ diff --git a/help/manual/pl/snap-podrecznik.tex b/help/manual/pl/snap-podrecznik.tex index 121ec9c..f041a17 100644 --- a/help/manual/pl/snap-podrecznik.tex +++ b/help/manual/pl/snap-podrecznik.tex @@ -61,12 +61,12 @@ Uruchom teraz środowisko \Snap{}. Powinieneś zobaczyć ekran podzielony na kil Program w~języku \Snap{} składa się z~jednego lub więcej \emph{skryptów}, te zaś z~kolei --- z~\emph{bloków}. Oto przykładowy skrypt: -\label{fig:typical-script} -\bigpic{typical-script} +\label{fig:typowy-skrypt} +\bigpic{typowy-skrypt} -Na powyższy skrypt składa się pięć bloków w~trzech różnych kolorach, odpowiadających trzem z~ośmiu \emph{palet} z~blokami. Obszar palet, znajdujący się po lewej stronie okna, pokazuje jedną paletę na raz. Do zmiany widocznej palety służy osiem przycisków znajdujących się tuż nad tym obszarem. Bloki ciemnożółte, widoczne w~naszym skrypcie, pochodzą z~palety Kontrola; zielone z~palety Pisak, a~niebieskie --- z~palety Ruch. Aby złożyć taki skrypt, należy poprzeciągać odpowiednie bloki z~palet do \emph{obszaru skryptów}, umiejscowionego na środku okna. Kiedy układamy jeden blok pod drugim w~taki sposób, aby wcięcie dolnego bloku znalazło się w~pobliżu wypustki tego powyżej, bloki łączą się ze sobą (ang. \textit{snap together}; stąd nazwa języka \Snap{}): +Na powyższy skrypt składa się pięć bloków w~trzech różnych kolorach, odpowiadających trzem z~ośmiu \emph{palet} z~blokami. Obszar palet, znajdujący się po lewej stronie okna, pokazuje jedną paletę na raz. Do zmiany widocznej palety służy osiem przycisków znajdujących się tuż nad tym obszarem. Bloki ciemnożółte, widoczne w~naszym skrypcie, pochodzą z~palety ,,Kontrola''; zielone z~palety ,,Pisak'', a~niebieskie --- z~palety ,,Ruch''. Aby złożyć taki skrypt, należy poprzeciągać odpowiednie bloki z~palet do \emph{obszaru skryptów}, umiejscowionego na środku okna. Kiedy układamy jeden blok pod drugim w~taki sposób, aby wcięcie dolnego bloku znalazło się w~pobliżu wypustki tego powyżej, bloki łączą się ze sobą (ang. \textit{snap together}; stąd nazwa języka \Snap{}): -\bigpic{snapping-blocks} +\bigpic{laczenie-blokow} Pozioma biała linia sygnalizuje, że jeśli puścimy zielony blok, połączy się on z~wypustką ciemnożółtego. @@ -74,13 +74,13 @@ Pozioma biała linia sygnalizuje, że jeśli puścimy zielony blok, połączy si Na górze skryptu znajduje się \emph{blok-czapka}, który określa, kiedy skrypt ma zostać wykonany. Nazwy bloków-czapek zazwyczaj zaczynają się słowem ,,\code{kiedy}''; nasz przykładowy skrypt powinien zostać uruchomiony w~momencie kliknięcia zielonej flagi, znajdującej się w pobliżu prawej strony paska narzędzi \Snap{a}. (Pasek ten jest częścią okna programu \Snap{}; nie chodzi tutaj o pasek menu przeglądarki lub systemu operacyjnego.) Skrypt nie musi posiadać czapki, jednak w~takim przypadku zostanie wykonany tylko wtedy, gdy użytkownik sam go kliknie. Skrypt nie może mieć więcej niż jednej czapki; jej charakterystyczny kształt służy łatwiejszemu zapamiętaniu tej szczególnej własności. -Pozostałe bloki w naszym skrypcie to \emph{bloki poleceń}. Każdy z~nich oznacza jakąś akcję, którą \Snap{} potrafi wykonać. Na przykład blok \inlinepic{move-10-steps} nakazuje duszkowi\footnote{W grafice komputerowej słowem ,,duszek'' (ang. \textit{sprite}) nazywa się ruchomy obiekt na ekranie --- przyp. tłum.}, czyli strzałce na \emph{scenie} po prawej stronie okna, aby przesunął się o~dziesięć kroków do przodu w~kierunku, w~którym jest zwrócony. Każdy krok to niewielka odległość na ekranie. Wkrótce przekonamy się, że na scenie może być więcej duszków, a~każdy z nich może mieć własne skrypty. Ponadto duszki nie muszą wyglądać jak strzałki; ich kostiumy mogą być dowolnymi obrazkami. Kształt bloku \code{przesuń} ma za zadanie przypominać klocek, skrypt zaś jest jak wieża z klocków. Słowa ,,blok'' będziemy używać dla oznaczenia zarówno graficznego symbolu na ekranie, jak i~procedury (akcji) jaką ten blok wykonuje. +Pozostałe bloki w naszym skrypcie to \emph{bloki poleceń}. Każdy z~nich oznacza jakąś akcję, którą \Snap{} potrafi wykonać. Na przykład blok \inlinepic{przesun-o-10-krokow} nakazuje duszkowi\footnote{W grafice komputerowej słowem ,,duszek'' (ang. \textit{sprite}) nazywa się ruchomy obiekt na ekranie --- przyp. tłum.}, czyli strzałce na \emph{scenie} po prawej stronie okna, aby przesunął się o~dziesięć kroków do przodu w~kierunku, w~którym jest zwrócony. Każdy krok to niewielka odległość na ekranie. Wkrótce przekonamy się, że na scenie może być więcej duszków, a~każdy z nich może mieć własne skrypty. Ponadto duszki nie muszą wyglądać jak strzałki; ich kostiumy mogą być dowolnymi obrazkami. Kształt bloku \code{przesuń} ma za zadanie przypominać klocek, skrypt zaś jest jak wieża z klocków. Słowa ,,blok'' będziemy używać dla oznaczenia zarówno graficznego symbolu na ekranie, jak i~procedury (akcji) jaką ten blok wykonuje. -Liczbę 10 w powyższym bloku \code{przesuń} nazywamy jego \emph{parametrem}. Kliknąwszy na białym, zaokrąglonym polu, możemy wpisać w~jej miejsce dowolną inną. W przykładowym skrypcie ze strony \pageref{fig:typical-script} parametrem jest liczba 100. Jak się później okaże, pola parametrów mogą mieć kształty inne od zaokrąglonych; oznacza to wtedy, że akceptują one wartości inne niż liczby. Zobaczymy również, że zamiast wpisywać konkretne wartości w~pola, możemy nakazać komputerowi je obliczać. Ponadto blok może mieć więcej niż jeden parametr. Na przykład blok \code{leć}, znajdujący się mniej więcej w~połowie palety Ruch, przyjmuje trzy parametry. +Liczbę 10 w powyższym bloku \code{przesuń} nazywamy jego \emph{parametrem}. Kliknąwszy na białym, zaokrąglonym polu, możemy wpisać w~jej miejsce dowolną inną. W przykładowym skrypcie ze strony \pageref{fig:typowy-skrypt} parametrem jest liczba 100. Jak się później okaże, pola parametrów mogą mieć kształty inne od zaokrąglonych; oznacza to wtedy, że akceptują one wartości inne niż liczby. Zobaczymy również, że zamiast wpisywać konkretne wartości w~pola, możemy nakazać komputerowi je obliczać. Ponadto blok może mieć więcej niż jeden parametr. Na przykład blok \code{leć}, znajdujący się mniej więcej w~połowie palety ,,Ruch'', przyjmuje trzy parametry. -Większość bloków poleceń ma kształt klocków, lecz niektóre, jak \code{powtórz} z~tego samego przykładu, wyglądają jak \emph{klamry}. Większość bloków klamrowych można znaleźć na palecie Kontrola. Wnętrze klamry jest szczególnym rodzajem pola parametru, który przyjmuje \emph{skrypt} jako parametr. W~przykładowym skrypcie blok \code{powtórz} ma dwa parametry: liczbę 4 oraz skrypt +Większość bloków poleceń ma kształt klocków, lecz niektóre, jak \code{powtórz} z~tego samego przykładu, wyglądają jak \emph{klamry}. Większość bloków klamrowych można znaleźć na palecie ,,Kontrola'. Wnętrze klamry jest szczególnym rodzajem pola parametru, który przyjmuje \emph{skrypt} jako parametr. W~przykładowym skrypcie blok \code{powtórz} ma dwa parametry: liczbę 4 oraz skrypt -\bigpic{typical-script-inner} +\bigpic{typowy-skrypt-wnetrze} diff --git a/help/manual/pl/snapping-blocks.png b/help/manual/pl/snapping-blocks.png deleted file mode 100644 index 0dc5922..0000000 Binary files a/help/manual/pl/snapping-blocks.png and /dev/null differ diff --git a/help/manual/pl/typical-script-inner.png b/help/manual/pl/typical-script-inner.png deleted file mode 100644 index b5503f7..0000000 Binary files a/help/manual/pl/typical-script-inner.png and /dev/null differ diff --git a/help/manual/pl/typical-script.png b/help/manual/pl/typical-script.png deleted file mode 100644 index 6763aad..0000000 Binary files a/help/manual/pl/typical-script.png and /dev/null differ diff --git a/help/manual/pl/typowy-skrypt-wnetrze.png b/help/manual/pl/typowy-skrypt-wnetrze.png new file mode 100644 index 0000000..c3618ca Binary files /dev/null and b/help/manual/pl/typowy-skrypt-wnetrze.png differ diff --git a/help/manual/pl/typowy-skrypt.png b/help/manual/pl/typowy-skrypt.png new file mode 100644 index 0000000..6e2efe0 Binary files /dev/null and b/help/manual/pl/typowy-skrypt.png differ -- cgit v1.3.1