Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions changelog.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,12 @@
# v0.9.2

QoL: Adding Pinboard Card. The Pinboard card allows you to pin multiple cards together, like Maps or Images before, but for a specialized card type.
FIX: Some issues with card pinning.
FIX: It wasn't possible to desaturate the color selected in the Edit Color menu previously; this is now fixed.
FIX: Crash when loading some images that are indexed.

# v0.9.2

QoL: Adding Pinboard Card. The Pinboard card is just a blank card that allows you to pin multiple cards together.
FIX: Some issues with card pinning and copying cards that are pinned.
FIX: Cards now properly are pinned when loading projects.
QoL: Adding keybinding shortcut to cycle capitalization for highlighted text.
QoL: Clicking and highlighting a word and then dragging will highlight whole words, like most text editors (there's a little work to be done here still).
Expand Down
14 changes: 8 additions & 6 deletions contents.go
Original file line number Diff line number Diff line change
Expand Up @@ -361,7 +361,7 @@ func (cc *CheckboxContents) Color() Color {
if cc.Card.CustomColor != nil {
color = cc.Card.CustomColor
h, s, v := cc.Card.CustomColor.HSV()
completedColor = NewColorFromHSV(h+0.08, s-0.2, v+0.2)
completedColor = NewColorFromHSV(h+0.04, s-0.2, v+0.2)
}

if len(cc.DependentCards()) > 0 {
Expand Down Expand Up @@ -636,7 +636,7 @@ func (nc *NumberedContents) Draw() {
completionColor := getThemeColor(GUICompletedColor)
if nc.Card.CustomColor != nil {
h, s, v := nc.Card.CustomColor.HSV()
completionColor = NewColorFromHSV(h+30, s-0.2, v+0.2)
completionColor = NewColorFromHSV(h+0.04, s-0.2, v+0.2)
}

nc.Card.Result.Texture.SetColorMod(completionColor.RGB())
Expand Down Expand Up @@ -670,7 +670,7 @@ func (nc *NumberedContents) Color() Color {
if nc.Card.CustomColor != nil {
color = nc.Card.CustomColor
h, s, v := nc.Card.CustomColor.HSV()
completedColor = NewColorFromHSV(h+30, s-0.2, v+0.2)
completedColor = NewColorFromHSV(h+0.04, s-0.2, v+0.2)
}

if !nc.Card.Properties.Get("hideMax").AsBool() && nc.PercentageComplete >= 0.99 {
Expand Down Expand Up @@ -1507,9 +1507,11 @@ func (ic *ImageContents) Draw() {

if shadowTexture != nil && (!ic.Card.VisualDragging || ic.Card.PinnedTo == nil || !ic.Card.PinnedTo.VisualDragging) {

tp := ic.Card.Page.Project.Camera.TranslatePoint(ic.Card.ShadowDisplayPosition)
tp.X += 4
tp.Y += 4
p := ic.Card.ShadowDisplayPosition
p.X += ic.Card.DisplayRect.W / 16
p.Y += ic.Card.DisplayRect.H / 16

tp := ic.Card.Page.Project.Camera.TranslatePoint(p)

dstRect := &sdl.FRect{
X: tp.X,
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ require (
github.com/mikelolasagasti/xz v1.0.1 // indirect
github.com/minio/minlz v1.0.1 // indirect
github.com/nfnt/resize v0.0.0-20180221191011-83c6a9932646 // indirect
github.com/nwaples/rardecode/v2 v2.1.1 // indirect
github.com/nwaples/rardecode/v2 v2.2.0 // indirect
github.com/otiai10/mint v1.6.3 // indirect
github.com/phpdave11/gofpdi v1.0.15 // indirect
github.com/pierrec/lz4/v4 v4.1.22 // indirect
Expand Down
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -172,8 +172,8 @@ github.com/ncruces/zenity v0.10.14 h1:OBFl7qfXcvsdo1NUEGxTlZvAakgWMqz9nG38TuiaGL
github.com/ncruces/zenity v0.10.14/go.mod h1:ZBW7uVe/Di3IcRYH0Br8X59pi+O6EPnNIOU66YHpOO4=
github.com/nfnt/resize v0.0.0-20180221191011-83c6a9932646 h1:zYyBkD/k9seD2A7fsi6Oo2LfFZAehjjQMERAvZLEDnQ=
github.com/nfnt/resize v0.0.0-20180221191011-83c6a9932646/go.mod h1:jpp1/29i3P1S/RLdc7JQKbRpFeM1dOBd8T9ki5s+AY8=
github.com/nwaples/rardecode/v2 v2.1.1 h1:OJaYalXdliBUXPmC8CZGQ7oZDxzX1/5mQmgn0/GASew=
github.com/nwaples/rardecode/v2 v2.1.1/go.mod h1:7uz379lSxPe6j9nvzxUZ+n7mnJNgjsRNb6IbvGVHRmw=
github.com/nwaples/rardecode/v2 v2.2.0 h1:4ufPGHiNe1rYJxYfehALLjup4Ls3ck42CWwjKiOqu0A=
github.com/nwaples/rardecode/v2 v2.2.0/go.mod h1:7uz379lSxPe6j9nvzxUZ+n7mnJNgjsRNb6IbvGVHRmw=
github.com/orcaman/writerseeker v0.0.0-20200621085525-1d3f536ff85e h1:s2RNOM/IGdY0Y6qfTeUKhDawdHDpK9RGBdx80qN4Ttw=
github.com/orcaman/writerseeker v0.0.0-20200621085525-1d3f536ff85e/go.mod h1:nBdnFKj15wFbf94Rwfq4m30eAcyY9V/IyKAGQFtqkW0=
github.com/orisano/pixelmatch v0.0.0-20220722002657-fb0b55479cde h1:x0TT0RDC7UhAVbbWWBzr41ElhJx5tXPWkIHA2HWPRuw=
Expand Down
8 changes: 1 addition & 7 deletions gui.go
Original file line number Diff line number Diff line change
Expand Up @@ -3793,13 +3793,7 @@ func (cw *ColorWheel) Update() {

h := float32(mpX) / float32(cw.HueStrip.W-1)

cw.SampledHue = NewColorFromHSV(float64(h), 1, 1)

// r, g, b, _ := ColorAt(cw.HueStrip, int32(mpX), int32(mpY))

// fmt.Println(r, g, b)

// cw.SampledHue = NewColor(r, g, b, 255)
cw.SampledHue = NewColorFromHSV(float64(h), float64(mpY)/float64(cw.HueStrip.H-1), 1)

if cw.OnColorChange != nil {
cw.OnColorChange()
Expand Down
2 changes: 1 addition & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ func init() {

runtime.LockOSThread()

globals.Version = semver.MustParse("0.9.2")
globals.Version = semver.MustParse("0.9.3")
globals.Keyboard = NewKeyboard()
globals.Mouse = NewMouse()
nm := NewMouse()
Expand Down
2 changes: 1 addition & 1 deletion resources.go
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,7 @@ func (resource *Resource) Parse() {

// Create shadow version

shadowSurface, _ := sdl.CreateSurface(int(w), int(h), surface.Format)
shadowSurface, _ := sdl.CreateSurface(int(w), int(h), sdl.PIXELFORMAT_RGBA32)

surface.SetColorMod(0, 0, 0)
surface.SetAlphaMod(20)
Expand Down
Loading