]> git.cworth.org Git - kub/log
kub
14 years agoExperimenting with save/commit immediately after switching from test
Kevin Worth [Sat, 13 Jun 2009 22:18:41 +0000 (18:18 -0400)]
Experimenting with save/commit immediately after switching from
      master branch to this test branch

14 years agoSelection box now draws correctly in all four directions
Kevin Worth [Sat, 6 Jun 2009 15:15:40 +0000 (11:15 -0400)]
Selection box now draws correctly in all four directions

14 years agoShowing carl error with drawing the selection_box
Kevin Worth [Sat, 6 Jun 2009 14:31:36 +0000 (10:31 -0400)]
Showing carl error with drawing the selection_box

14 years agoshow carl latest changes, name selection_rectangle to selection_box, etc.
Kevin Worth [Sat, 6 Jun 2009 12:43:43 +0000 (08:43 -0400)]
show carl latest changes, name selection_rectangle to selection_box, etc.

14 years agotest code
Kevin Worth [Fri, 5 Jun 2009 18:52:46 +0000 (14:52 -0400)]
test code

14 years agoFinal commit to fix indentation with mixed tabs and spaces
Kevin Worth [Fri, 29 May 2009 01:38:05 +0000 (21:38 -0400)]
Final commit to fix indentation with mixed tabs and spaces

14 years agoFirst attempt to fix indenting to mix of tabs and spaces
Kevin Worth [Thu, 28 May 2009 14:02:21 +0000 (10:02 -0400)]
First attempt to fix indenting to mix of tabs and spaces

      Kevin tried to fix things, and in his emacs the first level
      of indent appears to be 3 columns. This commit made so Carl
      can try and fix things and push them back

14 years agoSmall update to kub_todo.txt
Kevin Worth [Thu, 7 May 2009 20:15:03 +0000 (16:15 -0400)]
Small update to kub_todo.txt

14 years agoFix tile_group_is_set
Kevin Worth [Thu, 7 May 2009 19:15:43 +0000 (15:15 -0400)]
Fix tile_group_is_set

Previous version was validating sets with repeat colors.
The error appeared to be an incomplete check through the array;
when num_tiles was 3, it was checking index 0 and 1. Thus, if
index 0 and 2 had the same color, it wasn't being caught.

New version now steps through entire array.

14 years agoFix tile group validation functions
Kevin Worth [Thu, 7 May 2009 15:06:03 +0000 (11:06 -0400)]
Fix tile group validation functions

tile_group_is_set() has been tested
and appears to be working. No major changes
made here.

tile_group_is_run_one() has been tested and
appears to be working. This version has been
significantly revamped. The concept for the previous
version was "slick" but was flawed. One failure came
from testing a 3 tile group containing a yellow tile.
The yellow tile tried to increment index 3, but the max
index was 2.

no changes made to tile_group_is_run_two() which
has not been tested. It may not be needed unless
it can be shown to be "better" than _is_run_one()

14 years agoClick-n-drag to select multiple tiles
Kevin Worth [Wed, 6 May 2009 23:04:41 +0000 (19:04 -0400)]
Click-n-drag to select multiple tiles

The main purpose here is to facilitate testing of
the functions tile_group_is_set and tile_group_is_run.
Eventually it will be improved for general UI purposes.
Grouped tiles are printed to terminal.

XXX There is a bug here XXX
Selections must:
(a)start above the highest tile and catch all the
top left corners of each tile
OR
(b)start below the lowest tile and catch all the
bottom left corners of each tile

14 years agoAdd first version of kub_todo.txt into repository
Kevin Worth [Wed, 6 May 2009 02:31:06 +0000 (22:31 -0400)]
Add first version of kub_todo.txt into repository

14 years agoFid indents broken from in previous commit(tabs now changed to 4 spaces)
Kevin Worth [Tue, 5 May 2009 23:07:01 +0000 (19:07 -0400)]
Fid indents broken from in previous commit(tabs now changed to 4 spaces)

14 years agoDraw 2 digit numbers *closer* to center of tile
Kevin Worth [Tue, 5 May 2009 01:25:12 +0000 (21:25 -0400)]
Draw 2 digit numbers *closer* to center of tile

17 years agoUse the expose event's region to avoid drawing tiles that don't need to be redrawn.
Carl Worth [Thu, 15 Mar 2007 16:25:54 +0000 (09:25 -0700)]
Use the expose event's region to avoid drawing tiles that don't need to be redrawn.

The reason that dragging was so slow before is that the program
was redrawing every single tile every time the mouse moved. Now
we only redraw tiles that are actually affected by the movement.

This is fast enough now that we probably don't even need to add
caches for pre-rendered tiles, (though of course, if we did that
it would be even faster).

17 years agoDeal in players and draw tiles for player 1(players[0])
Kevin Worth [Thu, 15 Mar 2007 01:05:55 +0000 (21:05 -0400)]
Deal in players and draw tiles for player 1(players[0])

17 years agoKeep cursor on original spot(of tile) clicked while dragging
Kevin Worth [Wed, 14 Mar 2007 21:24:10 +0000 (17:24 -0400)]
Keep cursor on original spot(of tile) clicked while dragging

17 years agoFix tile dragging(no tile dragged when blank area clicked)
Kevin Worth [Wed, 14 Mar 2007 21:00:49 +0000 (17:00 -0400)]
Fix tile dragging(no tile dragged when blank area clicked)

17 years agoFix bug causing garbage lines
Kevin Worth [Wed, 14 Mar 2007 16:06:38 +0000 (12:06 -0400)]
Fix bug causing garbage lines

17 years agoCommit to undo changes from previous commit
Kevin Worth [Wed, 14 Mar 2007 15:28:14 +0000 (11:28 -0400)]
Commit to undo changes from previous commit

17 years agoFixed bug so that when no tile is clicked, no tile moves.
Kevin Worth [Wed, 14 Mar 2007 15:02:17 +0000 (11:02 -0400)]
Fixed bug so that when no tile is clicked, no tile moves.

17 years agoMove tile movement/redraw code from on_button_press_event to on_button_motion_event
Carl Worth [Wed, 14 Mar 2007 14:35:26 +0000 (07:35 -0700)]
Move tile movement/redraw code from on_button_press_event to on_button_motion_event

We queue redraws rather than calling draw_tile directly so that we
only draw in the idle loop, for much better performance, (and for
proper interaction with GTK+'s double buffering).

17 years agoFix typo (should be motion_notify_event, not button_motion_event)
Carl Worth [Wed, 14 Mar 2007 14:33:10 +0000 (07:33 -0700)]
Fix typo (should be motion_notify_event, not button_motion_event)

This is some naming inconsistency in GTK+ that makes it confusing
to program, (probably left over from naming inconsistency in Xlib).

17 years agoAttempt at dragging tiles(compiles, but no dragging)
Kevin Worth [Tue, 13 Mar 2007 19:29:24 +0000 (15:29 -0400)]
Attempt at dragging tiles(compiles, but no dragging)

17 years agoCreated deck_spread which gives x, y values to tiles in deck, for drawing 8 rows...
Kevin Worth [Tue, 6 Mar 2007 12:45:02 +0000 (07:45 -0500)]
Created deck_spread which gives x, y values to tiles in deck, for drawing 8 rows of 13 tiles

17 years agoRevised deck_draw by removing obsolete for loops(now that tile_draw is handling the...
Kevin Worth [Tue, 6 Mar 2007 12:11:48 +0000 (07:11 -0500)]
Revised deck_draw by removing obsolete for loops(now that tile_draw is handling the x,y of where to print the tile)

17 years agoUse mouse clicks to position tiles one by one.
Carl Worth [Thu, 1 Mar 2007 15:09:58 +0000 (07:09 -0800)]
Use mouse clicks to position tiles one by one.

17 years agoMove tile dimensions as #defines into kub.c
Carl Worth [Thu, 1 Mar 2007 15:09:42 +0000 (07:09 -0800)]
Move tile dimensions as #defines into kub.c

17 years agoGive each tile its own position and use it to draw the tile.
Carl Worth [Thu, 1 Mar 2007 14:50:18 +0000 (06:50 -0800)]
Give each tile its own position and use it to draw the tile.

17 years agoBreakout new tile_init function from deck_init
Carl Worth [Thu, 1 Mar 2007 14:48:55 +0000 (06:48 -0800)]
Breakout new tile_init function from deck_init

17 years agoMerge branch 'master' of kevin:kub
Carl Worth [Thu, 1 Mar 2007 14:43:45 +0000 (06:43 -0800)]
Merge branch 'master' of kevin:kub

17 years agoRename card to tile
Carl Worth [Thu, 1 Mar 2007 14:43:00 +0000 (06:43 -0800)]
Rename card to tile

17 years agoRealized value for TILE_SUN_Y_OFFSET was missing from last commit
Kevin Worth [Wed, 21 Feb 2007 06:02:08 +0000 (01:02 -0500)]
Realized value for TILE_SUN_Y_OFFSET was missing from last commit

17 years agoCompleted tiledimensions.txt with missing values
Kevin Worth [Wed, 21 Feb 2007 03:47:51 +0000 (22:47 -0500)]
Completed tiledimensions.txt with missing values

17 years agoAdded tiledimensions.txt to document tile size constants
Kevin Worth [Tue, 20 Feb 2007 18:44:42 +0000 (13:44 -0500)]
Added tiledimensions.txt to document tile size constants

17 years agoDraw tiles as 1-13 instead of 0-12
Carl Worth [Tue, 20 Feb 2007 17:45:07 +0000 (09:45 -0800)]
Draw tiles as 1-13 instead of 0-12

A simple off-by-one error in card_draw.

17 years agoFix card_draw for multi-digit tiles.
Carl Worth [Tue, 20 Feb 2007 17:44:35 +0000 (09:44 -0800)]
Fix card_draw for multi-digit tiles.

Previously, for tiles > 9 we were just using the next larger
character values in ACII above '9'. Oops! Now, we're properly
using snprintf to format the number as an integer within the
string.

17 years agoFixed deck_draw, though still have bugs in card_draw
Kevin Worth [Tue, 20 Feb 2007 15:22:53 +0000 (10:22 -0500)]
Fixed deck_draw, though still have bugs in card_draw

17 years agoStarted deck_draw, currently full of errors
Kevin Worth [Tue, 20 Feb 2007 14:50:45 +0000 (09:50 -0500)]
Started deck_draw, currently full of errors

17 years agoTemporarily add -Wno-unused-function
Carl Worth [Tue, 20 Feb 2007 14:17:50 +0000 (06:17 -0800)]
Temporarily add -Wno-unused-function

Generally, this is a useful warning to have turned on, but for now
while we have some unused functions still in-progress, let's turn it
off so that we can have clean, warning-free compilation.

17 years agoFix signature of card_compare to make qsort happy
Carl Worth [Tue, 20 Feb 2007 14:15:45 +0000 (06:15 -0800)]
Fix signature of card_compare to make qsort happy

It really wants to see 'const void *' arguments.

17 years agoFix compilation errors (& confusion)
Carl Worth [Tue, 20 Feb 2007 14:12:33 +0000 (06:12 -0800)]
Fix compilation errors (& confusion)

17 years agoAttempt at card_draw function, probably full of errors :)
Kevin Worth [Tue, 20 Feb 2007 13:44:15 +0000 (08:44 -0500)]
Attempt at card_draw function, probably full of errors :)

17 years agoResized blanktile now drawn in corner
Kevin Worth [Wed, 14 Feb 2007 19:59:58 +0000 (14:59 -0500)]
Resized blanktile now drawn in corner

17 years agoAdd comments about the various parts of the sun
Carl Worth [Wed, 14 Feb 2007 18:34:40 +0000 (10:34 -0800)]
Add comments about the various parts of the sun

17 years agoAdd tile and sun id attributes
Carl Worth [Wed, 14 Feb 2007 18:33:09 +0000 (10:33 -0800)]
Add tile and sun id attributes

17 years agoMove duplicated style attributes to enclosing group
Carl Worth [Wed, 14 Feb 2007 18:32:22 +0000 (10:32 -0800)]
Move duplicated style attributes to enclosing group

17 years agoStrip out most of the inkscape-specfic cruft from blanktile.svg
Carl Worth [Wed, 14 Feb 2007 17:56:34 +0000 (09:56 -0800)]
Strip out most of the inkscape-specfic cruft from blanktile.svg

17 years agoDraw blanktile.svg instead of red6.svg so that numbers can be added dynamically
Carl Worth [Wed, 14 Feb 2007 17:56:13 +0000 (09:56 -0800)]
Draw blanktile.svg instead of red6.svg so that numbers can be added dynamically

17 years agoAdd very basic usage of librsvg to draw a red tile.
Carl Worth [Wed, 14 Feb 2007 17:29:05 +0000 (09:29 -0800)]
Add very basic usage of librsvg to draw a red tile.

This is basically the minimal necessary support to start using
librsvg to render SVG graphics. Just a single, static red 6 tile
for now.

17 years agoAdd some cairo drawing (just a solid, red rectangle)
Carl Worth [Wed, 14 Feb 2007 17:26:08 +0000 (09:26 -0800)]
Add some cairo drawing (just a solid, red rectangle)

This is the minimal necessary code to be able to start drawing
with cairo.

17 years agoMerge branch 'master' of kevin:kub
Carl Worth [Wed, 14 Feb 2007 17:01:59 +0000 (09:01 -0800)]
Merge branch 'master' of kevin:kub

Conflicts:

kub.c

17 years agoDocument internals (and bug!) of card_group_is_run
Carl Worth [Wed, 14 Feb 2007 17:00:31 +0000 (09:00 -0800)]
Document internals (and bug!) of card_group_is_run

17 years agoAdd kub binary to .gitignore
Carl Worth [Wed, 14 Feb 2007 16:54:17 +0000 (08:54 -0800)]
Add kub binary to .gitignore

17 years agoOne final(hopefully) fix to qsort
Kevin Worth [Mon, 29 Jan 2007 18:07:17 +0000 (13:07 -0500)]
One final(hopefully) fix to qsort

17 years agoRemoved extra card_compare
Kevin Worth [Mon, 29 Jan 2007 18:02:43 +0000 (13:02 -0500)]
Removed extra card_compare

17 years agoCouple of attempts to fix qsort, per Carl's suggestions.
Kevin Worth [Mon, 29 Jan 2007 18:02:18 +0000 (13:02 -0500)]
Couple of attempts to fix qsort, per Carl's suggestions.

17 years agoAttempt at implementing qsort into card_group_is_run
Kevin Worth [Mon, 29 Jan 2007 16:45:54 +0000 (11:45 -0500)]
Attempt at implementing qsort into card_group_is_run

17 years agoImplement card_group_is_run with one loop instead of two.
Carl Worth [Mon, 29 Jan 2007 15:19:33 +0000 (07:19 -0800)]
Implement card_group_is_run with one loop instead of two.

It's simpler to just implement a single check for color in the same
loop that's examining the color of every card. We don't need to
check every pair of cards for matching color as we were in the old
loop.

17 years agoUse subraction to implement card_compare
Carl Worth [Mon, 29 Jan 2007 15:09:23 +0000 (07:09 -0800)]
Use subraction to implement card_compare

17 years agoFixed card_group_is_run to include last card in number compare
Kevin Worth [Mon, 29 Jan 2007 14:46:08 +0000 (09:46 -0500)]
Fixed card_group_is_run to include last card in number compare

17 years agoRemove duplicate definition of card_group_is_run
Carl Worth [Mon, 29 Jan 2007 14:22:36 +0000 (06:22 -0800)]
Remove duplicate definition of card_group_is_run

17 years agoAdd unconditional return value to card_compare
Carl Worth [Mon, 29 Jan 2007 14:22:09 +0000 (06:22 -0800)]
Add unconditional return value to card_compare

This avoids a wanring from gcc about a function possibly not returning
a value.

17 years agoFix syntax errors in card_compare
Carl Worth [Mon, 29 Jan 2007 14:21:18 +0000 (06:21 -0800)]
Fix syntax errors in card_compare

17 years agoAdd some minimal GTK+ love to kub
Carl Worth [Mon, 29 Jan 2007 14:14:50 +0000 (06:14 -0800)]
Add some minimal GTK+ love to kub

This initializes GTK+, creates a window, and establishes 4 callback functions
for handling expose, key press, and button press/release events. So far,
the callbacks are just printing things to stdout and not really doing anything
useful yet.

17 years agoAdded beginnings of card_compare and added to card_group_is_run(still incomplete)
Kevin Worth [Sat, 27 Jan 2007 20:17:43 +0000 (15:17 -0500)]
Added beginnings of card_compare and added to card_group_is_run(still incomplete)

17 years agoNew svg files of Kevin's Kub tiles
Kevin Worth [Mon, 15 Jan 2007 20:39:56 +0000 (12:39 -0800)]
New svg files of Kevin's Kub tiles

17 years agoKub can now _reliably_ shuffle deck and deal in 1-4 players
Kevin Worth [Sat, 4 Feb 2006 18:33:43 +0000 (10:33 -0800)]
Kub can now _reliably_ shuffle deck and deal in 1-4 players

17 years agoMinor fixes to kub
Kevin Worth [Sat, 21 Jan 2006 07:42:39 +0000 (23:42 -0800)]
Minor fixes to kub

17 years agoCompleted _is_set and _is_run but still lacking debugging code for said functions
Kevin Worth [Sat, 21 Jan 2006 07:38:14 +0000 (23:38 -0800)]
Completed _is_set and _is_run but still lacking debugging code for said functions

17 years agoFixed kub to print deck better(still not perfect)
Kevin Worth [Sun, 15 Jan 2006 07:50:42 +0000 (23:50 -0800)]
Fixed kub to print deck better(still not perfect)

17 years agoKub compiles with no errors but still plenty of bugs
Kevin Worth [Sat, 14 Jan 2006 18:50:49 +0000 (10:50 -0800)]
Kub compiles with no errors but still plenty of bugs

17 years agoAdd .gitignore file
Carl Worth [Sat, 27 Jan 2007 14:29:50 +0000 (06:29 -0800)]
Add .gitignore file

17 years agoAdd simple Makefile
Carl Worth [Sat, 27 Jan 2007 14:22:38 +0000 (06:22 -0800)]
Add simple Makefile

We needed a trivial little Makefile since we extracted kub
out of a former project that had been using automake.

17 years agoAdd kub program
Kevin Worth [Sat, 14 Jan 2006 17:01:24 +0000 (09:01 -0800)]
Add kub program