Web app for .gobook file

For discussing go computing, software announcements, etc.
Post Reply
User avatar
oca
Lives in gote
Posts: 699
Joined: Wed Feb 19, 2014 2:53 am
Rank: DDK
GD Posts: 0
KGS: aco
IGS: oca
OGS: oca
Location: Switzerland
Has thanked: 485 times
Been thanked: 166 times

Web app for .gobook file

Post by oca »

Hi,

Here is the very first try of a web app to see/edit .gobook files

*** Use Chrome browser for now...***

http://www.gocdf.ch/test/gobook/demo3.html

You should see something like that :
Capture_gobook.PNG
Capture_gobook.PNG (279.63 KiB) Viewed 9798 times

Very very buggy... but at least I reached something I can play with and I can spend now more time on fixing the bugs...

I will post here future improvements.

Have fun :D
Last edited by oca on Thu Nov 06, 2014 8:33 am, edited 1 time in total.
Converting the book Shape UP! by Charles Matthews/Seong-June Kim
to the gobook format. last updated april 2015 - Index of shapes, p.211 / 216
User avatar
oca
Lives in gote
Posts: 699
Joined: Wed Feb 19, 2014 2:53 am
Rank: DDK
GD Posts: 0
KGS: aco
IGS: oca
OGS: oca
Location: Switzerland
Has thanked: 485 times
Been thanked: 166 times

Re: [bugged] Web app for .gobook file

Post by oca »

Quick update :
Here are the main components I will use for the project

gobook file format
- by Anders Kierulf of "smartgo" (http://www.smartgo.com/pdf/gobookformat.pdf)

gobook library
- Didn't find anything... so I will build my own stuff here.

GO diagram and engine
- WGo.js (http://wgo.waltheri.net/ lastest version : https://github.com/waltheri/wgo.js)

Editor
- Cloud9 ACE Editor (http://ace.c9.io/#nav=about)

Layout
- w2ui (http://w2ui.com/web/)

Other
- JQuery (http://jquery.com/)
Converting the book Shape UP! by Charles Matthews/Seong-June Kim
to the gobook format. last updated april 2015 - Index of shapes, p.211 / 216
User avatar
oca
Lives in gote
Posts: 699
Joined: Wed Feb 19, 2014 2:53 am
Rank: DDK
GD Posts: 0
KGS: aco
IGS: oca
OGS: oca
Location: Switzerland
Has thanked: 485 times
Been thanked: 166 times

Re: [bugged] Web app for .gobook file

Post by oca »

Quick update, I fixed tons of bugs (but of course still not perfect...)
You can give a try to the new version here...

http://www.gocdf.ch/test/gobook/demo3.html
[edit]this test has been as been removed, use http://www.gocdf.ch/gobook instead [/edit]


The funny thing is that you can now click on a diagram to add stones on the text.
Just follow what's written on the editor to do a quick test. (use chrome browser)
Last edited by oca on Fri Jan 09, 2015 9:42 am, edited 1 time in total.
Converting the book Shape UP! by Charles Matthews/Seong-June Kim
to the gobook format. last updated april 2015 - Index of shapes, p.211 / 216
User avatar
oca
Lives in gote
Posts: 699
Joined: Wed Feb 19, 2014 2:53 am
Rank: DDK
GD Posts: 0
KGS: aco
IGS: oca
OGS: oca
Location: Switzerland
Has thanked: 485 times
Been thanked: 166 times

Re: [bugged] Web app for .gobook file

Post by oca »

I'm close to be ready...



It is now possible to save your own books.

For whose who want to try : http://www.gocdf.ch/gobook

login with demo/demo as user/password

There is a few sample book there, but please, create your own book so that everybody can see the original samples unmodified.

This is still for testing/demo purpose, but I think I will be ready to create proper accounts for anyone who may be interested by november.

PS: The editor as a few shortcut you may want to try...

bo[tab]
ch[tab]
--[tab]
**[tab]
***[tab]
gf[tab]
go[tab]
fig[tab]
dia[tab]
ll[tab]
rr[tab]
demo[tab]
h1[tab]

etc...

PS :YES I know, placing own stones in playing mode still don't work well... ;-)
Attachments
Capture1.PNG
Capture1.PNG (152.3 KiB) Viewed 9620 times
Capture2.PNG
Capture2.PNG (15.37 KiB) Viewed 9620 times
Last edited by oca on Fri Jan 09, 2015 9:43 am, edited 1 time in total.
Converting the book Shape UP! by Charles Matthews/Seong-June Kim
to the gobook format. last updated april 2015 - Index of shapes, p.211 / 216
User avatar
oca
Lives in gote
Posts: 699
Joined: Wed Feb 19, 2014 2:53 am
Rank: DDK
GD Posts: 0
KGS: aco
IGS: oca
OGS: oca
Location: Switzerland
Has thanked: 485 times
Been thanked: 166 times

Re: [bugged] Web app for .gobook file

Post by oca »

Hi,

If anyone want to create a proper account, you can now do so.

Just go to :

http://www.gocdf.ch/gobook

and click on the link "Want to create an Account ?"
It's free and will always be free. but the tools is provided "as is" without any warranty.

Have fun.
Last edited by oca on Fri Jan 09, 2015 9:43 am, edited 1 time in total.
Converting the book Shape UP! by Charles Matthews/Seong-June Kim
to the gobook format. last updated april 2015 - Index of shapes, p.211 / 216
User avatar
oca
Lives in gote
Posts: 699
Joined: Wed Feb 19, 2014 2:53 am
Rank: DDK
GD Posts: 0
KGS: aco
IGS: oca
OGS: oca
Location: Switzerland
Has thanked: 485 times
Been thanked: 166 times

Re: [bugged] Web app for .gobook file

Post by oca »

Added a few tools so that we can do "minimal basic stuff" without knowing the gobook syntax.

An flash demo is here :

http://www.gocdf.ch/gobook/demo/demo1.html

Also fixed the engine which should be ok now for ::fig (Figure), ::dia (Diagram) and ::var (Variations)
I'm now working on the "::prb" (Problem) which is still missing...
Converting the book Shape UP! by Charles Matthews/Seong-June Kim
to the gobook format. last updated april 2015 - Index of shapes, p.211 / 216
hyperpape
Tengen
Posts: 4382
Joined: Thu May 06, 2010 3:24 pm
Rank: AGA 3k
GD Posts: 65
OGS: Hyperpape 4k
Location: Caldas da Rainha, Portugal
Has thanked: 499 times
Been thanked: 727 times

Re: Web app for .gobook file

Post by hyperpape »

I don't know how I failed to notice this, but wonderful project. I mulled over trying a .gobook reader, but never actually started.

My idea was to use an inline player, and advance the commentary as you go through moves, to allow a single comment to accompany multiple moves.
User avatar
oca
Lives in gote
Posts: 699
Joined: Wed Feb 19, 2014 2:53 am
Rank: DDK
GD Posts: 0
KGS: aco
IGS: oca
OGS: oca
Location: Switzerland
Has thanked: 485 times
Been thanked: 166 times

Re: Web app for .gobook file

Post by oca »

Hi hyperpape,

Doing an inline player for .gobbok, just as eidogo does for sgf is also something I plan to do.
but I will do that after my engine can handle problems as that's what would be the most usefull for an inline use I think.
Converting the book Shape UP! by Charles Matthews/Seong-June Kim
to the gobook format. last updated april 2015 - Index of shapes, p.211 / 216
Gojira
Beginner
Posts: 18
Joined: Tue Oct 01, 2013 6:32 am
Rank: ogs 15k
GD Posts: 0
DGS: MasterOfWTF
OGS: Gojira
Has thanked: 5 times
Been thanked: 4 times

Re: Web app for .gobook file

Post by Gojira »

works on safari too :)
User avatar
oca
Lives in gote
Posts: 699
Joined: Wed Feb 19, 2014 2:53 am
Rank: DDK
GD Posts: 0
KGS: aco
IGS: oca
OGS: oca
Location: Switzerland
Has thanked: 485 times
Been thanked: 166 times

Re: Web app for .gobook file

Post by oca »

Gojira wrote:works on safari too :)


Thanks for the feedback, that's good to know !

Here is a quick try at what an inline usage may looks like.

Code: Select all

<div class="gobook">::fig mv=A1 at=end vw=A1G8</div>


A demo is here :
http://www.gocdf.ch/gobook/inline_demo.html

The html looks like this :

Code: Select all

<html>
   <head>
      <script type="text/javascript" src="wgo/wgo.js"></script>
      <script src="js/jquery.min.js"></script>
      <script src="gobook.parser.js"></script>
      <script src="gobook.engine.js"></script>
      <script src="gobook.bridge.wgo.js"></script>
   </head>

   <body>
      
      <div class="gobook">
         ::book
         ::h2 Click on a diagram to make it bigger and to place stones.

         Text1
         A second line... **bold Text** __italics__

         Another paragraph here...
                  
         ::fig ca="Hoshi"
            mv=D4
            at=end
            vw=A1G8
            width="half" align="left"


         ::fig ca="Komoku"
            mv=D3
            at=end
            vw=A1G8
            width="half" align="right"

         Line break before this text is important, so that the parser knows that
         this line is not part of the above ::fig tag.
      </div>
      
      <hr>


      <table border=1>
         <tr>
            <td>
               <div class="gobook">::fig mv=A1 at=end vw=A1G8</div>
            </td>
            <td>
               <div class="gobook">::fig mv=B2 at=end vw=A1G8</div>
            </td>
         </tr>
         <tr>
            <td>
               <div class="gobook">::fig mv=C3 at=end vw=A1G8 pl=w</div>
            </td>
            <td>
               <div class="gobook">::fig mv=D4 at=end vw=A1G8 pl=w</div>
            </td>
         </tr>
      </table>   


      <script>
         initGoBooks(".gobook",{square_size : 4, play_square_size: 20});   
      </script>
   </body>
</html>

Converting the book Shape UP! by Charles Matthews/Seong-June Kim
to the gobook format. last updated april 2015 - Index of shapes, p.211 / 216
User avatar
oca
Lives in gote
Posts: 699
Joined: Wed Feb 19, 2014 2:53 am
Rank: DDK
GD Posts: 0
KGS: aco
IGS: oca
OGS: oca
Location: Switzerland
Has thanked: 485 times
Been thanked: 166 times

Re: Web app for .gobook file

Post by oca »

Hi all,

I splitted my project in two parts.
One being the "My Own Go Book" Web App which has a new url http://www.gocdf.ch/gobook
As I'm still the lonly one user, I think nobody get lost ;)

The other project is a library that can be used for using gobook directy in html pages
I did a quick demo here :

http://www.gocdf.ch/gobook/lib/demo/turnjs_demo.html

you should see something like that :
2014-11-12_142907.jpg
2014-11-12_142907.jpg (118.83 KiB) Viewed 9322 times


Here I used Turn.js for the fun, but you really don't need that if you don't like that turning page effect.

I also attched a zip file so that you can try for your self.
just unzip and go the the folder "demo" and open one of the html file.

Note that I added basic stuff for the problem mode, which accept both gobook or sgf data (see code in demo/turnjs_demo.html)

Have fun.

[edit] gobook-lib.zip updated on 01/09/15 to fix a bug that occured while playing the problemon the second page of the turnjs_demo[/edit]
Attachments
gobook-lib.zip
(411.88 KiB) Downloaded 512 times
Converting the book Shape UP! by Charles Matthews/Seong-June Kim
to the gobook format. last updated april 2015 - Index of shapes, p.211 / 216
User avatar
oca
Lives in gote
Posts: 699
Joined: Wed Feb 19, 2014 2:53 am
Rank: DDK
GD Posts: 0
KGS: aco
IGS: oca
OGS: oca
Location: Switzerland
Has thanked: 485 times
Been thanked: 166 times

Re: Web app for .gobook file

Post by oca »

just updated the zip file in the previous post has there where a bug.
Converting the book Shape UP! by Charles Matthews/Seong-June Kim
to the gobook format. last updated april 2015 - Index of shapes, p.211 / 216
Post Reply