topic stringlengths 1 63 | text stringlengths 1 577k ⌀ |
|---|---|
he conseguido un iphone | [quote="pgfdz":2l1tzzku][quote="mastintin":2l1tzzku][quote="pgfdz":2l1tzzku]DBUSEAREA( .t., ,AppPath()+ "/ruta.dbf" , "rutas")
ERROR
[Session started at 2010-12-23 19:50:45 +0100.]
Detected an attempt to call a symbol in system libraries that is not present on the iPhone:
stat$INODE64 called from function s_fileExtOpen in image Tutor02.
If you are encountering this problem running a simulator binary within gdb, make sure you 'set start-with-shell off' first.[/quote:2l1tzzku]
Te envio la nueva librería que en teoría ya resuelve el problema . Cambiala y miramos a ver si funciona...
[url:2l1tzzku]http://rapidshare.com/files/438930423/libfivephone.a[/url:2l1tzzku]
Saludos.[/quote:2l1tzzku]
Se queda colgado y pone en la consola todo el rato:
2010-12-23 23:17:45.929 Tutor02[5874:207] stat
2010-12-23 23:17:45.930 Tutor02[5874:207] open
2010-12-23 23:17:45.931 Tutor02[5874:207] stat
2010-12-23 23:17:45.931 Tutor02[5874:207] open
Ahora he hecho el create en el apppath y luego el use y me sale:
[Session started at 2010-12-23 23:26:42 +0100.]
2010-12-23 23:26:43.515 Tutor02[5970:207] stat
2010-12-23 23:26:43.517 Tutor02[5970:207] open
2010-12-23 23:26:43.518 Tutor02[5970:207] fcntl
2010-12-23 23:26:43.518 Tutor02[5970:207] fstat
Detected an attempt to call a symbol in system libraries that is not present on the iPhone:
pwrite$UNIX2003 called from function hb_fsWriteAt in image Tutor02.
If you are encountering this problem running a simulator binary within gdb, make sure you 'set start-with-shell off' first.[/quote:2l1tzzku]
Nueva libreria con la funcion añadida .... [url:2l1tzzku]http://rapidshare.com/files/439055213/libfivephone.a[/url:2l1tzzku]
Cambiala y vemos si falta algo mas .
Saludos. |
he conseguido un iphone | Antonio , intentando seguirte , me quedo en hb_vmInit( TRUE );
Aqui se me rompe la aplicacion ...
Saludos.
-------------- edito -----------------------
Solucionado , se me paso el codigo que teniamos metido por plantilla en el main.c .
Antonio funciona perfectamente y a mi me funcionan las acciones de los botones y demas ..
Saludos. |
he conseguido un iphone | He estado experimentando un poco con los outlet del Interface builder y la verdad es que quitan mucho código ....
Con estas lineas solo y tengo funcionando el webview con los botones y todo ....tiempo estimado 2minuto +-
Si alguien no lo cree aqui esta el video para demostrarlo .[url:1hgbkzpx]http://www.youtube.com/watch?v=YFUit5Rtr6Q[/url:1hgbkzpx]
[code=fw:1hgbkzpx]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"fivephone.ch"</span><br /><br /><span style="color: #00C800;">function</span> Main<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /> <span style="color: #00C800;">local</span> owebview ,oWnd := TWindow<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">GetMain</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <br /> <span style="color: #0000ff;">REDEFINE</span> WEB oWebview <span style="color: #0000ff;">ID</span> <span style="color: #000000;">77</span> <span style="color: #0000ff;">OF</span> oWnd URL <span style="color: #ff0000;">"http://www.google.com"</span><br /> <br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span> <br /><br /> </div>[/code:1hgbkzpx]
[img:1hgbkzpx]http://img838.imageshack.us/img838/7682/screencapturefd.png[/img:1hgbkzpx] |
he conseguido un iphone | Hola
Estoy intentando recuperar los últimos cambios para rehacer la libreria. A ver si lo hago bien.
svn dobleclick en fivephone, update
Una vez actualizado abro el terminal
cd fivephone
make
eso supongo que remonta las librerias con los últimos cambios.
He hecho lo mismo que en el video de youtube, por cierto genial, y no me compila.
Me da este error:
Command /bin/sh failed with exit code 1
el código del prg es el que pones en el anterior post
Un saludo |
he conseguido un iphone | [quote="pgfdz":b5ef8374]Hola
Estoy intentando recuperar los últimos cambios para rehacer la libreria. A ver si lo hago bien.
svn dobleclick en fivephone, update
Una vez actualizado abro el terminal
cd fivephone
make
eso supongo que remonta las librerias con los últimos cambios.
He hecho lo mismo que en el video de youtube, por cierto genial, y no me compila.
Me da este error:
Command /bin/sh failed with exit code 1
el código del prg es el que pones en el anterior post
Un saludo[/quote:b5ef8374]
El video utiliza los ultimos cambios en en webview.prg y en el archivo fivephone.ch ( son pocos , pero existen ) y la manera de componer las librerias es como dices haciendo make .
Tambien tiene un cambio en la plantilla de fivephone , para adaptarlo a los cambios que ha hecho Antonio en el uso de archivos nib , pero aun no se ha subido pues lo estoy probando primero para evitar problemas . |
he conseguido un iphone | El error entonces, no te suena? |
he conseguido un iphone | [quote="pgfdz":kjdh786c]El error entonces, no te suena?[/quote:kjdh786c]
Si despliegas el notificador de errores del xcode seguro que te da el error exacto . Seguro que es que no te compila correctamente el prg ...
si quieres pon aqui todo el archivo de error y lo miramos ..
Voy a preparar un video corto para que veas como mirar los errores ....
el video [url:kjdh786c]http://www.youtube.com/watch?v=-6XPsLEmdsA[/url:kjdh786c] |
he conseguido un iphone | [quote="mastintin":2n6tfqhk][quote="pgfdz":2n6tfqhk]El error entonces, no te suena?[/quote:2n6tfqhk]
Si despliegas el notificador de errores del xcode seguro que te da el error exacto . Seguro que es que no te compila correctamente el prg ...
si quieres pon aqui todo el archivo de error y lo miramos ..
Voy a preparar un video corto para que veas como mirar los errores ....
el video [url:2n6tfqhk]http://www.youtube.com/watch?v=-6XPsLEmdsA[/url:2n6tfqhk][/quote:2n6tfqhk]
Genial, voy a ver cual es mi error.
Por cierto ¿con que capturas las secuencias?
Es que me parece genial el tema de los vídeos. En el siglo 21 que vamos creo que tenemos que utilizar mas a menudo los vídeos y cualquier nueva forma que trascienda al simple manual de texto puro y duro. |
he conseguido un iphone | tutor03.prg(6) Error E0030 Syntax error "syntax error at 'WEB'"
1 error
parece que el redefine esta mal, voy a ver |
he conseguido un iphone | para crear las capturas quicktime es tu amigo <!-- s:D --><img src="{SMILIES_PATH}/icon_biggrin.gif" alt=":D" title="Very Happy" /><!-- s:D --> .
En windows siempre debes añadir programas para hacer cualquier cosa . En Mac casi siempre tienes un programa simple que viene con el sistema , para hacer cosas simples .Para las complicadas seguro que tienes version profesional .
Quicktime player ->Archivo -> nueva grabaciopn de pantalla .
Si quieres salir en el video en una esquina ( por ejemplo) . Enciende el photo booth deja que tu camara te grabe mientras que con el quicktime grabas la pantalla .( tip <!-- s:shock: --><img src="{SMILIES_PATH}/icon_eek.gif" alt=":shock:" title="Shocked" /><!-- s:shock: --> )
Saludos. |
he conseguido un iphone | [quote="pgfdz":33rurtpi]tutor03.prg(6) Error E0030 Syntax error "syntax error at 'WEB'"
1 error
parece que el redefine esta mal, voy a ver[/quote:33rurtpi]
---- edito ----
Pues el ch está bien. ¿Puede ser que este tirando de otro ch? El que está bien es el que esta en mi usuario/fivephone/include no se si hay algun otro path por otro lado |
he conseguido un iphone | [quote="mastintin":3ifei8zc]para crear las capturas quicktime es tu amigo <!-- s:D --><img src="{SMILIES_PATH}/icon_biggrin.gif" alt=":D" title="Very Happy" /><!-- s:D --> .
En windows siempre debes añadir programas para hacer cualquier cosa . En Mac casi siempre tienes un programa simple que viene con el sistema , para hacer cosas simples .Para las complicadas seguro que tienes version profesional .
Quicktime player ->Archivo -> nueva grabaciopn de pantalla .
Si quieres salir en el video en una esquina ( por ejemplo) . Enciende el photo booth deja que tu camara te grabe mientras que con el quicktime grabas la pantalla .( tip <!-- s:shock: --><img src="{SMILIES_PATH}/icon_eek.gif" alt=":shock:" title="Shocked" /><!-- s:shock: --> )
Saludos.[/quote:3ifei8zc]
que fuerte, joder en Windows todo son parches. |
he conseguido un iphone | [quote="pgfdz":3q8jpsb7]tutor03.prg(6) Error E0030 Syntax error "syntax error at 'WEB'"
1 error
parece que el redefine esta mal, voy a ver[/quote:3q8jpsb7]
Si no te sale cambia el redefine por :
[code=fw:3q8jpsb7]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><br />oweb:=TwebView<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">Resources</span><span style="color: #000000;">(</span>ownd,<span style="color: #000000;">77</span><span style="color: #000000;">)</span><br />oweb:<span style="color: #000000;">setUrl</span><span style="color: #000000;">(</span><span style="color: #ff0000;">"http://www.google.com"</span><span style="color: #000000;">)</span><br /><br /> </div>[/code:3q8jpsb7] |
he conseguido un iphone | pues estaba montando en usuario/fivephone y xcode lo pilla de developer/fivephone/fivephone
Bueno ahora no hay errores pero tampoco muestra la vista. Voy a seguir investigando
Gracias |
he conseguido un iphone | Donde estas generando la nueva lib ¿ en tu usuario ? , sustituye la lib que tienes en /developer/fivephone/fivephone/lib por la nueva y sustituye el preprocesado por las dos lineas que te puse arriba a ver si sale algo . |
he conseguido un iphone | [quote="mastintin":hxaklf4y]Donde estas generando la nueva lib ¿ en tu usuario ? , sustituye la lib que tienes en /developer/fivephone/fivephone/lib por la nueva y sustituye el preprocesado por las dos lineas que te puse arriba a ver si sale algo .[/quote:hxaklf4y]
Si es eso lo que había hecho. La pantalla se queda negra total, pero se nota que sale algo.
Pelicula, jajaja
[url:hxaklf4y]http://www.youtube.com/watch?v=hFBCgD7Cm4c[/url:hxaklf4y]
a ver que tal
--- edito ----
para ser la primera...
la siguiente saldra mejor. Creo que no ha terminado de procesarla bien youtube |
he conseguido un iphone | Vamos a hacer unos cambios .... vete a tu proyecto y edita en main.c .... en el tienes una linea hb_vinit() ... comentala .
Vete a la carpeta clases dentro tendras 2 archivos uno se llamara tutorwebviewAppDelegate ... editalo ....y en didFinisLauchingWithOptions pon asi :
[code=fw:1juzqoo4]<div class="fw" id="{CB}" style="font-family: monospace;"><br />- <span style="color: #000000;">(</span>BOOL<span style="color: #000000;">)</span>application:<span style="color: #000000;"><span style="color: #000000;">(</span>UIApplication</span> *<span style="color: #000000;">)</span>application didFinishLaunchingWithOptions:<span style="color: #000000;"><span style="color: #000000;">(</span>NSDictionary</span> *<span style="color: #000000;">)</span>launchOptions <span style="color: #000000;">{</span> <br /> <br /> <br /> SetWndMain<span style="color: #000000;">(</span> <span style="color: #00C800;">self</span>.<span style="color: #0000ff;">window</span> <span style="color: #000000;">)</span>;<br /> <br /> <span style="color: #B900B9;">// Add the view controller's view to the window and display.</span><br /> <br /> <span style="color: #000000;">[</span><span style="color: #00C800;">self</span>.<span style="color: #0000ff;">window</span> addSubview:<span style="color: #000000;">viewController</span>.view<span style="color: #000000;">]</span>;<br /> <span style="color: #000000;">[</span><span style="color: #00C800;">self</span>.<span style="color: #0000ff;">window</span> makeKeyAndVisible<span style="color: #000000;">]</span>;<br /> <br /> hb_vmInit<span style="color: #000000;">(</span> <span style="color: #00C800;">TRUE</span> <span style="color: #000000;">)</span>;<br /><br /> <span style="color: #B900B9;">/*<br /> PHB_SYMB symMain = hb_dynsymSymbol( hb_dynsymFindName( "MAIN" ) );<br /> <br /> // app = self;<br /> <br /> hb_vmPushSymbol( symMain );<br /> hb_vmPushNil();<br /> hb_vmDo( 0 ); <br /> <br /> return YES;<br /> */</span><br /><span style="color: #000000;">}</span><br /><br /><br /> </div>[/code:1juzqoo4] |
he conseguido un iphone | Tocado y hundido, jajajaja
genial, funciona.
Oye, yo no se si la gente es muy consciente de lo interesante que es todo esto.
No me gusta ser un "fundamentalista" de nada. NO me gusta casarme con algo porque no sepa hacer lo superior. Yo lo que veo que de esta forma se va a programar el iphone y el ipad con la gorra. Es mas de lo que nos pasó con FiveWin. No se si Antonio tiene un plan de comercialización de esto o que, pero creo que esto puede ser grande. Bueno, tengo claro que todo no se podrá hacer con 5p pero tenemos, otra vez, todo el C para hacer lo que no se haga fácil. |
he conseguido un iphone | los cambios que acabas de hacer son los que estan pendientes de colocar en la plantilla . Falta que Antonio repase el proceso pues el tenía algun problema , pero en el momento que veamos que no rompe nada de lo anterior , cambiamos la plantilla y listo .
Como bien dices ,se puede programar el iphone de una forma sencilla y las unicas limitaciones son por parte de la propia Apple . A dia de hoy se pueden hacer ya cosas interesantes y seguro que con ideas podemos pulir cosas que quedan .
Saludos. |
he conseguido un iphone | Por mi parte he estado mirando como se pinta en las views y me parece bastante sencillo. Lo que no se muy bien como hacer para poder interceptar el pintado de una view en concreto. ¿Podríais hacer un bPaint o algo asi para poder empezar a hacer pruebas?
para un programa que quiero hacer necesito hacer una especie de Radar, bueno, una especie no, un radar. Voy a ir pintando puntos de latitud y longitud en un radar con centro en mi posición. |
he conseguido un iphone | [quote="pgfdz":2gqgh0um]Por mi parte he estado mirando como se pinta en las views y me parece bastante sencillo. Lo que no se muy bien como hacer para poder interceptar el pintado de una view en concreto. ¿Podríais hacer un bPaint o algo asi para poder empezar a hacer pruebas?
para un programa que quiero hacer necesito hacer una especie de Radar, bueno, una especie no, un radar. Voy a ir pintando puntos de latitud y longitud en un radar con centro en mi posición.[/quote:2gqgh0um]
SEgun leo aqui :
[code=fw:2gqgh0um]<div class="fw" id="{CB}" style="font-family: monospace;"><br />The View Drawing Cycle<br />View drawing occurs <span style="color: #0000ff;">on</span> an as-needed basis. <span style="color: #0000ff;">When</span> a view is first shown, or <span style="color: #0000ff;">when</span> all or part <span style="color: #0000ff;">of</span> it becomes visible due <span style="color: #0000ff;">to</span> layout changes, the system asks the view <span style="color: #0000ff;">to</span> draw its contents. <span style="color: #00C800;">For</span> views that contain custom content using UIKi or Core Graphics, the system calls the view’s drawRect: <span style="color: #00C800;">method</span>. Your implementation <span style="color: #0000ff;">of</span> this <span style="color: #00C800;">method</span> is responsible <span style="color: #00C800;">for</span> drawing the view’s content into the current graphics context, which is set <span style="color: #0000ff;">up</span> by the system automatically prior <span style="color: #0000ff;">to</span> calling this <span style="color: #00C800;">method</span>. This creates a <span style="color: #00C800;">static</span> visual representation <span style="color: #0000ff;">of</span> your view’s content that can then be displayed <span style="color: #0000ff;">on</span> the screen.<br /><br /><span style="color: #0000ff;">When</span> the actual content <span style="color: #0000ff;">of</span> your view changes, it is your responsibility <span style="color: #0000ff;">to</span> notify the system that your view needs <span style="color: #0000ff;">to</span> be redrawn. You <span style="color: #00C800;">do</span> this by calling your view’s setNeedsDisplay or setNeedsDisplayInRect: <span style="color: #00C800;">method</span> <span style="color: #0000ff;">of</span> the view. These methods let the system know that it should <span style="color: #0000ff;">update</span> the view during the <span style="color: #00C800;">next</span> drawing cycle. Because it waits until the <span style="color: #00C800;">next</span> drawing cycle <span style="color: #0000ff;">to</span> <span style="color: #0000ff;">update</span> the view, you can call these methods <span style="color: #0000ff;">on</span> multiple views <span style="color: #0000ff;">to</span> <span style="color: #0000ff;">update</span> them <span style="color: #00C800;">at</span> the same time.<br /><br /> </div>[/code:2gqgh0um]
el metodo que se usa para pintar es el drawrect , en el se ponen las instrucciones de lo que queremos pintar ( lo que va a quedar estatico , en tu caso el radar ) y con una llamada a los metodos setneedsDisplay se mandaría al systema que repintara el view y asi poder colocar los puntos moviles ... sería como un oView:refresh() o algo similar . ¿ Es Eso lo que necesitas ? .Yo creo que se podría implementar ,sin demasiado problema .
Podemos intentarlo a ver que pasa , ponme una idea del codigo que tienes pensado para dibujar ..., supongo que primero deberíamos crear unas "funciones" en "harbour que nos dibujen los circulos o algo similar . |
he conseguido un iphone | [quote="pgfdz":3mpr1yrp]Por mi parte he estado mirando como se pinta en las views y me parece bastante sencillo. Lo que no se muy bien como hacer para poder interceptar el pintado de una view en concreto. ¿Podríais hacer un bPaint o algo asi para poder empezar a hacer pruebas?
para un programa que quiero hacer necesito hacer una especie de Radar, bueno, una especie no, un radar. Voy a ir pintando puntos de latitud y longitud en un radar con centro en mi posición.[/quote:3mpr1yrp]
Paco .
Tengo ya implentadas , a falta de probar y mirar si tienen bug ( estoy en windows ) las funciones de abajo :
Tambien tengo a medias el evento drawRect:(CGRect)rect pero no sé si implementarlo como un bpaint o un bInit ( no me manejo demasiado en fivewin ) ¿ Antonio ? ....
[code=fw:3mpr1yrp]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><br /><span style="color: #00C800;">HB_FUNC</span><span style="color: #000000;">(</span> CLEARAREA <span style="color: #000000;">)</span><br /><span style="color: #000000;">{</span><br />CGContextRef ctx = UIGraphicsGetCurrentContext<span style="color: #000000;">(</span><span style="color: #000000;">)</span>;<br />CGContextClearRect<span style="color: #000000;">(</span>ctx, hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">1</span> <span style="color: #000000;">)</span><span style="color: #000000;">)</span>;<br /><span style="color: #000000;">}</span><br /><br /><span style="color: #00C800;">HB_FUNC</span><span style="color: #000000;">(</span> DRAWBORDERCIRCLE <span style="color: #000000;">)</span><br /><span style="color: #000000;">{</span><br />CGContextRef ctx = UIGraphicsGetCurrentContext<span style="color: #000000;">(</span><span style="color: #000000;">)</span>;<br /><span style="color: #B900B9;">// Draw a circle (border only)</span><br />CGContextSetRGBStrokeColor<span style="color: #000000;">(</span>ctx, <span style="color: #000000;">(</span> hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">5</span> <span style="color: #000000;">)</span>/<span style="color: #000000;">255.0</span> <span style="color: #000000;">)</span>, <span style="color: #000000;">(</span> hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">6</span> <span style="color: #000000;">)</span>/<span style="color: #000000;">255.0</span> <span style="color: #000000;">)</span> , <span style="color: #000000;">(</span> hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">7</span> <span style="color: #000000;">)</span>/<span style="color: #000000;">255.0</span> <span style="color: #000000;">)</span> , <span style="color: #000000;">(</span> hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">8</span> <span style="color: #000000;">)</span>/<span style="color: #000000;">100.0</span> <span style="color: #000000;">)</span> <span style="color: #000000;">)</span>;<br />CGContextStrokeEllipseInRect<span style="color: #000000;">(</span>ctx, CGRectMake<span style="color: #000000;">(</span>hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">1</span> <span style="color: #000000;">)</span>, hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">2</span> <span style="color: #000000;">)</span>, hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">3</span> <span style="color: #000000;">)</span>, hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">4</span> <span style="color: #000000;">)</span> <span style="color: #000000;">)</span> <span style="color: #000000;">)</span>;<br /><span style="color: #000000;">}</span><br /><br /><span style="color: #00C800;">HB_FUNC</span><span style="color: #000000;">(</span> DRAWCIRCLE <span style="color: #000000;">)</span><br /><span style="color: #000000;">{</span><br />CGContextRef ctx = UIGraphicsGetCurrentContext<span style="color: #000000;">(</span><span style="color: #000000;">)</span>;<br /><span style="color: #B900B9;">// Draw a circle (border only)</span><br />CGContextSetRGBFillColor<span style="color: #000000;">(</span>ctx,<span style="color: #000000;">(</span> hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">5</span> <span style="color: #000000;">)</span>/<span style="color: #000000;">255.0</span> <span style="color: #000000;">)</span>, <span style="color: #000000;">(</span> hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">6</span> <span style="color: #000000;">)</span>/<span style="color: #000000;">255.0</span> <span style="color: #000000;">)</span> , <span style="color: #000000;">(</span> hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">7</span> <span style="color: #000000;">)</span>/<span style="color: #000000;">255.0</span> <span style="color: #000000;">)</span> , <span style="color: #000000;">(</span> hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">8</span> <span style="color: #000000;">)</span>/<span style="color: #000000;">100.0</span> <span style="color: #000000;">)</span> <span style="color: #000000;">)</span>;<br />CGContextFillEllipseInRect<span style="color: #000000;">(</span>ctx, CGRectMake<span style="color: #000000;">(</span>hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">1</span> <span style="color: #000000;">)</span>, hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">2</span> <span style="color: #000000;">)</span>, hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">3</span> <span style="color: #000000;">)</span>, hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">4</span> <span style="color: #000000;">)</span> <span style="color: #000000;">)</span> <span style="color: #000000;">)</span>;<br /><span style="color: #000000;">}</span><br /><br /><span style="color: #00C800;">HB_FUNC</span><span style="color: #000000;">(</span> DRAWLINE <span style="color: #000000;">)</span><br /><span style="color: #000000;">{</span><br />CGContextRef ctx = UIGraphicsGetCurrentContext<span style="color: #000000;">(</span><span style="color: #000000;">)</span>;<br />CGContextSetRGBStrokeColor<span style="color: #000000;">(</span>ctx, <span style="color: #000000;">(</span> hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">5</span> <span style="color: #000000;">)</span>/<span style="color: #000000;">255.0</span> <span style="color: #000000;">)</span>, <span style="color: #000000;">(</span> hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">6</span> <span style="color: #000000;">)</span>/<span style="color: #000000;">255.0</span> <span style="color: #000000;">)</span> , <span style="color: #000000;">(</span> hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">7</span> <span style="color: #000000;">)</span>/<span style="color: #000000;">255.0</span> <span style="color: #000000;">)</span> , <span style="color: #000000;">(</span> hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">8</span> <span style="color: #000000;">)</span>/<span style="color: #000000;">100.0</span> <span style="color: #000000;">)</span> <span style="color: #000000;">)</span>;<br />CGPoint points<span style="color: #000000;">[</span><span style="color: #000000;">2</span><span style="color: #000000;">]</span> = <span style="color: #000000;">{</span> CGPointMake<span style="color: #000000;">(</span>hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">1</span> <span style="color: #000000;">)</span>, hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">2</span> <span style="color: #000000;">)</span><span style="color: #000000;">)</span>, CGPointMake<span style="color: #000000;">(</span>hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">3</span> <span style="color: #000000;">)</span>,hb_parnl<span style="color: #000000;">(</span> <span style="color: #000000;">4</span> <span style="color: #000000;">)</span><span style="color: #000000;">)</span> <span style="color: #000000;">}</span>;<br />CGContextStrokeLineSegments<span style="color: #000000;">(</span>ctx, points, <span style="color: #000000;">2</span><span style="color: #000000;">)</span>;<br /><span style="color: #000000;">}</span><br /><br /> </div>[/code:3mpr1yrp] |
he conseguido un iphone | [url:1kui3z6n]http://osdir.com/ml/cocoa-dev/2009-09/msg02037.html[/url:1kui3z6n]
a ver si esto sirve. Voy a ver que me pusiste en el anterior post. Un segundo |
he conseguido un iphone | Los controles personalizados creo que se pueden hacer desde el Interface Builder en forma de plugins. Mira:
[i:3r7yzqwi]Custom views in Interface Builder using IBPlugins[/i:3r7yzqwi] [url:3r7yzqwi]http://cocoawithlove.com/2009/07/custom-views-in-interface-builder-using.html[/url:3r7yzqwi] |
he conseguido un iphone | [quote="pgfdz":15e2hon7][url:15e2hon7]http://osdir.com/ml/cocoa-dev/2009-09/msg02037.html[/url:15e2hon7]
a ver si esto sirve. Voy a ver que me pusiste en el anterior post. Un segundo[/quote:15e2hon7]
Esto que me pones es para Macosx . figate que en el código pone NSview en vez UIView . Las interfaces de IOS empiezan por UI . Como idea para traspasarlo a ios puede servir lo miraré .
Por otro lado , independiente que creemos las funciones para dibujar ,yo colocaría una imagen PNG con fondo traspatente como imagen de "radar" y sobre ella pintaría los puntos . |
he conseguido un iphone | Hola
(toy mailto) Entre desmallo y desmallo <!-- s:( --><img src="{SMILIES_PATH}/icon_sad.gif" alt=":(" title="Sad" /><!-- s:( -->
He visto que tenemos una clase TView. Supongo que en esa clase se puede interceptar DrawRect ¿no? Esta clase sería la TControl de la que podríamos hacer user controls. Luego empezamos a hacer wrapers para las funciones de pintado, que con lo que me has puesto antes tengo para empezar y listo ¿no?
El CGContextRef se convierte en DATA que se rellena al principio del DrawRect y apartir de ahi se le pasa a las funciones de pintado
No lo veo muy diferente a Wnd2 |
he conseguido un iphone | he encontrado esto :[url:2jnwxlvt]http://books.google.com/books?id=QoxeAqTvevIC&pg=PA41&lpg=PA41&dq=draw+circle+in+interface+builder+iphone&source=bl&ots=fKTbQ1IDf_&sig=VAOsi2ehQmx9WnN1o4cltUB06_U&hl=en&ei=In0YTbi0Nc6OjAeF5ej2BQ&sa=X&oi=book_result&ct=result&resnum=9&ved=0CEwQ6AEwCDgU#v=onepage&q&f=false[/url:2jnwxlvt]
en el capitulo 3 aparece un proyecto simple que puede servir de referencia ... |
he conseguido un iphone | [quote="mastintin":2q4gtc5v]he encontrado esto :[url:2q4gtc5v]http://books.google.com/books?id=QoxeAqTvevIC&pg=PA41&lpg=PA41&dq=draw+circle+in+interface+builder+iphone&source=bl&ots=fKTbQ1IDf_&sig=VAOsi2ehQmx9WnN1o4cltUB06_U&hl=en&ei=In0YTbi0Nc6OjAeF5ej2BQ&sa=X&oi=book_result&ct=result&resnum=9&ved=0CEwQ6AEwCDgU#v=onepage&q&f=false[/url:2q4gtc5v]
en el capitulo 3 aparece un proyecto simple que puede servir de referencia ...[/quote:2q4gtc5v]
lo miro |
he conseguido un iphone | Primera aproximación .Ya ruta el evento bpaint y ya dibujo circunferencias con color desde una funcion de harbour :
[img:2ahleavt]http://img213.imageshack.us/img213/8959/screencaptures.png[/img:2ahleavt] |
he conseguido un iphone | Hola
La cosa sería poder tener un TView del que heredar para poder hacer controles. ¿Cómo lo ves?
Si yo hago TRadar FROM TView y empiezo a programar el objeto...
¿Con eso se puede hacer algo? |
he conseguido un iphone | [quote="pgfdz":29ewyplt]Hola
La cosa sería poder tener un TView del que heredar para poder hacer controles. ¿Cómo lo ves?
Si yo hago TRadar FROM TView y empiezo a programar el objeto...
¿Con eso se puede hacer algo?[/quote:29ewyplt]
Creo que si . No tiene porque tener problemas .Espera que esta noche que suba el código al repositorio ( ya te aviso con un mensaje aqui) regenera la lib y miramos que problemas nos da. |
he conseguido un iphone | huston, huston...
/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/libtool -static -o ./lib/libfive.a ./obj/accel.o ./obj/actind.o ./obj/actionsheet.o ./obj/button.o ./obj/datepck.o ./obj/imgview.o ./obj/label.o ./obj/movie.o ./obj/navbar.o ./obj/nsobject.o ./obj/tblview.o ./obj/get.o ./obj/toolbar.o ./obj/picview.o ./obj/progres.o ./obj/search.o ./obj/segment.o ./obj/slider.o ./obj/switch.o ./obj/tabbar.o ./obj/timer.o ./obj/tblviewCell.o ./obj/valtochr.o ./obj/webview.o ./obj/view.o ./obj/window.o
/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/gcc-4.2 -arch armv6 -mthumb -isysroot /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS4.2.sdk -fobjc-legacy-dispatch -I./../harbour/include -I./include -Wall -c -o objc/views.o source/sdkapi/views.m
source/sdkapi/views.m: In function ‘-[View drawRect:]’:
source/sdkapi/views.m:74: error: ‘symFPH’ undeclared (first use in this function)
source/sdkapi/views.m:74: error: (Each undeclared identifier is reported only once
source/sdkapi/views.m:74: error: for each function it appears in.)
source/sdkapi/views.m:77: warning: implicit declaration of function ‘hb_vmPushSymbol’
source/sdkapi/views.m:78: warning: implicit declaration of function ‘hb_vmPushNil’
source/sdkapi/views.m:79: warning: implicit declaration of function ‘hb_vmPushLong’
source/sdkapi/views.m:79: error: aggregate value used where an integer was expected
source/sdkapi/views.m:80: error: ‘WM_VIEWPAINT’ undeclared (first use in this function)
source/sdkapi/views.m:81: warning: implicit declaration of function ‘hb_vmDo’
source/sdkapi/views.m: In function ‘HB_FUN_CLEARAREA’:
source/sdkapi/views.m:303: error: incompatible type for argument 2 of ‘CGContextClearRect’
make: *** [objc/views.o] Error 1
rm obj/progres.c obj/actind.c obj/get.c obj/label.c obj/search.c obj/switch.c obj/timer.c obj/webview.c obj/tabbar.c obj/navbar.c obj/picview.c obj/nsobject.c obj/slider.c obj/segment.c obj/accel.c obj/toolbar.c obj/valtochr.c obj/tblview.c obj/tblviewCell.c obj/view.c obj/button.c obj/window.c obj/movie.c obj/actionsheet.c obj/imgview.c obj/datepck.c
MacBook-Pro-de-Francisco-Garcia-Fernandez:fivephone franciscogarciafernandez$ |
he conseguido un iphone | Te lo grabo en video para que veas. También me ha salido un directorio fivephone Working Copy ??? que coño he hecho???
[url:1j6p6csl]http://www.youtube.com/watch?v=HUs-CXwO_JA[/url:1j6p6csl] |
he conseguido un iphone | Aun no estaban subidos los cambios al repositorio . Vuelve a cargar el repositorio ahora ... atento que el archivo fmsgs.h que esta en include tambien tiene cambios . |
he conseguido un iphone | la libreria monta ok. Pegame el código, plis |
he conseguido un iphone | [quote="pgfdz":19zmzf79]la libreria monta ok. Pegame el código, plis[/quote:19zmzf79]
He vuelto a subir una nueva version de view.m al repositorio borrando un msginfo() de la depuracion que se quedo sin borrar .Vuelve a cargar el repositorio y regenera la libreria .
El codigo que tengo ahora mismo , un poco mas elaborado ya es este :
[code=fw:19zmzf79]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"fivephone.ch"</span><br /><br /><span style="color: #00C800;">function</span> Main<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /> <span style="color: #00C800;">local</span> owebview ,oWnd := TWindow<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">GetMain</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <br /> <br /> oView1 = TView<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #00C800;">New</span><span style="color: #000000;">(</span> oWnd,<span style="color: #000000;">0</span>, <span style="color: #000000;">0</span>, ScreenWidth<span style="color: #000000;">(</span><span style="color: #000000;">)</span>, ScreenHeight<span style="color: #000000;">(</span><span style="color: #000000;">)</span> - <span style="color: #000000;">49</span> <span style="color: #000000;">)</span><br /> oView1:<span style="color: #000000;">SetBkgColor</span><span style="color: #000000;">(</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">255</span>, <span style="color: #000000;">0</span>, <span style="color: #000000;">255</span> <span style="color: #000000;">)</span><br /> oview1:<span style="color: #000000;">bpaint</span>:= <span style="color: #000000;">{</span>|| dibuja<span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">}</span><br /> <span style="color: #B900B9;">// oview1:Repaint() </span><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span> <br /><br /><span style="color: #00C800;">Function</span> dibuja<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> DrawBorderCircle<span style="color: #000000;">(</span><span style="color: #000000;">50</span>,<span style="color: #000000;">50</span>,<span style="color: #000000;">130</span>,<span style="color: #000000;">130</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">100</span> <span style="color: #000000;">)</span><br /> DrawBorderCircle<span style="color: #000000;">(</span><span style="color: #000000;">60</span>,<span style="color: #000000;">60</span>,<span style="color: #000000;">110</span>,<span style="color: #000000;">110</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">100</span> <span style="color: #000000;">)</span> <br /> DrawBorderCircle<span style="color: #000000;">(</span><span style="color: #000000;">70</span>,<span style="color: #000000;">70</span>,<span style="color: #000000;">90</span>,<span style="color: #000000;">90</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">100</span> <span style="color: #000000;">)</span><br /> DrawBorderCircle<span style="color: #000000;">(</span><span style="color: #000000;">80</span>,<span style="color: #000000;">80</span>,<span style="color: #000000;">70</span>,<span style="color: #000000;">70</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">100</span> <span style="color: #000000;">)</span><br /> DrawBorderCircle<span style="color: #000000;">(</span><span style="color: #000000;">90</span>,<span style="color: #000000;">90</span>,<span style="color: #000000;">50</span>,<span style="color: #000000;">50</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">100</span> <span style="color: #000000;">)</span><br /> DrawBorderCircle<span style="color: #000000;">(</span><span style="color: #000000;">100</span>,<span style="color: #000000;">100</span>,<span style="color: #000000;">30</span>,<span style="color: #000000;">30</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">100</span> <span style="color: #000000;">)</span> <br /> DrawCircle<span style="color: #000000;">(</span><span style="color: #000000;">110</span>,<span style="color: #000000;">110</span>,<span style="color: #000000;">10</span>,<span style="color: #000000;">10</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">100</span> <span style="color: #000000;">)</span> <br /> DrawLine<span style="color: #000000;">(</span><span style="color: #000000;">69</span>,<span style="color: #000000;">69</span>,<span style="color: #000000;">161</span>,<span style="color: #000000;">161</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">100</span><span style="color: #000000;">)</span> <br /> DrawLine<span style="color: #000000;">(</span><span style="color: #000000;">115</span>,<span style="color: #000000;">50</span>,<span style="color: #000000;">115</span>,<span style="color: #000000;">180</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">100</span><span style="color: #000000;">)</span> <br /> DrawLine<span style="color: #000000;">(</span><span style="color: #000000;">50</span>,<span style="color: #000000;">115</span>,<span style="color: #000000;">180</span>,<span style="color: #000000;">115</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">100</span><span style="color: #000000;">)</span> <br /> DrawLine<span style="color: #000000;">(</span><span style="color: #000000;">69</span>,<span style="color: #000000;">161</span>,<span style="color: #000000;">161</span>,<span style="color: #000000;">69</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">100</span><span style="color: #000000;">)</span> <br /> <span style="color: #00C800;">Return</span> <span style="color: #00C800;">nil</span><br /><br /> </div>[/code:19zmzf79]
[img:19zmzf79]http://img830.imageshack.us/img830/8418/screencapturen.png[/img:19zmzf79] |
he conseguido un iphone | Subido al repositorio el nuevo template compatible con los cambios propuestos por Antonio.
Saludos. |
he conseguido un iphone | [quote="mastintin":d45kogap][quote="pgfdz":d45kogap]la libreria monta ok. Pegame el código, plis[/quote:d45kogap]
He vuelto a subir una nueva version de view.m al repositorio borrando un msginfo() de la depuracion que se quedo sin borrar .Vuelve a cargar el repositorio y regenera la libreria .
El codigo que tengo ahora mismo , un poco mas elaborado ya es este :
[code=fw:d45kogap]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"fivephone.ch"</span><br /><br /><span style="color: #00C800;">function</span> Main<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /><br /> <span style="color: #00C800;">local</span> owebview ,oWnd := TWindow<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">GetMain</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <br /> <br /> oView1 = TView<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #00C800;">New</span><span style="color: #000000;">(</span> oWnd,<span style="color: #000000;">0</span>, <span style="color: #000000;">0</span>, ScreenWidth<span style="color: #000000;">(</span><span style="color: #000000;">)</span>, ScreenHeight<span style="color: #000000;">(</span><span style="color: #000000;">)</span> - <span style="color: #000000;">49</span> <span style="color: #000000;">)</span><br /> oView1:<span style="color: #000000;">SetBkgColor</span><span style="color: #000000;">(</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">255</span>, <span style="color: #000000;">0</span>, <span style="color: #000000;">255</span> <span style="color: #000000;">)</span><br /> oview1:<span style="color: #000000;">bpaint</span>:= <span style="color: #000000;">{</span>|| dibuja<span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">}</span><br /> <span style="color: #B900B9;">// oview1:Repaint() </span><br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span> <br /><br /><span style="color: #00C800;">Function</span> dibuja<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> DrawBorderCircle<span style="color: #000000;">(</span><span style="color: #000000;">50</span>,<span style="color: #000000;">50</span>,<span style="color: #000000;">130</span>,<span style="color: #000000;">130</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">100</span> <span style="color: #000000;">)</span><br /> DrawBorderCircle<span style="color: #000000;">(</span><span style="color: #000000;">60</span>,<span style="color: #000000;">60</span>,<span style="color: #000000;">110</span>,<span style="color: #000000;">110</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">100</span> <span style="color: #000000;">)</span> <br /> DrawBorderCircle<span style="color: #000000;">(</span><span style="color: #000000;">70</span>,<span style="color: #000000;">70</span>,<span style="color: #000000;">90</span>,<span style="color: #000000;">90</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">100</span> <span style="color: #000000;">)</span><br /> DrawBorderCircle<span style="color: #000000;">(</span><span style="color: #000000;">80</span>,<span style="color: #000000;">80</span>,<span style="color: #000000;">70</span>,<span style="color: #000000;">70</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">100</span> <span style="color: #000000;">)</span><br /> DrawBorderCircle<span style="color: #000000;">(</span><span style="color: #000000;">90</span>,<span style="color: #000000;">90</span>,<span style="color: #000000;">50</span>,<span style="color: #000000;">50</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">100</span> <span style="color: #000000;">)</span><br /> DrawBorderCircle<span style="color: #000000;">(</span><span style="color: #000000;">100</span>,<span style="color: #000000;">100</span>,<span style="color: #000000;">30</span>,<span style="color: #000000;">30</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">100</span> <span style="color: #000000;">)</span> <br /> DrawCircle<span style="color: #000000;">(</span><span style="color: #000000;">110</span>,<span style="color: #000000;">110</span>,<span style="color: #000000;">10</span>,<span style="color: #000000;">10</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">100</span> <span style="color: #000000;">)</span> <br /> DrawLine<span style="color: #000000;">(</span><span style="color: #000000;">69</span>,<span style="color: #000000;">69</span>,<span style="color: #000000;">161</span>,<span style="color: #000000;">161</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">100</span><span style="color: #000000;">)</span> <br /> DrawLine<span style="color: #000000;">(</span><span style="color: #000000;">115</span>,<span style="color: #000000;">50</span>,<span style="color: #000000;">115</span>,<span style="color: #000000;">180</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">100</span><span style="color: #000000;">)</span> <br /> DrawLine<span style="color: #000000;">(</span><span style="color: #000000;">50</span>,<span style="color: #000000;">115</span>,<span style="color: #000000;">180</span>,<span style="color: #000000;">115</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">100</span><span style="color: #000000;">)</span> <br /> DrawLine<span style="color: #000000;">(</span><span style="color: #000000;">69</span>,<span style="color: #000000;">161</span>,<span style="color: #000000;">161</span>,<span style="color: #000000;">69</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">0</span>,<span style="color: #000000;">100</span><span style="color: #000000;">)</span> <br /> <span style="color: #00C800;">Return</span> <span style="color: #00C800;">nil</span><br /><br /> </div>[/code:d45kogap]
[img:d45kogap]http://img830.imageshack.us/img830/8418/screencapturen.png[/img:d45kogap][/quote:d45kogap]
!!!GRANDE MANUEL!!!! <!-- s:D --><img src="{SMILIES_PATH}/icon_biggrin.gif" alt=":D" title="Very Happy" /><!-- s:D --> |
he conseguido un iphone | Creo que las funciones de pintado deben incluir el Contexto, no pillar el que existe en ese momento. Si quisieras pintar en otro contxto, en memoria, supongo, con estas funciones no podrías. En W2 obtenemos un DC y pintamos en el. Aquí creo que debería ser mas o menos lo mismo. ¿qué te parece? |
he conseguido un iphone | [quote="pgfdz":jiaekgvd]Creo que las funciones de pintado deben incluir el Contexto, no pillar el que existe en ese momento. Si quisieras pintar en otro contxto, en memoria, supongo, con estas funciones no podrías. En W2 obtenemos un DC y pintamos en el. Aquí creo que debería ser mas o menos lo mismo. ¿qué te parece?[/quote:jiaekgvd]
Todos los ejemplos que he visto ,lo usan asi .
Normalmente asignan primero el tipo de contexto en el que van a trabajar por ejemplo :
UIGraphicsBeginImageContext(self.view.frame.size);
.... uso del currentcontext
UIGraphicsEndImageContext();
digamos como si fuera ( entiendase la comparativa ) un Area en los dbfs .
Si tienes algun ejemplo distinto mandame el enlace y miramos como podemos cambiarlo .
---------edito-----
he encontrado la referencia de apple ....[url:jiaekgvd]http://developer.apple.com/library/mac/#documentation/GraphicsImaging/Reference/CGContext/Reference/reference.html[/url:jiaekgvd]
[code=fw:jiaekgvd]<div class="fw" id="{CB}" style="font-family: monospace;"><br />A graphics context contains drawing parameters and all device-specific information needed <span style="color: #0000ff;">to</span> render the <span style="color: #0000ff;">paint</span> <span style="color: #0000ff;">on</span> a <span style="color: #0000ff;">page</span> <span style="color: #0000ff;">to</span> the destination, whether the destination is a <span style="color: #0000ff;">window</span> in an application, a bitmap <span style="color: #0000ff;">image</span>, a PDF document, or a <span style="color: #0000ff;">printer</span>.<br /> </div>[/code:jiaekgvd] |
he conseguido un iphone | Mira:
[url:h0alhvfk]http://www.codingventures.com/2009/08/image-manipulation-and-drawing-using-quartz-in-the-background-threads/[/url:h0alhvfk]
y
[url:h0alhvfk]http://developer.apple.com/library/ios/#documentation/GraphicsImaging/Conceptual/drawingwithquartz2d/Introduction/Introduction.html[/url:h0alhvfk]
creo que deberiamos usar Quartz:
[i:h0alhvfk]Quartz 2D is an advanced, two-dimensional drawing engine available for iOS application development and to all Mac OS X application environments outside of the kernel.[/i:h0alhvfk] |
he conseguido un iphone | [quote="pgfdz":22s5b6m4]Mira:
[url:22s5b6m4]http://www.codingventures.com/2009/08/image-manipulation-and-drawing-using-quartz-in-the-background-threads/[/url:22s5b6m4]
y
[url:22s5b6m4]http://developer.apple.com/library/ios/#documentation/GraphicsImaging/Conceptual/drawingwithquartz2d/Introduction/Introduction.html[/url:22s5b6m4]
creo que deberiamos usar Quartz:
[i:22s5b6m4]Quartz 2D is an advanced, two-dimensional drawing engine available for iOS application development and to all Mac OS X application environments outside of the kernel.[/i:22s5b6m4][/quote:22s5b6m4]
Paco , todas las funciones que estamos usando para dibujar "CGContext" llaman al framework Quarz 2d asi que ya lo estas utilizando . Por otro lado mirando toda esta documentacion la operativa es la misma genera un contexto lo usa y lo destruye ...
Podriamos intentar que estas funciones no cogieran el contexto por defecto pero el problema radica en como pasas un parametro del tipo CGContextRef a harbour ? Creo que es una extructura c , CGrect por ejemplo se puede trasformar a string , pasarla como estring y luego recuperarla , pero CGContextRef no tengo ni idea ...
Una solucion podria ser enumerar los distintos contextos , pasar el integer correspondiente , luego recuperar el contexto segun el integer que pasemos , pero sinceramente no es la mejor solucion . |
he conseguido un iphone | Pues no se, la verdad. Vamos a dejarlo de momento como tu decías. Creo que no es lo mas importante decidir eso ahora. Creo que es mas interesante el poder disponer una clase "TControl" en IOS osea una TView de la que se pueda heredar para hacer controles. No es que este pirao por hacer controles pero por ejemplo, hacer un browse a imagen y semejanza de los controles nativos creo que sería un puntazo. Yo me voy a poner a ello en cuanto se pueda. Lo único que necesito es un Pseudo TControl ya sabes, poder interactuar con los gestos en pantalla, los toques, pintar y esas pequeñas cosas.
La idea que tengo del iBrowse es como si fuera una pagina grande que se pueda ver a través de la ventanita que nos proporciona el iphone-ipad
que podamos hacerla scroll moviendola con el dedo arriba-abajo-izda-dcha. La estoy viendo en mi mente y creo que puedo hacer el iBrowse o el iGrid o que se yo. Me lo imagino con todas estas posibilidades que da este entorno gráfico y alucino. Bueno... mañana mas.
buenas noches <!-- s;) --><img src="{SMILIES_PATH}/icon_wink.gif" alt=";)" title="Wink" /><!-- s;) --> |
he conseguido un iphone | Antonio ...
-------edito ------------
Olvidate de esto era todo un bug introducido al meter el codigo para coger imagenes desde url y yaestá corregido .... lo siento <!-- s:cry: --><img src="{SMILIES_PATH}/icon_cry.gif" alt=":cry:" title="Crying or Very sad" /><!-- s:cry: -->
NO -> Nos falta la funcion fwrite$UNIX2003 con el ejemplo tutor image.prg
Saludos.
------ edito -----------------
siguiendo el dedo ....
[url:1v9tgngv]http://www.youtube.com/watch?v=62OwAJUb8TQ[/url:1v9tgngv] |
he conseguido un iphone | Antonio , Daniel .
Estoy liado con el tema del zoom in - zoom out , o pinch o como se llame ( detectar dos dedos que se separan , o se juntan ) .
Ya casi lo tengo , pero me falta un pequeño detalle , fijo que es una tonteria , pero estoy ofuscado.
El codigo siguiente captura los dos dedos y la distancia entre ellos ,la compara con otra tomada anteriormente en el evento touchbegan y dependiendo sea positiva o negativa , discernimos el evento
( puede que sea mejor hacerlo en un solo evento ) .El problema surge en que quiero pasar la diferencia a harbour .
Se supone que la diferencia entre 2 CGFloat es una CGFloat y esta no se como pasarla a harbour . He puesto LONG por poner algo , pero es otra cosa seguro <!-- s:D --><img src="{SMILIES_PATH}/icon_biggrin.gif" alt=":D" title="Very Happy" /><!-- s:D -->
¿ como seria ?
[code=fw:2u8frrq1]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><br /> UITouch *touch1 = <span style="color: #000000;">[</span><span style="color: #000000;">[</span>allTouches allObjects<span style="color: #000000;">]</span> objectAtIndex:<span style="color: #000000;">0</span><span style="color: #000000;">]</span>;<br /> UITouch *touch2 = <span style="color: #000000;">[</span><span style="color: #000000;">[</span>allTouches allObjects<span style="color: #000000;">]</span> objectAtIndex:<span style="color: #000000;">1</span><span style="color: #000000;">]</span>;<br /> <br /> CGFloat finalDistance = distanceBetweenTwoPoints<span style="color: #000000;">(</span><span style="color: #000000;">[</span>touch1 locationInView:<span style="color: #00C800;">self</span><span style="color: #000000;">]</span>, <span style="color: #000000;">[</span>touch2 locationInView:<span style="color: #00C800;">self</span><span style="color: #000000;">]</span><span style="color: #000000;">)</span> ; <br /> <br /> <br /> <span style="color: #00C800;">if</span> <span style="color: #000000;">(</span> initialDistance > finalDistance<span style="color: #000000;">)</span> <span style="color: #000000;">{</span><br /> <br /> hb_vmPushSymbol<span style="color: #000000;">(</span> symFPH <span style="color: #000000;">)</span>;<br /> hb_vmPushNil<span style="color: #000000;">(</span><span style="color: #000000;">)</span>;<br /> hb_vmPushLong<span style="color: #000000;">(</span> <span style="color: #000000;">(</span> LONG <span style="color: #000000;">)</span> <span style="color: #00C800;">self</span> <span style="color: #000000;">)</span>;<br /> hb_vmPushLong<span style="color: #000000;">(</span> WM_TOUCHOUT <span style="color: #000000;">)</span>;<br /> hb_vmPushLong<span style="color: #000000;">(</span> <span style="color: #000000;">0</span> <span style="color: #000000;">)</span>;<br /> hb_vmPushLong<span style="color: #000000;">(</span> <span style="color: #000000;">(</span> LONG <span style="color: #000000;">)</span> <span style="color: #000000;">(</span> initialDistance > finalDistance<span style="color: #000000;">)</span> <span style="color: #000000;">)</span>;<br /> hb_vmDo<span style="color: #000000;">(</span> <span style="color: #000000;">4</span> <span style="color: #000000;">)</span>; <br /> <span style="color: #000000;">}</span><br /> <span style="color: #00C800;">else</span> <span style="color: #000000;">{</span><br /> <br /> hb_vmPushSymbol<span style="color: #000000;">(</span> symFPH <span style="color: #000000;">)</span>;<br /> hb_vmPushNil<span style="color: #000000;">(</span><span style="color: #000000;">)</span>;<br /> hb_vmPushLong<span style="color: #000000;">(</span> <span style="color: #000000;">(</span> LONG <span style="color: #000000;">)</span> <span style="color: #00C800;">self</span> <span style="color: #000000;">)</span>;<br /> hb_vmPushLong<span style="color: #000000;">(</span> WM_TOUCHIN <span style="color: #000000;">)</span>;<br /> hb_vmPushLong<span style="color: #000000;">(</span> <span style="color: #000000;">0</span> <span style="color: #000000;">)</span>;<br /> hb_vmPushLong<span style="color: #000000;">(</span> <span style="color: #000000;">(</span> LONG <span style="color: #000000;">)</span> <span style="color: #000000;">(</span> initialDistance > finalDistance<span style="color: #000000;">)</span> <span style="color: #000000;">)</span>;<br /> hb_vmDo<span style="color: #000000;">(</span> <span style="color: #000000;">4</span> <span style="color: #000000;">)</span>; <br /> <br /> <span style="color: #000000;">}</span><br /><br /> </div>[/code:2u8frrq1] |
he conseguido un iphone | Manuel
intenta pasar un valor doble de 2 decimales
hb_vmPushDouble( double dNumber, int iDec ) |
he conseguido un iphone | [quote="Daniel Garcia-Gil":1ixf2pna]Manuel
intenta pasar un valor doble de 2 decimales
hb_vmPushDouble( double dNumber, int iDec )[/quote:1ixf2pna]
Gracias Daniel , funciono perfecto .
Ya tengo funcionando el pinch sobre los view .
Saludos. |
he conseguido un iphone | pinch a la fivephone :
faltan por pasar las funciones de centrado y scalado a la clase timage
[code=fw:jrq1hump]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"fivephone.ch"</span><br /><br /><span style="color: #00C800;">function</span> Main<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> <span style="color: #00C800;">local</span> oWnd := TWindow<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">GetMain</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <br /> <span style="color: #00C800;">local</span> oimage,olabel<br /> <br /> oView1 = TView<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #00C800;">New</span><span style="color: #000000;">(</span> oWnd,<span style="color: #000000;">0</span>, <span style="color: #000000;">0</span>, ScreenWidth<span style="color: #000000;">(</span><span style="color: #000000;">)</span>, ScreenHeight<span style="color: #000000;">(</span><span style="color: #000000;">)</span> - <span style="color: #000000;">49</span> <span style="color: #000000;">)</span><br /> oView1:<span style="color: #000000;">SetBkgColor</span><span style="color: #000000;">(</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">255</span>, <span style="color: #000000;">0</span>, <span style="color: #000000;">255</span> <span style="color: #000000;">)</span><br /> <br /> oImage := TImageView<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #00C800;">New</span><span style="color: #000000;">(</span> oView1, <span style="color: #ff0000;">"tab_star.png"</span>, <span style="color: #000000;">70</span>, <span style="color: #000000;">120</span> <span style="color: #000000;">)</span><br /> <br /> olabel := Tlabel<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #00C800;">New</span><span style="color: #000000;">(</span> oView1, <span style="color: #ff0000;">"apple.jpg"</span>, <span style="color: #000000;">340</span>, <span style="color: #000000;">150</span>,<span style="color: #000000;">100</span>,<span style="color: #000000;">50</span> <span style="color: #000000;">)</span> <br /> oLabel:<span style="color: #000000;">SetColor</span><span style="color: #000000;">(</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">0</span>, <span style="color: #000000;">0</span>, <span style="color: #000000;">255</span> <span style="color: #000000;">)</span> <br /> <br /> oview1:<span style="color: #000000;">bTouchesBegan</span>:= <span style="color: #000000;">{</span>|o,hpoint|IMAGEVIEWCENTERNSSTRING<span style="color: #000000;">(</span>oimage:<span style="color: #000000;">hWnd</span> ,hpoint <span style="color: #000000;">)</span> <span style="color: #000000;">}</span><br /> oview1:<span style="color: #000000;">bTouchMoved</span> := <span style="color: #000000;">{</span>|o,hpoint|IMAGEVIEWCENTERNSSTRING<span style="color: #000000;">(</span>oimage:<span style="color: #000000;">hWnd</span> ,hpoint <span style="color: #000000;">)</span> <span style="color: #000000;">}</span> <br /> oview1:<span style="color: #000000;">bTouchout</span> := <span style="color: #000000;">{</span>|o,nlen| olabel:<span style="color: #000000;">setText</span><span style="color: #000000;">(</span><span style="color: #ff0000;">"dist "</span>+ str<span style="color: #000000;">(</span>nlen/<span style="color: #000000;">100</span><span style="color: #000000;">)</span><span style="color: #000000;">)</span> , IMAGEVIEWSCALE<span style="color: #000000;">(</span>oImage:<span style="color: #000000;">hWnd</span>,<span style="color: #000000;">1</span>+<span style="color: #000000;">(</span>nlen/<span style="color: #000000;">10000</span><span style="color: #000000;">)</span>,<span style="color: #000000;">1</span>+<span style="color: #000000;">(</span>nlen/<span style="color: #000000;">10000</span><span style="color: #000000;">)</span><span style="color: #000000;">)</span> <span style="color: #000000;">}</span> <br /> <br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span> <br /><br /> </div>[/code:jrq1hump]
[url:jrq1hump]http://www.youtube.com/watch?v=4OwcNBVDHNI[/url:jrq1hump]
--------------- edito -----------------
el codigo definitivo quedaria asi:
[code=fw:jrq1hump]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"fivephone.ch"</span><br /><br /><span style="color: #00C800;">function</span> Main<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> <span style="color: #00C800;">local</span> oWnd := TWindow<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #000000;">GetMain</span><span style="color: #000000;">(</span><span style="color: #000000;">)</span> <br /> <span style="color: #00C800;">local</span> oimage,olabel<br /> <br /> oView1 = TView<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #00C800;">New</span><span style="color: #000000;">(</span> oWnd,<span style="color: #000000;">0</span>, <span style="color: #000000;">0</span>, ScreenWidth<span style="color: #000000;">(</span><span style="color: #000000;">)</span>, ScreenHeight<span style="color: #000000;">(</span><span style="color: #000000;">)</span> - <span style="color: #000000;">49</span> <span style="color: #000000;">)</span><br /> oView1:<span style="color: #000000;">SetBkgColor</span><span style="color: #000000;">(</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">255</span>, <span style="color: #000000;">0</span>, <span style="color: #000000;">255</span> <span style="color: #000000;">)</span><br /> <br /> oImage := TImageView<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #00C800;">New</span><span style="color: #000000;">(</span> oView1, <span style="color: #ff0000;">"tab_star.png"</span>, <span style="color: #000000;">70</span>, <span style="color: #000000;">120</span> <span style="color: #000000;">)</span><br /> <br /> olabel := Tlabel<span style="color: #000000;">(</span><span style="color: #000000;">)</span>:<span style="color: #00C800;">New</span><span style="color: #000000;">(</span> oView1, <span style="color: #ff0000;">"apple.jpg"</span>, <span style="color: #000000;">340</span>, <span style="color: #000000;">150</span>,<span style="color: #000000;">100</span>,<span style="color: #000000;">50</span> <span style="color: #000000;">)</span> <br /> oLabel:<span style="color: #000000;">SetColor</span><span style="color: #000000;">(</span> <span style="color: #000000;">0</span>, <span style="color: #000000;">0</span>, <span style="color: #000000;">0</span>, <span style="color: #000000;">255</span> <span style="color: #000000;">)</span> <br /> <br /> oview1:<span style="color: #000000;">bTouchesBegan</span>:= <span style="color: #000000;">{</span>|o,aPoint| oImage:<span style="color: #0000ff;">Center</span><span style="color: #000000;">(</span>aPoint<span style="color: #000000;">[</span><span style="color: #000000;">1</span><span style="color: #000000;">]</span>,aPoint<span style="color: #000000;">[</span><span style="color: #000000;">2</span><span style="color: #000000;">]</span> <span style="color: #000000;">)</span> <span style="color: #000000;">}</span><br /> oview1:<span style="color: #000000;">bTouchMoved</span> := <span style="color: #000000;">{</span>|o,aPoint| oImage:<span style="color: #0000ff;">Center</span><span style="color: #000000;">(</span>aPoint<span style="color: #000000;">[</span><span style="color: #000000;">1</span><span style="color: #000000;">]</span>,aPoint<span style="color: #000000;">[</span><span style="color: #000000;">2</span><span style="color: #000000;">]</span> <span style="color: #000000;">)</span> <span style="color: #000000;">}</span> <br /> oview1:<span style="color: #000000;">bTouchout</span> := <span style="color: #000000;">{</span>|o,nlen| olabel:<span style="color: #000000;">setText</span><span style="color: #000000;">(</span><span style="color: #ff0000;">"dist "</span>+ str<span style="color: #000000;">(</span>nlen/<span style="color: #000000;">100</span><span style="color: #000000;">)</span><span style="color: #000000;">)</span> , oImage:<span style="color: #000000;">zoom</span><span style="color: #000000;">(</span> <span style="color: #000000;">1</span>+<span style="color: #000000;">(</span>nlen/<span style="color: #000000;">10000</span><span style="color: #000000;">)</span>,<span style="color: #000000;">1</span>+<span style="color: #000000;">(</span>nlen/<span style="color: #000000;">10000</span><span style="color: #000000;">)</span><span style="color: #000000;">)</span> <span style="color: #000000;">}</span> <br /> <br /><span style="color: #00C800;">return</span> <span style="color: #00C800;">nil</span> <br /><br /><br /> </div>[/code:jrq1hump] |
he conseguido un iphone | HB_FUNC( CREATEPICKERVIEW )
{
UIWindow * window = ( UIWindow * ) hb_parnl( 1 );
PickerView * picker = [ [ PickerView alloc ]
initWithFrame : CGRectMake( hb_parnl( 4 ), hb_parnl( 3 ), hb_parnl( 5 ), hb_parnl( 6 ) ) ];
picker.showsSelectionIndicator = true; // [b:ykqyjgn0]PARA QUE APAREZCA LA SELECCION EN EL PICKVIEW[/b:ykqyjgn0]
DataSource * dataSource = [ [ DataSource alloc ] init ];
int n;
dataSource->items = [ [ NSMutableArray alloc ] init ];
for( n = 1; n <= hb_parinfa( 2, 0 ); n++ )
[ dataSource->items addObject : [ [ [ NSString alloc ] initWithCString: hb_parvc( 2, n ) ] autorelease ] ];
picker.dataSource = dataSource;
[ picker setDelegate : picker ];
[ picker selectRow : 1 inComponent : 0 animated : NO ];
[ window addSubview : picker ];
hb_retnl( ( LONG ) picker );
} |
he conseguido un iphone | Una pregunta de nuevo en esto.
¿Los UILabel, UIButton, UIPickView etc, no se les hace un release en ningun lado?
y de los alloc que se hacen en PickView, el Datasource, tampoco?
No se si es que se hacen solos en algun lado pero pensaba que si se hacen alloc habría que hacer tambien release, no? |
he conseguido un iphone | [quote="pgfdz":homhwr8l]Una pregunta de nuevo en esto.
¿Los UILabel, UIButton, UIPickView etc, no se les hace un release en ningun lado?
y de los alloc que se hacen en PickView, el Datasource, tampoco?
No se si es que se hacen solos en algun lado pero pensaba que si se hacen alloc habría que hacer tambien release, no?[/quote:homhwr8l]
Probablemente falten .Se hace un release de todo al terminar la aplicación ,pero me da que mientras no.
Ten en cuenta que aun no estan totalmente definidas algunas cosas en fivephone y por el momento no deja de ser una beta ( operativa , pero beta) .
Una cosa que falta aun por decidir es el sistema a usar para "anotar" los objetos . Fijate que muchas clases usan un sistema de array , pero otras desarrolladas por Daniel ( por ejemplo uibutton ) proponen usar el sistema de basura de harbour .
Probablemente sea mas eficiente el sistema de Daniel , pero parece ser que en FWPPC dió problemas y se tubo que retirar . Aqui parece que funciona , y estamos esperando a ver si no se detectan problemas .Si la cosa sigue asi , y parece que que funciona , supongo que se cambiará a ese codigo en todos objetos .Una vez resuelto esto ,Imagino que se pasará a mirar donde se producen consumos de memoria y donde realizar los release .
Sería bueno que fueras haciendo pruebas ,para tener claro donde no se deben hacer . <!-- s:D --><img src="{SMILIES_PATH}/icon_biggrin.gif" alt=":D" title="Very Happy" /><!-- s:D --> .
Para mi estos dias son dificiles ,tengo mucho trabajo atrasado y poco tiempo para dedicar a "divertirme" con fivephone , asi que estaré "de baja" del proyecto una temporadita ( veras que llevo unos dias sin avances) .Supongo que tanto Antonio como Daniel tendran sus prioridades en los proyectos que esta comunidad demanda insistentemente tipo fiveweb y cosas similares que son realmente su sustento economico y les permite " estar aqui " ( por cierto que discrepo de la opinion general de los usuarios de este foro de llevar los programas de escritorio al navegador, siendo mucho mas eficiente el usar los servicios de internet en los programa de escritorio ,miremos sino que es lo que hacen todos los programas ios ) .
Saludos. |
he conseguido un iphone | >Para mi estos dias son dificiles ,tengo mucho trabajo atrasado y poco tiempo para dedicar a "divertirme" con fivephone , asi que estaré "de baja" del proyecto >una temporadita ( veras que llevo unos dias sin avances)
Como dijo alguien: !!No mi Judas¡¡
Ahora que ibas lanzado. Bueno, seguiré haciendo prácticas. Un saludo |
he conseguido un iphone | [color=#0000FF:30fvtkhn]>>por cierto que discrepo de la opinion general de los usuarios de este foro de llevar los programas de escritorio al navegador, siendo mucho mas eficiente el usar los servicios de internet en los programa de escritorio ,miremos sino que es lo que hacen todos los programas ios[/color:30fvtkhn]
Mastintin,
Interesante tu opinion. Podrias ahondar un poco mas al respecto.
Saludos
George |
he conseguido un iphone | Hola
¿Funciona correctamente las aplicaciones 5p cuando se suspende el programa por una llamada, pongamos el caso?
Por cierto, ya me he dado de alta como desarrollador, a falta de confirmación de Apple. ¿Cómo se instalan los programas 5p en el ipod?
Un saludo |
he conseguido un iphone | [quote="George":26icscun][color=#0000FF:26icscun]>>por cierto que discrepo de la opinion general de los usuarios de este foro de llevar los programas de escritorio al navegador, siendo mucho mas eficiente el usar los servicios de internet en los programa de escritorio ,miremos sino que es lo que hacen todos los programas ios[/color:26icscun]
Mastintin,
Interesante tu opinion. Podrias ahondar un poco mas al respecto.
Saludos
George[/quote:26icscun]
Primero es una opinion muy personal , segundo depende realmente del destino del programa , pero...
Si nuestro proposito es el uso "publico" pienso que fiveweb ( o lo que yo imagino que pueda ser ) , no será la mejor opción . El desarrollo web va rápido , muy rapido y cada dia salen nuevas y nuevas tecnologias . Yo por ejemplo en su momento desarrolle algo en asp puro , pero me vi desbordado por el ritmo , asp.net,php, ruby ,python, etc,etc, para el desarrollador es una locura de idiomas .Si se genera fiveweb atacando una tecnología concreta al cabo de 3 años estará obsoleta .Para eso es mejor coger el toro por los cuernos y aprender bien algo ( no se decirte ... ¿python ? ) y olvidarse de las ventajas del lenguaje FIVE ( que tiene muchas) .
Si el desarrollo es corporativo existen opciones tipo Terminal server , o mejor dicho application server o aun mejor citrix que atacan un programa en el servidor central y tienes un mantenimiento centralizado y un control sobre usuarios estupendo .Esta solucion se ha adoptado en sitios como proteccion civil de España , para que te hagas una idea .
Pienso que por norma general y en empresa mas pequeña pienso que usar programas centrados en los servicios web es mas eficiente .
para que nos entendamos , a nivel de usuario medio de empresa ,es mas facil el uso de de gmail por la web o por un gestor de correo ? . Es mas facil el uso de twitter por web o por un cliente twitter ?. para mi siempre es mas facil usar un programa de escritorio que ataca un servicio .
Repito , opinion muy muy personal , y se que contracorriente .
Saludos. |
he conseguido un iphone | [quote="pgfdz":2fk7t615]Hola
¿Funciona correctamente las aplicaciones 5p cuando se suspende el programa por una llamada, pongamos el caso?
Por cierto, ya me he dado de alta como desarrollador, a falta de confirmación de Apple. ¿Cómo se instalan los programas 5p en el ipod?
Un saludo[/quote:2fk7t615]
Pues no se me ha dado el caso , no lo sé , pero cambiando programas funciona bien .
Para instalar en el ipod touch , conecta el ipod al ordenador por cable ,cambia la opcion de compilar para simulador por dispositivo .cuando le des al boton de ejecutar te instala la aplicacion.
Saludos. |
he conseguido un iphone | Mastintin,
Te hice la pregunta pues considero, al igual que tu, que con una aplicacion de escritorio podemos acceder a los beneficios de la web sin necesidad de usar los lenguajes PHP, Java, etc. que estan intimamente ligado al browser.
Se que hay algunos beneficios al usar el browser como plataforma de desarrollo de software, (como por ejemplo que no hay que instalar nada en el computador del usuario) y de que habran muchos defensores de usar esta metodologia. Sin embargo los software mas potentes y mas rapido de seguro seran siempre aplicaciones de escritorio que usen database local, remota o hibrida (local + remota). Notamos que el software de Microsoft "Dynamics CRM" (la competencia de salesforce.com) te permite usar la base de datos remota (en las "nubes" como le llaman ahora) al igual que la misma database de forma local a la cual le llaman "offline" para cuando no tengas acceso al internet.
Talvez FiveWeb pudiera encaminarse por esta direccion.
Saludos
George |
he conseguido un iphone | Hola
Iba a ejecutar el programa en el ipod y ... otra vez a las andadas. Me sale este error:
Harbour 2.1.0beta1 (Rev. 14766)
Copyright (c) 1999-2010, <!-- m --><a class="postlink" href="http://harbour-project.org/">http://harbour-project.org/</a><!-- m -->
Cannot open tutor02.prg, assumed external
No code generated.
Command /bin/sh failed with exit code 1
Una ayudita...
---- Edito -----
Ya funciona. Estaba poniendo el prg en un directorio donde no lo encontraba el compilador. |
he conseguido un iphone | Hola
Al poner interrogaciones o acentos en MsgYesNoModal me sale una cagarruta
[img:3urx1aau]http://img687.imageshack.us/img687/339/msgyesnomodal.png[/img:3urx1aau]
¿Cómo se soluciona eso? |
he conseguido un iphone | Paco,
Que editor de PRGs estás usando ? xcode ? |
he conseguido un iphone | Si, claro |
he:=TOleAuto():New(""InternetExplorer.Application"") | Hi,
he:=TOleAuto():New("InternetExplorer.Application")
he:Visible := .T.
OleSetProperty(he,"Toolbar",.F.)
OleSetProperty(he,"Statusbar",.F.)
OleSetProperty(he,"MenuBar",.F.)
he:Navigate(cUrl)
What is the equivalent instruction for Edge or Chrom or Firefox
Thanks ,
Philippe |
he:=TOleAuto():New(""InternetExplorer.Application"") | hi,
Edge, Chrom or Firefox does not have ActiveX Support.
not sure if FiveWin have a "wrapper" for Edge.
HMG have this
[url:14s4rrlx]http://www.hmgforum.com/viewtopic.php?f=9&t=7012[/url:14s4rrlx] |
he:=TOleAuto():New(""InternetExplorer.Application"") | Hi Jimmy !!!
Look at [url:y6zamcfc]http://fivetechsupport.com/forums/viewtopic.php?f=17&t=40854&p=244531&hilit=webview2&sid=ab30778fbb719cab8c08cc43907756ad&sid=d7310d089d1d40dc4482e3d65f1b473f#p244531[/url:y6zamcfc]
Kind regards, |
he:=TOleAuto():New(""InternetExplorer.Application"") | hi,
thx for link
seems i have to change my Compiler (MinGW) ... |
he:=TOleAuto():New(""InternetExplorer.Application"") | Jimmy,
Microsoft Visual Studio Community works great <!-- s:-) --><img src="{SMILIES_PATH}/icon_smile.gif" alt=":-)" title="Smile" /><!-- s:-) --> |
header folderex | can I hide the header of a folderex ? |
header folderex | Tabs ? ::nFolderHeight := 0 ?
Saludos |
header with a UDF | How can I click on the header of a column in xbrowse and bring up a user defined function? |
header with a UDF | oBrw:aCols[xx]:bLClickHeader := {||yourfunction() }
HTH |
header with a UDF | thanks for the help. haven't tried it yet. Will tonite or tomorrow. |
header with a UDF | I keep getting abound array access error.
Here is the code sample I use.
Its a xbrowse from resources.
What am I doing wrong. Thanks for the help.
[code=fw:23e8w32v]<div class="fw" id="{CB}" style="font-family: monospace;"> <br /><span style="color: #00C800;">local</span> aCols<span style="color: #000000;">[</span><span style="color: #000000;">24</span><span style="color: #000000;">]</span> <br /><br />oBrw:<span style="color: #000000;">aCols</span><span style="color: #000000;">[</span><span style="color: #000000;">8</span><span style="color: #000000;">]</span>:<span style="color: #000000;">bLClickHeader</span> := <span style="color: #000000;">{</span>||msgInfo<span style="color: #000000;">(</span><span style="color: #ff0000;">"Works"</span><span style="color: #000000;">)</span> <span style="color: #000000;">}</span><br /><br /> ADD column <span style="color: #0000ff;">to</span> <span style="color: #0000ff;">xbrowse</span> oBrw;<br /> <span style="color: #00C800;">DATA</span> <span style="color: #000000;">{</span>|| <span style="color: #00C800;">if</span><span style="color: #000000;">(</span>drill->title == repli<span style="color: #000000;">(</span><span style="color: #ff0000;">'-'</span>, <span style="color: #000000;">30</span><span style="color: #000000;">)</span>, repli<span style="color: #000000;">(</span><span style="color: #ff0000;">' '</span>, <span style="color: #000000;">20</span><span style="color: #000000;">)</span>, ;<br /> <span style="color: #00C800;">if</span><span style="color: #000000;">(</span>drill->title == repli<span style="color: #000000;">(</span><span style="color: #ff0000;">'='</span>, <span style="color: #000000;">30</span><span style="color: #000000;">)</span>, repli<span style="color: #000000;">(</span><span style="color: #ff0000;">' '</span>, <span style="color: #000000;">20</span><span style="color: #000000;">)</span>, ;<br /> oBrw:<span style="color: #000000;">oDbf</span>:<span style="color: #000000;">drill</span>:<span style="color: #000000;">Invoice</span><span style="color: #000000;">)</span><span style="color: #000000;">)</span> <span style="color: #000000;">}</span>;<br /> <span style="color: #0000ff;">SIZE</span> <span style="color: #000000;">50</span> <span style="color: #0000ff;">LEFT</span> HEADER <span style="color: #ff0000;">"Invoice"</span> <span style="color: #0000ff;">COLOR</span> CLR_BLACK,CLR_WHITE<br /><br /> </div>[/code:23e8w32v] |
header with a UDF | Harvey
Make sure oBrw:aCols[8]:bLClickHeader := {||msgInfo("Works") } is after column definition
HTH
Richard |
header with a UDF | perfect <!-- s:D --><img src="{SMILIES_PATH}/icon_biggrin.gif" alt=":D" title="Very Happy" /><!-- s:D --> |
height of taskbar | Can I use getsysmetrics() to retrive the height of the windows taskbar? |
height of taskbar | Yes, but you have to subtract the value returned by the API SystemParametersInfo() with the argument SPI_GETWORKAREA.
EMG |
height of taskbar | Enrico,
Can you please show me how to do it. What value to use for getsysmetrics()? |
height of taskbar | This should be a working sample:
[code:hdpjx4vr]#include "Fivewin.ch"
FUNCTION MAIN()
? GETTASKBARHEIGHT()
RETURN NIL
#pragma BEGINDUMP
#include "windows.h"
#include "hbapi.h"
HB_FUNC( GETTASKBARHEIGHT )
{
RECT rct;
LONG nHDiff, nVDiff;
SystemParametersInfo( SPI_GETWORKAREA, 0, &rct, 0 );
nHDiff = GetSystemMetrics( SM_CXSCREEN ) - ( rct.right - rct.left );
nVDiff = GetSystemMetrics( SM_CYSCREEN ) - ( rct.bottom - rct.top );
if ( nHDiff > 0 )
hb_retnl( nHDiff );
else
hb_retnl( nVDiff );
}
#pragma ENDDUMP[/code:hdpjx4vr]
EMG |
height of taskbar | Enrico,
As always you been a great help, thanks. |
height of taskbar | Enrico,
This same function SystemParametersInfo() can be used to set the height of the top window border.. Am I right???
Do you think you can help me with it????? I am building a Touch Screen App, the default sysmenu is too small for that... |
height of taskbar | [quote="Bayron":2q88sz0q]This same function SystemParametersInfo() can be used to set the height of the top window border.. Am I right???[/quote:2q88sz0q]
No, as far as I know.
EMG |
height of taskbar | Thnx Enrico...
I found a way of doing what I need, but I don't know anything about C
[url:11pk9kyl]http://www.codeproject.com/KB/vista/AeroGlassLegacyWindowsApp.aspx[/url:11pk9kyl]
[img:11pk9kyl]http://www.codeproject.com/KB/vista/AeroGlassLegacyWindowsApp/monthcal.png[/img:11pk9kyl] |
height of taskbar | Enrico,
[img:26fgv6gn]http://www.codeproject.com/KB/vista/VGGlassIntro/dlgclocklogo.png[/img:26fgv6gn]
I think it can be done this way using c++
[code=fw:26fgv6gn]<div class="fw" id="{CB}" style="font-family: monospace;"> <span style="color: #00C800;">if</span> <span style="color: #000000;">(</span> !IsThemeNull<span style="color: #000000;">(</span><span style="color: #000000;">)</span> <span style="color: #000000;">)</span><br /> GetThemeSysFont <span style="color: #000000;">(</span> TMT_MSGBOXFONT, &lf <span style="color: #000000;">)</span>;<br /> <span style="color: #00C800;">else</span><br /> <span style="color: #000000;">{</span><br /> NONCLIENTMETRICS ncm = <span style="color: #000000;">{</span> sizeof<span style="color: #000000;">(</span>NONCLIENTMETRICS<span style="color: #000000;">)</span> <span style="color: #000000;">}</span>;<br /><br /> SystemParametersInfo <span style="color: #000000;">(</span> SPI_GETNONCLIENTMETRICS, sizeof<span style="color: #000000;">(</span>NONCLIENTMETRICS<span style="color: #000000;">)</span>, &ncm, <span style="color: #00C800;">false</span> <span style="color: #000000;">)</span>;<br /> lf = ncm.lfMessageFont;<br /> <span style="color: #000000;">}</span><br /> </div>[/code:26fgv6gn]
***********************************
from MSDN:
SPI_GETNONCLIENTMETRICS
0x0029
Retrieves the metrics associated with the nonclient area of nonminimized windows. The pvParam parameter must point to a NONCLIENTMETRICS structure that receives the information. Set the cbSize member of this structure and the uiParam parameter to sizeof(NONCLIENTMETRICS).
Public Domain Code from:
[url:26fgv6gn]http://www.codeproject.com/KB/vista/VGGlassIntro.aspx[/url:26fgv6gn] |
height of taskbar | Yes, I was wrong: according to MSDN, SystemParametersInfo() can also be used to set the parameters but I never done it and can't help you, sorry.
EMG |
height of taskbar | Enrico,
Thanks a lot anyway; at least it's a start, maybe someone else may help...
I know that Laiton is working with FiveTechSoft to implement something like this to FiveWin.... |
height of taskbar | Can this be used???
[url:1113e5tc]http://stackoverflow.com/questions/2135068/how-to-set-the-size-of-the-non-client-area-of-a-win32-window-native[/url:1113e5tc] |
help | ciao a tutti
come posso aggiungere un nuovo campo durante l'esecuzione del programma.
saluti marino |
help | And now in English ? |
help | tricarico sad
can I add a field when I execut an application ? |
help | You can, but you have to close the table. Have a look at DbStruct() function. You have to create the new empty table, append the record from the old table, delete the old table and rename the new one.
EMG |
help #ifndef __HARBOUR__ | Hi all,
I have one app in 32 bits; my application passes a value to another application that this done in "VB", it app in VB take one value in this format: 0x65 ( hexadecimal ) and it does not admit 101 ( the equivalent one to the value 0x65 ).
the problem is that when compiling the application in 16bits gives an error "error syntaxis" in this line:
[code:2xxh9xev]local xCommand:= 0x65[/code:2xxh9xev]
Some idea?
Tank´s |
help #ifndef __HARBOUR__ | Gustavo,
"0x65" maybe ? |
help #ifndef __HARBOUR__ | [quote="Antonio Linares":3ck3bfun]Gustavo,
"0x65" maybe ?[/quote:3ck3bfun]
No, because next i need this:
[code:3ck3bfun] DO CASE
CASE xComando = 0x65
cRespuesta:= LeeConfiguracion()[/code:3ck3bfun]
And "0x65" is diferent to 0x65
Sorry. |
help #ifndef __HARBOUR__ | Gustavo,
CASE xComando = 0x65
is equivalent to:
CASE xComando = 101
It must work the same way |
help #ifndef __HARBOUR__ | [quote="Antonio Linares":1ud55r3j]Gustavo,
CASE xComando = 0x65
is equivalent to:
CASE xComando = 101
It must work the same way[/quote:1ud55r3j]
Antonio,
I´m make one simulation of machine, this machine work with one app Visual Basic and only accept 0x65 and not 101, then need make one app that work with 0x65 and not with 101 or "0x65".
Sorry. |
help Problem with Adordd | Hi Coleagues
I need connect to Mysql but I Can T Can Anybody Help me
Im use Fwh 8.05 xharbour 1.1. , Mysql 5 , My odbc driver 5.1
thanks in advance
Fabian
The Error
Mysql .prg
Application
===========
Path and name: C:\ADO2241\samples\mysql.exe (32 bits)
Size: 1,517,056 bytes
Time from start: 0 hours 0 mins 0 secs
Error occurred at: 01/06/09, 23:13:24
Error description: Error ADODB.Connection/0 S_OK: OPEN
Args:
[ 1] = C DRIVER={MySQL ODBC 3.51 Driver};server=www.freesql.org;database=test00;uid=myuser;pwd=mypass
Stack Calls
===========
Called from: win32ole.prg => TOLEAUTO:OPEN(0)
Called from: adordd.PRG => ADO_OPEN(0)
Called from: => DBUSEAREA(0)
Called from: mysql1.PRG => MAIN(0 |
help Problem with Adordd | Fabian,
Show me the part of your source code trying to connect to MySQL. I am able to connect without any problem.
I think I have replied to your query in the Spanish forum and you have not replied back. You have not specified the MySql port
Your connection string is wrong.
[quote:11fr9x1v]I need connect to Mysql but I Can T Can Anybody Help me
Im use Fwh 8.05 xharbour 1.1. , Mysql 5 , My odbc driver 5.1[/quote:11fr9x1v]
You have said that your ODBC Driver is 5.1 and in your connection string you have specified the driver as 3.51
Please change the connection string to
"Driver={MySQL ODBC 5.1 Driver};Server=YourServerIP;Port=3306;Database=YourDataBaseName;User=YourUserName;Password=YourPassword;Option=3;"
[quote:11fr9x1v]The Error
Mysql .prg
Application
===========
Path and name: C:\ADO2241\samples\mysql.exe (32 bits)
Size: 1,517,056 bytes
Time from start: 0 hours 0 mins 0 secs
Error occurred at: 01/06/09, 23:13:24
Error description: Error ADODB.Connection/0 S_OK: OPEN
Args:
[ 1] = C [b:11fr9x1v]DRIVER={MySQL ODBC 3.51 Driver}[/b:11fr9x1v];server=www.freesql.org;database=test00;uid=myuser;pwd=mypass
Stack Calls
===========
Called from: win32ole.prg => TOLEAUTO:OPEN(0)
Called from: adordd.PRG => ADO_OPEN(0)
Called from: => DBUSEAREA(0)
Called from: mysql1.PRG => MAIN(0[/quote:11fr9x1v]
Regards
Anser |
help Problem with Adordd | Anser I put the por number but the problem exist
Im use odbc driver 5.1 y msql 5
USE test VIA "ADORDD" TABLE "stock" MYSQL ;
FROM "127.0.0.1:3306" USER "root" PASSWORD "
[ 1] = C DRIVER={MySQL ODBC 3.51 Driver};server=127.0.0.1:3306;database=test;uid=root;pwd=
thanks
Fabian |
help Problem with Adordd | HI :
I Had Same Problem for test ADORDD + MySQL.
1) try MySQL ODBC 3.51 smae error message as Databaselab2002 pasted .
2) try MySQL ODBC 5.1
a) Edit ADORDD.prg
[quote:18kh1ich]
case Upper( cDbEngine ) == "MYSQL"
oConnection:Open( "DRIVER={MySQL ODBC 5.1 Driver};" + ;
"server=" + cServer + ;
";database=" + cDataBase + ;
";uid=" + cUserName + ;
";pwd=" + cPassword + ;
";option=3" )
[/quote:18kh1ich]
b) Error message as
[quote:18kh1ich]
Application
===========
Path and name: D:\PROGRAM\xHarBour\BLES_NEW\blessing.exe (32 bits)
Size: 5,936,640 bytes
Time from start: 0 hours 0 mins 37 secs
Error occurred at: 2009/02/03, 11:52:39
Error description: Error ADODB.Connection/0 S_OK: OPEN
Args:
[ 1] = C DRIVER={MySQL ODBC 5.1 Driver};server=127.0.0.1;database=item;uid=users;pwd=s1234;option=3
Stack Calls
===========
Called from: source\rtl\win32ole.prg => TOLEAUTO:OPEN(0)
Called from: \program\xharbour\BLES_NEW\ADORDD.PRG => ADO_OPEN(224)
Called from: => DBUSEAREA(0)
Called from: \program\xharbour\BLES_NEW\TEST_ADO.PRG => ADO_TEST(20)
Called from: \program\xharbour\BLES_NEW\BLESSING.PRG => (b)MAIN(755)
[/quote:18kh1ich]
MYSQL VERSION : mysql-connector-odbc-noinstall-5.1.5-win32
ANYONE HELP ME ?
--
Best Regards
--------------------------------------------------------------
kokoo KAO |
help with adir test | I must found number of file have the header init with a code for sample
0014-test.pdf
[b:2iq3yw6h]my test [/b:2iq3yw6h]
[code=fw:2iq3yw6h]<div class="fw" id="{CB}" style="font-family: monospace;"><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"fivewin.ch"</span><br /><span style="color: #00D7D7;">#include</span> <span style="color: #ff0000;">"constant.ch"</span><br /><br /><span style="color: #00C800;">Function</span> Test<span style="color: #000000;">(</span><span style="color: #000000;">)</span><br /> <span style="color: #00C800;">Local</span> oDlgTest<br /> <span style="color: #00C800;">Local</span> nBottom := <span style="color: #000000;">33</span><br /> <span style="color: #00C800;">Local</span> nRight := <span style="color: #000000;">75</span><br /> <span style="color: #00C800;">Local</span> nWidth := <span style="color: #0000ff;">Max</span><span style="color: #000000;">(</span> nRight * DLG_CHARPIX_W, <span style="color: #000000;">180</span> <span style="color: #000000;">)</span><br /> <span style="color: #00C800;">Local</span> nHeight := nBottom * DLG_CHARPIX_H<br /> <span style="color: #00C800;">local</span> oBtnAllegati<br /><br /> <span style="color: #00C800;">Local</span> cRecord:=<span style="color: #ff0000;">"0014"</span><br /> <span style="color: #00C800;">local</span> cFolderAllegati:=<span style="color: #ff0000;">".<span style="color: #000000;">\d</span>oc<span style="color: #000000;">\"</span><br /> local aAllegati := Array( ADir(cFolderAllegati+ "</span>*.*<span style="color: #ff0000;">" ) )<br /> local nNumeroAllegati := Len( aAllegati )<br /><br /> DEFINE DIALOG oDlgTest ;<br /> TITLE "</span>trying allegati<span style="color: #ff0000;">" ;<br /> SIZE nWidth, nHeight TRANSPARENT PIXEL<br /><br /><br /><br /> @ 10,10 button oBtnAllegati Prompt str(nNumeroAllegati)+"</span>Allegati<span style="color: #ff0000;">" size 100,12 of oDlgTest action NIL<br /><br /><br /><br /> ACTIVATE DIALOG oDlgTest CENTERED<br /><br /> return nil</span></div>[/code:2iq3yw6h]
it count all files on doc folder ( I wish only all initiating with 0014 header)
but on array aAllegati I not see any files
if I made xbrowser aAllegati it is empty |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.