Upload files to 'studio'

This commit is contained in:
Jeison Yehuda Amihud (Blender Dumbass) 2021-12-19 18:14:53 +00:00
parent ce27337298
commit 1920944a5d
4 changed files with 154 additions and 23 deletions

View file

@ -753,9 +753,15 @@ def draw(outlayer, win, path, back="story_editor"):
if task["fraction"]:
task["fraction"] = 0.0
history.record(win, path, "[Un-Checked]", schedulepath)
win.textactive = ""
try: del win.text["editing_task"]
except: pass
else:
task["fraction"] = 1.0
history.record(win, path, "[Checked]", schedulepath)
win.textactive = ""
try: del win.text["editing_task"]
except: pass
# Saving
save(path, win.checklists[path])

View file

@ -1,7 +1,20 @@
# THIS FILE IS A PART OF VCStudio
# PYTHON 3
# This a console project manager.
####################################
# #
# COPYRIGHT NOTICE #
# #
# This file is a part of Victori- #
# ous Children Studio Organizer. #
# Or simply VCStudio. Copyright #
# of J.Y.Amihud. But don't be sad #
# because I released the entire #
# project under a GNU GPL license. #
# You may use Version 3 or later. #
# See www.gnu.org/licenses if your #
# copy has no License file. Please #
# note. Ones I used the GPL v2 for #
# it. It's no longer the case. #
# #
####################################
import os
import datetime
@ -449,7 +462,7 @@ def layer(win):
x = win.current["w"]/4
y = 280
width = win.current["w"] / 2
height = (win.current["h"]-300)/2
height = 100
# Now let's make a layer.
@ -571,6 +584,7 @@ def layer(win):
# graph, so to speak. But representing differnt kind of data.
# OKAY. SETTINGS.
if "schedule_analytics_settings" not in win.current:
@ -647,7 +661,7 @@ def layer(win):
y = y + height + 60
height = height - 100
height = win.current["h"]-500
# Making the layer
graphsurface = cairo.ImageSurface(cairo.FORMAT_ARGB32, int(width), int(height))
@ -743,14 +757,15 @@ def layer(win):
node.show_text(theday.split("/")[2])
UI_color.set(node, win, "dark_overdrop")
if theday == today:
UI_color.set(node, win, "button_clicked")
UI_elements.roundrect(node, win,
5+current_X+win.scroll["days"],
67,
40,
height-67,
10)
if theday >= today:
if theday == today:
UI_color.set(node, win, "button_clicked")
UI_elements.roundrect(node, win,
5+current_X+win.scroll["days"],
67,
40,
height-67,
10)
if win.current["date"] == theday:
UI_color.set(node, win, "progress_background")
@ -846,9 +861,47 @@ def layer(win):
fill=False)
node.stroke()
##################### BOTTOM GRAPH #######################
# Blender-Organizer legacy had two graphs. One smaller
# that shows all the project from start to finish
# ( Implemented above ) and one bigger. That shows a
# Zoomed in version of the graph. Back then I made it
# executing the same code twice. Which was fine. Since
# I had to make a change only ones. Now it's a bit of a
# problem to do so. Since the graph above is baked. And
# need to be able to navigate with in the bottom graph.
# So instead I'm going to redo the graph, but since we
# are re-doing it. I gonna make a slightly different design.
# It will show the same exact data. But drawn with a bit more
# beauty, compared to the top graph.
for num, thing in enumerate(reversed(cat)):
if cat[thing][0]:
UI_color.set(node, win, cat[thing][2])
try:
fracs = win.analytics["dates"][theday]["fractions"]
gfraction = fracs[thing]
# For now I will implement only Linear mode
# other modes will come later
graphY = ((height-80) - (height-80) * gfraction)+60
UI_elements.roundrect(node, win,
8+current_X+win.scroll["days"],
graphY,
35,
8,
5)
except:
pass
# Now here I want to draw the representations of scheduled
# tasks that are insife
# tasks that are inside
sch = []
if theday in win.analytics["dates"]:

View file

@ -61,6 +61,33 @@ def run(project, win):
except:
pass
# Sometimes the projects could be corrupted. So we need to
# insure that they are alright.
fn = project
try: os.mkdir(fn)
except: pass
try: os.mkdir(fn+"/rnd")
except: pass
try: os.mkdir(fn+"/dev")
except: pass
try: os.mkdir(fn+"/ast")
except: pass
try: os.mkdir(fn+"/pln")
except: pass
try: os.mkdir(fn+"/mus")
except: pass
try: os.mkdir(fn+"/set")
except: pass
for f in ["chr","loc","veh","obj"]:
try: os.mkdir(fn+"/ast/"+f)
except: pass
try: os.mkdir(fn+"/dev/"+f)
except: pass
# Setting up the window
@ -241,12 +268,25 @@ def pmdrawing(pmdrawing, main_layer, win):
# Current frame (for animations and things like this)
win.current["frame"] += 1
# Getting data about the frame
win.current['mx'] = win.get_pointer()[0]
win.current['my'] = win.get_pointer()[1]
win.current['w'] = win.get_size()[0]
win.current['h'] = win.get_size()[1]
if not "scale" in win.settings:
settings.write("scale", 1) # Writing to file
win.settings = settings.load_all()
# Getting data about the frame
win.current['mx'] = int(round(win.get_pointer()[0] / win.settings["scale"]))
win.current['my'] = int(round(win.get_pointer()[1] / win.settings["scale"]))
win.current['w'] = int(round(win.get_size()[0] / win.settings["scale"] ))
win.current['h'] = int(round(win.get_size()[1] / win.settings["scale"] ))
if 65451 in win.current["keys"]:
settings.write("scale", win.settings["scale"]+0.2)
win.settings = settings.load_all()
win.current["keys"] = []
elif 65453 in win.current["keys"]:
settings.write("scale", win.settings["scale"]-0.2)
win.settings = settings.load_all()
win.current["keys"] = []
win.cursors = {
"arrow":Gdk.Cursor.new(Gdk.CursorType.ARROW),
@ -283,8 +323,8 @@ def pmdrawing(pmdrawing, main_layer, win):
main_layer.rectangle(
0,
0,
win.current['w'],
win.current['h'])
win.current['w']*win.settings["scale"],
win.current['h']*win.settings["scale"])
main_layer.fill()
# Tooltips and other junk has to be defined here. And then drawn later to
@ -355,6 +395,10 @@ def pmdrawing(pmdrawing, main_layer, win):
Layers.append([UI_testing.layer(win)])
Layers.append([win.tooltip_surface])
if win.settings["scale"] != 1:
main_layer.scale(win.settings["scale"],
win.settings["scale"])
# Combining layers
for layer in Layers:
if len(layer) > 1:

View file

@ -565,6 +565,34 @@ def layer(win):
current_Y + win.scroll["studio_settings"] + 135)
layer.show_text(talk.text("Auto_De-Blur"))
current_Y += 50
# Pixelated Blur
ablur_ok = "unchecked"
if win.settings["PixelBlur"]:
ablur_ok = "checked"
def do():
win.settings["PixelBlur"] = not win.settings["PixelBlur"]
settings.write("PixelBlur", win.settings["PixelBlur"])
UI_elements.roundrect(layer, win,
win.current["w"]/2-240,
110 + current_Y + win.scroll["studio_settings"],
450,
40,
10,
button=do,
icon=ablur_ok,
tip=talk.text("PixelBlur"))
UI_color.set(layer, win, "text_normal")
layer.set_font_size(20)
layer.move_to(win.current["w"]/2-180,
current_Y + win.scroll["studio_settings"] + 135)
layer.show_text(talk.text("PixelBlur"))
current_Y += 50
# ROUNDNESS