Jump to content




Bedrock - The Complete GUI Framework


  • You cannot reply to this topic
60 replies to this topic

#41 SquidDev

    Frickin' laser beams | Resident Necromancer

  • Members
  • 1,427 posts
  • LocationDoes anyone put something serious here?

Posted 20 February 2015 - 10:02 PM

View Postsmigger22, on 20 February 2015 - 09:24 PM, said:

I was looking for a textbox api and found it on the github repo.

(Note to self: Stay away from Bedrock; too hard to understand)

This really, really isn't helpful. I've been part of the CC forums for almost a year now, and it feels like much longer. It is the friendliest programming communities I've ever participated in, and I love every moment of it. Maybe I'm just taking this the wrong way but this sort of comment just isn't helpful for anyone. Sometimes there are threads that end up being "I'm right, you're wrong" arguments and I know I'm as guilty of that as anyone sometimes. I stumbled upon this thread (which please, no one necro) which involved some people who's work I really admire (ElvishJerricco, theoriginalbit, etc...) bashing each other up something-or-other.

I guess what I am trying to say is if you have something to say that is negative, please say it in a more constructive way than "it is too hard to understand": What did you struggle with? How can oeed make this better? IMO Bedrock is the GUI framework to use. Compared with WinForms or Java's Swing, Bedrock is much easier. The only way it could get any simpler would be using HTML/XAML instead.

Sorry for the bit of a rant, but sometimes I just get ugghr at people. Sorry.

Edited by SquidDev, 20 February 2015 - 10:11 PM.


#42 oeed

    Oversimplifier

  • Members
  • 2,095 posts
  • LocationAuckland, New Zealand

Posted 20 February 2015 - 10:39 PM

View Postsmigger22, on 20 February 2015 - 09:24 PM, said:

I was looking for a textbox api and found it on the github repo.

(Note to self: Stay away from Bedrock; too hard to understand)

Well, you're not really allowed to just take parts of Bedrock and make it suit your situation, as the license stays.

#43 cdel

  • Banned
  • 496 posts
  • LocationMelbourne, Australia

Posted 22 February 2015 - 02:54 AM

Wasn't sure if I should chuck this in ask a pro or not, but if it not suitable here im sure an admin/mod could move it. I am having the problem where I am not able to click the "Okay" response on the first alert.

Image:
Posted Image

startup file (OneOS Program):
-- Xeon Jailbreak
OneOS.ToolBarColour = colours.green
OneOS.ToolBarTextColour = colours.white
local version = "v1.3.41"
local bedrockPath='/' if OneOS then OneOS.LoadAPI('/System/API/Bedrock.lua', false)elseif fs.exists(bedrockPath..'/Bedrock')then os.loadAPI(bedrockPath..'/Bedrock')else if http then print('Downloading Bedrock...')local h=http.get('http://pastebin.com/raw.php?i=0MgKNqpN')if h then local f=fs.open(bedrockPath..'/Bedrock','w')f.write(h.readAll())f.close()h.close()os.loadAPI(bedrockPath..'/Bedrock')else error('Failed to download Bedrock. Is your internet working?') end else error('This program needs to download Bedrock to work. Please enable HTTP.') end end if Bedrock then Bedrock.BasePath = bedrockPath Bedrock.ProgramPath = shell.getRunningProgram() end
local program = Bedrock:Initialise()
program:Run(function()
  if version ~= OneOS.Version then
	program:DisplayAlertWindow("Incompatible Version", "Xeon can't Jailbreak this version of OneOS.", { "Okay" }, function(value)
	  if value == "Okay" then
		OneOS.Close()
	  end
	end)
  end
  if not _G.Xeon then
	program:DisplayAlertWindow("Install Jailbreak", "Jailbreak OneOS "..OneOS.Version.."?", { "Yes", "No" }, function(value)
	   if value == "Yes" then
	
	  end	  
	end)
  end
end)

Edited by cdel, 22 February 2015 - 02:54 AM.


#44 oeed

    Oversimplifier

  • Members
  • 2,095 posts
  • LocationAuckland, New Zealand

Posted 22 February 2015 - 03:09 AM

View Postcdel, on 22 February 2015 - 02:54 AM, said:

Wasn't sure if I should chuck this in ask a pro or not, but if it not suitable here im sure an admin/mod could move it. I am having the problem where I am not able to click the "Okay" response on the first alert.

Image:
Posted Image

startup file (OneOS Program):
-- Xeon Jailbreak
OneOS.ToolBarColour = colours.green
OneOS.ToolBarTextColour = colours.white
local version = "v1.3.41"
local bedrockPath='/' if OneOS then OneOS.LoadAPI('/System/API/Bedrock.lua', false)elseif fs.exists(bedrockPath..'/Bedrock')then os.loadAPI(bedrockPath..'/Bedrock')else if http then print('Downloading Bedrock...')local h=http.get('http://pastebin.com/raw.php?i=0MgKNqpN')if h then local f=fs.open(bedrockPath..'/Bedrock','w')f.write(h.readAll())f.close()h.close()os.loadAPI(bedrockPath..'/Bedrock')else error('Failed to download Bedrock. Is your internet working?') end else error('This program needs to download Bedrock to work. Please enable HTTP.') end end if Bedrock then Bedrock.BasePath = bedrockPath Bedrock.ProgramPath = shell.getRunningProgram() end
local program = Bedrock:Initialise()
program:Run(function()
  if version ~= OneOS.Version then
	program:DisplayAlertWindow("Incompatible Version", "Xeon can't Jailbreak this version of OneOS.", { "Okay" }, function(value)
	  if value == "Okay" then
		OneOS.Close()
	  end
	end)
  end
  if not _G.Xeon then
	program:DisplayAlertWindow("Install Jailbreak", "Jailbreak OneOS "..OneOS.Version.."?", { "Yes", "No" }, function(value)
	   if value == "Yes" then
	
	  end	  
	end)
  end
end)

Here's fine, it means I actually notice it.

One thing, you can actually set the OneOS top bar colour in your Bedrock main.view view. Just set ToolBarColour, so for example:

{
	Children = {
		{
			X = 1,
			Y = 1,
			.... etc
			}
		},
	},
	ToolBarColour = 'green',
	ToolBarTextColour = 'white'
}

Although in version 2 it automatically detects the colour, so you won't need it.

Anyway. Your issue is because you are showing two windows at once. I'll probably try and make a fix for it, as it is technically a Bedrock bug. Essentially you've got dodgy logic in there. You say that it doesn't support that version, but then you still continue the program and try to show the window to start the process.

So just change:
  end
  if not _G.Xeon then  

To:
elseif not _G.Xeon then

Then it should work.

Posted Image

I look forward to seeing how it turns out!

Edited by oeed, 22 February 2015 - 03:09 AM.


#45 cdel

  • Banned
  • 496 posts
  • LocationMelbourne, Australia

Posted 22 February 2015 - 03:19 AM

thankyou :)

#46 Viking

  • Members
  • 14 posts

Posted 24 February 2015 - 12:41 PM

I have few suggestions what Bedrock should support without creating custom objects or a custom Bedrock source.

1. Fragments
- These are very useful for creating dynamic and more complex UIs. ( think Android SDK )

2. Integration with other apps ( It's more like a OneOS function. I don't know. )
- You could use/reach OneOS app APIs in your programs as an image editor ( Sketch ) or share something via an other app( think Google+, Facebook etc... )

#47 cdel

  • Banned
  • 496 posts
  • LocationMelbourne, Australia

Posted 21 March 2015 - 05:52 AM

If I were to use in something such as an os, would I just put the line of code you provided in something such as a startup file?

#48 oeed

    Oversimplifier

  • Members
  • 2,095 posts
  • LocationAuckland, New Zealand

Posted 21 March 2015 - 05:58 AM

Pretty much, you'd just make it like any other program.

#49 cdel

  • Banned
  • 496 posts
  • LocationMelbourne, Australia

Posted 21 March 2015 - 05:59 AM

okay, thanks for clearing that up. :)

#50 _removed

  • Members
  • 262 posts

Posted 15 April 2015 - 04:00 PM

Brings me right back to home, so much designed like CSS.

View PostSquidDev, on 20 February 2015 - 10:02 PM, said:

View Postsmigger22, on 20 February 2015 - 09:24 PM, said:

-snip

This really, really isn't helpful. I've been part of the CC forums for almost a year now, and it feels like much longer. It is the friendliest programming communities I've ever participated in, and I love every moment of it. Maybe I'm just taking this the wrong way but this sort of comment just isn't helpful for anyone. Sometimes there are threads that end up being "I'm right, you're wrong" arguments and I know I'm as guilty of that as anyone sometimes. I stumbled upon this thread (which please, no one necro) which involved some people who's work I really admire (ElvishJerricco, theoriginalbit, etc...) bashing each other up something-or-other.

I guess what I am trying to say is if you have something to say that is negative, please say it in a more constructive way than "it is too hard to understand": What did you struggle with? How can oeed make this better? IMO Bedrock is the GUI framework to use. Compared with WinForms or Java's Swing, Bedrock is much easier. The only way it could get any simpler would be using HTML/XAML instead.

Sorry for the bit of a rant, but sometimes I just get ugghr at people. Sorry.
Yeah, I was having a bad day due to having the compiler throw millions of errors at me when we tried to make our own textbox api. Eventually, we did it, but I was stupid to post that. I'm sorry about that.

Besides, this is great! I tried to understand the source code and it looks complicated. Nevertheless, it is a outstanding program/API and should deserver more praise.

#51 Creator

    Mad Dash Victor

  • Members
  • 2,168 posts
  • LocationYou will never find me, muhahahahahaha

Posted 15 April 2015 - 07:52 PM

What is that colours transparent you use. Is it like that it tells the rendering engine to skip the pixel?

#52 Lignum

  • Members
  • 558 posts

Posted 15 April 2015 - 08:09 PM

View PostCreator, on 15 April 2015 - 07:52 PM, said:

What is that colours transparent you use. Is it like that it tells the rendering engine to skip the pixel?

When rendering a transparent pixel, Bedrock will use the pixel that is currently at that location. If there is no pixel there in the buffer, it renders a black pixel.

#53 oeed

    Oversimplifier

  • Members
  • 2,095 posts
  • LocationAuckland, New Zealand

Posted 15 April 2015 - 10:13 PM

View Postsmigger22, on 15 April 2015 - 04:00 PM, said:

Brings me right back to home, so much designed like CSS.
Well, I can see what you mean in some aspects by setting properties. But other than that it's virtually completely different. But if you like it that's all that matter I guess.

View PostLignum, on 15 April 2015 - 08:09 PM, said:

View PostCreator, on 15 April 2015 - 07:52 PM, said:

What is that colours transparent you use. Is it like that it tells the rendering engine to skip the pixel?

When rendering a transparent pixel, Bedrock will use the pixel that is currently at that location. If there is no pixel there in the buffer, it renders a black pixel.
Hit the nail on the head there, that's exactly how it works. Basically you use it when you want to see underneath something.

#54 MAPE

  • New Members
  • 1 posts

Posted 04 May 2015 - 08:46 PM

WOW

This framework is super cool. Easy to use and I can develop my programs faster than ever. The best part of this is how I can use this with my own "Object types".

Good job! I hope you will continue the developing.

#55 PixelFox

  • Members
  • 106 posts

Posted 11 October 2015 - 01:43 PM

On the server I'm on, this API is banned because it lags everything out, If you could somehow make it less laggy, that'd be amazing!

#56 TheOddByte

    Lazy Coder

  • Members
  • 1,607 posts
  • LocationSweden

Posted 11 October 2015 - 01:58 PM

View PostLightning, on 11 October 2015 - 01:43 PM, said:

On the server I'm on, this API is banned because it lags everything out, If you could somehow make it less laggy, that'd be amazing!
First time I've seen an API banned from servers, but my guess is that oeed is currently busy with other stuff like Silica, so the probability of him continuing to work on this right now feels pretty low.

#57 oeed

    Oversimplifier

  • Members
  • 2,095 posts
  • LocationAuckland, New Zealand

Posted 11 October 2015 - 10:42 PM

View PostTheOddByte, on 11 October 2015 - 01:58 PM, said:

View PostLightning, on 11 October 2015 - 01:43 PM, said:

On the server I'm on, this API is banned because it lags everything out, If you could somehow make it less laggy, that'd be amazing!
First time I've seen an API banned from servers, but my guess is that oeed is currently busy with other stuff like Silica, so the probability of him continuing to work on this right now feels pretty low.

Yeah, to be honest I'm not surprised. I used OneOS for the first time in ages and I was shocked at how slow it was. I don't even know how it got so slow.

Needless to say though, as Silica can animate resizing circle and recolouring a circle with different easing functions smoothly, this won't be a problem with Silica ;)

#58 PixelFox

  • Members
  • 106 posts

Posted 12 October 2015 - 11:50 PM

View Postoeed, on 11 October 2015 - 10:42 PM, said:

View PostTheOddByte, on 11 October 2015 - 01:58 PM, said:

View PostLightning, on 11 October 2015 - 01:43 PM, said:

On the server I'm on, this API is banned because it lags everything out, If you could somehow make it less laggy, that'd be amazing!
First time I've seen an API banned from servers, but my guess is that oeed is currently busy with other stuff like Silica, so the probability of him continuing to work on this right now feels pretty low.

Yeah, to be honest I'm not surprised. I used OneOS for the first time in ages and I was shocked at how slow it was. I don't even know how it got so slow.

Needless to say though, as Silica can animate resizing circle and recolouring a circle with different easing functions smoothly, this won't be a problem with Silica ;)
Honestly, I don't think CC 2.0 is even CC.

#59 Luca_S

  • Members
  • 407 posts
  • LocationGermany

Posted 27 April 2016 - 05:29 AM

Is there a function to "unfocus" all objects(Especially text fields) or to unfocus a specific object

#60 WolfDood

  • Members
  • 20 posts
  • Locationjava.exception:3753:location not found

Posted 28 October 2016 - 07:09 PM

Umm It doesn't seem to work for me, this is what it comes up with...
Downloading Bedrock...
No loaded view. You need to do program:LoadView
first.
this was before...
local bedrockPath='/' if OneOS then OneOS.LoadAPI('/System/API/Bedrock.lua', false)elseif fs.exists(bedrockPath..'/Bedrock')then os.loadAPI(bedrockPath..'/Bedrock')else if http then print('Downloading Bedrock...')local h=http.get('http://pastebin.com/raw.php?i=0MgKNqpN')if h then local f=fs.open(bedrockPath..'/Bedrock','w')f.write(h.readAll())f.close()h.close()os.loadAPI(bedrockPath..'/Bedrock')else error('Failed to download Bedrock. Is your internet working?') end else error('This program needs to download Bedrock to work. Please enable HTTP.') end end if Bedrock then Bedrock.BasePath = bedrockPath Bedrock.ProgramPath = shell.getRunningProgram() end


local program = Bedrock:Initialise()

program:Run(function()
end)
Now I added this:
local bedrockPath='/' if OneOS then OneOS.LoadAPI('/System/API/Bedrock.lua', false)elseif fs.exists(bedrockPath..'/Bedrock')then os.loadAPI(bedrockPath..'/Bedrock')else if http then print('Downloading Bedrock...')local h=http.get('http://pastebin.com/raw.php?i=0MgKNqpN')if h then local f=fs.open(bedrockPath..'/Bedrock','w')f.write(h.readAll())f.close()h.close()os.loadAPI(bedrockPath..'/Bedrock')else error('Failed to download Bedrock. Is your internet working?') end else error('This program needs to download Bedrock to work. Please enable HTTP.') end end if Bedrock then Bedrock.BasePath = bedrockPath Bedrock.ProgramPath = shell.getRunningProgram() end

local program = Bedrock:Initialise()

program:LoadView("main")
program:Run(function()
end)
then it says:

Bedrock:2725: The view: main.view does not exist.
But now there is a program called Bedrock what do I do?





2 user(s) are reading this topic

0 members, 2 guests, 0 anonymous users