Tjena, har börjat med att skriva en bok om android programmering, mest för att jag själv lättare ska ha snabb tillgång till en rad olika funktioner.
Vad jag tänkte höra om, är att om det finns något intresse här.
Jag hade tänkt göra denna boken väldigt lättläst och försöka göra det lätt för de eventuella läsarna att lära sig hur allt fungerar. Tänkte dela med mig en liten del av "boken"
________________________________________________________________________________
Chapter 2 - Layouts
Layouts are the template of your applet. With layouts, you can decide where you want your different objects ( for example, a button or perhaps an image )
There are different kinds of layouts, LinearLayout, which sorts your objects on an horiztonal or vertical plane.
LinearLayout
The basic construction of a LinearLayout is pretty simple.
<LinearLayout
android:layout_width=”fill_parent”
android:layout_height =”wrap_content”>
</LinearLayout>
Where “android:layout_width” is the width of the layout. “fill_parent” means that the width of the layout will fill out the screen in an horizontal width. “android:layout_height” defines the height of the layout. “wrap_content” means that the height of the layout will be as high as the content inside it.
You could take away the “fill_parent” or “wrap_content” and replace it with a number, for example “100px”.
Here’s an example where there are two buttons inside the Layout. The button codes will be explained in later chapters, so don’t bother about them right now. They will be placed next to eachother.
<LinearLayout android:layout_width=”fill_parent”
Android:layout_height = “wrap_content”>
<Button android:text = “This is a button” android:layout_width = “64px android:layout_height = “wrap_content”/>
<Button android:text = “This is a second button!”
android:layout_width = “64px android:layout_height = “wrap_content”/> </LinearLayout>
________________________________________________________________________________
Kanske lite tråkigt att läsa detta, i microsoft word ser upplägget mycket bättre ut. Bortset från det, förstår ni vad jag försöker säga och vad de handlar om?
Till er som kan programmera i android, ser ni några större brister?
Strunta i eventuella stavfel, grammatikfel etc. Dessa kommer fixas senare.
Hade också tänkt lägga in en del övningar i slutet av boken, som handlar om de olika kapitlen i boken, på så sätt kan läsaren se om de verkligen förstod vad det handlade om.
Är reklamen ivägen? Logga in eller registrera dig så försvinner den!